Time Constant of a Thermistor

Parts List

  • Laptop

  • CPX + USB Cable

In this lab we’re going to get the time constant of the thermistor on board the CPX. If you take data on the CPX and walk outside or place the thermistor directly into a fridge, the temperature change will not be immediate. Remember that the thermistor is a resistor that changes with temperature. The ADC on the CPX converts the voltage across the thermistor to temperature. The Adafruit Learn system does a bit of work to explain the conversion from voltage to temperature. My version of the code is also on my Github.

For this lab in order to get the time constant you can do a couple things to get the time constant. Here are a few ideas.

  1. Start logging data and then place the CPX into the fridge

  2. Put the CPX into the fridge and then pull the CPX out of the fridge and watch the temperature return to ambient

  3. Walk outside on a hot (or cold) day and watch the CPX change temperature due to your A/C

  4. Walk inside and watch the CPX get warmer (or colder) as your HVAC changes the CPX temperature.

I did the first two examples and plotted both data sets in the same script as shown below. I opted to use method 1 from the datalogging project and just have the data print to Serial and then unplug the CPX when I’m done taking data and copy and paste the data into a text file.

At this point it’s possible to get the time constant by using the equation below. The subscript A is for ambient temperature and 0 is for the initial temperature.

T(t)=(TAT0)(1e(t/τ))+T0T(t) = (T_A-T_0)(1-e^{(-t/\tau)})+T_0

Remember that the settling time (time it takes the temperature to settle out) is equal to 4 times the time constant () and thus the time constant is the settling time divided by 4. After computing the settling time for both data sets and overlaying the equations on the measured data I get these two plots.

What was interesting was that the time constant for heating up was 62.5 seconds and for cooling down it was 155 seconds. The time to get cold was way slower than heating up. I’m not a heat transfer expert so I won’t comment as to why this happened. One other import note I’d like to mention is the cool down phase was much more accurate than the heat up phase. This is most likely because when I pulled the thermistor out of the fridge I touched it with my hands and then moved it to a table. There was also alot more airflow outside the fridge which would change the overall dynamics. Still, the fitted data matches up pretty well and I hope yours does too.

Turning in this assignment

Upload a PDF with all of the photos and text below included. My recommendation is for you to create a Word document and insert all the photos and text into the document. Then export the Word document to a PDF. For videos I suggest uploading the videos to Google Drive, turn on link sharing and include a link in your PDF.

  1. Include a video of yourself talking about how you plan on changing the temperature of your CPX. Are you going outside? Putting the CPX in the fridge? Explain how you plan on taking data as well (again make sure your face is in the video at some point) - 50%

  2. Plot your raw temperature data with time on the x-axis and temperature on the y-axis - 20%

  3. Overlay your fitted data on top of your measured data. Points will be given based on how well your fit is - 20%

  4. Include the time constant of your thermistor. Did you get similar values as mine? - 10%

Last updated