Using multiple heaters with Thermocouple Daughterboard (J Type)
-
Hi, I'm using a Duet 3 Mini 5+ and I'm connecting 2 J-type thermocouples to the Thermocouple Daughterboard (thermocouple-max31856) and I'm running into a few issues:
- heaters aren't behaving as they should:
- not heating up at the same time (Heater 1 displaying 'fault' when Heater 2 displays 'active' and vice versa)
- overshooting allowed temperature on Heater 2 only (Heater 1 seems to follow the set temperature max correctly)
- We don't use or define Heater 0, however, console error messages often display: 'Heater 0 fault'
Could someone have a look at the config.g file for any syntax or logic errors that may be causing the above issues?
Additionally, if there are any hardware/wiring considerations which may also be problematic. I've confirmed that the wiring polarity is correct. For example, Heater 1 is reading out expected temperatures, but only when it is the only active heater.
; Configuration file for Duet 3 Mini 5+ (firmware version 3.3) ; executed by the firmware on start-up ; ; generated by RepRapFirmware Configuration Tool v3.3.16 on Sat Apr 15 2023 14:54:17 GMT-0400 (Eastern Daylight Time) ; General preferences G90 ; send absolute coordinates... M83 ; ...but relative extruder moves M550 P"Morphotonics" ; set printer name M669 K1 ; select CoreXY mode ; Network M552 S1 ; enable network M586 P0 S1 ; enable HTTP M586 P1 S0 ; disable FTP M586 P2 S0 ; disable Telnet ; Drives M569 P0.0 S0 ; physical drive 0.0 goes backwards M569 P0.1 S0 ; physical drive 0.1 goes backwards M569 P0.2 S1 ; physical drive 0.2 goes 0 to - M569 P0.3 S1 ; physical drive 0.3 goes 0 to - M569 P0.4 S0 ; physical drive 0.4 goes 0 to - M569 P0.5 S1 ; physical drive 0.5 goes forwards M569 P0.6 S1 ; physical drive 0.5 goes forwards M584 X0.0 Y0.1 Z0.2:0.3:0.4 E0.5 U0.6 ; set drive mapping M350 X16 Y16 Z16 E16 I1 U16 ; configure microstepping with interpolation M92 X80.00 Y80.00 Z80.00 E80.00 U80.00 ; set steps per mm M566 X900.00 Y900.00 Z24.00 E24.00 U24.00 ; set maximum instantaneous speed changes (mm/min) M203 X9000.00 Y9000.00 Z600.00 E900.00 U150.00 ; set maximum speeds (mm/min) M201 X250.00 Y250.00 Z50.00 E50.00 U50.00 ; set accelerations (mm/s^2) M906 X800 Y800 Z800 E800 I50 U800 ; set motor currents (mA) and motor idle factor in per cent M84 S30 ; Set idle timeout ; Axis Limits M208 X0 Y0 Z0 E0 U0 S1 ; set axis minima M208 X250 Y188 Z240 E1000000 U1000000 S0 ; set axis maxima ; Endstops M574 X1 S1 P"io0.in" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin io0.in M574 Y2 S1 P"io1.in" ; configure switch-type (e.g. microswitch) endstop for high end on Y via pin io1.in M564 U6 H0 ;M574 Z1 S1 P"io2.in" ; configure switch-type (e.g. microswitch) endstop for low end on Z via pin io2.in ; Z-Probe M950 S0 C"io3.out" ; Duet 3 Mini 5+ M558 P9 C"io3.in" H5 F120 T6000 ; Duet 3 Mini 5+ G31 X-20 Y0 Z6.7 P25 ; trigger height 6.7 (change it later when recalibrating with nozzle in place) M671 X20:140:220 Y0:188:0 ; Heaters M308 S1 P"spi.cs1" Y"thermocouple-max31856" K"J" ; configure sensor 1 as J-type thermocouple via CS pin spi.cs1 M950 H1 C"out2" T1 ; heater 1 uses the out2 pin, sensor 1 M307 H1 B0 S1.00 ; disable bang-bang mode for heater and set PWM limit ; M303 H1 P1 S50 ; tune heater 1 using 100% PWM, target temperature 50C M143 H1 S50 ; set temperature limit for heater 1 to 50C M308 S2 P"spi.cs2" Y"thermocouple-max31856" K"J" ; configure sensor 1 as J-type thermocouple via CS pin spi.cs1 M950 H2 C"out1" T2 ; heater 1 uses the out2 pin, sensor 2 M307 H2 B0 S1.00 ; disable bang-bang mode for heater and set PWM limit ; M303 H1 P1 S50 ; tune heater 1 using 100% PWM, target temperature 50C M143 H2 S50 ; set temperature limit for heater 1 to 50C ; Fans ; 2-wire fans, normally controlled and thermostatic M950 F0 C"out5" Q5000 ; create fan 0 on pin out5 and set its frequency M950 F1 C"out6" Q5000 ; create fan 1 on pin out6 and set its frequency M950 F2 C"out3" Q5000 ; create fan 2 on pin out3 and set its frequency ; Tools M563 P0 S"Syringe Pump" D0 H1:2 F0:1:2 ; 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
-
-
@ozgunkilicafsar did things work normally using thermistors, before you got the daughterboard?
here is my heater config if it helps. but i use thermistors for my heaters, but i do use the thermocouple daughterboard but i dont link them to any heaters for my setup.
; General preferences G90 ; send absolute coordinates... M83 ; ...but relative extruder moves M550 P"V-Core3" ; set printer name M669 K11 Y1:-1:0:-1 ; Dual Markforged Kinematics https://forum.duet3d.com/topic/7796/haq-xy/125 https://forum.duet3d.com/topic/21021/dual-markforged-kinematics?_=1672244913067 ;M669 K1 X1:0:0:0 Y1:-1:0:-1 Z0:0:1:0 U0:0:0:1 ; Matrix mapping for Axis - X:Y:Z:U ;M669 X1:0:0:0 Y1:-1:0:-1 Z0:0:1:0 U0:0:0:1 ; Matrix mapping for Axis - X:Y:Z:U G21 ; Set Units to Millimeters ; Network M552 S2 ; enable network, note P0.0.0.0 sets auto DHCP M553 P255.255.255.0 ; set subnet mask M554 P192.168.1.20 ; set gateway M586 P0 S1 ; enable HTTP M586 P1 S0 ; disable FTP M586 P2 S0 ; disable Telnet G4 S2 ; wait for expansion boards to start ; Drives M569 P0.0 S0 D2 ; Left Z physical drive 0.0 goes forwards M569 P0.1 S0 D2 ; Rear Z physical drive 0.1 goes forwards M569 P0.2 S0 D2 ; Right Z physical drive 0.2 goes forwards M569 P0.3 S1 D2 ; Right U toolhead drive 0.3 goes forwards M569 P0.4 S1 D2 ; Left X toolhead drive 0.4 goes forwards M569 P0.5 S0 D2 ; Left Y drive 0.5 goes forwards M569 P0.6 S1 D2 ; Right Y drive 0.6 goes reverse M569 P20.0 S1 D2 ; Extruder physical drive 20.0 goes forwards Toolboard 1LC M569 P21.0 S1 D2 ; Extruder physical drive 21.0 goes forwards Toolboard 1LC M569 P1.0 S0 D2 ; Extruder physical drive 1.0 goes forwards Expansion 3HC M569 P1.1 S0 D2 ; Extruder physical drive 1.1 goes forwards Expansion 3HC M569 P1.2 S1 D2 ; Extruder physical drive 1.2 goes forwards Expansion 3HC M584 Z0.0:0.1:0.2 Y0.5:0.6 X0.4 U0.3 E20.0:21.0:1.0:1.1 ; set drive mapping M350 U16 X16 Y16 Z16 E16:16:16:16 I1 ; configure microstepping with interpolation M92 U80.0 X80.00 Y80.00 Z800.00 E690:690:690:690 ; set steps per mm M906 U2000 X2000 Y2000 Z1800 E1000:1000:1000:1000 I30 ; set motor currents (mA) and motor idle factor in per cent -- safe for Duet 3 mini 5+ M84 S30 ; Set idle timeout ;M98 P"0:/sys/setspeeds.g" ; Set speed and acceleration M566 U500.00 X500.00 Y500.00 Z60.00 E300:300:300:300 P1 ;E300:300 P1 ;X1500.00 Y1500.00 Z6.00 E300 P1 ;E120.00 P1 ; set maximum instantaneous speed changes (mm/min) M203 U30000.00 X30000.00 Y30000.00 Z1000.00 E7200:7200:7200:7200 ;E7200:3600 ;E3600.00 ; set maximum speeds (mm/min) M201 U10000.00 X10000.00 Y10000.00 Z100.00 E10000:10000:10000:10000 ;E10000:3600 ;E3600.00 ; set accelerations (mm/s^2) M207 S0.6 F7200 Z0.2 ; firmware retraction orbiter 2.0 ; Axis Limits M208 X-70 U0 Y0 Z0 S1 ; set axis minima M208 X300 U380 Y306 Z300 S0 ; X310 ; set axis maxima ;M208 X-70:310 Y0:308 U0:308 Z0:300 ; Endstops M574 X1 S1 P"20.io2.in" ; configure active high endstops Toolhead 1 X low end M574 U2 S1 P"21.io2.in" ; configure active high endstops Toolhead 2 U high end M574 Y2 S1 P"io2.in" ; configure active high endstops Y. IO0 and IO1 also are UART, so do not put endstops on them, use them elsewhere to free up UART. M574 Z1 S2 M671 X-71:155:381 Y-1.5:305:-1.5 S5 ; NEW WIDEBOI WITH EXTRUSION SUPPORT LEADSCREW POSITIONS define positions of Z leadscrews or bed levelling screws ;M671 X-4.5:155:304.5 Y-4.5:305:-4.5 S5 ; OLD NON-WIDEBOI EXTRUION SUPPORT LEADSCREW POSITIONS define positions of Z leadscrews or bed levelling screws ;M557 X30:280 Y20:300 P5 ; define 5x5 mesh grid M557 X30:270 Y20:270 P5 ; Heaters M308 S0 P"temp0" Y"thermistor" T100000 B3950 A"Keenevo 600W Bed" ; configure sensor 0 as thermistor on pin temp0 M950 H0 C"out0" T0 Q10 ; Define Heater0 as the heated bed, bind to Sensor0 M140 H0 P0 ; Define Heated Bed M307 H0 R0.602 K0.401:0.000 D2.44 E1.35 S1.00 B0 ; PID Tuning for Heater0, Heated Bed (100C) M143 H0 S140 T0 A0 ; Set temperature limit for Heater0 to 120C M308 S1 P"20.temp0" Y"thermistor" T100000 B4725 C7.060000e-8 A"Slice Hotend 0" ;Slice Engineering 300C thermistor, settings are online M950 H1 C"20.out0" T1 Q100 ; Define Heater1 as Extruder0 heater, bind to Sensor1 M307 H1 R2.808 K0.368:0.000 D4.56 E1.35 S1.00 B0 V23.8 ; PID Tuning for Heater1, Extruder0 (240C) M143 H1 S325 T1 A0 ; Set temperature limit for heater 1 to 285C M308 S2 P"temp1" Y"thermistor" T100000 B3950 C7.060000e-8 A"Chamber" ; configure sensor 2 as thermistor on pin temp1 M950 H2 C"out1" T2 ;Q10 ; create chamber heater output on out1 and map it to sensor 2 M307 H2 R0.01 K0.200:0.000 D60 E1.35 S1.00 B1 ; enable bang-bang mode for the chamber heater and set PWM limit M141 H2 ; map chamber to heater 2 M143 H2 S120 T2 A0 ; set temperature limit for heater 2 to 60C M308 S3 P"21.temp0" Y"pt1000" A"Slice Hotend 1" ;Slice Engineering RTD PT1000 450C, settings are online M950 H3 C"21.out0" T3 Q100 ; Define Heater1 as Extruder0 heater, bind to Sensor1 M307 H3 R2.808 K0.368:0.000 D4.56 E1.35 S1.00 B0 V23.8 ; PID Tuning for Heater1, Extruder0 (240C) M143 H3 S425 T3 A0 ; S325 ; Set temperature limit for heater 1 to 285C M308 S4 P"20.temp1" Y"thermistor" A"Cooling Block" T100000 B3950 C7.060000e-8 ; Define Sensor as Chamber temperature M308 S5 Y"drivers" A"4028 Power" ; 4028 power using spare heater M308 S6 Y"mcu-temp" A"Mini 5+ MCU" ; Define Sensor3 as the integrated MCU temperature sensor M308 S7 Y"drivers" A"Mini 5+ TMC Drivers" ; Define Sensor4 as the TMC overheat sensor M308 S8 Y"mcu-temp" P"20.dummy" A"Toolboard0 MCU" M308 S9 Y"drivers" P"20.dummy" A"1LC0 Stepper" M308 S10 Y"mcu-temp" P"21.dummy" A"Toolboard1 MCU" M308 S11 Y"drivers" P"21.dummy" A"1LC1 Stepper" M308 S12 Y"mcu-temp" P"1.dummy" A"3HC MCU" M308 S13 Y"drivers" P"1.dummy" A"3HC TMC Drivers" M308 S14 P"temp2" Y"thermistor" T100000 B3950 C7.060000e-8 A"Orbiter Motor" ; configure sensor 9 as thermistor on pin temp2 M308 S15 P"spi.cs1" Y"thermocouple-max31856" K"K" A"TC0 Chamber Heater"; define temperature sensor number 10 as a K Type thermocouple on the first port of a temperature daughter board plugged into the expansion board with CAN bus address 3. M308 S16 P"spi.cs2" Y"thermocouple-max31856" K"K" A"TC1 Chamber Fins"; define temperature sensor number11 as a T Type thermocouple on the first port of a temperature daughter board plugged into the expansion board with CAN bus address 3. ;M308 S17 P"21.temp1" Y"thermistor" T4500000 B5315 C3.219245e-9 A"BLUE MELLOW" ; blue Mellow high temp thermistor (toolboard)https://duet3d.dozuki.com/Wiki/Connecting_thermistors_or_PT1000_temperature_sensors#Section_RepRapFirmware_3_x ;M308 S17 P"21.temp1" Y"pt1000" T500000 B4666 C1.117125e-7 A"WHITE MELLOW" ; white Mellow high temp pt1000 (toolboard)https://duet3d.dozuki.com/Wiki/Connecting_thermistors_or_PT1000_temperature_sensors#Section_RepRapFirmware_3_x ; Fans M950 H4 C"!out2" T2 Q10 ;H2 ; Define Heater2 as the 4028 fan power, bind to Sensor3 M143 H4 P2 S200 A0 ; Needed M143 to set max temp so the graph scaled correctly M950 F0 C"!20.out1+out1.tach" Q25000 ;Q500 ; create fan 0 on pin out4 and set its frequency M106 P0 C"T0 Layer Fan" L0.0 X1.0 S0 H-1 B0.1 ; set fan 0 name and value. Thermostatic control is turned off M950 F1 C"20.out2+out2.tach" Q500 ; Fan 1 uses out3, and using out3.tach as a tacho input M106 P1 C"T0 Hotend Fan" S0 H1 T45 ; For M106 the H is sensor # and NOT heater #. set fan 1 name and value. Thermostatic control turned on for Hotend M950 F2 C"out5" Q500 ; create fan 1 on pin out5 and set its frequency M106 P2 C"Mini 5+ Board Fan" S0 H5:6:7 T45 ; set fan 1 name and value. Thermostatic control turned on for Hotend M950 F3 C"!out3+out3.tach" Q25000 ; Q500 ; Chamber Heater Fan Noctua NF-F12 Industrial M106 P3 C"Chamber Heater Fan" H15 T30 ; H15 S0.3 L0.3 X0.6 B0.1 T30:40 ; set fan 1 name and value. Thermostatic control turned on for Hotend. M950 F4 C"1.out3" Q500 ; ; out6 on old mini 5+ ; create fan 4 for Water Cooling 12V Fan 4 on pin out4 and set its frequency M106 P4 C"Radiator Cooling Fan" S0 H4 T35 ; set fan 1 name and value. Thermostatic control turned on for liquid cooling hotend M950 F5 C"!out4+out4.tach" Q25000 ;Q500 ; create fan 4 for Water Cooling 12V Fan 4 on pin out4 and set its frequency M106 P5 C"Liquid Cooling Pump" L0.0 X1.0 S0.5 H4 ;S0.0 T20 ; set fan 4 name and value. Thermostatic control turned on for liquid cooling hotend M950 F6 C"!21.out1+out1.tach" Q25000 ;Q500 ; create fan 6 on pin out4 and set its frequency M106 P6 C"T1 Layer Fan" L0.0 X1.0 S0 H-1 B0.1 ; set fan 6 name and value. Thermostatic control is turned off M950 F7 C"21.out2+out2.tach" Q500 ; Fan 7 uses out3, and using out3.tach as a tacho input M106 P7 C"T1 Hotend Fan" S0 H3 T45 ; set fan 7 name and value. Thermostatic control turned on for Hotend M950 F8 C"1.out6" Q500 ; create fan 1 on pin out5 and set its frequency M106 P8 C"3HC Board Fan" S0 H12:13 T45 ; set fan 1 name and value. Thermostatic control turned on for Hotend M950 F9 C"!1.out4+out4.tach" Q25000 ;Q500 4028 filter fan ; create fan 0 on pin out4 and set its frequency M106 P9 C"Testing Chamber Fan" H-1 T30 ; Tool 0 X Axis M563 P0 D0 H1 X0 F0 S"Mosquito Mag Liquid" ; define tool 0 G10 P0 X0 Y0 Z-0.54 ; Z-0.54 S210 R175 ; set tool 0 axis offsets, set initial tool 0 active 60C and standby temperatures to 0C M568 P0 S210 R175 ; Tool 1 U Axis M563 P1 D1 H3 X3 F6 S"Mosquito Mag Air" ; define tool 0 G10 P1 U0 X0 Y0 Z0 ; S210 R175 ; L1 ; set tool 1 axis offsets, set initial tool 1 active 60C and standby temperatures to 0C M568 P1 S210 R175 ; Tool 2-- Toolhead 2 with ROME 1 M563 P2 D1:2 H3 X3 F6 S"ROME 1" ; tool 2 uses both extruders and hot end heaters, maps X to both X and U, and uses both print cooling fans G10 P2 U-2.31 X0 Y0.24 Z0.00 ; Z0.04 S210 R175 ; L1 ; set tool 0 axis offsets, set initial tool 0 active 60C and standby temperatures to 0C M567 P2 E1:1 ; set mix ratio 100% on both extruders for copy mode M568 P2 S210 R175 ; Tool 3-- Toolhead 2 with ROME 2 M563 P3 D1:3 H3 X3 F6 S"ROME 2" ; tool 2 uses both extruders and hot end heaters, maps X to both X and U, and uses both print cooling fans G10 P3 U-2.31 X0 Y0.24 Z0.00 ; Z0.04 S210 R175 ; L1 ; set tool 0 axis offsets, set initial tool 0 active 60C and standby temperatures to 0C M567 P3 E1:1 ; set mix ratio 100% on both extruders for copy mode M568 P3 S210 R175 ; Tool 4-- copy mode ;M563 P4 D0:1 H1:3 X0:3 F0:6 S"copy mode" ; tool 2 uses both extruders and hot end heaters, maps X to both X and U, and uses both print cooling fans ;G10 P4 U-77.5 X77.5 Y0 S210 R175 ; set tool offsets and temperatures for tool 2 ;M567 P4 E1:1 ; set mix ratio 100% on both extruders for copy mode ; Tool 5-- mirror mode ;M563 P5 D0:1 H1:3 X0:3 F0:6 S"mirror mode" ; tool for mirror mode ;G10 P5 U-77.5 X77.5 Y0 S210 R175 ; tool offset for mirror mode (flipped X offset) ;M567 P5 E1:1 ; set mix ratio 100% on both extruders for mirror mode ; Z-Probe Euclid Probe ;M558 P5 C"20.io0.in" H5 F400 T5000 ; set Z probe type to unmodulated and the dive height + speeds M558 P8 C"^20.io0.in" H8 F400 T9000 A1 ; S0.01 ; set Z probe type to unmodulated and the dive height + speeds G31 P1000 X-28 Y-20 Z9.71 ; Z9.21 ; K0 ; set Z probe trigger value, offset and trigger height, more Z means closer to the bed ;; BLTouch ; M950 S0 C"io7.out" ; Create a servo pin on io7 ; M558 P9 C"io7.in" H5 F240 T10800 A5 ; set Z probe type to unmodulated and the dive height + speeds ; G31 P25 X-28.00 Y-13.00 Z0.78 ; set Z probe trigger value, offset and trigger height, more Z means closer to the bed ;Accelerometer M955 P20.0 I14 ;Input Shaper M593 P"zvdd" F31 ; for 10k acceleration ;M593 P"mzv" F42.5 ; for 15k acceleration ;Filament Sensor0 ;M591 D0 P3 C"20.io1.in" S1 ;M591 D0 L27 R10:190 ;ROME Filament Sensor0 ;M591 D2 P1 C"21.io0.in" S1 ;M591 D2 L27 R10:190 ;M574 U2 S1 P"21.io0.in" ; configure active high endstops Toolhead 2 ROME toolhead filament sensor ;M577 wait until endstop is triggered. Does equivalent exist for a general IO sensor? M950 J0 C"^!21.io0.in" ;PanelDue 5i M575 P1 S1 B57600 ;NeoPixels x3 M150 X3 Q4000000 ;R128 U128 B128 P128 S2 F0 M150 X3 R255 U255 B255 W255 P255 S2 F0 ; display led ; Custom settings G29 S1 M572 D0:1:2:3 S0.045 ; set Pressure Advance K-factor M501 M376 H3 ;M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss global daemonLoop = true ; init filament sensor error global variables if !exists(global.filamentTimestamp) global filamentCounter = 0 global filamentTimestamp = state.Uptime ; init print time logging if !exists(global.runtime) M98 P"runtime.g" ; init LED variables if !exists(global.warmUp) global warmUp = false ; Select default tool M404 N1.75 ; Define filament diameter for print monitor T0
-
@ozgunkilicafsar said in Using multiple heaters with Thermocouple Daughterboard (J Type):
not heating up at the same time (Heater 1 displaying 'fault' when Heater 2 displays 'active' and vice versa)
What happens to the temperature of one when the other is active? To me it sounds like there may be interference between the two.
It looks like you haven't tuned either heater; they are both set to M307 H1 (or H2) B0 S1.00, which is the default. RRF needs an accurate model of how the heater behaves, so it knows if there is a heater problem. For tuning, see https://docs.duet3d.com/en/How_to_guides/Commissioning#h-7-tune-heaters
Also see https://docs.duet3d.com/en/User_manual/Troubleshooting/Heater_faultsovershooting allowed temperature on Heater 2 only (Heater 1 seems to follow the set temperature max correctly)
By how much does heater 2 overshoot? If the excursion is less than 5 seconds, or for less than 15 seconds (these are set by M570), no heater fault will be raised. Again, tuning the heaters should help.
We don't use or define Heater 0, however, console error messages often display: 'Heater 0 fault'
Send
M950 H0
to see how that heater is defined. It may be defined by default, though I don't think it is. What version of RRF are you using? Send M115 and post reply. Also sendM98 p"config.g"
and post the response. It may be something is trying to turn heater 0 on, and you get a fault because it is not found.Ian
-
@droftarts said in Using multiple heaters with Thermocouple Daughterboard (J Type):
Thank you very much for the detailed response @droftarts, I definitely did not tune the heaters so I'll get on with that.
Before that, to rule out H0 errors, I followed your suggestions and sent M950 H0 and got the message below, indicating that it's not defined (since I don't use heater 0):
Also sent M98 p"config.g" and the response is as below:
Is there a way to eliminate getting these error messages?
After resolving this, I'll go forward with heater tuning for H1 and H2.
-
@ozgunkilicafsar Can you post what firmware version you are using? Send M115 and post reply. Also check that you are using the same version of DWC as RRF.
Ian
-
@droftarts Totally right, I'm using DWC 3.4.0 while RRF 3.3. I'll update the RRF to match DWC and check again. Thanks a lot!