Home

Awesome

An Air/Ground Speed Sensor (Logger) Using Pitot Tube and GPS

(C) 2023 ekspla

Abstract

An air/ground speed measurement system with logging functionality was easily built with a Pitot tube <sup>1</sup> and a GPS receiver using micropython <sup>2</sup>. The system allows us to measure the air and the ground speeds almost simultaneously at 5 Hz and more in various outdoor activities. As a demonstration of this system, a correlation map of the air and the ground speeds of drafting in cycling <sup>3</sup> is shown.

Materials

RTC clock (LSE) adjusted to 32.768 kHz using a pair of additional ~5 pF C0G capacitors, pin headers of PC14/15 removed, a coin-cell (CR2032) attatched to VBAT.

A universal counter and this code <sup>5</sup> were used to measure/adjust the LSE frequency.

Micropython 1.20.0 <sup>2</sup> installed via ST-LINK <sup>6</sup>. The port (board definitions) to build the micropython firmware was obtained from github <sup>7</sup> <sup>, </sup><sup>8</sup>.

A home built GoPro (GP) <sup>10</sup> compatible mount for the tube and the differential pressure sensor (see below).

d6f_ph.py <sup>12</sup>

Similar sensors such as MS5525 (TE Connectivity) and SDP810 (Sensirion) may be used with their appropriate drivers.

micropyGPS.py <sup>14</sup>, a forked/modified version of inmcm/micropyGPS <sup>15</sup>

lcd_api.py, dhylands <sup>16</sup>

sdcard.py, micropython-lib <sup>17</sup>

A modified version of Adafruit <sup>19</sup> driver; normal mode, oversampling (Px16, Tx2), and w/o IIR filter.

Note that this sensor should be protected against direct sunlight and air stream. A tiny piece of black open-cell foam (sponge) may suffice.

Assembling

Most part of the micropython codes were precompiled using mpy-cross <sup>20</sup> before installation. The assembled units of SoC/GPS/display and air speed sensor are shown in the photos (see below). The procedure to calculate air speed from differential pressure of Pitot tube is shown in elesewhere. A link to Wikipedia <sup>1</sup>

PHOTO_DISPLAY_UNITPHOTO_SENSOR_AND_PITOTPHOTO_SENSOR_UNIT

In the following experiments, the air speed sensor unit shown in the 3rd photo (GP mount, consisting of the Pitot tube and the differential pressure sensor) was mounted in front of a bicycle. Update and logging rates were set at 5 Hz (200 ms interval), though the system can handle > 10 Hz.

Calibration

Air speed was calibrated by using Pitot coefficient and an offset of differential pressure. Its accuracy was tested in a foggy morning around dawn (no wind / no sunlight). See almost perfect fit in the correlation map below. The tiny deviation from the diagonal line in 10-20 km/h range may be caused by headwinds of oncoming cars.

FIG1

A Demonstrative Result -- Visualizing the Effect of Drafting in Cycling --

A pair of bicycles were used for this experiment in a day of almost no wind outdoor.
The air speed sensor was attached in front of the trailer's bicycle after the leader's bicycle following in line. The distances between them were kept 1.0-1.5 m at ground speeds below 40 km/h, while a bit longer distances at above these speeds for safety reasons.
The effect of drafting is easily seen in the figure; the measurement points in the correlation map start to deviate from the diagonal line by increasing the ground speed at above 10 km/h.

FIG2

It should be noted that this data was easily taken by a single experiment of 16 min, while most of the data in literatures consists of at least a couple of experiment, i.e. one with and the other without the leader's bicycle. Ref.

Concluding Remarks

An affordable priced (for the hobbiest) system to simultaneously measure the air and the ground speeds outdoor was easily built. As a demostrative example, a mesurement of drafting effect <sup>3</sup> in cycling outdoor is shown.

This system can be modified to show the effect of wind direction outdoor as well, by using multiple air speed sensors (possibly three, each at an angle of 120 deg.) and vectorial math.

References

Pitot Tube

Drafting (Aerodynamics)