Last time we left off with kind of a one step forward, two steps backward situation: I found that Tyvek is too gas-permeable to be a good sensor chamber material, that our sensors are quite temperature sensitive, and that store-bought apples don't really have much to report to these sensors.
That last part's not too big a deal. If we're buying an apple in a store then we know it's already ripe and ready to eat. That's not relevant to our goals. Apples were an easy fruit to test out as fruit season wound down here in Atlanta and there's less to choose from on the trees.
But I did start getting real, clean data. So now we can move on to fruit that we care about, which is also conveniently our last real option for the season: the native persimmon.
These are persimmons picked from this tree on October 26th and aside from the 2 small orange ones, it is a group of solidly unripe persimmons. We should hopefully get a good transition out of these.
Fun facts about persimmons: they taste like orange jello when ripe and they can form a bezoar in your belly if you eat too many unripe ones. PLUS double fun fact: you can drink a lot of Coke and its acid will dissolve the bezoar!
New Sensor Setup
I've got a new sample chamber setup for this iteration too:
I waterjet cut some holes in the lid to mount the sensor electronics outside of the chamber. I also have an extra hole in there for mounting a temperature sensor and a miscellaneous hole for doing power pass-through for a fan or whatever else. I'd love to find a small usb bulkhead fitting but this will do for now.
This new setup is great because:
- It keeps sensor electronics outside of the chamber and away from any condensation
- It mounts the sensors at the highest/hottest point so they should be more temperature stable
- It exposes the sensor trimpots so I can make adjustments without having to open the chamber.
- It's a little more repeatable since I can just screw the lid on and not crimp on a piece of aluminum foil every time I open the chamber.
Fully assembled with DS18B20 temperature sensor:
Before I get in to the persimmons, a note about the trimpots in parallel with each sensor: I don't really know what I'm doing with these yet. They form a voltage divider with the sensor and act as a way of calibrating the sensor or adjusting its sensitivity. Because I don't know exactly what I'm doing yet, I try to calibrate them to all to roughly same value in a chamber of precision reference air, which is the air in my house.
For reasons that I assume to be related to manufacturing, not all sensors respond the same way to trimpot adjustment, so it's mostly a matter of finding a low-medium shared value that I can reach with each of the sensors. That value is about 145 (out of 1024) with this particular array of sensors.
Ideally the trimpots would be replaced with digital potentiometers so that you could do software-based calibration, as it's pretty tedious to tune each trimpot with your tiny screwdriver. It also seems like the manual trimpots introduce another source of error and having digital potentiometers would allow for more repeatable experiments.
Smelling the Persimmons
The sensors had been off for a bit and I wanted to give them another burn-out to get readjusted. They began to drift during this time so I after a few days tuned them down to around 145, waited 5 minutes, and threw some persimmons in:
We have some cool data here! The sensors detected the persimmons instantly and you can see them really start to ripen around halfway through Thursday the 27th. Shortly after, there was a power outage that coincided with my being out of town. It should be noted that the power outage was likely a small blip that was only long enough to knock out the Raspberry Pi. The sensors were warm when I returned home and Atlanta had been in a 3 month drought at that point so it's unlikely it was an extended outage.
Since the container seemed well sealed and since the sensors were warm, I started logging again upon returning home. The sensors had mostly settled in place, with an especially strong response on the A3 sensor, which is an MQ5 LPG sensor. No comment one way or the other on what that means, but still strange and interesting to see. 🤔
Persimmons after removal (Oct 30).
Testing short-term repeatability
As a small side-experiment, I took all the persimmons out, grabbed my CO2 tank that I use for soda carbonation, and used it to purge the sample chamber gas. I let the sample chamber idle for about 9 hours. The sensors all returned to the 145 ballpark, and I was pleased with how close they got, but it could definitely be better. Low value in the array was in the 110s, high value was in the 160s. Putting the persimmons back in returned the sensors to their previous values. Cool.
Temperature changes over this whole period is here:
It's not that much more stable with the sensors mounted in this new position. What's more, the Atmega internal sensor is actually not too bad! It lags behind the actual temperature sensor for several days, but it's also now on the outside of the sample chamber.
The temperature range recorded over a day isn't really that different from before, even with the sensors in a the higher, hotter position. But even with a similar temperature range, there's much less of an obvious temperature effect on the sensor data. There's a slow decline centered around the "Thu 27" label and there might be a similar thing going on with "Tue 25" and "Wed 26": a small peak just before the day label, and then gradual slope downwards. The sharp upward peak also seems to begin as temperatures have bottomed out and start rising again. This may also happen on the 30th with the sharp peak just before the persimmons were removed.
Testing long-term repeatability
Taking persimmons out for 9 hours did fine, but what about trying an apple again, especially now that temperature seemed to be less of an issue? Kind of a horrible mess:
I removed the persimmons, recalibrated, added an apple, got data that didn't resemble previous apple data, removed apple, recalibrated, over and over.
I was finally saved from this sad loop by a fluke accident: I removed my iphone cable from my phone, dropped it on the desk, and it recoiled in such a way that it pushed my tiny screwdriver in to a small hole in my power supply, where it shorted a large capacitor and fried the supply. No joke.
Lessons learned / things for next time
- Need some digital potentiometers. Calibrating by hand is super annoying and error-prone.
- Need a calibration standard. A shot of vodka seems like a reasonable first start.
- Hide my power supply.
- Maybe an insulated/double-wall chamber?