Pulsing fans and PID tuning Q



  • 1] I have an interesting problem with my fans ATM. My board cooling and extruder fan are tied together, when 60c is triggered only the top board cooling fan is coming on. I had to manually override the extruder fan. It came on and ran until the extruder was below 60c and shut off.
    ; Fans
    M106 P0 S0 H1 T60 F500 ; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned on
    M106 P1 S0 I0 F500 H-1 ; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned off
    M106 P2 S0 I0 F500 H-1 ; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned off

    2] Also at anything less than 100% fan they pulse. they are oscillating the speed up and down. This was not the case with the previous board. They are 24v fans if that makes a difference.

    3] If my extruder heater is on E0 then PID, what is the bed. How do I differentiate between the two.

    4] I read about the M307 and the 2 sets of parameters. I'm not sure about the work flow here. Do I want to set an M301 first, then run M303 as usual, then save with M500?


  • administrators

    1. Please explain what you mean. Do you mean that you have an electronics cooling fan and the hot end heatsink fan wired in parallel?

    It's normal to connect the print cooling fan to the Fan 0 output, because that is the one that M106 commands with no P parameter that are generated by your slicer will control by default.

    2. Try changing the PWM frequency, which is the F parameter in the M106 command.

    3. The bed heater is heater 0, E0 heater is heater 1, E1 is heater 2 and so on.

    4. You don't need to use M301. The two sets of parameters are computed from the M307 parameters, which are determined by auto tuning and can be saved using M500.



  • 1. Yes they are wired in parallel on FAN0, I was trying to map FAN2 but it kept turning on print cooling fan. The configuration before this one looked teh same except that FAN0 and FAN2 were reversed.
    2. is this what the 255 I usually see in a config is? always wondered why it wasn't to 100. This won't be hard to test out.
    3. & 4. I figured these two out out, but left them up incase someone else had the same trouble.


  • administrators

    2. You can use values in the range 0.0-1.0 or in the range 1.01-255 to represent fully off to fully on. The 0-255 range is a hangover from Arduino firmware development.



  • Why do all my fans run at 100% on start up? they are the same as above only the F value is changed to 255 to quell the pulsing.


  • administrators

    They shouldn't. Immediately after power up, Fan 1 should be running (we designed it that way because Fan 1 is typically used to control a thermostatic hot end fan), but Fan 0 and Fan 2 should be off. If you are using these commands in config.g:

    M106 P0 S0 H1 T60 F255 ; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned on
    M106 P1 S0 I0 F255 H-1 ; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned off
    M106 P2 S0 I0 F255 H-1 ; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned off

    then after config.g is run, fan 0 should be off unless the hot end temperature is 60C or higher, and fans 1 and 2 should be off.

    Please confirm what type of Duet you are using. If a Duet 0.6 is mistakenly identified as a 0.8.5 or vice versa, that would cause the fan PWM to operate in reverse.

    Perhaps you have some other commands in config,g that are affecting the fans?



  • Its an Ethernet model.

    This is how it is set now:
    M106 P0 S1 I0 F255 H-1; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off (print cooling)
    M106 P1 S1 I0 F255 H1 T45; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned on (extruder)
    ;M106 P2 S1 I0 F255 H-1; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned off (none)

    When I just started it up, all the fans came on, the print cooling fan is still running. It never shuts off. Even using the sliders and the override in the DWC, it won't stop, or even slow down.



  • ; Configuration file for Duet Ethernet (firmware version 1.17)
    ; executed by the firmware on start-up
    ;
    ; generated by RepRapFirmware Configuration Tool on Mon May 22 2017 22:56:20 GMT-0400 (Eastern Daylight Time)

    ; Network
    M550 PGODZILLA ; Set machine name
    M540 PBE:EF:DE:AD:FE:ED ; Set MAC address
    M552 P192.168.1.149 S1 ; Enable network and acquire dynamic address via DHCP
    M586 P0 S1 ; Enable HTTP
    M586 P1 S0 ; Disable FTP
    M586 P2 S0 ; Disable Telnet

    ; General preferences
    M111 S0 ; Debugging off
    G21 ; Work in millimetres
    G90 ; Send absolute coordinates…
    M83 ; ...but relative extruder moves
    M555 P1 ; Set firmware compatibility to look like RepRapFirmare
    M665 R157 L397.1073 B175 H510 ; Set delta radius, diagonal rod length, printable radius and homed height
    M666 X0 Y0 Z0 ; Put your endstop adjustments here, or let auto calibration find them
    M208 Z0 S1 ; Set minimum Z

    ; Endstops
    M574 X2 Y2 Z2 S1 ; Define active high microswitches
    M558 P1 X0 Y0 Z0 H5 F120 T6000 ; Set Z probe type to unmodulated, the axes for which it is used and the probe + travel speeds
    M557 R130 S20 ; Define mesh grid

    ; BL-Touch
    M307 H3 A-1 C-1 D-1 ; reserve pin 21 for M42 or servo use
    M558 P4 X0 Y0 Z1 H20 F200 T5000
    G31 P25 X0 Y0 Z0.64 ; Set Z probe trigger value, offset and trigger height

    ; Drives
    M569 P0 S0 ; Drive 0 goes forwards
    M569 P1 S0 ; Drive 1 goes forwards
    M569 P2 S0 ; Drive 2 goes forwards
    M569 P3 S0 ; Drive 3 goes forwards
    M350 E32 I0 ; Configure microstepping without interpolation
    M350 X32 Y32 Z32 I1 ; Configure microstepping with interpolation
    M92 X160 Y160 Z160 E790 ; Set steps per mm
    M566 X1200 Y1200 Z1200 E3000 ; Set maximum instantaneous speed changes (mm/min)
    M203 X39960 Y39960 Z39960 E3000 ; Set maximum speeds (mm/min)
    M201 X1000 Y1000 Z1000 E1500 ; Set accelerations (mm/s^2)
    M906 X950 Y950 Z950 E950 I30 ; Set motor currents (mA) and motor idle factor in per cent
    M84 S30 ; Set idle timeout

    ; Heaters
    M143 S285 ; Set maximum heater temperature to 285C
    M301 H0 S1.00 P10 I0.1 D200 T0.4 W180 B30 ; Use PID on bed heater (may require further tuning)
    M305 P0 T100000 B4607 C8.950070e-8 R4700 ; Set thermistor + ADC parameters for heater 0
    M305 P1 T100000 B4138 C0 R4700 ; Set thermistor + ADC parameters for heater 1

    ; Tools
    M563 P0 D0 H1 f0 ; Define tool 0
    G10 P0 X0 Y0 Z0 ; Set tool 0 axis offsets
    G10 P0 R0 S0 ; Set initial tool 0 active and standby temperatures to 0C

    ; Fans
    M106 P0 S1 I0 F255 H-1; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off
    M106 P1 S1 I0 F255 H1 T45; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned on
    M106 P2 S1 I0 F255 H-1; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned off

    ; Miscellaneous
    M501 ; Load saved parameters from non-volatile memory


  • administrators

    @Cinpro:

    Its an Ethernet model.

    This is how it is set now:
    M106 P0 S1 I0 F255 H-1; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off (print cooling)
    M106 P1 S1 I0 F255 H1 T45; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned on (extruder)
    ;M106 P2 S1 I0 F255 H-1; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned off (none)

    When I just started it up, all the fans came on, the print cooling fan is still running. It never shuts off. Even using the sliders and the override in the DWC, it won't stop, or even slow down.

    S1 means turn the fan fully on. But the sliders in DWC should work. I wonder whether you had a short and blew the Fan0 mosfet? What happens if you replace S1 by S0?



  • starting a print, the fans go off. the extruder fan comes on, but at very low power, when the temp trigger is reached and I have to manually turn it up. the print cooling fan comes on when its supposed to


  • administrators

    Keep S1 in the M106 P1 command, because that defines the PWM for that fan when the temp trigger is reached. Use S0 for the other fans to have them off at startup.



  • TA DA! Taht fixed it, thank you very much. I'm getting there. A littler slower than I want, but I'm getting there. Thank you for your help


Locked
 

Looks like your connection to Duet3D was lost, please wait while we try to reconnect.