Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    Error with heater monitor number (M143)

    Scheduled Pinned Locked Moved
    General Discussion
    4
    12
    217
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • HeidiHundefined
      HeidiH
      last edited by

      Hi, I am getting error "Error in start-up file macro line 186: in file macro line 186: M143: parameter 'P' too high", which relates to heater monitor number. Also, my active and standby temperatures become -273.1C for all heaters.

      These errors appear when I define in the M143 commands maximum and minimum temperature limits, and I have added Heater monitor numbers 1-3 for my Heaters 1-3. Based on instructions on G-code dictionary, I understood that Heater monitor numbers could be added when monitoring with a specific heater temperature maximum (P0), temperature minimum (P1), and monitor disabled (P2). So, my configuration would look like below:

      ; Creating heaters (https://docs.duet3d.com/User_manual/Reference/Gcodes#m950-create-heater-fan-spindle-or-gpioservo-pin)
      M950 H1 C"out1" Q10 T1 ; Heater 1 
      M950 H2 C"out2" Q10 T2; Heater 2
      M950 H3 C"out3" Q10 T3 ; Heater 3
      
      ; Setting-up Pt100 sensors (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m308-set-or-report-sensor-parameters)
      M308 S1 P"spi.cs0" Y"rtd-max31865" A"Heater 1" U0.080, V-0.0040; includes also correcting factors for sensor reading
      M308 S2 P"spi.cs2" Y"rtd-max31865" A"Heater 2" U0.18, V-0.0088 ; includes also correcting factors for sensor reading
      M308 S3 P"spi.cs1" Y"rtd-max31865" A"Heater 3"
      
      ;Setting-up PID parameters for heaters (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m307-set-or-report-heating-process-parameters)
      M307 H1 R2.921 K0.455:0.000 D2.48 E1.35 S0.55 B0 ; Heater 1
      M307 H2 R5.771 K0.276:0.000 D3.88 E1.35 S0.15 B0 ; Heater 2
      M307 H3 A550 C303.1 S0.3 D15.0 B0 ; Heater 3
      
      ; Setting-up maximum temperatures for heaters (https://docs.duet3d.com/User_manual/Reference/Gcodes#m143-maximum-heater-temperature)
      M143 H1 P0 T1 S250 A0 C0; Heater 1
      M143 H2 P0 T2 S250 A0 C0 ; Heater 2
      M143 H3 P0 T3 S250 A0 C0 ; Heater 3
      
      ; Setting-up minimum temperatures for heaters (https://docs.duet3d.com/User_manual/Reference/Gcodes#m143-maximum-heater-temperature)
      M143 H1 P1 T1 S20 A0 C1; Heater 1
      M143 H2 P1 T2 S20 A0 C1; Heater 2
      M143 H3 P1 T3 S20 A0 C1; Heater 3
      
      ; Setting-up actions when heater monitoring disabled (https://docs.duet3d.com/User_manual/Reference/Gcodes#m143-maximum-heater-temperature)
      M143 H1 P2 T1 S20 A0 C-1; Heater 1
      M143 H2 P2 T2 S20 A0 C-1; Heater 2
      M143 H3 P2 T3 S20 A0 C-1; Heater 3
      
      ; Configuring heater fault detection https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m570-configure-heater-fault-detection
      M570 H1 P2 T10 R2; Heater 1
      M570 H2 P60 T10 R2; Heater 2
      M570 H3 P40 T10 R2; Heater 3
      

      When I don't specify heater numbers, then there does not appear any error.

      Have I understood something incorrectly in the instructions, and how I should change my configuration to have its temperature fault monitoring working for the heaters but not having these errors?

      BR; Heidi

      jay_s_ukundefined 1 Reply Last reply Reply Quote 0
      • jay_s_ukundefined
        jay_s_uk @HeidiH
        last edited by

        @HeidiH S is the maximum temperature permitted. You're setting them to have a maximum of 20 degrees. I suggest you either don't bother messing with it or go back re-read the gcode entry for M143 https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m143-maximum-heater-temperature

        Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

        HeidiHundefined 1 Reply Last reply Reply Quote 0
        • HeidiHundefined
          HeidiH @jay_s_uk
          last edited by

          @jay_s_uk Thank you. I will remove the P heater monitor number away from my code.

          About the temperature limits: I have used the S command to set-up both the minimum (20C) and maximum temperatures for the heaters, because in the M143 in C command it says that I can define that temperature is too low (1) or high (0) with the heater. Based on that I understood that the accepted heater temperature range can be configured between a temperature range minimum and maximum. Did I understand it incorrectly?

          BR, Heidi

          jay_s_ukundefined 1 Reply Last reply Reply Quote 0
          • jay_s_ukundefined
            jay_s_uk @HeidiH
            last edited by

            @HeidiH I'm not sure it works like that, but the document is a little vague on that. But I also don't see a reason why you'd want to be monitoring for a temperature lower than 20 degrees anyway, it's not like the heater circuit can do anything to stop that.

            Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

            HeidiHundefined 1 Reply Last reply Reply Quote 0
            • HeidiHundefined
              HeidiH @jay_s_uk
              last edited by

              @jay_s_uk My aim has been to determine the allowed temperatures for my heaters between 20-250C degrees. I have tried to add this required minimum 20C temperature to ensure that heaters don't start to accidentally start heating when I would have -273C temperature reading, caused by some error.

              However, I tested my minimum temperature limit by setting up the S25 to minimum temperature (current temperature 23C), but this didn't initiate heater fault that I had specified in the M143 command. Based on this, this code doesn't seem to work as I was aiming and I will remove those lines in which I have determined the temperature minima.

              BR, Heidi

              droftartsundefined 1 Reply Last reply Reply Quote 1
              • droftartsundefined
                droftarts administrators @HeidiH
                last edited by droftarts

                @HeidiH You can check what heater monitors are set for a heater by sending, for example, M143 H1 for me shows:

                M143 H1
                Heater 1 monitor 0 is disabled
                Heater 1 monitor 1 uses sensor 1 to generate a heater fault if the reading exceeds 310.0°C
                Heater 1 monitor 2 is disabled
                

                You should be able to set a minimum permitted temperature. I think the word 'maximum' in the M143 S parameter description is not correct. For example, sending M143 H1 C1 S-5 should set the minimum permitted temperature to -5C (-9°C appears to be the minimum).

                M143 H1 P2 ... C-1 just disables that heater monitor if it has previously been set; it does not set up what to do if heater monitoring is disabled.

                EDIT: so if I send what's in your config, I get:

                M143 H1 P0 T1 S250 A0 C0
                M143 H1 P1 T1 S20 A0 C1
                M143 H1 P2 T1 S20 A0 C-1
                M143 H1
                Heater 1 monitor 0 uses sensor 1 to generate a heater fault if the reading exceeds 250.0°C
                Heater 1 monitor 1 uses sensor 1 to generate a heater fault if the reading falls below 20.0°C
                Heater 1 monitor 2 is disabled
                

                I'll check and update the documentation.

                If you still have problems, please post your full config.g so I can see which line is causing the error, and the response to M122 (for firmware version and Duet board).

                Ian

                Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

                HeidiHundefined 1 Reply Last reply Reply Quote 0
                • HeidiHundefined
                  HeidiH @droftarts
                  last edited by HeidiH

                  @droftarts Hi, and thank you for your response. Based on that I modified my config. code now to include also the minimum temperature which triggers the temperature fault. However, I removed the monitor disabled because I don't see any need for having that. Accordingly, I got same information related to how monitors are used for minimum and maximum of Heater 1 as you wrote above. Nevertheless, after I added the minimum temperature monitoring, I still have the erraneous temperatures for the Current and Standby temperatures (-273.1C), while Current temperature sensor reading is OK. When I have only the maximum monitoring defined, this error does not appear.

                  Please, find below my config.g file:

                  ;PRINTER SETTINGS
                  ;
                  ; General preferences
                  M111 S0 ; Debugging off (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m111-set-debug-level)
                  G21 ; Work in millimetres (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#g21-set-units-to-millimeters)
                  G90 ; Send absolute coordinates... (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#g90-set-to-absolute-positioning)
                  M83 ; ...but relative extruder moves (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m83-set-extruder-to-relative-mode)
                  
                  ; Report local date and time (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m905-set-local-date-and-time)
                  M905
                  
                  ; Creating PanelDue2 (https://docs.duet3d.com/User_manual/Reference/Gcodes#m950-create-heater-fan-spindle-or-gpioservo-pin)
                  M950 J0 C"io0.in" ; Creating input for PanelDue
                  
                  ; Enabling PanelDue2 (https://docs.duet3d.com/User_manual/Reference/Gcodes#m575-set-serial-comms-parameters)
                  M575 P1 B57600 S1 ;
                  
                  ;Setting-up firmware compatibility (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m555-set-compatibility)
                  M555 P2 ; firmware compatibility to look like Marlin
                  
                  ; Setting-up device name (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m550-set-name)
                  M550 P"Device"; includes firmware version 
                  
                  ; Enable network (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m552-set-ip-address-enabledisable-network-interface)
                  if {network.interfaces[0].type = "ethernet"}
                      M552 P192.168.1.14 S1
                  else
                      M552 S1
                  
                  ; Additional sensors visualized (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m308-set-or-report-sensor-parameters)
                  M308 S10 Y"mcu-temp" A"MCU"
                  
                  ; Setting-up Z probe (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m558-set-z-probe-type)
                  M558 P0 ; No z probe
                  
                  ;Setting-up Z probe trigger value, offset and trigger height (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#g31-set-or-report-current-probe-status)
                  G31 X-30 Z1.1 P530 ; Not needed?
                  
                  ; Setting-up drives (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m569-set-motor-driver-direction-enable-polarity-mode-and-step-pulse-timing)
                  M569 P0 S0 ; Drive 0 (X motor) goes backwards
                  M569 P1 S0 ; Drive 1 (Y motor) goes forwards
                  M569 P2 S1 ; Drive 2 (Z motor) goes forwards
                  M569 P3 S0 ; Drive 3 (E motor) goes backwards
                  M569 P4 S0 ; Drive 4 (U motor) goes backwards
                  
                  ;Setting-up drive mapping (https://docs.duet3d.com/User_manual/Reference/Gcodes#m584-set-drive-mapping)
                  M584 X0 Y1 Z2 E3 U4;
                  
                  ; Setting-up axis movement restrictions (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m208-set-axis-max-travel)
                  M208 X0 Y0 Z0 S1 ; 
                  M208 X150 Y130 Z100 S0 ; 
                  
                  ; Setting-up endstop configuration (https://docs.duet3d.com/User_manual/Reference/Gcodes#m574-set-endstop-configuration)
                  M574 X1 S1 P"!io1.in" ; Active high endstop switch for low end on X
                  M574 Y1 S1 P"!io2.in" ; Active low endstop switch for low end on Y
                  M574 Z2 S1 P"!io3.in" ; Active high endstop switch for low end on Z 
                  
                  ;Configuring microstepping with interpolation (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m350-set-microstepping-mode)
                  M350 X256 Y256 Z256 E16 U16 I1 ;
                  
                  ;Setting-up steps per mm (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m92-set-axis-steps-per-unit)
                  M92 X6400 Y6400 Z12800 E357 U1600; 
                  
                  ;Setting-up maximum instantaneous speed changes (mm/min) (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m566-set-allowable-instantaneous-speed-change)
                  M566 X10 Y10 Z10 E1200 U7; 
                  
                  ; Setting-up maximum speeds (mm/min) (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m203-set-maximum-feedrate)
                  M203 X600 Y600 Z240 E900 U600; 
                  
                  ; Setting-up accelerations (mm/s^2) (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m201-set-max-acceleration)
                  M201 X60 Y60 Z60 E3000 U200 
                  
                  ; Setting-up motor currents (mA) and motor idle factor in per cent (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m906-set-motor-currents)
                  M906 X759.8 Y759.8 Z759.8 E890.8 U1781.6 I20 
                  
                  ; Allow movement before homing (https://docs.duet3d.com/User_manual/Reference/Gcodes#m564-limit-axes)
                  M564 H0 S1; Allow movement of axes that have not been homed and limited movement within axis boundaries
                  
                  ; Setting-up idle timeout (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m84-stop-idle-hold)
                  M84 S60 ; 60 seconds
                  
                  ; Setting-up Pt100 sensors (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m308-set-or-report-sensor-parameters)
                  M308 S1 P"spi.cs0" Y"rtd-max31865" A"Heater 1" U0.080, V-0.0040; required correcting factors for sensor reading
                  M308 S2 P"spi.cs2" Y"rtd-max31865" A"Heater 2" U0.18, V-0.0088 ; required correcting factors for sensor reading
                  M308 S3 P"spi.cs1" Y"rtd-max31865" A"Heater 3" ; 
                  
                  ; Creating heaters (https://docs.duet3d.com/User_manual/Reference/Gcodes#m950-create-heater-fan-spindle-or-gpioservo-pin)
                  M950 H1 C"out1" Q10 T1 ; Heater 1 
                  M950 H2 C"out2" Q10 T2; Heater 2
                  M950 H3 C"out3" Q10 T3 ; Heater 3
                  
                  ; Setting-up maximum temperatures for heaters (https://docs.duet3d.com/User_manual/Reference/Gcodes#m143-maximum-heater-temperature)
                  M143 H1 P0 T1 S250 A0 C0 ; Heater 1 maximum before heater fault
                  M143 H1 P1 T1 S0 A0 C1 ; Heater 1 minimum before heater fault
                  M143 H2 P0 T2 S250 A0 C0; Heater 2 maximum before heater fault
                  M143 H2 P1 T2 S20 A0 C1; Heater 2 minimum before heater fault
                  M143 H3 P0 T3 S250 A0 C0; Heater 3 maximum before heater fault
                  M143 H3 P1 T3 S20 A0 C1; Heater 3 minimum before heater fault
                  
                  ; Configuring heater fault detection https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m570-configure-heater-fault-detection
                  M570 H1 P2 T10 R2; Heater 1
                  M570 H2 P60 T10 R2; Heater 2
                  M570 H3 P40 T10 R2; Heater 3
                  
                  ;Setting-up PID parameters for heaters (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m307-set-or-report-heating-process-parameters)
                  M307 H1 R2.921 K0.455:0.000 D2.48 E1.35 S0.55 B0 ; Heater 1
                  M307 H2 R5.771 K0.276:0.000 D3.88 E1.35 S0.15 B0 ; Heater 2
                  M307 H3 A550 C303.1 S0.3 D15.0 B0 ; Heater 3 
                  
                  ; Cold extrusion (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m302-allow-cold-extrudes)
                  M302 P1 S120 R110; Allowed from 120 and rectraction from 110
                  
                  ; Setting-up outputs (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m950-create-heater-fan-spindle-led-strip-or-gpioservo-pin)
                  M950 P4 C"out4" ; 
                  M950 P5 C"out5" ; 
                  M950 P7 C"out7" ; 
                  M950 P0 C"out0" ; 
                  M950 P6 C"out6" ; 
                  M950 P11 C"out8" ; 
                  M950 S10 C"out9" ; 
                  
                  ; Setting-up inputs (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m950-create-heater-fan-spindle-led-strip-or-gpioservo-pin)
                  M950 J4 C"io4.in" ; 
                  M950 J6 C"io6.in" ; 
                  M950 J7 C"io7.in" ; 
                  M950 J8 C"io8.in"; 
                  
                  ; Defining tools section (https://docs.duet3d.com/User_manual/Machine_configuration/Configuration_cartesian#tool-definition-section)
                  M563 P1 S"Tool 1" D0 H1 ; Tool 1 uses extruder drive 0 and Heater 1
                  M563 P2 S"Tool 2" H2 ; Tool 2 uses Heater 2, no fan or extruder drive defined
                  M563 P3 S"Tool 3" H3 ; Tool 3 uses Heater 3, no fan or extruder drive defined 
                  
                  ; Setting-up Tool axis offsets (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#g10-tool-temperature-setting)
                  G10 P1 X0 Y0 ; Tool 1
                  G10 P2 X0 Y0 ; Tool 2
                  G10 P3 X0 Y0 ; Tool 3
                  
                  ; Setting-up Tool active and standby temperatures (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m568-set-tool-settings)
                  M568 P1 R0 S0 A0; Set initial tool 1 active and standby temperatures to 0C
                  M568 P2 R0 S0 A0 ; Set initial tool 2 active and standby temperatures to 0C
                  M568 P3 R0 S0 A0 ; Set initial tool 3 active and standby temperatures to 0C
                  
                  ; Tool selecting (https://docs.duet3d.com/en/User_manual/Reference/Gcodes#t-select-tool)
                  T-1 ; deselected all
                  

                  Here is the image of the erraneous Active and standby temperatures: Active and Standby Errors_190125.png

                  Here are the information of Duet firmware and board:
                  1/19/2025, 10:23:06 AM M115
                  FIRMWARE_NAME: RepRapFirmware for Duet 3 MB6HC FIRMWARE_VERSION: 3.5.3 ELECTRONICS: Duet 3 MB6HC v1.01 FIRMWARE_DATE: 2024-09-18 11:27:36

                  BR, Heidi

                  jay_s_ukundefined 1 Reply Last reply Reply Quote 0
                  • jay_s_ukundefined
                    jay_s_uk @HeidiH
                    last edited by

                    @HeidiH -273.1 is the usual way to turn a heater off without deactivating the tool

                    Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

                    HeidiHundefined 1 Reply Last reply Reply Quote 0
                    • HeidiHundefined
                      HeidiH @jay_s_uk
                      last edited by

                      @jay_s_uk Thanks. Does this mean that my Heater temperatures on Active and Standby should look like in above image, when the tools are off?

                      Before, I have had those Active and Standby temperatures as 0C, like I have defined in those values in lines 139-141 of my attached code?

                      BR, Heidi

                      T3P3Tonyundefined 1 Reply Last reply Reply Quote 0
                      • T3P3Tonyundefined
                        T3P3Tony administrators @HeidiH
                        last edited by

                        @HeidiH

                        Those temperatures need to be set to 0 to read 0.. I they are -273.1 that means they are on the "default" settings.

                        I see in your config.g there are the commands for setting them:

                        M568 P1 R0 S0 A0; Set initial tool 1 active and standby temperatures to 0C
                        M568 P2 R0 S0 A0 ; Set initial tool 2 active and standby temperatures to 0C
                        M568 P3 R0 S0 A0 ; Set initial tool 3 active and standby temperatures to 0C
                        

                        So that should be setting them

                        Please can you run M98 P"0:/sys/config.g" and see if you get any errors. It could be those commands are not being run due to an error earlier in your config.g

                        If that's not the issue then try sending them manually from the console to see what happens. I tested that they were valid and worked in my config.g in 3.6beta3 but you are running 3.5.3/

                        www.duet3d.com

                        HeidiHundefined 1 Reply Last reply Reply Quote 0
                        • HeidiHundefined
                          HeidiH @T3P3Tony
                          last edited by

                          @T3P3Tony Hi, and thank you for your response. I tested your advice and got the following warnings and errors:

                          1/22/2025, 12:06:31 PM	M98 P"0:/sys/config.g"
                          Current date and time: 2025-01-22 12:06:29
                          Warning: Heater 1 predicted maximum temperature at full power is 421°C
                          Warning: Heater 2 predicted maximum temperature at full power is 975°C
                          Warning: Heater 3 predicted maximum temperature at full power is 574°C
                          Error: M568: Requested temperature out of range
                          Error: M568: Requested temperature out of range
                          Error: M568: Requested temperature out of range
                          

                          Those M568 errors are related to setting-up the heaters off, and also determining the active and standby temperatures to 0C, as indicated in above. What could cause the error?

                          BR, Heidi

                          droftartsundefined 1 Reply Last reply Reply Quote 0
                          • droftartsundefined
                            droftarts administrators @HeidiH
                            last edited by

                            @HeidiH Possibly because you are setting the target temperature that is outside the allowed limits of the heater? ie you're setting 0C, but the heater temperature range set by M143 as 20 to 250.

                            Ian

                            Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

                            1 Reply Last reply Reply Quote 0
                            • First post
                              Last post
                            Unless otherwise noted, all forum content is licensed under CC-BY-SA