示例#1
0
 def thermistor(self):
     analogRead = self.hal.sensors.temp.value
     resistance = converters.tension2resistance(analogRead, 10000)
     temp = converters.resistance2celcius(resistance, **THERMISTANCE)
     return temp
示例#2
0
def thermistor(analogRead):
    resistance = converters.tension2resistance(analogRead, 10000)
    temp = converters.resistance2celcius(resistance, **THERMISTANCE)
    return temp