Freesteel Blog » Differential temperature sensing

Differential temperature sensing

Tuesday, December 23rd, 2014 at 7:39 pm Written by:

I printed this beautiful box for my speedy accurate barometer at the DoESLiverpool Xmas party designed on Openscad.



It’s in two pieces with a lid and a main bit, done by modelling the shape of the the positive() and subtracting it from the each piece to make sure it fits. The lid fits onto the box with plastic tightness by being the same dimensions. I learnt more about CAD than I have done in years. The code looks roughly like this:

wt = 2;  // wall thickness in mm
bv = 1;  eps = 0.02;  ovl = 3; 
module lid() 
  difference() {
    union() {
      hull() {
        translate([-wt-wt,-wt-wt,-wt+16-ovl])  cube([40+4*wt, 55+4*wt, ovl+wt+wt-eps]);
        translate([0,0,-wt+16-ovl+bv])  cube([40, 55, ovl+wt+wt-eps]);
      difference() {
        translate([-wt-wt-ovl+eps,16,12])  cube([3,20,5]);
        translate([-wt-wt-ovl+eps+1.3,18,11])  cube([1.7+eps,16,7+eps]);
      difference() {
        translate([ovl+eps+41,16,12])  cube([3,20,5]);
        translate([ovl-eps+0+41,18,11])  cube([1.7+eps,16,7+eps]);
    union() { outerbase();  positive(); }

It was a lazy weekend. We went surfing on the beach at Crosby on Sunday morning with the Liverpool Canoe Club because it was high tide and there had been westerly gales. This was a lot better than last weekend where I was hauled off to Yorkshire to sit in the corner of the caving hut crying. By Monday I was showing visible symptoms (coughing and streaming nose) above and beyond mere whinging and was believed.



Later in the week I was back to dreaming about things to put onto my glider as part of the PALvario project.

My vibration motors pulled out their wires and I thought of a better design involving speaker wire, 3.5mm jacks and some hot glue. More importantly I dropped at random into an Adafruit video where they happened to be showing off their new DRV2605L Haptic Motor Controller. Just what I needed. This is a repackaging of some Texas Instruments tech for driving these vibration motors efficiently by dynamically responding to the inductive kickback from the motor to determine its phase and speed, rather than dissipating this information through a diode. As a result I might be able to get bigger kick from the motors in terms of starting and stopping on a dime. All of this tech is being driven by the demands of mobile phones. This is a great time to exploit the fall-out.

The vibration motors will go in various places in the hang-glider harness to give silent information about the rate of climb or descent without this interminable bleeping of a conventional vario.

I also need something to measure the air directions at the trailing edges of the wing to know which parts are close to stall speed. Current plan is to have a flag with a magnet in it which is deflected close to or away from a sensor underneath the wing. I bought several hall effect switches, and yesterday I tested them for sensitivity.

The tiny magnet had a range of 5mm, while the superstrong magnet (still in its packaging) could be detected from 15mm away. It’s a binary on or off sensor, unfortunately. I would have liked one that gave an analog measure. It only responds to the south pole.


Just for a laugh I got a reed switch. Turned out to be much more satisfying because it worked at a greater range, only needs two wires (no poncy silicon circuitry), makes a satisfying “ting” when it releases, and comes in a weatherproof version that I can probably get away with sticking on to the wing.


Before I could get any further with that project, I was reminded of my success with my fridge temperature detector based on the tmp36 and an analog to digital converter, and wondered whether this would make it possible to detect the entry of a glider into a thermal where the air temperature is supposed to be higher.

Much of this was on my mind because I have just recently taken my pilot exam and had to read up on the theories to pass the test. When they say the sun heats up the ground and then releases a thermal which is a blob of air that’s a couple of degrees hotter than the surrounding atmosphere, I thought, “how do they know this?”

Has anyone actually measured the temperature of a thermal when they’ve flown into it? Maybe this will explain why some thermals are stronger than others. And, also, the warmth of the air could give an indication of whether it’s a real thermal, or just turbulence. Of course, this might not work if the thermal is a vortex kind where the fastest rising air is driven by the structure of the wind current rather than the hotness of the air.

An extremely good barometer [check] and a temperature sensor [check], if logged, could record the adiabatic lapse rate on the way down from cloudbase which will form the background measurement against which to estimate the thermal over-temperature. Additionally, a humidity sensor could feed an accurate calculation as to the height of cloud base (dew point). This rises throughout the day, and I don’t know if it’s because the air becomes drier or the air heats up.

How quickly and accurately can I measure temperature? I have rigged up two TMP36s on either end of a long stick to the 16 bit ADC and walked through doorways into differently heated rooms hoping for a spike when when they crossed the different zones.

The results were inconclusive as the circuitry kept falling apart and shredding the logfiles as I tried to open each door. I need to make myself a new all-bells-whistles logging device that’s got everything properly soldered, crimped and clipped together before I try this again.

For this idea to work it needs to measure the difference in less than a third of a second, given that the nose to tail of the glider is roughly 3m and it flies at about 10m/s. If this doesn’t work, I can try again with an infrared thermometer aimed at the underside of the wing hoping that it picks up the temperature of the flowing air pretty quickly and isn’t washed out by the sunlight.

So much of this is only just on the bounds of the possible. Hopefully it doesn’t all fail.

Leave a comment

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <blockquote cite=""> <code> <em> <strong>