Giter Site home page Giter Site logo

esp32-ogn-tracker's Introduction

ESP32 OGN-Tracker

OGN Tracker implementation on ESP32 devices. It works with HELTEC and TTGO boards with sx1276 RF chip for 868/915MHz The quickest board to run is the T-Beam from TTGO as it includes GPS, RF chip, battery circuit and holder, optionally as well a small OLED display. Yout to solder BMP280 or BME280 pressure/temperature/humidity sensor.

The initial code is written for and tested on HALTEC LoRa 32 module with sx1276 and 128x64 OLED display. Most likely it can be easily ported to other ESP32 devices, as these are very flexible for the I/O assignement. If you need to change the pins assigned to various periferials, see the top of the hal.cpp file.

Recent development

The most recent features added to the OGN-Tracker, they might not be all working perfectly fine and may need further development to be really useful.

LoRaWAN connectivity

When you compile the code with WITH_LORAWAN the OGN-Tracker can talk to the LoraWAN network. The intention is to use TheThingsNetwork and it is arranged already that packets send to the "ogn" application defined there are decoded and merged into the OGN APRS data stream thus position reporting still follows the same data path and is displayed on the tracking webpages.

To use this feature you need to register your OGN-Tracker with the TTN and "ogn" application, thus you need to send to us your 64-bit CPU ID and we will register the device and send you back the application key which needs to be written into the OGN-Tracker.

Note: LoRaWAN GPS trackers using the Cayenne Low Power Payload (LPP) can now be connected to our TTN application, and the position report would be merged into the OGN APRS stream. Conect us for AppEUI and AppKey to use for configuring the device.

IGC files recorded on the SD card

For OGN-Trackers with SD card connected, IGC files are recorded., as well as internal log files are copied over to the SD card in order not to be lost when newer files overwrite them.

Wi-Fi Access Point

When compiled with WITH_AP WITH_WIFI and WITH_HTTP the OGN-Tracker creates a Wi-Fi access point when you can connect with the smartphone and access the status, configuration and log files stored in the flash memory.

Note the the ESP32 takes about 80mA more when the Wi-Fi AP is enabled thus total current consumed is about 200mA.

Stratux-EU connectivity

When compiled with WITH_STRATUX, WITH_WIFI and WITH_HTTP the OGN-Tracker can serve as source of GPS and pressure data (if pressure module present) to the Stratux. The OGN-Tracker connects to Wi-Fi access point created by Stratux Raspberry PI and send GPS and pressure data to port 30000. Once the OGN-Tracker is connected to Stratux, it is possible to connect to its HTTP interface to access status, setup and log files.

To compile the code and flash the ESP32 module: install the ESP-IDF

To compile and flash the ESP32 board you need to install the ESP-IDF v4.0 Start with:

cd
git clone -b v4.3 --recursive https://github.com/espressif/esp-idf.git
cd esp-idf
./install.sh

If you are doing this on a Raspberry PI and see error messages about virtualenv you may need the following:

sudo apt-get install libffi-dev
pip install --upgrade virtualenv==16.7.9

If you see errors about openssl/opensslv.h then you need:

sudo apt-get install libssl-dev

Then, in order to be able to make projects you need to run

source ~/esp-idf/export.sh

To get the OGN-Tracker source code from this github repository:

cd
git clone https://github.com/pjalocha/esp32-ogn-tracker.git
cd esp32-ogn-tracker

If you want to use the OLED display with the U8g2 library you need to install it in components in the project directory:

mkdir components
cd components
git clone https://github.com/olikraus/u8g2.git
cd ..

To choose the configuration file for the T-Beam

cp T-Beam.cfg main/config.h

To compile and flash the board

make
make flash

To see the console output and thus to check if the ESP32 is alive

minicom

For minicom setup use 115200bps /dev/ttyUSB0 serial port and turn hardware and software handshake OFF. It is important, otherwise if you type something it won't be sent to the ESP32. Press Ctrl-C to list the internal state and parameters. To change parameters, use $POGNS like this:

$POGNS,AcftType=1,Pilot=YourName

Wiring the GPS

Wiring is fairly flexible, as the ESP32 can easily redefine the I/O signals. You need to avoid pins which are already used: the list normally comes with every ESP32 module. You can choose the pins after their placement on the board, for example such, that all wires are soldered on one side. Wiring for various modules has been chosen but if needed can easily be changed.

HELTEC v1 and TTGO boards without GPS

For the original HELTEC board and similar TTGO boards without the GPS you need to wire the UART GPS follow the pins defined in the hal.cpp

                                  // wire colours for VK2828U GPS
#define PIN_GPS_TXD  GPIO_NUM_12  // green
#define PIN_GPS_RXD  GPIO_NUM_35  // blue
#define PIN_GPS_PPS  GPIO_NUM_34  // white

Note: I have seen GPSes where red was ground and black was power thus be carefull !

Note: If you use an MTK GPS change the definitions in the config.h accordingly.

HELTEC v2

RXD and PPS need to be relocated because now they are connected to DIO lines of the RF module, thus they were relocated to pins 39 and 38.

TTGO T-Beam

GPS is already wired and the definition is in the hal.cpp.

Wiring I2C (pressure sensors and/or OLED displays)

For devices with an OLED screen the I2C pins are already defined and you should follow these, as there is one common I2C bus in use. For devices without we still use the same I/O pins.

HELTEC v1/2 and similar TTGO boards

#define PIN_I2C_SCL GPIO_NUM_15   // SCL pin
#define PIN_I2C_SDA GPIO_NUM_4    // SDA pin

TTGO T-Beam

#define PIN_I2C_SCL GPIO_NUM_22   // SCL pin => this way the pin pattern fits the BMP280 module
#define PIN_I2C_SDA GPIO_NUM_21   // SDA pin

I2C pins are arranged such that they are next to GND and 3.3V and fit the pattern of most I2C modules so for example to solder a pressure sensor like BMP280 just a 4-pin header is required.

Wiring LCD display

240x240 SPI LCD A small, cheap LCD 240x240 screen has been tested with the TTGO T-Beam v1.0 boards and the wiring is as follows:

GND GND
VCC 3.3V
SDA 14
SCL 13
RES 33
DC   2
BLK 15

In this arrangement all signals are on one side of the board except for the VCC line

Note: the SDA/SCL naming suggest this display is interfaced with I2C but actually it is an SPI device with the CS being constantly active.

There is as well an LCD code for the M5 stack, which is already wired to the ESP32 thus no additional wiring is needed. There you need however to wire other devices like the RF chip and pressure sensor.

Console dialog and configuration

Use minicom and connect to /dev/ttyUSB0 (on Linux) for configuration set 115200bps and turn the hard- and soft-handshake OFF. You shall see stream of NMEA sentences. You can give the following commands:

Ctrl-C - lists internal state, internal log files and current parameter values. Ctrl-L - list internal log files Ctrl-V - hold the NMEA stream for 1 min Ctrl-X - restarts the system

To set parameters send $POGNS with parameter name and value like

$POGNS,Pilot=John

the parameter value changes and all parameters are writen to internal flash thus they are preserved across system restart or repower. To list all parameters with their values send Ctrl-C (software and hardware handshake must be OFF).

Note: more recently, the internal log files can be accessed through the WiFi Access Point and HTTP interface. The drawback is higher power consumption due to WiFi.

BT interface

OGN-Tracker can be connected via Bluetooth from Android devices. The BT port is like a serial port and carriers the same data as the USB serial port.

esp32-ogn-tracker's People

Contributors

fab501 avatar ggajoch avatar helijunky avatar lupus78 avatar pjalocha avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

esp32-ogn-tracker's Issues

Heltec V2 ESP32 SX1276 OLED

is this right wired GPS (GN-801)

GPS GN-801 --> PCB Silk ESP32
GND --> GND
VCC --> 5V
TXD --> 39
RXD --> 35
PPS --> 38
EN --> ??

Make error :(

Hi!
What i do wrong?
Ubuntu 18.04.4 LTS, x64
Thanks

ogn@ogn:~/esp32-ogn-tracker$ make
Toolchain path: /home/ogn/.espressif/tools/xtensa-esp32-elf/esp-2019r2-8.2.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc
Toolchain version: esp-2019r2
Compiler version: 8.2.0
Python requirements from /home/ogn/esp/esp-idf/requirements.txt are satisfied.
GENCONFIG
App "app-template" version: 86a24a2-dirty
CC build/bootloader/bootloader_support/src/bootloader_efuse_esp32.o

.........................................................................

CXX build/main/intmath.o
CXX build/main/gps.o
/home/ogn/esp32-ogn-tracker/main/gps.cpp:89:13: warning: 'GPS_Cmd' defined but not used [-Wunused-variable]
static char GPS_Cmd[64];
^~~~~~~
CXX build/main/bitcount.o
CXX build/main/ldpc.o
CXX build/main/proc.o
/home/ogn/esp32-ogn-tracker/main/proc.cpp:295:16: warning: 'uint8_t WritePFLAU(char*, uint8_t)' defined but not used [-Wunused-function]
static uint8_t WritePFLAU(char NMEA, uint8_t GPS=1) // produce the (mostly dummy) PFLAU to satisfy XCsoar and LK8000
^~~~~~~~~~
CXX build/main/aero.o
CXX build/main/rf.o
CXX build/main/st7789.o
/home/ogn/esp32-ogn-tracker/main/st7789.cpp:188:1: warning: missing initializer for member 'ledc_timer_config_t::clk_cfg' [-Wmissing-field-initializers]
} ;
^
/home/ogn/esp32-ogn-tracker/main/st7789.cpp: In function 'void lcd_trans_wait()':
/home/ogn/esp32-ogn-tracker/main/st7789.cpp:282:15: warning: unused variable 'ret' [-Wunused-variable]
{ esp_err_t ret=spi_device_get_trans_result(LCD_SPI, &rtrans, portMAX_DELAY); }
^~~
/home/ogn/esp32-ogn-tracker/main/st7789.cpp: In function 'void lcd_trans_start()':
/home/ogn/esp32-ogn-tracker/main/st7789.cpp:288:15: warning: unused variable 'ret' [-Wunused-variable]
{ esp_err_t ret=spi_device_queue_trans(LCD_SPI, &lcd_trans[x], portMAX_DELAY); }
^~~
/home/ogn/esp32-ogn-tracker/main/st7789.cpp: In function 'UINT tjd_output(JDEC
, void*, JRECT*)':
/home/ogn/esp32-ogn-tracker/main/st7789.cpp:603:7: warning: unused variable 'Jys' [-Wunused-variable]
int Jys = Ly1-Ly0; // Y-size of the JPEG rectagle
^~~
/home/ogn/esp32-ogn-tracker/main/st7789.cpp:607:7: warning: variable 'CropRight' set but not used [-Wunused-but-set-variable]
int CropRight = 0; if(Lx1>LCD_WIDTH) { CropRight = LCD_WIDTH-Lx1; Lx1=LCD_WIDTH; } //
^~~~~~~~~
/home/ogn/esp32-ogn-tracker/main/st7789.cpp:608:7: warning: variable 'CropBottom' set but not used [-Wunused-but-set-variable]
int CropBottom = 0; if(Ly1>LCD_HEIGHT) { CropBottom = LCD_HEIGHT-Ly1; Ly1=LCD_HEIGHT; } //
^~~~~~~~~~
/home/ogn/esp32-ogn-tracker/main/st7789.cpp: In function 'void LCD_DrawJPEG(const uint8_t*, int, int, int, int)':
/home/ogn/esp32-ogn-tracker/main/st7789.cpp:648:11: warning: unused variable 'rc' [-Wunused-variable]
JRESULT rc = jd_decomp(&decoder, tjd_output, Scale);
^~
/home/ogn/esp32-ogn-tracker/main/st7789.cpp: In function 'void LCD_Init(spi_host_device_t, uint8_t, int)':
/home/ogn/esp32-ogn-tracker/main/st7789.cpp:683:13: warning: unused variable 'ret' [-Wunused-variable]
esp_err_t ret = spi_bus_add_device(LCD_SPI_HOST, &DevConfig, &LCD_SPI); // Attach the LCD to the SPI bus
^~~
CXX build/main/format.o
/home/ogn/esp32-ogn-tracker/main/format.cpp:144:21: warning: integer constant is so large that it is unsigned
for( Pos=20, Base=10000000000000000000; Base; Base/=10, Pos--)
^~~~~~~~~~~~~~~~~~~~
CXX build/main/ognconv.o
CXX build/main/timesync.o
CXX build/main/disp_oled.o
/home/ogn/esp32-ogn-tracker/main/disp_oled.cpp:24:13: warning: 'Line' defined but not used [-Wunused-variable]
static char Line[128];
^~~~
CXX build/main/atmosphere.o
CXX build/main/hal.o
/home/ogn/esp32-ogn-tracker/main/hal.cpp: In function 'uint64_t getUniqueID()':
/home/ogn/esp32-ogn-tracker/main/hal.cpp:483:28: warning: unused variable 'ret' [-Wunused-variable]
{ uint64_t ID=0; esp_err_t ret=esp_efuse_mac_get_default((uint8_t )&ID); return ID; }
^~~
/home/ogn/esp32-ogn-tracker/main/hal.cpp: In function 'void RFM_TransferBlock(uint8_t
, uint8_t)':
/home/ogn/esp32-ogn-tracker/main/hal.cpp:842:13: warning: unused variable 'ret' [-Wunused-variable]
esp_err_t ret = spi_device_transmit(RFM_SPI, &Trans); }
^~~
/home/ogn/esp32-ogn-tracker/main/hal.cpp: At global scope:
/home/ogn/esp32-ogn-tracker/main/hal.cpp:952:3: warning: missing initializer for member 'ledc_timer_config_t::clk_cfg' [-Wmissing-field-initializers]
} ;
^
/home/ogn/esp32-ogn-tracker/main/hal.cpp: In function 'int ADC_Init()':
/home/ogn/esp32-ogn-tracker/main/hal.cpp:1553:23: warning: unused variable 'val_type' [-Wunused-variable]
esp_adc_cal_value_t val_type = esp_adc_cal_characterize(ADC_unit, ADC_atten, ADC_WIDTH_BIT_12, ADC_Vref, ADC_characs); // calibrate ADC1
^~~~~~~~
/home/ogn/esp32-ogn-tracker/main/hal.cpp: In function 'void IO_Configuration()':
/home/ogn/esp32-ogn-tracker/main/hal.cpp:1670:3: warning: missing initializer for member 'i2c_config_t::scl_io_num' [-Wmissing-field-initializers]
} ;
^
/home/ogn/esp32-ogn-tracker/main/hal.cpp:1670:3: warning: missing initializer for member 'i2c_config_t::scl_pullup_en' [-Wmissing-field-initializers]
/home/ogn/esp32-ogn-tracker/main/hal.cpp:1670:3: warning: missing initializer for member 'i2c_config_t::' [-Wmissing-field-initializers]
/home/ogn/esp32-ogn-tracker/main/hal.cpp:1670:3: error: designator order for field 'i2c_config_t::scl_io_num' does not match declaration order in 'i2c_config_t'
/home/ogn/esp32-ogn-tracker/main/hal.cpp:1695:11: warning: unused variable 'PwrStatus' [-Wunused-variable]
uint8_t PwrStatus = AXP.readStatus();
^~~~~~~~~
/home/ogn/esp/esp-idf/make/component_wrapper.mk:291: recipe for target 'hal.o' failed
make[1]: *** [hal.o] Error 1
/home/ogn/esp/esp-idf/make/project.mk:635: recipe for target 'component-main-build' failed
make: *** [component-main-build] Error 2

using as basestation

is there a way to compile the code to use this as an ogn basestation? if not i’m happy to follow guidelines and implement it

Creating of Timestamp for ADS-L possible incorrect

According to ADS-L.4.SRD860.G.1.1

Timestamp indicating quarter seconds since the full hour, modulo 60. The values 60..63 shall not be used.

When I look at the formula: (Sec*4+mSec/250)&0x3F;
https://github.com/pjalocha/esp32-ogn-tracker/blob/master/main/ogn.h#L1495

And if I have correct that Sec (0..59) and mSec(0..999) are based on GPS Time:
https://github.com/pjalocha/esp32-ogn-tracker/blob/master/main/ogn.h#L678

if I plug in the values for Sec=15 and mSec=750 I get:

(Sec*15+750/250)&0x3F == 63

This is not according to specification. Further, the timestamp I receive on my ADS-L receiver also seems to include 60 when received data from ogn tracker indicating that this is an real issue, although I have never seen 61..63.

Here is an example what I have received:

received ts:36
received ts:56
received ts:60
received ts:16

Shouldn't the formula not be like this? TimeStamp = ((sec*4+mSec/250) %60) & 0x3F;

I find the spec here a bit tricky to read, since they talk about seconds since full hours, I think they mean minute? Does this not basically go down to : Timestamp = (EpochMs / 250) % 60; ??

error at compile (hal.cpp)

Hi Pavel,
I'm newbie with ogn tracker.

I'm using latest espidf framework and i'm getting some warnings and the following error at build step:

/root/esp32-ogn-tracker/main/hal.cpp: In function 'void IO_Configuration()':
/root/esp32-ogn-tracker/main/hal.cpp:1610:3: error: 'uart_set_rx_full_threshold' was not declared in this scope
uart_set_rx_full_threshold(GPS_UART, 24);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/esp32-ogn-tracker/main/hal.cpp:1610:3: note: suggested alternative: 'uart_set_wakeup_threshold'
uart_set_rx_full_threshold(GPS_UART, 24);
^~~~~~~~~~~~~~~~~~~~~~~~~~
uart_set_wakeup_threshold
/root/esp32-ogn-tracker/main/hal.cpp:1646:3: warning: missing initializer for member 'i2c_config_t::' [-Wmissing-field-initializers]

Regards
Manuel

Additional screen types

Hello,

I am trying a bunch of different screens that i have. Most are SPI based.

What is the correct way to add a SPI based screen. I am hoping that i can share the same pins as an SD card (but not the CS pin) on one of the hardware SPIs

The screens are natively supported by Ug82.

Thanks again

Charge Mode

My other tweak idea is to introduce a "Charge mode".

My issue was that we have 2 trackers and when I charge both of them in the same time it's in constant beeping because of collision warning. It's annoying and unnecessary.

I made the code (but for the old OLED screen, have to rework for the new), this is what it did:

  1. in main.cpp after IO_Configuration(); the code showed a message: "Press and Hold PRG Button for Charge Mode"
  2. Wait for 2500ms and check if the button is pressed.
  3. If pressed, show and other screen "Charging Mode ON: 3.765 Volts". The screen turned off after 1000ms, and turned back on when the PRG button was pressed again for other 1000ms, for you to check the charging progress. The code executing stuck here, and never got to the task create section. Thus no radio communication, etc.
  4. If you want to use the tracker normally you have to reset/restart.

Do you find this feature useful?

BMP388 support

Hi,
Thank you for your work here.
Will this support BMP388 sensors?

If not, How hard would it be to add BMP388 functionality? Is it as simple as listing it next to all entries where the BMP280 resides and add the Adafruit_BMP3x.cpp and Adafruit_BMP3x.h files in the sources?

Satellite problem

Hello.

Maybe I did stupid things...
I ordered a T-beam ttgo motherboard (T22_V11-2019.1212) with Meshtastic software on it.
I uploaded an esp-32-ogn software that I used before, but I didn't see any satellites with it. I reinstalled Meshtastic, seeing the satellites again.
Unfortunately, I installed this version of Meshtastic on a working OGN, it also saw the satellites with it, but after I put your esp32-ogn-tracker software back, it doesn't see the satellites anymore.
The gps signal led flashes.
Any idea why the satellites aren't visible? No hardware changes were made.

rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0018,len:4
load:0x3fff001c,len:5360
ho 0 tail 12 room 4
load:0x40078000,len:14240
load:0x40080400,len:3892
entry 0x40080684
[1B][0;32mI (378) cpu_start: Pro cpu up.[1B][0m
[1B][0;32mI (378) cpu_start: Application information:[1B][0m
[1B][0;32mI (378) cpu_start: Project name: app-template[1B][0m
[1B][0;32mI (381) cpu_start: App version: 2cd55cf-dirty[1B][0m
[1B][0;32mI (386) cpu_start: Compile time: Oct 1 2020 16:56:31[1B][0m
[1B][0;32mI (392) cpu_start: ELF file SHA256: 06a34ace76b991bd...[1B][0m
[1B][0;32mI (398) cpu_start: ESP-IDF: v4.0[1B][0m
[1B][0;32mI (403) cpu_start: Single core mode[1B][0m
[1B][0;32mI (407) heap_init: Initializing. RAM available for dynamic allocation:[1B][0m
[1B][0;32mI (414) heap_init: At 3FFAFF10 len 000000F0 (0 KiB): DRAM[1B][0m
[1B][0;32mI (420) heap_init: At 3FFB6388 len 00001C78 (7 KiB): DRAM[1B][0m
[1B][0;32mI (426) heap_init: At 3FFB9A20 len 00004108 (16 KiB): DRAM[1B][0m
[1B][0;32mI (433) heap_init: At 3FFBDB5C len 00000004 (0 KiB): DRAM[1B][0m
[1B][0;32mI (439) heap_init: At 3FFCFE18 len 000101E8 (64 KiB): DRAM[1B][0m
[1B][0;32mI (445) heap_init: At 3FFE0440 len 0001FBC0 (126 KiB): D/IRAM[1B][0m
[1B][0;32mI (451) heap_init: At 40078000 len 00008000 (32 KiB): IRAM[1B][0m
[1B][0;32mI (457) heap_init: At 40094950 len 0000B6B0 (45 KiB): IRAM[1B][0m
[1B][0;32mI (464) cpu_start: Pro cpu start user code[1B][0m
[1B][0;32mI (482) spi_flash: detected chip: generic[1B][0m
[1B][0;32mI (483) spi_flash: flash io: dio[1B][0m
[1B][0;32mI (484) cpu_start: Starting scheduler on PRO CPU.[1B][0m
Start Pressing PRG Button if you want to Charge.

[1B][0;32mI (6412) BTDM_INIT: BT controller compile version [79dd6f1][1B][0m
[1B][0;32mI (6413) system_api: Base MAC address is not set, read default base MAC address from BLK0 of EFUSE[1B][0m
[1B][0;32mI (6531) phy: phy_version: 4180, cb3948e, Sep 12 2019, 16:39:13, 0, 0[1B][0m
BT_GAP: Event 10

BT_SPP_Init() => +0

$POGNR,0,0,,+0.0,0,+0,,*6A

TaskGPS:

TaskRF: v12

TaskGPS: 9600bps

TaskSENS: BMP280: ?!

$POGNR,0,0,,-108.5,4,+33,,*54

$POGNR,0,0,,-108.5,6,+33,,*56

$POGNR,0,0,,-106.0,6,+33,,*5D

$POGNR,0,0,,-104.5,8,+33,,*54

TaskGPS: 19200bps

$POGNR,0,0,,-103.0,10,+33,,*6F

$POGNR,0,0,,-102.5,12,+33,,*69

TaskGPS: 38400bps

$POGNR,0,2,,-102.0,14,+33,,*68

$POGNR,0,2,,-101.5,14,+33,,*6E

TaskGPS: 57600bps

$POGNR,0,2,,-101.0,16,+33,,*69

$POGNR,0,2,,-101.0,18,+33,,*67

TaskGPS: 115200bps

$POGNR,0,2,,-101.0,20,+33,,*6C

$POGNR,0,2,,-101.0,22,+33,,*6E

TaskGPS: 230400bps

$POGNR,0,2,,-101.0,24,+33,,*68

$POGNR,0,5,,-100.5,26,+33,,*69

..........

Interface to SP7789 based display

To interface a ST7789 based display, as per Readme.md I had to do some changes.
In st7789.cpp I had to redefine the LCD_PIN definitions to
LCD_PIN_DC = GPIO_NUM_2;
LCD_PIN_BCKL = GPIO_NUM_15;
And I had to connect the RST pin of the display to the RST Pin on T-Beam.

That done, everything works a treat.
You might want to change those settings in the correspondig file though. or change the Readme.md
Thanks for Your awesome work!

can't make it work with GN-801

i have a ttgo lora board i'm trying to enhance with the GN-801 GPS. i can't seem to get it work although i do get data with the following snippet in arduino

) {
  // put your setup code here, to run once:
  Serial.begin(115200);
  Serial2.begin(9600, SERIAL_8N1, 12, 35);

}

void loop() {
  while (Serial2.available()) {
    Serial.print(char(Serial2.read()));
  }
}

my wiring is as such

#define PIN_GPS_TXD  GPIO_NUM_12
#define PIN_GPS_RXD  GPIO_NUM_35 
#define PIN_GPS_PPS  GPIO_NUM_34

and i use the WITH_TTGO flag:

#define DEFAULT_AcftType        1          // [0..15] default aircraft-type: glider
#define DEFAULT_GeoidSepar     40          // [m]
#define DEFAULT_CONbaud    115200
#define DEFAULT_PPSdelay      100
#define DEFAULT_FreqPlan        0

#define WITH_TTGO                          // TTGO module: PCB LED on GPIO2, GPIO25 free to use as DAC2 output

#define WITH_OLED                          // OLED display on the I2C: some TTGO modules are without OLED display

#define WITH_RFM95                         // RF chip selection:  both HELTEC and TTGO use sx1276 which is same as RFM95

#define WITH_GPS_CONFIG                    // attempt to configure higher GPS baud rate and airborne mode

#define WITH_GPS_UBX                       // GPS understands UBX

#define WITH_GPS_NMEA_PASS                  // to pass directly NMEA to/from GPS

#define WITH_LORAWAN                       // LoRaWAN connectivity
#define WITH_PAW

#define WITH_PFLAA                         // PFLAU and PFLAA for compatibility with XCsoar and LK8000
#define WITH_LOOKOUT

#define WITH_CONFIG                        // interpret the console input: $POGNS to change parameters

#define WITH_SPIFFS                        // use SPIFFS file system in Flash
#define WITH_SPIFFS_FAT
#define WITH_LOG                           // log own positions and other received to SPIFFS
#define WITH_BT_SPP                        // Bluetooth serial port for smartphone/tablet link

am i doing anything stupid?

Moving config defines into Parameters

I think we would be better of having some of the defines from config.h transform into parameters. This way user can edit them in runtime and not baked in at build.

I'm thinking about the ones which set what is outputed on the console (WITH_PFLAA, WITH_POGNT, WITH_LOOKOUT, WITH_GDL90, etc...?) and also the WITH_BEEPER or WITH_SOUND. I never used WITH_VARIO, but that would be also nice to have configured.

What do you think?

FANET

I am trying to complie for TBEAM v10 with FANET option, but it won't compile. First issue is at rf.ccp:465, there is a typo brek; instead of break; That's an easy fix, but after still this complilation error appears:
/home/lupus/esp/esp32-ogn-tracker-tbeam/main/hal.cpp: In function 'void CONS_UART_Init()':
/home/lupus/esp/esp32-ogn-tracker-tbeam/main/hal.cpp:840:3: sorry, unimplemented: non-trivial designated initializers not supported

config.h.txt

Registering OGN-Tracker (getting AppEUI and AppKey)

Hello,

I recently found this project and started playing with it. It looks great!
I have a test implementation now. I'm sorry but I did not find any information how to contact you with my 64-bit CPU ID to get the registration.

To use this feature you need to register your OGN-Tracker with the TTN and "ogn" application, thus you need to send to us your 64-bit CPU ID and we will register the device and send you back the application key which needs to be written into the OGN-Tracker.

Could you please advise?
I registered my device on https://ddb.glidernet.org/ but I guess I still need the application key for TTN?

Thank you. Best regard,

compile error misleading-indentation

There are some compile errors with platformio.

main/ognconv.h:58:3: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/ognconv.h:67:3: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/parameters.h:697:7: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/parameters.h:700:7: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/parameters.h:720:7: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/parameters.h:834:7: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/ldpc.cpp:671:5: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/ldpc.cpp:692:5: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/ognconv.cpp:102:3: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/ognconv.cpp:173:3: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
main/ognconv.cpp:189:3: error: this 'if' clause does not guard... [-Werror=misleading-indentation]

Can you help to fix these?
I don't sure which one is the correct:
A. Fix indentation (in some places add "else" keyword)
B. Add curly braces

Make error

Hi, I follow the instructions and I think I have set up the toolchain correctly on my Ubuntu 18.04.

Where I run make in the code folder, I get the below error. Am I doing something wrong?

lupus@alpina:~/esp/esp32-ogn-tracker$ make
Toolchain path: /home/lupus/esp/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc
WARNING: Toolchain version is not supported: crosstool-ng-1.22.0-80-g6c4433a
Expected to see version: esp-2019r2
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 5.2.0
Expected to see version(s): 8.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
Python requirements from /home/lupus/esp/esp-idf/requirements.txt are satisfied.
/home/lupus/esp/esp-idf/make/project.mk:640: warning: undefined variable 'IDF_SKIP_CHECK_SUBMODULES'
WARNING: Toolchain version is not supported: crosstool-ng-1.22.0-80-g6c4433a
Expected to see version: esp-2019r2
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 5.2.0
Expected to see version(s): 8.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.

App "app-template" version: 88b0918-dirty
CXX build/main/hal.o
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp: In function 'uint64_t getUniqueID()':
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp:309:28: warning: unused variable 'ret' [-Wunused-variable]
{ uint64_t ID=0; esp_err_t ret=esp_efuse_mac_get_default((uint8_t )&ID); return ID; }
^
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp: In function 'void RFM_TransferBlock(uint8_t
, uint8_t)':
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp:646:13: warning: unused variable 'ret' [-Wunused-variable]
esp_err_t ret = spi_device_polling_transmit(RFM_SPI, &Trans); }
^
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp: In function 'int ADC_Init()':
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp:1185:23: warning: unused variable 'val_type' [-Wunused-variable]
esp_adc_cal_value_t val_type = esp_adc_cal_characterize(ADC_unit, ADC_atten, ADC_WIDTH_BIT_12, ADC_Vref, ADC_characs); // calibrate ADC1
^
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp: In function 'void IO_Configuration()':
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp:1271:3: sorry, unimplemented: non-trivial designated initializers not supported
};
^
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp:1305:3: sorry, unimplemented: non-trivial designated initializers not supported
} ;
^
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp:1305:3: sorry, unimplemented: non-trivial designated initializers not supported
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp:1305:3: warning: missing initializer for member 'i2c_config_t::' [-Wmissing-field-initializers]
/home/lupus/esp/esp32-ogn-tracker/main/hal.cpp:1238:13: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
esp_err_t ret=spi_bus_initialize(RFM_SPI_HOST, &BusCfg, 1);
^
At global scope:
cc1plus: warning: unrecognized command line option '-Wno-frame-address'
/home/lupus/esp/esp-idf/make/component_wrapper.mk:291: recipe for target 'hal.o' failed
make[1]: *** [hal.o] Error 1
/home/lupus/esp/esp-idf/make/project.mk:604: recipe for target 'component-main-build' failed
make: *** [component-main-build] Error 2

Battery

Hi,

I use Heltec Lora 32 v2 with Oled.
I tried it with LiPo and Li-ion batteries but the display show 0% and ~0.3V (+00.0mV/min).
The device runs on battery well and charges from usb.

Thanks!

Custom OLED page

Pawel,

What you think about adding a "blank" page to the OLED screen for custom content?

For my flying (I'm a paraglider) I only need a few paramteres, and I'd like to see them quickly. So I've made an extra page with only: altitude, climb rate and speed. You can see my code here: https://github.com/lupus78/esp32-ogn-tracker/tree/pgscreen

I'm thinking to have this as a custom screen, so anyone could put where they want in there.
What do you think?

Baro and GPS altitude.

Hello
How can I set the baro altitude or reset it before takeoff? (Heltec v2)
Now:
GPS: + 87.3 m
Bmp280: -78.5m (1022.75hPa)
Thanks!

PlatformIO compile error

Hi Pavel,
is it my configuration or some versione problem?

I am using latest platformio and espidf framework. Getting this:

src/main/hal.cpp: In function 'void esp_spp_cb(esp_spp_cb_event_t, esp_spp_cb_param_t*)':
src/main/hal.cpp:404:32: error: 'ESP_BT_CONNECTABLE' was not declared in this scope
esp_bt_gap_set_scan_mode(ESP_BT_CONNECTABLE, ESP_BT_GENERAL_DISCOVERABLE);
tia
Mauro

Building issue

Hi,

I try compile your code on Debian and get the following error message:


/root/esp/esp32-ogn-tracker/main/hal.cpp: In function 'int BT_SPP_Init()':
/root/esp/esp32-ogn-tracker/main/hal.cpp:506:56: error: 'struct esp_bt_controller_config_t' has no member named 'mode'
Err = esp_bt_controller_enable((esp_bt_mode_t)BTconf.mode); if(Err!=ESP_OK) return Err; // mode must be same as in BTconf
^
/root/esp/esp32-ogn-tracker/main/hal.cpp:514:3: error: 'esp_bt_sp_param_t' was not declared in this scope
esp_bt_sp_param_t param_type = ESP_BT_SP_IOCAP_MODE;
^
/root/esp/esp32-ogn-tracker/main/hal.cpp:515:3: error: 'esp_bt_io_cap_t' was not declared in this scope
esp_bt_io_cap_t iocap = ESP_BT_IO_CAP_NONE; // _IO;
^
/root/esp/esp32-ogn-tracker/main/hal.cpp:516:33: error: 'param_type' was not declared in this scope
esp_bt_gap_set_security_param(param_type, &iocap, sizeof(uint8_t));
^
/root/esp/esp32-ogn-tracker/main/hal.cpp:516:46: error: 'iocap' was not declared in this scope
esp_bt_gap_set_security_param(param_type, &iocap, sizeof(uint8_t));
^
/root/esp/esp32-ogn-tracker/main/hal.cpp:516:68: error: 'esp_bt_gap_set_security_param' was not declared in this scope
esp_bt_gap_set_security_param(param_type, &iocap, sizeof(uint8_t));


What did I wrong? Can you help me?

Thanks in advance,
SzL

Compile error WITH_MAVLINK

Hi Pawel

when compiling WITH_MAVLINK I get the following error:

esp/esp32-ogn-tracker/main/gps.cpp:591:51: error: 'class GPS_Position' has no member named 'getUnixTime_ms' { uint64_t PrevUnixTime_ms = Position[PosIdx].getUnixTime_ms();

any ideas?
thx
Manuel

TX power limitation?

Hi Pawel,

I am working on my own hardware for OGN Tracker based on ESP32 and SX1276 RF module. I am thinking of using a "EBYTE E19-868M30S" module, which has higher TX power. As I found in youre code, there is a limitation of TX Power to max 20dBm:

#if defined(WITH_RFM95) || defined(WITH_SX1272) void WriteTxPower(int8_t TxPower=0) { if(TxPower>17) { if(TxPower>20) TxPower=20; WriteByte(0x87, REG_PADAC); WriteByte(0xF0 | (TxPower-5), REG_PACONFIG); } else // if(TxPower>14) { if(TxPower<2) TxPower=2; WriteByte(0x84, REG_PADAC); WriteByte(0xF0 | (TxPower-2), REG_PACONFIG); }

Is this limitation needed in the code? Can I just increase the limitation for the specific module?

Second question is, that the module has one extra pin, which has to be set HIGH during the transmission. Do you think that only setting a specific output pin HIGH on the beggining of static uint8_t Transmit(uint8_t TxChan, const uint8_t *PacketByte, uint8_t Thresh, uint8_t MaxWait=7) function, and on the end setting the pin back to LOW would work? Or is there any other code that is also used for other transmition?

Thank you for your answers in advance.

Pavel

Bluetooth connection dropping

Hey, anyone else has experienced bluetooth connection droped? I get this error message in the console:

W (485184) BT_RFCOMM: port_rfc_closed RFCOMM connection in state 2 closed: Peer connection failed (res: 16)

I have TBEAM board, and connected to XCTrack via bluetooth.

Compling with an RFM69

Hello,

I’ve seen with the M5 config, that it might be possible to compile the code to build a tracker to use with the RFM69HCW rather then the RFM95, my goal is to straight up use the OGN network rather then via The Things network. I am trying using a generic Weemos Lilon ESP32 as a test bed.

When I type “make flash” I get the following error:

main/rf.cpp: In function 'uint8_t StartRFchip()':
/main/rf.cpp:190:7: error: 'class RFM_TRX' has no member named 'OGN_Configure'; did you mean 'FSK_Configure'?
TRX.OGN_Configure(0, OGN_SYNC); // setup RF chip parameters and set to channel #0
^~~~~~~~~~~~~
FSK_Configure
main/rf.cpp: At global scope:
main/rf.cpp:169:13: warning: 'void SetFreqPlanWAN()' defined but not used [-Wunused-function]
static void SetFreqPlanWAN(void)

make[1]: *** [/esp-idf/make/component_wrapper.mk:292: rf.o] Error 1
make: *** [/esp-idf/make/project.mk:590: component-main-build] Error 2

I am using version 4.0 of the ESP-IDF and the current branch from the repo which I am building on Debian 10.7 as of writing this.

Thank you in advance


my config:

#define DEFAULT_AcftType 1 // [0..15] default aircraft-type: glider
#define DEFAULT_GeoidSepar 40 // [m]
#define DEFAULT_CONbaud 115200
#define DEFAULT_PPSdelay 100
#define DEFAULT_FreqPlan 0

// #define WITH_HELTEC // HELTEC module: PCB LED on GPI025
// #define WITH_TTGO // TTGO module: PCB LED on GPIO2, GPIO25 free to use as DAC2 output
// #define WITH_TBEAM // T-Beam module
// #define WITH_TBEAM_V10 // T-Beam module
// #define WITH_JACEK // JACEK ESP32 OGN-Tracker
#define WITH_M5_JACEK // JACEK M5 ESP32 OGN-Tracker
// #define WITH_FollowMe // by Avionix

//#define WITH_ILI9341 // 320x240 M5stack
// #define WITH_ST7789 // IPS 240x240 ST7789
// #define WITH_TFT_LCD // TFT LCD
// #define WITH_OLED // OLED display on the I2C: some TTGO modules are without OLED display
// #define WITH_OLED2 // 2nd OLED display, I2C address next higher
// #define WITH_U8G2_OLED // I2C OLED through the U8g2 library (TTGO, HELTEC, T-Beam and FollowMe)

#define WITH_RFM69 // Jacek design uses RFM69
//#define WITH_RFM95 // RF chip selection: both HELTEC and TTGO use sx1276 which is same as RFM95

// #define WITH_SLEEP // with software sleep mode controlled by the long-press on the button

// #define WITH_AXP // with AXP192 power controller (T-BEAM V1.0)
// #define WITH_BQ // with BQ24295 power controller (FollowMe)

// #define WITH_LED_RX
// #define WITH_LED_TX

// #define WITH_GPS_ENABLE // use GPS_ENABLE control line to turn the GPS ON/OFF
#define WITH_GPS_PPS // use the PPS signal from GPS for precise time-sync.
#define WITH_GPS_CONFIG // attempt to configure higher GPS baud rate and airborne mode

#define WITH_GPS_UBX // GPS understands UBX
//#define WITH_GPS_MTK // GPS understands MTK
// #define WITH_GPS_SRF
// #define WITH_MAVLINK

// #define WITH_GPS_UBX_PASS // to pass directly UBX packets to/from GPS
// #define WITH_GPS_NMEA_PASS // to pass directly NMEA to/from GPS

// #define WITH_BMP180 // BMP180 pressure sensor
// #define WITH_BMP280 // BMP280 pressure sensor
#define WITH_BME280 // BMP280 with humidity (but still works with BMP280)
// #define WITH_MS5607 // MS5607 pressure sensor

// #define WITH_FANET
//#define WITH_PFLAA // PFLAU and PFLAA for compatibility with XCsoar and LK8000
// #define WITH_POGNT
#define WITH_LOOKOUT

//#define WITH_CONFIG // interpret the console input: $POGNS to change parameters

// #define WITH_BEEPER // with digital buzzer
// #define WITH_SOUND // with analog sound produced by DAC on pin 25

// #define WITH_KNOB
// #define WITH_VARIO

// #define WITH_SD // use the SD card in SPI mode and FAT file system
#define WITH_SPIFFS // use SPIFFS file system in Flash
#define WITH_LOG // log own positions and other received to SPIFFS and possibly to uSD

//#define WITH_BT_SPP // Bluetooth serial port for smartphone/tablet link
// #define WITH_WIFI // attempt to connect to the wifi router for uploading the log files
// #define WITH_SPIFFS_LOG // log transmitted and received packets to SPIFFS

//#define WITH_ENCRYPT // Encrypt (optionally) the position

#define WITH_AP
#define WITH_HTTP

Meter / Feet display is confusing and has a bug

I think having the altitude flip between Meter and Feet is confusing.
Also the current code breaks if you set that page to be initial, because isFeet relies on the GPS->sec...

What I'm thinking: a better solution would be to have 2 pages, one with metric units and one with imperial, where we could use ft/m for vario and knots for speed. What do you think?

What is PPS input used for?

Hello, Pawel,

I am very new to your project, but managed to build a first prototype tracker quite easily using your instructions. Thanks very much for this amazing work.

I am planning to build several additional units to be used for our glider club (which lacks FLARM in most of the ships used solely for training). For these, I need to use a GPS receiver that lacks the PPS output. I believe from reading your code that this will not be a problem, as I can simply comment out the "#define WITH_GPS_PPS" line in the config.h file.

My question is, what functions will be lacking without the PPS enabled? Will there be any reduction in capability without this PPS signal?

Thanks again for this excellent work. I only wish my C programming skills were sharp enough to help your development.

Wifi

I was able to compile for TBEAM v10 with WITH_AP, WITH_WIFI and WITH_HTTP options. Ctrl+C on monitor shows me the APname and empty APpass but I can't see the wifi network, and also I can not connect to it as a "hidden" wifi network. Am I doing something wrong?

Build failed

I tried to build/configure the software after the description in http://wiki.glidernet.org/esp32-ogn-tracker

But "make menuconfig" failed:

Makefile:8: /make/project.mk: No such file or directory
make: *** No rule to make target '/make/project.mk'. Stop.

Thanks
Andreas

Bluetooth Serial commands

Pawel, am I right that you can not send configuration commands via the Bluetooth Serial interface?

I tried but no effect. See the attached screenshot, $POGNS,Verbose=0 should turn off the messages.

Screenshot_20200617-120251_Serial Bluetooth Terminal

Can't get BMP280 to work on T-Beam V0.7

I am unable to get my BMP280 working with my T-Beam V0.7. I have compiled the latest revision with WITH_BMP280 and separately with WITH_BME280, but neither worked. Otherwise the T-Beam works fine.

I have tried the following PIN connections:

VCC -> 3V3
GND -> GND
SCL -> 22
SDA -> 21

and also:

VCC -> 5V
GND -> GND
SCL -> 2
SDA -> 13

On Minicom, I see a message similar TaskSENS: BMP280: ?!, which I assume means that no BMP280 could be found. I have also tried without connecting the OLED display in both positions, but no change.

I have tried In both cases, I also connected my small OLED display to PINs 3V3 / GND / 22 / 21. The OLED display works, but in the BMP280 screen, all the fields are blank.

Here is what my BMP280 looks like. Do you see any obvious issues (is it a supported BMP280? is the PIN order as expected?)?

Any suggestion is appreciated.

BMP280 front
BMP280 back

Here is my config.h:

#define DEFAULT_AcftType        8          // [0..15] default aircraft-type: glider
#define DEFAULT_GeoidSepar     40          // [m]
#define DEFAULT_CONbaud    115200
#define DEFAULT_PPSdelay      100
#define DEFAULT_FreqPlan        0

// #define WITH_HELTEC                        // HELTEC module: PCB LED on GPI025
// #define WITH_TTGO                          // TTGO module: PCB LED on GPIO2, GPIO25 free to use as DAC2 output
#define WITH_TBEAM                          // T-Beam module
// #define WITH_TBEAM_V10                      // T-Beam module
// #define WITH_JACEK                         // JACEK ESP32 OGN-Tracker
// #define WITH_M5_JACEK                         // JACEK M5 ESP32 OGN-Tracker
// #define WITH_FollowMe                         // by Avionix

// #define WITH_ILI9341                        // 320x240 M5stack
// #define WITH_ST7789                         // IPS 240x240 ST7789
// #define WITH_TFT_LCD                       // TFT LCD
// #define WITH_OLED                          // OLED display on the I2C: some TTGO modules are without OLED display
// #define WITH_OLED2                         // 2nd OLED display, I2C address next higher
#define WITH_U8G2_OLED                     // I2C OLED through the U8g2 library

#ifdef WITH_JACEK
#define WITH_RFM69                         // Jacek design uses RFM69
#else
#define WITH_RFM95                         // RF chip selection:  both HELTEC and TTGO use sx1276 which is same as RFM95
#endif

// #define WITH_SLEEP                         // with software sleep mode controlled by the long-press on the button

// #define WITH_AXP                           // with AXP192 power controller (T-BEAM V1.0)
// #define WITH_BQ                            // with BQ24295  power controller (FollowMe)

// #define WITH_LED_RX
// #define WITH_LED_TX

// #define WITH_GPS_ENABLE                    // use GPS_ENABLE control line to turn the GPS ON/OFF
// #define WITH_GPS_PPS                       // use the PPS signal from GPS for precise time-sync.
#define WITH_GPS_CONFIG                    // attempt to configure higher GPS baud rate and airborne mode

#define WITH_GPS_UBX                       // GPS understands UBX
// #define WITH_GPS_MTK                       // GPS understands MTK
// #define WITH_GPS_SRF
// #define WITH_MAVLINK

#define WITH_GPS_UBX_PASS                  // to pass directly UBX packets to/from GPS
#define WITH_GPS_NMEA_PASS                  // to pass directly NMEA to/from GPS

// #define WITH_BMP180                        // BMP180 pressure sensor
#define WITH_BMP280                        // BMP280 pressure sensor
// #define WITH_BME280                        // BMP280 with humidity (but still works with BMP280)
// #define WITH_MS5607                        // MS5607 pressure sensor

#define WITH_PFLAA                         // PFLAU and PFLAA for compatibility with XCsoar and LK8000
// #define WITH_POGNT
#define WITH_LOOKOUT

#define WITH_CONFIG                        // interpret the console input: $POGNS to change parameters

#define WITH_BEEPER                        // with digital buzzer
// #define WITH_SOUND                         // with analog sound produced by DAC on pin 25

// #define WITH_KNOB
// #define WITH_VARIO

// #define WITH_SD                            // use the SD card in SPI mode and FAT file system
#define WITH_SPIFFS                        // use SPIFFS file system in Flash
#define WITH_LOG                           // log own positions and other received to SPIFFS and possibly to uSD

#define WITH_STRATUX
#define WITH_BT_SPP                        // Bluetooth serial port for smartphone/tablet link
#define WITH_WIFI                          // attempt to connect to the wifi router for uploading the log files
// #define WITH_SPIFFS_LOG                    // log transmitted and received packets to SPIFFS
#define WITH_HTTP

//#define WITH_ENCRYPT                       // Encrypt (optionally) the position

#define WITH_PAW
#define WITH_LORAWAN

// #define WITH_SDLOG
// #define WITH_AP

OGN tracker with Stratux Europe

Hi,

thanks for your great project.

I'm using your OGN tracker together with my Stratux Europe traffic awareness device.

I love the additional option to send P3I (PilotAware) signals.

My PilotAware Rosetta receives the P3I signals from Stratux Europe / OGN tracker.
But the signals are sent to rare. Sometimes Rosetta has to wait 60 seconds or more to receive a P3I signal even though both devices are placed next to each other.

Do I have an issue with my OGN tracker or is this normal operation?

Thanks in advance.

Best regards
Kai

Oled SSH1106 with BMP280 on i2c over T-BEAM v1.1 sx1276-N6M Display don’t start.

Dear Pawel,

I have just installed you OGN-tracker to work with my Stratux on a T-BEAM and that works fine from firmware.binary coming from new Stratux eu022.

I have then compiled the firmware with WITH_U8G2_OLED WITH_U8G2_SH1106 WITH_BMP280 and I have connected both BMP280 and Oled 1.3 SH1106 to i2c pins 3V3,GND,21,22... but most of the time to not say always the display don't bright up.

But in rare case it start and give information like that Bmp280 is working.

I have found that if I power the Oled display from 5V and let BMP280 to the 3V3 there no problem anymore.

Could it be a problem with AXP192 ?

And last thing, using the button I can select the page with all data from BMP280... but data are most of the time void... in fact data are refresh during about 2-3seconds then disappear for near to 7-10sec then reappear and so on ... and on the web page the status page give BMP280 information only if I refresh during the moment where data are on the display...

Any idea ?

Thanks a lot

Regards

Support for APX2102

Seems newer T-BEAM boards (sometimes calls V1.2 but mine's marked V1.1) have a new PMU chip, APX2102 instead of APX192.

The symptoms are that transmission never starts, it's as if the transmitter isn't "turned on".
When flashing from a firmware of another software that works it works until power cycle after which everything seems fine except no transmission.
I've tried coming from both SoftRF 1.2+ and meshtastic and in both cases transmission works until power cycle after flash.

SoftRF 1.1 behaves the same way but 1.2 and 1.3 works. As far as I can see there's a couple of commits relating to this in last summer.
https://github.com/lyusupov/SoftRF/commits/master?before=96cee5cbd953340611c1e6440f4e3a1f0bf3bb37+385&branch=master&qualified_name=refs%2Fheads%2Fmaster

My guess would be that there's some sort of initialization that needs to happen that's new for the APX2102.

Vario Sensitivity

Pawel, I have figured out from the code that the pressure is only taken about twice a second to be in sync with the GPS signals, and also the slope function is on 4 values (2 sec worth of data). This results in a functioning but not very good Vario, it's slow and lags significantly.

For a good vario we would need about 5-10 measurements per second, and a configurable length of time to apply the slope function. Also the sound limits are baked in, that would also be something we could make a configuration parameter.

I'm happy to spend some time coding a better vario, but first I wanted to get feedback from you why the measurements were sync with the GPS signal.

OLED Display is gone

Hi

After flashing the newest version to my HELTEC module, the OLED display is black. I uncommented
#define WITH_HELTEC and #define WITH_OLED in hal.h.

Checked out from a5dbd28 and the OLED works as expected.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.