Integrating the TMP36 temperature sensor was simple, I've used it before. It looks like a transistor and outputs a voltage proportional to temperature. Adafruit has a thorough guide on its use.
Making the sensor work was easy. Using the temperature data to make meaningful decisions about detecting Peril is less easy. Certainly, at a high level I want to assume Peril is present whenever the temperature rises or drops too suddenly, but how do you go about doing that, exactly? What
I realized that a "sudden" shift in temperature is really a temperature change (up or down) that happens too quickly. To measure temperature is easy - read the sensor. But to decide whether the temperature change is too quick requires comparing temperature change X to an amount of time Y.
Change over Time is textbook calculus something. It might definitely be a derivative, or maybe an integral. Either way I don't know a lick more about it than that so I settled for a software framework that measures temperature regularly and creates rolling averages at different times. A change of temperature in excess of X in time period Y is considered Perilous. (X and Y values are a little up in the air right now but I'm sure a little fiddling will reveal something useful.)
That about wraps it up for the guts of the Temperature Sensor.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.