sudomesh / disaster-radio

A (paused) work-in-progress long-range, low-bandwidth wireless disaster recovery mesh network powered by the sun.
https://disaster.radio
1.04k stars 110 forks source link

Brownout detector was triggered TTGO Lora32 T3_1.6.1 #118

Open robbo007 opened 1 year ago

robbo007 commented 1 year ago

Hi guys, Trying to compile code and upload to my TTGO Lora32 T3_1.6.1. I can compile the source (firmware) without problems and it uploads to my device but when I run the pio monitor command I see I get the error:

`rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT) configsip: 188777542, 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:0x3fff0030,len:1184 load:0x40078000,len:13132 load:0x40080400,len:3036 entry 0x400805e4 [ 227][E][Preferences.cpp:483] getString(): nvs_get_str len fail: un NOT_FOUND No name saved Got username Got IF setting WiFi Got txPwr setting 17 Got loraFrq setting 915 Got sf setting 9 [ 238][E][Preferences.cpp:503] getBytesLength(): nvs_get_blob len fail: duty NOT_FOUND Got duty setting 0.100000 Got interval setting 10000 Got gps setting 0

rst:0x8 (TG1WDT_SYS_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT) configsip: 188777542, 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:0x3fff0030,len:1184 load:0x40078000,len:13132 load:0x40080400,len:3036 entry 0x400805e4 [ 227][E][Preferences.cpp:483] getString(): nvs_get_str len fail: un NOT_FOUND No name saved Got username Got IF setting WiFi Got txPwr setting 17 Got loraFrq setting 915 Got sf setting 9 [ 238][E][Preferences.cpp:503] getBytesLength(): nvs_get_blob len fail: duty NOT_FOUND Got duty setting 0.100000 Got interval setting 10000 Got gps setting 0

Brownout detector was triggered

ets Jun 8 2016 00:22:57

`

robbo007 commented 1 year ago

So it looks like building the code from scratch is broken. Can anyone assist. Thanks

robbo007 commented 1 year ago

Tried building the code again and flashing the TTGO. Monitor displays:

`rst:0x8 (TG1WDT_SYS_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT) configsip: 188777542, 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:0x3fff0030,len:1184 load:0x40078000,len:13132 load:0x40080400,len:3036 entry 0x400805e4 [ 227][E][Preferences.cpp:483] getString(): nvs_get_str len fail: un NOT_FOUND No name saved Got username Got IF setting WiFi Got txPwr setting 17 Got loraFrq setting 915 Got sf setting 9 [ 238][E][Preferences.cpp:503] getBytesLength(): nvs_get_blob len fail: duty NOT_FOUND Got duty setting 0.100000 Got interval setting 10000 Got gps setting 0

rst:0x8 (TG1WDT_SYS_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT) configsip: 188777542, 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:0x3fff0030,len:1184 load:0x40078000,len:13132 load:0x40080400,len:3036 entry 0x400805e4 [ 227][E][Preferences.cpp:483] getString(): nvs_get_str len fail: un NOT_FOUND No name saved Got username Got IF setting WiFi Got txPwr setting 17 Got loraFrq setting 915 Got sf setting 9 [ 238][E][Preferences.cpp:503] getBytesLength(): nvs_get_blob len fail: duty NOT_FOUND Got duty setting 0.100000 Got interval setting 10000 Got gps setting 0

samuk commented 1 year ago

Been a long time since I've thought about this project.

I'm assuming you've seen this ticket already? https://github.com/sudomesh/disaster-radio/issues/110

Unless you have a specific need for Disaster Radio I'd suggest checking out Meshtastic or Reticulum

samuk commented 1 year ago

Although I just spotted @Juul made an update a few months ago: https://github.com/sudomesh/disaster-radio/commit/e8cfe8a2913b4da5391f7b2826755ffce7b7c349

Perhaps you could try using one of the releases: https://github.com/sudomesh/disaster-radio/releases perhaps that recent update broke stuff?

robbo007 commented 1 year ago

Right I've managed to compile the release candidate v1.0.0-rc.1 seems to work but there are a few errors. Any ideas? I cant see any initial problems but might affect something somewhere?

`MACPRO:new home$ pio run -t upload Processing ttgo-lora32-v2 (board: ttgo-lora32-v1; platform: https://github.com/platformio/platform-espressif32.git; framework: arduino)

Verbose mode can be enabled via -v, --verbose option CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/ttgo-lora32-v1.html PLATFORM: Espressif 32 (5.2.0+sha.03254d4) > TTGO LoRa32-OLED V1 HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa) PACKAGES:

In file included from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-gpio.h:29, from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal.h:79, from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36, from /var/folders/tz/_fsjhc3s7ddcp9r4d_60wxfw0000gn/T/tmpcbntv4io:1: /Users/home/.platformio/packages/framework-arduinoespressif32/variants/ttgo-lora32-v1/pins_arduino.h:15: note: this is the location of the previous definition

define OLED_SDA 4**

In file included from /Users/home/LoRa/new/firmware/esp32/main.ino:16: firmware/esp32/config.h:31: warning: "OLED_SCL" redefined

define OLED_SCL 22

In file included from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-gpio.h:29, from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal.h:79, from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36, from /var/folders/tz/_fsjhc3s7ddcp9r4d_60wxfw0000gn/T/tmpcbntv4io:1: /Users/home/.platformio/packages/framework-arduinoespressif32/variants/ttgo-lora32-v1/pins_arduino.h:16: note: this is the location of the previous definition

define OLED_SCL 15

In file included from /Users/home/LoRa/new/firmware/esp32/main.ino:16: firmware/esp32/config.h:32: warning: "OLED_RST" redefined

define OLED_RST NOT_A_PIN

In file included from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-gpio.h:29, from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal.h:79, from /Users/home/.platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36, from /var/folders/tz/_fsjhc3s7ddcp9r4d_60wxfw0000gn/T/tmpcbntv4io:1: /Users/home/.platformio/packages/framework-arduinoespressif32/variants/ttgo-lora32-v1/pins_arduino.h:17: note: this is the location of the previous definition

define OLED_RST 16

Retrieving maximum program size .pio/build/ttgo-lora32-v2/firmware.elf Checking size .pio/build/ttgo-lora32-v2/firmware.elf Advanced Memory Usage is available via "PlatformIO Home > Project Inspect" RAM: [== ] 23.1% (used 75776 bytes from 327680 bytes) Flash: [======== ] 82.7% (used 1680689 bytes from 2031616 bytes) Configuring upload protocol... AVAILABLE: cmsis-dap, esp-bridge, esp-prog, espota, esptool, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa CURRENT: upload_protocol = esptool Looking for upload port... Using manually specified: /dev/tty.wchusbserial54790547481 Uploading .pio/build/ttgo-lora32-v2/firmware.bin esptool.py v4.2.1 Serial port /dev/tty.wchusbserial54790547481 Connecting...... Chip is ESP32-PICO-D4 (revision 1) Features: WiFi, BT, Dual Core, 240MHz, Embedded Flash, VRef calibration in efuse, Coding Scheme None Crystal is 40MHz MAC: e8:9f:6d:08:87:58 Uploading stub... Running stub... Stub running... Changing baud rate to 460800 Changed. Configuring flash size... Flash will be erased from 0x00001000 to 0x00005fff... Flash will be erased from 0x00008000 to 0x00008fff... Flash will be erased from 0x0000e000 to 0x0000ffff... Flash will be erased from 0x00010000 to 0x001abfff... Compressed 17440 bytes to 12127... Writing at 0x00001000... (100 %) Wrote 17440 bytes (12127 compressed) at 0x00001000 in 0.5 seconds (effective 254.0 kbit/s)... Hash of data verified. Compressed 3072 bytes to 116... Writing at 0x00008000... (100 %) Wrote 3072 bytes (116 compressed) at 0x00008000 in 0.1 seconds (effective 449.3 kbit/s)... Hash of data verified. Compressed 8192 bytes to 47... Writing at 0x0000e000... (100 %) Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.1 seconds (effective 626.6 kbit/s)... Hash of data verified. Compressed 1686464 bytes to 1089314... Writing at 0x00010000... (1 %) Writing at 0x0001c567... (2 %) Writing at 0x00027a29... (4 %) Writing at 0x00032f3f... (5 %) Writing at 0x0003b637... (7 %) Writing at 0x0004de77... (8 %) Writing at 0x00053946... (10 %) Writing at 0x00058f00... (11 %) Writing at 0x0005ed54... (13 %) Writing at 0x00064d60... (14 %) Writing at 0x0006a800... (16 %) Writing at 0x00070462... (17 %) Writing at 0x00076184... (19 %) Writing at 0x0007b8c3... (20 %) Writing at 0x000814c6... (22 %) Writing at 0x00086992... (23 %) Writing at 0x0008bc21... (25 %) Writing at 0x000910f8... (26 %) Writing at 0x0009654f... (28 %) Writing at 0x0009b6d8... (29 %) Writing at 0x000a16a2... (31 %) Writing at 0x000a6e9d... (32 %) Writing at 0x000ac5f8... (34 %) Writing at 0x000b1a03... (35 %) Writing at 0x000b6cc6... (37 %) Writing at 0x000bd0d6... (38 %) Writing at 0x000c293d... (40 %) Writing at 0x000c8565... (41 %) Writing at 0x000ce253... (43 %) Writing at 0x000d3b83... (44 %) Writing at 0x000d9424... (46 %) Writing at 0x000dec54... (47 %) Writing at 0x000e43cd... (49 %) Writing at 0x000ea1be... (50 %) Writing at 0x000f0018... (52 %) Writing at 0x000f70b1... (53 %) Writing at 0x000fd1a8... (55 %) Writing at 0x00102b7e... (56 %) Writing at 0x001082f4... (58 %) Writing at 0x0010d86c... (59 %) Writing at 0x00113074... (61 %) Writing at 0x0011825d... (62 %) Writing at 0x0011d48c... (64 %) Writing at 0x00122611... (65 %) Writing at 0x00128642... (67 %) Writing at 0x0012e87a... (68 %) Writing at 0x00134881... (70 %) Writing at 0x00139cf4... (71 %) Writing at 0x0013f8a3... (73 %) Writing at 0x00145191... (74 %) Writing at 0x0014a2c9... (76 %) Writing at 0x0014f6bd... (77 %) Writing at 0x00154870... (79 %) Writing at 0x00159efb... (80 %) Writing at 0x0015f7df... (82 %) Writing at 0x00165408... (83 %) Writing at 0x0016aefe... (85 %) Writing at 0x001706b5... (86 %) Writing at 0x00176d44... (88 %) Writing at 0x0017f8e4... (89 %) Writing at 0x00187c3c... (91 %) Writing at 0x0018d63d... (92 %) Writing at 0x00192cc9... (94 %) Writing at 0x001983d4... (95 %) Writing at 0x0019e22f... (97 %) Writing at 0x001a359a... (98 %) Writing at 0x001a8fb0... (100 %) Wrote 1686464 bytes (1089314 compressed) at 0x00010000 in 25.0 seconds (effective 540.2 kbit/s)... Hash of data verified.

Leaving... Hard resetting via RTS pin... ================================================================================== [SUCCESS] Took 39.29 seconds ==================================================================================

Environment Status Duration


ttgo-lora32-v2 SUCCESS 00:00:39.294 =================================================================================== 1 succeeded in 00:00:39.294 =================================================================================== MACPRO:new home$ `

samuk commented 1 year ago

I think all the errors loook related to OLED stuff? So if that works you should be OK?

Can you send messages?

robbo007 commented 1 year ago

Yep, screen displays everything fine. So looks good. Thanks

The only other issue is the SD card. Its a 32GB FAT32 formatted. SD card works and formats fine in other systems.

E (363) SPIFFS: mount failed, -10025 [ 369][E][SPIFFS.cpp:89] begin(): Mounting SPIFFS failed! Error: -1 --> SPIFFS initializtion failed [ 969][E][sd_diskio.cpp:126] sdSelectCard(): Select Failed [ 969][E][sd_diskio.cpp:621] ff_sd_status(): Check status failed [ 1469][E][sd_diskio.cpp:126] sdSelectCard(): Select Failed [ 1969][E][sd_diskio.cpp:126] sdSelectCard(): Select Failed [ 1969][E][vfs_api.cpp:104] open(): /sd/log.txt does not exist, no permits for creation