-
Pressure Sensor Concerns
11/25/2023 at 23:03 • 0 commentsThe MPX10DP I purchased has an overpressure limit of 75 kPA, with an operation range of 0 to 10 kPA. 10 KPA = 1.45 PSI. This is equivalent to 248 knots at standard atmosphere. This seems fine, but I am concerned that the gauge reads in milliVolts with a range of 20 to 54. I think the ESP A/D converter only reads in increments of 1 milliVolt. This would mean that we would not have very good resolution.
If this is true, we'll need to consider maybe amplifying the voltage output so we can get a range more like 1000 to 2500 milliVolts, or 50x the output voltage.
Ok...a little digging. There seems to be a method to change the AtoD attenuation in the ESP32 chip. But not clear if this will be easily done. Will need to dig into the drivers for the ESP32 and look for variable ADC_ATTEN_11 for a start.
Ok...github is awesome. Found the header file arduino-esp32/cores/esp32/esp32-hal-adc.h
and tried to compile my project with the following line...it worked.
analogSetPinAttenuation(VBATPIN,ADC_11db);
So now need to carefully try this out with a low voltage signal and different attenuations. Humans can produce about 2.8 psi by blowing, or 19 kPa. So we should be able to blow on the input and max out the pressure without overpressuring the sensor.
typedef enum { ADC_0db, ADC_2_5db, ADC_6db, ADC_11db, ADC_ATTENDB_MAX } adc_attenuation_t; /* * Set the attenuation for all channels * Default is 11db * */ void analogSetAttenuation(adc_attenuation_t attenuation); /* * Set the attenuation for particular pin * Default is 11db * */ void analogSetPinAttenuation(uint8_t pin, adc_attenuation_t attenuation);
-
Preliminary Calculations
11/25/2023 at 20:40 • 0 commentsIntention is to set up entire system sending dummy data to get base programming completed prior to any functional testing. Researched existing documents to get a reasonable base line for initial calculations and expected sensor readings.
- alpha = f(Pfwd/P45)
- See FAA TC18-7 Fig 33 to get following formula. Going to set up for a quadratic formula in the future even though this one is linear.
fRatio = fPfwd/fP45; #define A 0.0 #define B -16.908083 #define C 42.415008 fAlpha = A*fRatio*fRatio + B*fRatio + C
- See FAA TC18-7 Fig 33 to get following formula. Going to set up for a quadratic formula in the future even though this one is linear.
- Output voltage vs Pressure from MPX10 documentation graph below. Using linear fit at +25C gives following equation
#define A .0419 #define B -0.8279 fPSI = A*fVolts + B
- alpha = f(Pfwd/P45)
-
LED Strip Testing
11/24/2023 at 16:47 • 0 commentsSee sketch Strip_Test.ino for testing performed. I found that the brightness control on this strip is non-linear. Brightness is a unit8, but at value over 70 a fully blue LED will start to decrease in brightness and at above 100 goes completely dark.
For five levels of brightness the following seems to be a reasonable choice.
uint8_t auBrightness[] = {1,3,5,8,25};
And for colors I phoned a friend and got the following values for the ROYGBIV colors
//colors #define RED 255, 0, 0 #define ORANGE 255, 80, 0 #define YELLOW 255, 255, 0 #define GREEN 0, 255, 0 #define BLUE 0, 0, 255 #define INDIGO 75, 0, 130 #define VIOLET 148, 0, 211 #define WHITE 255,255,255 #define TRUE_WHITE 0, 0, 0, 255 #define OFF 0, 0, 0, 0
Here is the display at a brightness of 8 with the LEDs set to my initial AoA scheme [Red, Red, Orange, Blue, Yellow, Yellow, Green, Green]
-
Airfoil Research
11/24/2023 at 16:01 • 0 commentsIdeally we will collect data from the unit and calculate our cruise AoA, landing AoA (1.3 Vso) and stall speed Vso from empirical data. But to get started I looked into the theoretical AoA information for the PA-18 Supercub, our intended test bed.
Found The Incomplete Guide to Airfoil Usage to determine the airfoil in use on a PA-18, which is the USA 35B. Found NACA Report 233 on the airfoil as well as listing in Airfoil Tools
Reynold's number
Been a hot minute since I calculated Reynold's number, so asked to phone a friend. Need to vet this but here's a start.
Certainly! Let's calculate the Reynolds numbers for the given velocities:
- At 35 mph (15.65 m/s): Re=(1.225 kg/m3)⋅(15.65 m/s)⋅(1.6 m)(1.81×10−5 Pa\cdotps)Re=(1.81×10−5 Pa\cdotps)(1.225 kg/m3)⋅(15.65 m/s)⋅(1.6 m) Re≈1.76×106 Re≈1.76×10^6
- At 50 mph (22.35 m/s): Re=(1.225 kg/m3)⋅(22.35 m/s)⋅(1.6 m)(1.81×10−5 Pa\cdotps)Re=(1.81×10−5 Pa\cdotps)(1.225 kg/m3)⋅(22.35 m/s)⋅(1.6 m) Re≈2.51×106 Re≈2.51×10^6
- At 70 mph (31.29 m/s): Re=(1.225 kg/m3)⋅(31.29 m/s)⋅(1.6 m)(1.81×10−5 Pa\cdotps)Re=(1.81×10−5 Pa\cdotps)(1.225 kg/m3)⋅(31.29 m/s)⋅(1.6 m) Re≈3.51×106 Re≈3.51×10^
- At 110 mph (49.16 m/s): Re=(1.225 kg/m3)⋅(49.16 m/s)⋅(1.6 m)(1.81×10−5 Pa\cdotps)Re=(1.81×10−5 Pa\cdotps)(1.225 kg/m3)⋅(49.16 m/s)⋅(1.6 m) Re≈5.50×106 Re≈5.50×10^6
So something like 2,000,000 to 6,000,000
Airfoil Tools gives us the following plots for Re 500,000 and 1,000,000
-
OLED Display Layout Testing
11/23/2023 at 15:07 • 0 commentsOLED Testing available in the Sketch display_testing.ino
Version 1 of the screen layout
Splash ScreenFont testing
Line Spacing testing
-
Soldering Notes and OLED Wiring Mystery
11/20/2023 at 16:12 • 0 commentsFollow steps to solder connections:
- Attached OLED wing to Feather using soldering notes provided by Adafruit. Really needed a third hand. My result is that the wing is slightly off parallel. The side away from USB is slightly closer to the Feather. This became beneficial as the 2mm screws available where only 6mm long. This is not long enough to reach through both boards and into the enclosure if the board are parallel as they should be.
- Soldered wires for LED strip and environmental board after the Wing and Feather connection was completed. This was tricky to thread them between the two boards and up into the correct connections in the Feather board, but doable. Used solid core 22 awg, With stranded wire it would have been a major pain. Next time would recommend trying 24 awg. 22 awg seems like over kill.
After making all connections, I was not able to successfully use the LED strip. After some head scratching, I realized that I had connected the digital signal line to A4 on the Feather. Turns out this is an INPUT only pin. Duh. So removed and soldered into A5. Ops Chk OK!
-
Display Enclosure V1 Assembly
11/20/2023 at 15:59 • 0 commentsFollowing changes required to version 1 of the Display enclosure.
- minimize standoff height
- make walls to extend to the LED strip and OLED display
- reduce wall thickness on LED strip standoffs on board side for clearance
- move USB hole away from face
- redesign the buttons
- reduce OLED hole in width and height
Holes in standoff etc work well for 2mm and at least a few turns of 2.3mm
Used 2x5mm for LED to enclosure and 2.3 x 10mm for two holes of the Feather/Wing to the enclosure. Really need longer 12mm or 14mm.
Enclosure is serviceable as is. See photos. (Note: I did not yet install the side switch for power)
-
Gas Sensor Screw Up
11/13/2023 at 22:41 • 0 commentsI wanted to add CO monitoring to the display, as it should be very easy and would be another way to track CO. I originally bought the Adafruit MiCS5524 CO, Alcohol and VOC Gas Sensor. Turns out that chip is 5V and I don't have 5V available. I could use USB voltage, which would require plugging in which I'd like to avoid. Or I could get a voltage booster, like the PowerBoost 500 Basic - 5V USB Boost @ 500mA from 1.8V+. Then I would have to do a voltage divider to ensure the output was within what the Feather can handle. Doable. But at that point, I could really just get a 3v VOC sensor.
3V compatible VOC sensor options:
Adafruit sells the Bosch BME688 which also senses temperature, pressure and humidity. Temperature and pressure would be nice. Uses I2C. Current consumption (peak) 3mA
Another alternative is the Adafruit SGP40 Air Quality Sensor Breakout - VOC Index for $15. I2C interface. Current consumption 2.6mA.
So, we need to make provisions to solder the gas sensor into the I2C connections that will be shared with the OLED display.
-
3d Printing Notes
11/11/2023 at 13:18 • 0 comments- 1.5mm = .060 in min wall thickness
- .6mm = .024 in absolute min wall thickness
- .3mm = .012 in gap for loose fit
- .15mm = .006 in gap for tight fit
- When 3D printing parts that will fit together, a clearance of about 0.3 mm for a loose fit and about 0.15 mm for a tight fit is recommended. The required clearance may vary slightly depending on the material and geometry.
- A good minimum wall thickness for 3D printing PLA is 1.5 mm. The absolute minimum wall thickness a 3D printer can print is 0.6 mm.
-
Adafruit Notes
11/09/2023 at 20:38 • 0 comments