The Fire-EdUp platform has these sliders for inputting data. This could be data that we collect outside and then take into the lab and input into our platform. We can improve the Fire-EdUp platform with a real temperature sensor. By connecting this temperature sensor to our daisy-chain of hardware, we can replace the need for manually inputting a temperature. And you can see how this idea could be extensible to other ideas like humidity or wind speed where we could set up a weather station that brings data into the platform.
For now though we'll just add this precision temperature sensor to our platform so that our platform can base its temperature data off real sensor data rather than data that we might enter using the slider. Your temperature sensor has four little switches in the bottom right corner. Make sure only the first switch is in the up position and the rest are down. Then connect a cable to your temperature sensor and connect the other end to the vacant connection on the last slider.
Now in our regular code, we're going to instruct the platform to ignore the slider and instead read the temperature sensor. In the collect data method we're going to add the argument use underscore temperature underscore sensor and set that equal to true. It'll be helpful if we print the data so make sure that the print data line is uncommented and I'll comment out the print FBI line so that there's no mess. There's a lot of data on screen right now so we can use the same trick that we've used before where we can access just the temperature component of our data set.
Rerun the script. Beautiful. We have just one number printing out and according to this temperature sensor, the temperature inside the lab here is 26 and a half degrees. I'll press my warm thumb onto the sensor and we can see that it starts to rise already to about 30 degrees and that proves that we're working with the temperature sensor. I'll fan the sensor to help it cool down and you can see that temperature falling again in the plotter. How good. And of course, if we move this slider nothing changes.
And just like that we've upgraded our Fire-EdUp platform a little bit by using real sensor data rather than data that we the scientist has to input manually and maybe we make some mistakes or inaccuracies. Now we can depend on reliable sensor equipment to take our measurements for us. It makes our job that little bit easier.
Have a think about other kinds of sensors that can be used for these inputs. There's humidity. Weather stations have humidity sensors. There's wind speed. Weather stations also have anemometers that measure wind speed. Fuel moisture content is a trickier one as is fuel load. I wonder if there's some kind of sensor or drone with a camera that can somehow infer or measure these directly. In any case that's all I have for you for this video. Until next time, thanks for watching.
Makers love reviews as much as you do, please follow this link to review the products you have purchased.