T-Display ESP32 code to read analog value from Aithre Altus Meso pressure sensor. GUI was designed in SquareLine Studio 1.5.3
First setup with 3D printed connector extension and black display background.
The TFT display should be easier to read in sunlight than the AMOLED display.
The analog inputs can only handle a maximum of 3.3V. Since the Meso sensor delivers up to 4.5V, a voltage divider must be installed. Otherwise, the analog inputs may be damaged.
I simply used two identical resistors. Since the analog input of the ESP32 converts 12 bits (4095), there is no significant loss of resolution for this application.
The time forecast for the remaining oxygen quantity is based on a regression method, whereby the parameters have not yet been adjusted to the actual pressure drop magnitudes. If no pressure drop is registered for a longer period of time, the theoretical oxygen duration for a requirement at 6000 m is assumed, which is indicated by the label 6K.
The Meso sensor is equipped with a 3-pin plug connection. The following female connector fits: “Cable repair kit, pressure switch (air conditioning) Loro 120-00-137”. The contacts must be crimped.
Caution: the contacts can only be inserted from the front. Therefore, first pull the cable through the plug, crimp it with the contact, and only then press it into the plug.
The connector can be kept significantly lower by drilling a hole directly to the side for the cable outlet. The cable should be reinforced in this area using heat-shrink tubing. Once the contacts have been crimped and pressed in, the open area on the back of the plug can be filled with hot glue. To smooth the surface of the pressed-in hot glue, it can be melted and smoothed using a small burner flame.
Add the folowing links in the IDE at line: “Additional boards managers URLs:”.
https://dl.espressif.com/dl/package_esp32_index.json https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_dev_index.json
Check the readme of the lvgl library. The file “lv_conf.h” must be copied to the libraries folder parallel to the lvgl folder. Also check in “lv_conf.h” that all neccessary “LV_FONT_MONTSERRAT” - Fonts are enabled by flag 1.
Select the following Board parameters