SAFETY ISSUE TEMP CONTROL!!!!!! MIN_DEFECT_TEMPERATURE >0 not working correct

Hi,

i'v got a strange problem with my ramps:

using for my HeatBed Thermistor100K Honeywell 135-...
But The firmware shows only 0° IF i do NOT connect the  thermistor. First i tought ok, well, MIN_DEFECT_TEMPERATURE is set to -10° so it looks like it is ok for the firmware. 
So i set MIN_DEFECT_TEMPERATURE to 10° but it did not report the sensor as defective.
Why not?
I messed around  little bit. Set the thermistor for the hotend to 100K NTC 3950 and the firmware reports -178.4° if i do not connect the thermistor. But as long as the MIN_DEFECT_TEMPERATURE is set to >=0 the firmware won't detect the not connected thermistor.

So
problem nr.1: MIN_DEFECT_TEMPERATURE >=0 won't trigger a not connected thermistor
problem nr.2: Thermistor type 100K Honeywell 135-.. report 0° temp on a not connected thermistor.

Can you verify/reproduce this?

Comments

  • I think here is the Problem:
    // Check for obvious sensor errors
    if((act->currentTemperatureC < MIN_DEFECT_TEMPERATURE || act->currentTemperatureC > MAX_DEFECT_TEMPERATURE) &&
    act->targetTemperatureC > MIN_DEFECT_TEMPERATURE /*is heating*/ &&
    (act->preheatTime() == 0 || act->preheatTime() >= MILLISECONDS_PREHEAT_TIME /*preheating time is over*/)) { // no temp sensor or short in sensor, disable heater

    targetTemperatureC is initialized with 0. 
    So the 
    act->targetTemperatureC > MIN_DEFECT_TEMPERATURE
    
    will not get true if MIN_DEFECT_TEMPERATURE is =>0. Only when the user changes the TargetTemperatur.

    And the Second: the 100k Honeywell 135-104LAG-J01 Temp-Table starts at zero!?
  • The lookup table just ends at 0°C so a small measurement error will make 0°C fail. See extruder.cpp

    #define NUMTEMPS_9 67 // 100k Honeywell 135-104LAG-J01

    const short temptable_9[NUMTEMPS_9][2] PROGMEM = {

        {1 * 4, 941 * 8}, {19 * 4, 362 * 8}, {37 * 4, 299 * 8}, //top rating 300C

        {55 * 4, 266 * 8}, {73 * 4, 245 * 8}, {91 * 4, 229 * 8}, {109 * 4, 216 * 8}, {127 * 4, 206 * 8}, {145 * 4, 197 * 8}, {163 * 4, 190 * 8}, {181 * 4, 183 * 8}, {199 * 4, 177 * 8},

        {217 * 4, 171 * 8}, {235 * 4, 166 * 8}, {253 * 4, 162 * 8}, {271 * 4, 157 * 8}, {289 * 4, 153 * 8}, {307 * 4, 149 * 8}, {325 * 4, 146 * 8}, {343 * 4, 142 * 8}, {361 * 4, 139 * 8},

        {379 * 4, 135 * 8}, {397 * 4, 132 * 8}, {415 * 4, 129 * 8}, {433 * 4, 126 * 8}, {451 * 4, 123 * 8}, {469 * 4, 121 * 8}, {487 * 4, 118 * 8}, {505 * 4, 115 * 8}, {523 * 4, 112 * 8},

        {541 * 4, 110 * 8}, {559 * 4, 107 * 8}, {577 * 4, 105 * 8}, {595 * 4, 102 * 8}, {613 * 4, 99 * 8}, {631 * 4, 97 * 8}, {649 * 4, 94 * 8}, {667 * 4, 92 * 8}, {685 * 4, 89 * 8},

        {703 * 4, 86 * 8}, {721 * 4, 84 * 8}, {739 * 4, 81 * 8}, {757 * 4, 78 * 8}, {775 * 4, 75 * 8}, {793 * 4, 72 * 8}, {811 * 4, 69 * 8}, {829 * 4, 66 * 8}, {847 * 4, 62 * 8},

        {865 * 4, 59 * 8}, {883 * 4, 55 * 8}, {901 * 4, 51 * 8}, {919 * 4, 46 * 8}, {937 * 4, 41 * 8},

        {955 * 4, 35 * 8}, {973 * 4, 27 * 8}, {991 * 4, 17 * 8}, {1009 * 4, 1 * 8}, {1023 * 4, 0} //to allow internal 0 degrees C


    You might make last entry 4095, -50 then I guess it will work, also result is not correct then, but only in that unusable area. Maybe we should add such a thing to all thermistors. Can you test if that would work so I can make the change. Unfortunately I have the wrong thermistors which go below 0 already. Question is more if that small range will be enough to detect defect then.

  • edited December 2017
    Well, this would only be a workaround. I tried that yesterday with {1023 * 4, -100 * 8} as last entry and the temp resulting was -100° or so on the DISCONNECTED thermistor.
    You can test this yourself just DISCONNECT the thermistor.
    And a MIN_DEFECT_TEMPERATURE  >=0 would still not work correct.

    and why are some thermistor-tabels end on 0° Celcius when e.g. the Thermistor 100k Honeywell 135-104LAG-J01 works from -60° till 300°?
  • > You can test this yourself just DISCONNECT the thermistor.
    Sometimes you do not see the obvious:-)

    The tables are older then the firmware and already were part of Sprinter which was the base. The problem at low temperatures is that resistance goes to infinity an a voltage divider made to measure on the other side of temperature scale. If you look into this

     {3945, 160}, {4002, 80}, {4038, 0}, {4061, -80}, {4075, -160}

    for example you see that very small changes measured cause very big changes, so that side is never reliable.


    Defect is tested here (are you using dev version?)

            if((act->currentTemperatureC < MIN_DEFECT_TEMPERATURE || act->currentTemperatureC > MAX_DEFECT_TEMPERATURE) &&

                    act->targetTemperatureC > MIN_DEFECT_TEMPERATURE /*is heating*/ &&

                    (act->preheatTime() == 0 || act->preheatTime() >= MILLISECONDS_PREHEAT_TIME /*preheating time is over*/)) { // no temp sensor or short in sensor, disable heater


    As you see sign should not matter, only additional reason is preheat time if enabled must be up. Will test when I think on it anyway with positive MIN_DEFECT_TEMPERATURE

  • edited December 2017
    targetTemperatureC is initialized with 0. 
    So the 
    act->targetTemperatureC > MIN_DEFECT_TEMPERATURE
    
    will not get true if MIN_DEFECT_TEMPERATURE is =>0. Only when the user changes the TargetTemperatur.

    And of course i am using DEV version
  • Ok, I see. I also see that it was what I wanted regarding the comment that I want only trigger the error while heating. Only thing for negative temperatures it would also trigger when not heating, what is not very consequent.

    For next update I have set this to > 0 so it behaves the same.

    The condition is good for printers that also swap to cnc tools, so they do not complain about defect temperatures all the time also they are not using them.
  • So you implemented this now, that it only triggers when heating?
    I tried the new commited version, and for the extruder it triggers "Heizelem. entkoppelt" when i change the target-temperature it is heating a short time and then it triggers.
    The Sensor says -178°. It acts like MIN_DEFECT_Temperature config doesn't exists.

    If i change it to act->targetTemperatureC >= 0 then it triggers immediatly "Temp.-Sensor defekt" 
  • Do you have preheat time set? During that period defect test is skipped (to solve problems with some printers on startup). When I start heating without thermocouple added (-99°C) I get the correct message. But without sensor it will also decouple at some time so question is which one wins here I guess. For my setup defect is still winning your settings seem to trigger decouple first.
  • i think i have the preheat time default value.
    Tested a little around. If i set the min_heat_temp to 30 it triggers defect also on the extruder.
    Looks ok for me.
Sign In or Register to comment.