BlueAndi / Pixelix

Full RGB LED matrix, based on an ESP32 and WS2812B LEDs.
MIT License
300 stars 59 forks source link

[Bug] Bare Board Bootstrapping Blues #137

Closed robertlipe closed 1 month ago

robertlipe commented 1 year ago

Describe the bug I have an extremely bare S3 board. I successfully built and flashed the code. (Yay!) I looked for a way to break the deadlock of having no WiFi to configure WiFi. I was prepared to edit a config file and just build it into the image, but learned that you have to ground GPIO4 for some time in order to get either to a serial console (the default doesn't accept inout) or to get a WiFi hotspot mode so you can configure the board.

So far, I can't get to either one.

To Reproduce Steps to reproduce the behavior:

  1. Build and install to new ESP32-S3 board without screen, keys
  2. Look for way to configure WiFi via software, denied.
  3. Look for serial console. it's write-only.
  4. Used WiFi scanner to find new AP, hoping I could hop to the config page. No new radio observed. Expected behavior I gathered I should be able to ground GPIO 4 and be presented with a serial console (none is available) or a new WiFi AP running in local mode that I should be able to join and then use THAT to configure WiFi fully enough to get the device booted to local LAN.

No joy.

Screenshots ESP-ROM:esp32s3-20210327 Build:Mar 27 2021 rst:0x1 (POWERON),boot:0x10 (DOWNLOAD(USB/UART0)) waiting for download [ 397][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ha_dp NOT_FOUND [ 417][E][Preferences.cpp:483] getString(): nvs_get_str len fail: mqtt_broker_url NOT_FOUND [ 418][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 5398][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7421][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7474][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7474][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7484][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7488][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8045][E][vfs_api.cpp:105] open(): /littlefs/configuration/4176.sprite does not exist, no permits for creation [ 8052][E][vfs_api.cpp:105] open(): /littlefs/configuration/4176.bmp does not exist, no permits for creation [ 8070][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8146][E][vfs_api.cpp:182] remove(): /configuration/4176.sprite does not exists or is directory [ 8299][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 8299][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND [ 397][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ha_dp NOT_FOUND [ 417][E][Preferences.cpp:483] getString(): nvs_get_str len fail: mqtt_broker_url NOT_FOUND [ 418][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 5399][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7421][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7460][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7461][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7471][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7474][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8021][E][vfs_api.cpp:105] open(): /littlefs/configuration/4176.sprite does not exist, no permits for creation [ 8029][E][vfs_api.cpp:105] open(): /littlefs/configuration/4176.bmp does not exist, no permits for creation [ 8047][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8119][E][vfs_api.cpp:182] remove(): /configuration/4176.sprite does not exists or is directory [ 8267][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 8267][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND [ 397][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ha_dp NOT_FOUND [ 417][E][Preferences.cpp:483] getString(): nvs_get_str len fail: mqtt_broker_url NOT_FOUND [ 418][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 5399][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7421][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7461][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7461][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7472][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7475][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8022][E][vfs_api.cpp:105] open(): /littlefs/configuration/4176.sprite does not exist, no permits for creation [ 8030][E][vfs_api.cpp:105] open(): /littlefs/configuration/4176.bmp does not exist, no permits for creation [ 8048][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8120][E][vfs_api.cpp:182] remove(): /configuration/4176.sprite does not exists or is directory [ 8268][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 8268][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND

I can't find Preferences.cpp in the source. Otherwise, I'd just edit in SSID network configuration.

No new radio presents. This means that Variant 1 isn't an option. I get serial debugging, but nothing like a console. No input is accepted. This means that Variant 2 isn't an option.

I've tried holding GPIO4 long for extended time. No change in screen action and no input is accepted or even echoed.

The onboard LED turns blue and I definitely see WS2812 signal on pin 5 (or whatever it was - it was las night that I configured that, but the described pin is exactly where I found the signal and I confirmed that a small NeoPixel ring light did indeed do NeoPixel stuff.

Please complete the following information:

Additional context I suspect existing users (of supported hardware) aren't affected. They have their credentials already on the littlefs/spiffs. I think this is just new user bootstrapping issue.

Is that GPIO configured with an internal pull-up? If it's left floating, maybe we're not seeing a solid edge as we transition GPIO4 to ground.

Log From a fresh reset: Connected. [ 397][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ha_dp NOT_FOUND [ 417][E][Preferences.cpp:483] getString(): nvs_get_str len fail: mqtt_broker_url NOT_FOUND [ 418][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 5399][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7421][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7461][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7461][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7472][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7475][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8022][E][vfs_api.cpp:105] open(): /littlefs/configuration/4176.sprite does not exist, no permits for creation [ 8030][E][vfs_api.cpp:105] open(): /littlefs/configuration/4176.bmp does not exist, no permits for creation [ 8048][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8120][E][vfs_api.cpp:182] remove(): /configuration/4176.sprite does not exists or is directory [ 8268][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 8268][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND

By themselves, these don't seem too alarming on a first boot. (Well, the /littlefs failure are, but only a little...) It's the inability to further make progress that's bumming me out.

BlueAndi commented 1 year ago

Hi Robert, can you show me your board configuration? I am wondering that the serial connection shows only the logs of the Arduino part, but not from the Pixelix application. Hmm ...

On the other hand to just configure your wifi crendentials add them after the whole if/else block: https://github.com/BlueAndi/esp-rgb-led-matrix/blob/d02f4732a3f04be2213966291e33f5abce7f6406/src/StateMachine/ConnectingState.cpp#L72-L88

like

m_wifiSSID = "...";
m_wifiPassphrase = "...";

After you configured the SSID and the passphrase in the web frontend, you can remove this code again.

BlueAndi commented 1 year ago

And just for a little bit of debugging :-) ... can you add this to your board configuration and check whether you now can use the serial terminal?

-D ARDUINO_USB_MODE=1
-D ARDUINO_USB_CDC_ON_BOOT=1
robertlipe commented 1 year ago

Hi, and thanx for the quick help!

There's no real configuration. It's a totally bare board without any connections, as pictured on the page in the first link.

I'm just "dialed in" to the provided serial port: ✗ sudo cu -s115200 -l /dev/cu.usbmodem556E0082011

Same results as if I use sudo cu -s 115200 -l /dev/cu.wchusbserial556E0082011

The only mods i made to the source tree were just hardwiring shortcuts:

[env:lilygo-t-display-s3] +upload_port = /dev/cu.wchusbserial556E0082011

(On MacOS, VSC gets dumb and locks up trying to upload to the "serial port" on every Bluetooth headset you've ever connected.)

And I tweaked a default her: --- a/platformio.ini +++ b/platformio.ini @@ -11,10 +11,10 @@ [platformio] ;default_envs = adafruit_feather_esp32_v2 ;default_envs = az-delivery-devkit-v4 -default_envs = esp32doit-devkit-v1 +;default_envs = esp32doit-devkit-v1 ;default_envs = esp32-nodemcu ;default_envs = lilygo-ttgo-t-display -;default_envs = lilygo-t-display-s3 +default_envs = lilygo-t-display-s3 ;default_envs = m5stack_core ;default_envs = ulanzi-tc001 ;default_envs = wemos_lolin_s2_mini

(The first two were probably just paranoia.) ...confirmed that COnnectingState.cc was getting recompiled..

I threw your flags here: diff --git a/config/board.ini b/config/board.ini index c07f47c8..4e39c3f8 100644 --- a/config/board.ini +++ b/config/board.ini @@ -249,6 +249,8 @@ build_flags = ${display:lilygo_tdisplay-s3.build_flags} ${config:normal.build_flags} -D BOARD_HAS_PSRAM

I rebuilt thusly:

set -e PORT=/dev/cu.wchusbserial556E0082011 esptool.py -p $PORT erase_flash ~/.platformio/penv/bin/pio run --upload-port $PORT --target uploadfs ~/.platformio/penv/bin/pio run --upload-port $PORT --target upload

and got a blue light. Yay. More importantly, I can see my router has issued a DHCP grant. Yay! I threw a LOG_INFO next to the hardwired password to convince myself I was running the right password, but don't see that in the logs. But that's definitely the ESP I see on the network, so is definitely running. Who ever really knows where logs go on these embedded things. {shrug}

I see the DHCP grant being issued, so I know the IP address. It doesn't, however, respond to pings, telnet, or browser connections.

I still don't get a serial console and I still don't get a web admin change. I don't know how much logging you do, but this seems pretty quiet.

[ 397][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ha_dp NOT_FOUND [ 417][E][Preferences.cpp:483] getString(): nvs_get_str len fail: mqtt_broker_url NOT_FOUND [ 418][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 5399][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7421][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7461][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7461][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7472][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7475][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8022][E][vfs_api.cpp:105] open(): /littlefs/configuration/17310.sprite does not exist, no permits for creation [ 8030][E][vfs_api.cpp:105] open(): /littlefs/configuration/17310.bmp does not exist, no permits for creation [ 8048][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8118][E][vfs_api.cpp:182] remove(): /configuration/17310.sprite does not exists or is directory [ 8265][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 9822][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 9822][E][Preferences.cpp:483] getString(): nvs_get_str len fail: notify_url NOT_FOUND [ 9827][E][Preferences.cpp:483] getString(): nvs_get_str len fail: timezone NOT_FOUND [ 9834][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ntp_server NOT_FOUND

I get a blue light on the board. That's probably it trying to turn on the backlight on the t-display or something wacky that just happens to be wired to that LED on my board. It's a convenient sign of life.

If not for the presence of the observed DHCP grant, it seems that very little observable behaviour has changed.

Should it be crowing more loudly about getting the network up? Should there actually be evidence of a tiny little webserver running on it?

On Tue, Jul 25, 2023 at 1:26 PM Andreas Merkle @.***> wrote:

Hi Robert, can you show me your board configuration? I am wondering that the serial connection shows only the logs of the Arduino part, but not from the Pixelix application. Hmm ...

On the other hand to just configure your wifi crendentials add them after the whole if/else block:

https://github.com/BlueAndi/esp-rgb-led-matrix/blob/d02f4732a3f04be2213966291e33f5abce7f6406/src/StateMachine/ConnectingState.cpp#L72-L88

like

m_wifiSSID = "..."; m_wifiPassphrase = "...";

— Reply to this email directly, view it on GitHub https://github.com/BlueAndi/esp-rgb-led-matrix/issues/137#issuecomment-1650329824, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCSD37D3RRTAR3GOEWRXULXSAFWJANCNFSM6AAAAAA2XM6ZQY . You are receiving this because you authored the thread.Message ID: @.***>

BlueAndi commented 1 year ago

You are welcome ... especially on the embedded world. :-) First the choosen development board "lilygo-t-display-s3" expects to have a TFT display connected and the button is on a different pin. You mentioned to have a WS2812 led matrix connected to GPIO 5, so we need a different configuration.

I configured a separate board, this maybe makes it easier. Please checkout the branch https://github.com/BlueAndi/esp-rgb-led-matrix/tree/support/LuatOS-esp32s3

And try "luatos-esp32s3".

Here you can see the configuration: https://github.com/BlueAndi/esp-rgb-led-matrix/blob/e122ffb85154ae0d505617899516df82d139cbaa/config/board.ini#L290-L338

Its a first shot based on the documentation and your comments ... keep fingers crossed and try.

You can add your wifi credentials to the same place of course. My assumption is that with your jumper on GPIO 4 it should work now as well to start the access point mode.

If Pixelix is connected to your wifi network, you will (should) be able to connect to the internal webserver. As well as in access point mode.

robertlipe commented 1 year ago

Sorry for the delay. Pain break. I really appreciate your efforts on this. Let me be honest that I don't know if this board really even makes sense for you to support. I was just searching github for "esp32s3 + ws2812b" because I was diagnosing a problem with another project. So I'll be honest that you're my mistress here. :-) The pin 4 thing was because I found doc that said pin 4 - and I couldn't figure out in the Button code what actual pin you were expecting to wiggle. That same doc gave a pin for WS2812, so I stuck a scope on it, found a signal about 800kHz with 30/70 duty cycle, shrugged that this sounded very familiar and then ust proceeded straight to jamming a tiny ring on it that I was pretty sure wouldn't brown out the unbuffered output of the chip. So there's absolutely nothing cast in stone about those pins.

However, if an output of this effort is that I can be your eyes and fingers to produce something that's useful to more of your users, particularly those less determined than me, then that's great!

This comes out of the gate strong, but ends quickly in a sad trombone.

Hard resetting via RTS pin... Processing luatos-esp32s3 (board: esp32-s3-devkitc-1; platform: espressif32 @ ~6.3.0; framework: arduino) [ chomp ] Software version : v7.1.1:b Software revision long : e122ffb85154ae0d505617899516df82d139cbaa Software revision short: e122ffb8 Software branch : support/LuatOS-esp32s3 CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32-s3-devkitc-1.html PLATFORM: Espressif 32 (6.3.2) > Espressif ESP32-S3-DevKitC-1-N8 (8 MB QD, No PSRAM) HARDWARE: ESP32S3 240MHz, 320KB RAM, 8MB Flash DEBUG: Current (esp-builtin) On-board (esp-builtin) 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) [ chugga chugga chugga. ] Stub running... Changing baud rate to 460800 Changed. Configuring flash size...

A fatal error occurred: File .pio/build/luatos-esp32s3/littlefs.bin (length 3538944) at offset 13172736 will not fit in 8388608 bytes of flash. Use --flash_size argument, or change flashing address. *** [uploadfs] Error 2 ========================= [FAILED] Took 49.99 seconds =========================

Environment Status Duration


luatos-esp32s3 FAILED 00:00:49.990

I think the key is that it keep misidentifying the hardware as "HARDWARE: ESP32S3 240MHz, 320KB RAM, 8MB Flash but when I run esptool.py --p=$PORT flash_ id Chip is ESP32-S3 (revision v0.1) Manufacturer: c8 Detected flash size: 16MB

So somewhere we're misdetecting the board. This is different than last night and there's only one CL to pick through, so I'll go over this lovely new target you made for me.

Thanx! Off to study that last commit.

robertlipe commented 1 year ago

The above post is probably invalid. I'd changed to the right branch, but hadn't run git update. Now I've confirmed the changes are actually there.

[board:luatos-esp32s3] extends = mcu:esp32, display:led_matrix_column_major_alternating, config:normal -board = esp32-s3-devkitc-1 +; board = esp32-s3-devkitc-1^M +board = lilygo-t-display-s3^M

The lilygo baseline almost works. Building the devkitc baseline does not. If I kept the luatos configuration active, but based it on lilygo, things look up a tad.

I now get a few more lines from the console, probably because pins are #defined to hardware that's not answering or to pins that >> off the registers (see other bugreport) into outer space. None of the #defines look really very radical, but the pinMode and Gpio_set_level() chatter below are new.

[ 415][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ha_dp NOT_FOUND [ 436][E][Preferences.cpp:483] getString(): nvs_get_str len fail: mqtt_broker_url NOT_FOUND [ 436][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 445][E][Preferences.cpp:483] getString(): nvs_get_str len fail: timezone NOT_FOUND [ 449][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ntp_server NOT_FOUND [ 622][E][esp32-hal-gpio.c:102] pinMode(): Invalid pin selected [ 622][E][esp32-hal-gpio.c:102] pinMode(): Invalid pin selected [ 624][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected E (794) gpio: gpio_set_level(226): GPIO output gpio_num error [ 655][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected [ 924][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 2995][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3034][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 3034][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 3045][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 3047][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 3646][E][vfs_api.cpp:105] open(): /littlefs/configuration/15105.sprite does not exist, no permits for creation [ 3665][E][vfs_api.cpp:105] open(): /littlefs/configuration/15105.bmp does not exist, no permits for creation [ 3682][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3817][E][vfs_api.cpp:182] remove(): /configuration/15105.sprite does not exists or is directory [ 3991][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 5605][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 5605][E][Preferences.cpp:483] getString(): nvs_get_str len fail: notify_url NOT_FOUND

It DOES show up on my router as getting a grant. It does not show as a hotspot and the serial console does not respond to input. I don't know if you inentionally chnaged to the devkitc hoping that would make some material change, but that just doesn't work out.

Now that I'm lookig at it closely, it's interesting that it's loading the "no over the air" configurtion, without an OTA1 and OTA2 partition...

esptool.py \ --chip esp32s3 \ --port "/dev/tty.wchusbserial556E0082011" \ --baud 460800 --before default_reset --after hard_reset write_flash \ -z --flash_mode dio --flash_freq 80m --flash_size 16MB \ 0x0000 .pio/build/luatos-esp32s3/bootloader.bin \ 0x8000 .pio/build/luatos-esp32s3/partitions.bin \ 0xe000 ~/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin \ 0x10000 .pio/build/luatos-esp32s3/firmware.bin

This makes the extent of my local changes these, but the result is pretty much where we were yesterday. Still no serial console, no hotspot, no wifi, etc. Grounding pin four changes nothing visible, whether long held or strapped at boot.

diff --git a/config/board.ini b/config/board.ini index ff1f632a..4b8f31fa 100644 --- a/config/board.ini +++ b/config/board.ini @@ -294,13 +294,17 @@ extra_scripts = ; **** [board:luatos-esp32s3] extends = mcu:esp32, display:led_matrix_column_major_alternating, config:normal -board = esp32-s3-devkitc-1 +; board = esp32-s3-devkitc-1^M +board = lilygo-t-display-s3^M +^M board_build.partitions = default_16MB.csv board_build.filesystem = littlefs build_flags = ${mcu:esp32.build_flags} ${display:led_matrix_column_major_alternating.build_flags} -D BOARD_HAS_PSRAM

BlueAndi commented 1 year ago

Hi Robert, I am on a business trip since today. Will come back if I am back at home. Just to note, I thought putting the stuff to a branch and improve it there is easier than pushing fragments over the issue. :-)

BlueAndi commented 1 year ago

The lilygo baseline almost works. Building the devkitc baseline does not. If I kept the luatos configuration active, but based it on lilygo, things look up a tad.

-board = esp32-s3-devkitc-1 +; board = esp32-s3-devkitc-1^M +board = lilygo-t-display-s3^M

By changing this, you always compile the Lilygo with the same result. Was the flash size problem the only one with the LuatOS ESP32 S3 configuration? Please stay with the luatos-esp32-s3 configuration (without additional changes, except wifi credentials). I updated the configuration for 16 MB flash and set the memory type like for the Lilygo. Now you can try again.

BlueAndi commented 1 year ago

And I saw right now in the schematic, that you can choose between direct USB CDC and usb-to-uart ... I guess the real Pixelix log output will be shown by changing the jumper. image

BlueAndi commented 1 year ago

Hi @robertlipe any success with my previous changes in the branch?

robertlipe commented 1 year ago

I've fallen out of sync as this message got buried in an avalanche of ESP32-related chatter. Sorry. I kept the old tree (as much for my own reference as I've forgotten where we are) but made a Fresh checkout, so we're exactly in sync. git checkout support/LuatOS-esp32s3

$ pio run --list-targets [ good grief the downloads .... ] confirms many, but of relevance: luatos-esp32s3 Platform buildfs Build Filesystem Image luatos-esp32s3 Platform erase Erase Flash luatos-esp32s3 Platform size Program Size Calculate program size luatos-esp32s3 Platform upload Upload luatos-esp32s3 Platform uploadfs Upload Filesystem Image luatos-esp32s3 Platform uploadfsota Upload Filesystem Image OTA

So let's start off with pio run -t uploadfs -t upload --upload-port /dev/cu.wchusbserial556E0082011 luatos-esp32s3 SUCCESS 00:01:38.100

Jolly good.

sudo cu -s 115200 -l /dev/cu.wchusbserial556E0082011

Definitely the serial port of the luatos board. I get debug prints that's definitely the IP address of the LuaToS board .... but it's running code from my other ESP32 project, not ESP-RGB-LED. This is definitely a debug build of the Mesmerizer/Nightdriver code, and it's running debug code that I added. It's like a partition table didn't get reset to point to your load address or something. I can punch the reset button and I'm definitely on teh right board. I'm pretty baffled right now... Maybe it picked up Mesmerizers's secondary OTA partition and is choosing to boot from that? WTH?

Watching the addresses, the code is definitely writing to the partition table, but not overwriting where the other code lived.

Compressed 3072 bytes to 146... Writing at 0x00008000... (100 %) Wrote 3072 bytes (146 compressed) at 0x00008000 in 0.0 seconds (effective 815.6 kbit/s)...

Meh. Big hammer time.: esptool.py -p /dev/cu.wchusbserial556E0082011 erase_flash OK, Good old fashioned panic Core 1 register dump: PC : 0x40382343 PS : 0x00060036 A0 : 0x80380a5c A1 : 0x3fcec570 Null deref: EXCVADDR: 0x00000000 LBEG : 0x400570e8 LEND : 0x400570f3 LCOUNT : 0x00000000

Backtrace: 0x40382340:0x3fcec570 0x40380a59:0x3fcec5b0 0x4037ef50:0x3fcec5e0 0x4037ef46:0xa5a5a5a5 |<-CORRUPTED

ELF file SHA256: 46254a9169a4341e

Rebooting... ~E (275) psram: PSRAM ID read error: 0x00ffffff

We're onto something: pio run -t upload -e lilygo-t-display-s3 gets back to a familiar form of failure: [ 7584][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7587][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8181][E][vfs_api.cpp:105] open(): /littlefs/configuration/16619.sprite does not exist, no permits for creation [ 8201][E][vfs_api.cpp:105] open(): /littlefs/configuration/16619.bmp does not exist, no permits for creation [ 8219][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8338][E][vfs_api.cpp:182] remove(): /configuration/16619.sprite does not exists or is directory [ 8494][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 8495][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND

While pio run -t upload definitely identifies the "right" build type: Uploading .pio/build/luatos-esp32s3/firmware.bin

... but that build just boot loops with the above crash.

So there's something unique to this new branch and/or this build type.

BlueAndi commented 1 year ago

Let's try two things:

  1. Use the luatos-esp32-s3 environment, remove this line https://github.com/BlueAndi/esp-rgb-led-matrix/blob/6dc41533ff30ab4e6374e9808e80024e89168e0b/config/board.ini#L307 , then rebuild and try. Whats the result?
  2. Continue by replacing this line https://github.com/BlueAndi/esp-rgb-led-matrix/blob/6dc41533ff30ab4e6374e9808e80024e89168e0b/config/board.ini#L297 with lilygo-t-display-s3. Whats the result?

Just to note, I will be off for some days, starting from tomorrow ... need vacation. :-)

robertlipe commented 1 year ago

Hi, Andreas. No worries on the delay. Enjoy your vacation! I don't sense that you have users knocking down your door trying to make this board work.

So I reset my tree back to match yours exactly.

Remove -DBOARD_HAS_PSRAM - interesting indeed!

That gets us back to the very original failure case: Hard resetting via RTS pin... ========================= [SUCCESS] Took 95.98 seconds

Environment Status Duration


luatos-esp32s3 SUCCESS 00:01:35.982 ========================= 1 succeeded in 00:01:35.982

�xxx�xxx�xx��������xx���xx��xx��x�x���xx��x�xx�xxx�xx���xx��xxx�x�x�x�x��x�x�xxxx�����x�x�xx�xxx�xx�x�x�x��xxx�x���xx��x�x���xxx�xx���x�xxxx�x�xxx��xx��x��x��)�[ 667][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected [ 936][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3008][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3059][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 3060][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 3071][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 3073][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 3661][E][vfs_api.cpp:105] open(): /littlefs/configuration/16619.sprite does not exist, no permits for creation [ 3679][E][vfs_api.cpp:105] open(): /littlefs/configuration/16619.bmp does not exist, no permits for creation [ 3696][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3831][E][vfs_api.cpp:182] remove(): /configuration/16619.sprite does not exists or is directory [ 4000][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 4000][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND

Then, since you said "continue", I'm leaving that line removed and replacing lilygo-t-display-s3

(Which I thought I documented doing last night; that was the happiest of our config. Same.

5.33 seconds =========================

Environment Status Duration


luatos-esp32s3 SUCCESS 00:01:35.332 ========================= 1 succeeded in 00:01:35.332

xxx�xxx�x��xxx�x����xx��xx��xxx�x��x�x�x��x�x��xxx�x��xx��xxx�x�x�x�x��x�x�xxxx�����x�x�xx�xxx�xx�x�x�x��xxx�x���xx��x�x���xxx�xx���x�xxxx�x�xxx��xx��x��x���rror [ 668][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected [ 937][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3009][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3053][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 3053][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 3064][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 3066][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 3669][E][vfs_api.cpp:105] open(): /littlefs/configuration/16619.sprite does not exist, no permits for creation [ 3687][E][vfs_api.cpp:105] open(): /littlefs/configuration/16619.bmp does not exist, no permits for creation [ 3705][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3840][E][vfs_api.cpp:182] remove(): /configuration/16619.sprite does not exists or is directory [ 4008][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 4008][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND

You didn't ask, but because machine cycles are cheap, adding back HAS_PSRAM and leaving lilygo... (which I'd definitely done because this build is hitting heavily on build cache, but still stupid slow because scons/python are slow.)

Environment Status Duration


luatos-esp32s3 SUCCESS 00:01:01.789 ========================= 1 succeeded in 00:01:01.789

�xxx�x���xx��x�x����x�xxx�xxx�x�xxx�x���x�xxxx�x�xxx��xx���xx��xxx�x�x�x�x��x�x�xxxx�����x�x�xx�xxx�xx�x�x�x��xxx�x���xx��x�x���xxx�xx���x�xxxx�x�xxx��xx��x��x���-hal-gpio.c:102] pinMode(): Invalid pin selected [ 635][E][esp32-hal-gpio.c:102] pinMode(): Invalid pin selected [ 637][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected E (807) gpio: gpio_set_level(226): GPIO output gpio_num error [ 668][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected [ 937][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3009][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3058][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 3059][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 3070][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 3072][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 3668][E][vfs_api.cpp:105] open(): /littlefs/configuration/16619.sprite does not exist, no permits for creation [ 3687][E][vfs_api.cpp:105] open(): /littlefs/configuration/16619.bmp does not exist, no permits for creation [ 3704][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 3839][E][vfs_api.cpp:182] remove(): /configuration/16619.sprite does not exists or is directory [ 4007][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 4007][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND

By the time you're back, I hope to have integrated this board into my actual project in duty, but since we're debugging such early stages it's not like extra GPIO load is going to make a difference, so I suspect we can keep bouncing between helping you get this going and its duty with mesmerizer/nightdriverled development.

Then again, there I was mostly concerned about extra "disk" space, but building that board as Lilygo, ESP.getFreePsram(), ESP.getPsramSize()) aren't exactly thrilled with that board:

(I) (loop)(C1) WiFi: WL_CONNECTED, IP: 192.168.2.168, Mem: 24264, LargestBlk: 15092, PSRAM Free: 0/0, LED FPS: 30 LED Bright: 100%, LED Watts: 11, Buffer: 0/262, CPU: 000%, 001%, FreeDraw: 0.019

I see it at https://thingpulse.com/esp32-how-to-use-psram/ that both the define and --mfix-esp32-psram-cache-issue are issued.

When I change NLD's build to use both, I see an early error that's very much like the crash I saw in rgb:

E (278) psram: PSRAM ID read error: 0x00ffffff

The difference seems to be that NLD detects it and charges on.

So maybe this board is just funky and doesn't play nice with Arduino/Platformio or something. It came with ūpython that was talking to all the space.

Hmm. Recursive mysteries.

Just hte other day, I got three OTHER 8/16 S3 boards. I'm almost afraid to try them, but I guess I probably should. :-)

Go enjoy your vacation. I'll decide which battle I want to fight here. Later!

On Sun, Aug 20, 2023 at 8:05 AM Andreas Merkle @.***> wrote:

Let's try two things:

  1. Use the luatos-esp32-s3 environment, remove this line https://github.com/BlueAndi/esp-rgb-led-matrix/blob/6dc41533ff30ab4e6374e9808e80024e89168e0b/config/board.ini#L307 , then rebuild and try. Whats the result?
  2. Continue by replacing this line https://github.com/BlueAndi/esp-rgb-led-matrix/blob/6dc41533ff30ab4e6374e9808e80024e89168e0b/config/board.ini#L297 with lilygo-t-display-s3. Whats the result?

Just to note, I will be off for some days, starting from tomorrow ... need vacation. :-)

— Reply to this email directly, view it on GitHub https://github.com/BlueAndi/esp-rgb-led-matrix/issues/137#issuecomment-1685280862, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCSD33PMYVXTWFJNP5DSF3XWIDRFANCNFSM6AAAAAA2XM6ZQY . You are receiving this because you were mentioned.Message ID: @.***>

BlueAndi commented 1 year ago

Hi Robert, I am back ... unfortunately :-) ... although the luatos wiki talks about supporting 8 MB PSRAM, it seems not to be available on your board or maybe not compatible with the current pio setup. Lets remove BOARD_HAS_PSRAM. At the moment Pixelix doesn't use PSRAM internally, its planned for the future.

Correct me if I am wrong, but now without PSRAM support the logs are looking similar between the lilygo-t-display-s3 configuration and the luatos-esp32s3 configuration ... except the warning(s) about a pin, but we can skip this for a moment.

The previous logs are all three with the luatos-esp32s3 configuration, right (its mentioned at the begin of every log). But funny with different number of __pinMode(): Invalid pin selected warnings. :-?

We should keep going now only with the luatos-esp32s3 configuration, because it supports the led matrix with WS28xx support. The lilygo-t-display-s3 expects to have a TFT display.

BTW these kind of logs [ 3009][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND are coming from the underlying esp32 Arduino library and although logged as error, they are not. Pixelix reads at startup from a persistent storage partition to check for overwritten default values. If there is no explicit value, this error appears, but Pixelix will just use the default value which is ok.

The mesmerizer/nightdriverled seems to be private, I can not see it.

I will check how to route the Pixelix logs through the right uart, this should give us much better information.

BlueAndi commented 1 year ago

Could you try Serial.setDebugOutput(true); before the println and have a look to the logs?: https://github.com/BlueAndi/esp-rgb-led-matrix/blob/2454575e59d70b5b51ec63b5f4856521662b1e11/src/main.cpp#L156-L166

robertlipe commented 1 year ago

Welcome back.

Sometime, you and I will both be firing at the same time and find our collective mojo on this. :-) It doesn't help that I think we're chasing at least three, if not four, different problems.

1) PSRAM configuration. 2) Why do debug prints just go away? 3) Why doesn't this go into the "I'm an AP, connect to me!" mode.

Since we can disable #1 and remove that from the list, if it's not important to your project, maybe we just leave that out.

As I learn more about the ESP parts, the more frustrating it is to find out what I actually HAVE on any given board. When I last poked at this, my working theory was that the dual/quad/octo speed SPI for the PSRAM. I could find that some ESP32-S3's would do octal and some wouldn't and that the symptoms were the same kind of " PSRAM ID read error: 0x00ffffff" read error. There a lot of platformio (ESP-IDF?) gibberish that has to be passed to distinguish between the quad and octal configurations, for example, and I think that's where we're currently stuck. But that's a theory.

The logs start as garbage but "heal". My theory is that something starts writing to the serial port before a Serial.initialize(115200) (whatever) comes along and 'fixes' it. Any characters already transmitted or maybe even in flight tot the part are just trash. That's why we get a differing amount of trash.

If so, that's mystery #4. You're clearly a smart dude and wouldn't write a kilobyte of crap before initializing the UART. You wouldn't do it in two different threads or otherwise separate time domains. Even if you were this silly (you're not) the "fix" would always happen about the same time. So is there maybe something ELSE that's trying to control the serial port? I mean, we're compiling every opcode it can execute so we can't exactly accuse some TSR in your autoexec.bat (from 30 years ago...) or something, but it doesn't make sense that it doesn't resynchronize at one consistent point. Is there maybe a debug and a main thread both controlling the UART?

The 'hostname not found' path makes total sense. It's first boot. There IS no hostname yet. That didn't even raise my curiousity enough to confirm it in the code. Those seem legit.

Nightdriverled.com is not private. 'mesmerizer' is the project, err, 'environment' that's a couple of HUB75 LED matrices. We have other projects (like 'demo') that just light up pin 5 (except when it's a different pin, like lilygo and it's freakin' hard to guess which one until you telnet or use the serial console and find the debug print that SAYS which pin it's using. Or put a #define LED_PIN0 p00kie and then look at the error message and see what set of defines got used for your build. It'll then start spewing WS2812 babble out Pin5. It's also a project using this arduino pio IDE thingy so it SHOULD be familiar. I tend to script a lot of things that look approximately like:

~/.platformio/penv/bin/pio run --target upload -e mesmerizer && && (stty 115200 ; cat ) < /dev/cu.usbserial-101

Well, my ACTUAL scripts are excessively clever to find one of three serial port values or if it's an IP address used for --upload_port then it'll use netcat and so on. But I'm sure you have all those same kinds of developer QOL improvements. The point is that the basic workflow (type programmer stuff into a window, pio run, receive blinking lights) should be similar. Our worlds shouldn't be as alien to each other as parts of this conversation imply. :-)

So let's go back to basics.

esp-rgb-led-matrix git:(e122ffb8) ✗ git diff (which I'm editing by hand for clarity)

--- a/src/StateMachine/ConnectingState.cpp +++ b/src/StateMachine/ConnectingState.cpp @@ -76,9 +76,18 @@ void ConnectingState::entry(StateMachine& sm) / Are remote wifi network informations available? / if (true == settings.open(true)) { +#if 0^M m_wifiSSID = settings.getWifiSSID().getValue(); m_wifiPassphrase = settings.getWifiPassphrase().getValue(); m_isQuiet = settings.getQuietMode().getValue(); +#else^M

Sidebar: Never have I seen those printfs, but I can "feel" their presence because the device WILL join wifi while without this change, it obvsoiusly can't get an auth tokey or a DHCP grant. So those LOG_INFOs get lost.

As a starting place for this conversation, I have the following leftovers in board.ini

--- a/config/board.ini +++ b/config/board.ini @@ -294,13 +294,17 @@ extra_scripts = ;



[board:luatos-esp32s3] extends = mcu:esp32, display:led_matrix_column_major_alternating, config:normal -board = esp32-s3-devkitc-1 +; board = esp32-s3-devkitc-1^M +board = lilygo-t-display-s3^M +^M board_build.partitions = default_16MB.csv board_build.filesystem = littlefs build_flags = ${mcu:esp32.build_flags} ${display:led_matrix_column_major_alternating.build_flags} -D BOARD_HAS_PSRAM

And here is my build and run: ➜ esp-rgb-led-matrix git:(e122ffb8) ✗ cat doall-lily set -e PORT=/dev/cu.wchusbserial556E0082011 BENV=lilygo-t-display-s3

esptool.py -p $PORT erase_flash ~/.platformio/penv/bin/pio run --upload-port $PORT --target uploadfs -e $BENV ~/.platformio/penv/bin/pio run --upload-port $PORT --target upload -e $BENV

esptool.py --p=$PORT image_info .pio/build/$BENV/firmware.bin (stty 115200 ; cat -u ) < $PORT

And we get:

Writing at 0x00159d26... (98 %) Writing at 0x0015f510... (100 %) Wrote 1395312 bytes (866579 compressed) at 0x00010000 in 21.4 seconds (effective 522.7 kbit/s)... Hash of data verified.

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

Environment Status Duration


lilygo-t-display-s3 SUCCESS 00:01:22.042 ========================= 1 succeeded in 00:01:22.042

esptool.py v4.6.2 File size: 1395312 (bytes) Detected image type: ESP32-S3 Image version: 1 Entry point: 40377288 6 segments

Segment 1: len 0x45c74 load 0x3c100020 file_offs 0x00000018 [DROM] Segment 2: len 0x06148 load 0x3fc97300 file_offs 0x00045c94 [BYTE_ACCESSIBLE,MEM_INTERNAL,DRAM] Segment 3: len 0x0422c load 0x40374000 file_offs 0x0004bde4 [MEM_INTERNAL,IRAM] Segment 4: len 0xf591c load 0x42000020 file_offs 0x00050018 [IROM] Segment 5: len 0x0f0d0 load 0x4037822c file_offs 0x0014593c [MEM_INTERNAL,IRAM] Segment 6: len 0x00024 load 0x600fe000 file_offs 0x00154a14 [RTC_DRAM,RTC_IRAM] Checksum: f0 (valid) Validation Hash: 3208b49ee41c12336a6be32ac7e4b12f76f5384829b47f317bfb20e8f424c8a7 (valid) x���x�xxxx�x�xxx��xx��xxx�x���xx��x�x����x�xxx�xxx�x�xxx��xx��xxx�x��x�xxxx�����x�x�xx��xxxx�x���xx��x�xxx�x����x�xxxx�x�xxx��xx��x��x����x���xx��xxx�x��xx��xxx�xxx�xxx�xxxx�xx�xxx����xx��xxx�x�x�x�x��x�x�xxxx�����x�x[ 4711][E][vfs_api.cpp:105] open(): /littlefs/configuration/sensors.json does not exist, no permits for creation [ 5575][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7626][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7677][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7677][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7687][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7690][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8221][E][vfs_api.cpp:105] open(): /littlefs/configuration/slotConfig.json does not exist, no permits for creation [ 8241][E][vfs_api.cpp:105] open(): /littlefs/configuration/25542.sprite does not exist, no permits for creation [ 8260][E][vfs_api.cpp:105] open(): /littlefs/configuration/25542.bmp does not exist, no permits for creation [ 8273][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8441][E][vfs_api.cpp:182] remove(): /configuration/25542.sprite does not exists or is directory [ 8848][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 10400][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 10400][E][Preferences.cpp:483] getString(): nvs_get_str len fail: notify_url NOT_FOUND

As a bonus little gift, shortly after power up, a LED turns blue. Probably we're configuring the LCD or something on a GPIO pin that happens to be connected to a light I didn't even know this board had until a a week or two ago when we stumbled into this build.

Now, in subsequent builds, I probably won't reflash the FS on each run just because it takes PIO forever for even a "do nothing" build.

Network connection is alive: Nmap scan report for 192.168.2.168 Host is up (0.051s latency). MAC Address: 7C:DF:A1:FA:0A:FC (Espressif)

I can ping it. I cannot open a connection to it via telnet on telnet port or port 80. Nmap shows no open ports of any kind.

So in this configuration: +) The app is kind of running. It clearly logged into my network. It responds to pings. It turns on the blue led. -) debug prints are working too well to be broken, but too broken to be useful. ?) Interestingly, none of those errors are actually yours. I don't see them in your source. "KEY_WIFI_SSID" appears in exactly one file. It's push_backed into m_keyValueList. Whether it's registerSetting or getSettingByKey, the code is traversing the list responsibly and doing its own error checking but not actually printing these. These are printed "below us" somehow, probably by the IDF library. -) It doesn't actually do "app things".

It's a zombie. Both dead and not dead.

OK, no other changes but adding:

[ time passes. Sooooo much time ]

Nothing. Nothing AT ALL prints: Segment 6: len 0x00024 load 0x600fe000 file_offs 0x00154b30 [RTC_DRAM,RTC_IRAM] Checksum: 38 (valid) Validation Hash: 377f3672d4a5849b8a344133355c3c5e14d60e27e29df8e76e679db2016bc5d5 (valid)

Reset. Try cu instead of cat.

Still nothing.

So I comment out that line and go through the whole process.

Poof. Stuff re-appears. [ ... ] Segment 5: len 0x0f0d0 load 0x4037822c file_offs 0x0014593c [MEM_INTERNAL,IRAM] Segment 6: len 0x00024 load 0x600fe000 file_offs 0x00154a14 [RTC_DRAM,RTC_IRAM] Checksum: 75 (valid) Validation Hash: a41b375c12eeeb1a72a4318b06acfaf91050b6ee47c3b948d70bd626edfebb70 (valid) x���x�xxxx�x�xxx��xx��xxx�x���xx��x�x����x�xxx�xxx�x�xxx��xx��xxx�x��x�xxxx�����x�x�xx��xxxx�x���xx��x�xxx�x����x�xxxx�x�xxx��xx��x��x����x���xx��xxx�x��xx��xxx�xxx�xxx�xxxx�xx�xxx����xx��xxx�x�x�x�x��x�x�xxxx�����x�x[ 4711][E][vfs_api.cpp:105] open(): /littlefs/configuration/sensors.json does not exist, no permits for creation [ 5574][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7625][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7675][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7676][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7686][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7689][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8220][E][vfs_api.cpp:105] open(): /littlefs/configuration/slotConfig.json does not exist, no permits for creation [ 8240][E][vfs_api.cpp:105] open(): /littlefs/configuration/18517.sprite does not exist, no permits for creation [ 8259][E][vfs_api.cpp:105] open(): /littlefs/configuration/18517.bmp does not exist, no permits for creation [ 8272][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8440][E][vfs_api.cpp:182] remove(): /configuration/18517.sprite does not exists or is directory [ 8843][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 10432][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 10432][E][Preferences.cpp:483] getString(): nvs_get_str len fail: notify_url NOT_FOUND

That's not At All how I expected that to work.

On a lark, I tried enabling a serial port I don't think I even have:

 * boot mode message.
 */
// Serial.setDebugOutput(true); // RJL from Andreas
Serial.println("\n");
Serial1.setDebugOutput(true); // RJL from Andreas
Serial1.println("Whee! I'm alive on 1!"); // RJL from Andreas
Serial2.setDebugOutput(true); // RJL from Andreas
Serial2.println("Whee! I'm alive on 2!"); // RJL from Andreas

/* Set severity for esp logging system. */

No real difference. I get the debug output that we don't write, but don't get the stuff we do. None of the Whee strings printed, of course.

Some online doc I found says setDebugOutput works only on 8266, but I recognize the trap that I'll bet a lot of old doc didn't see "8266" becoming "493 boards call called esp32something".

So ATM, I'm mystified. I'm going to go ahead and dash this off to you. I'll either fall asleep or keep poking at it.

Best of luck, RJL

On Tue, Sep 5, 2023 at 8:32 AM Andreas Merkle @.***> wrote:

Hi Robert, I am back ... unfortunately :-) ... although the luatos wiki talks about supporting 8 MB PSRAM, it seems not to be available on your board or maybe not compatible with the current pio setup. Lets remove BOARD_HAS_PSRAM. At the moment Pixelix doesn't use PSRAM internally, its planned for the future.

Correct me if I am wrong, but now without PSRAM support the logs are looking similar between the lilygo-t-display-s3 configuration and the luatos-esp32s3 configuration ... except the warning(s) about a pin, but we can skip this for a moment.

The previous logs are all three with the luatos-esp32s3 configuration, right (its mentioned at the begin of every log). But funny with different number of __pinMode(): Invalid pin selected warnings. :-?

We should keep going now only with the luatos-esp32s3 configuration, because it supports the led matrix with WS28xx support. The lilygo-t-display-s3 expects to have a TFT display.

BTW these kind of logs [ 3009][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND are coming from the underlying esp32 Arduino library and although logged as error, they are not. Pixelix reads at startup from a persistent storage partition to check for overwritten default values. If there is no explicit value, this error appears, but Pixelix will just use the default value which is ok.

The mesmerizer/nightdriverled seems to be private, I can not see it.

I will check how to route the Pixelix logs through the right uart, this should give us much better information.

— Reply to this email directly, view it on GitHub https://github.com/BlueAndi/esp-rgb-led-matrix/issues/137#issuecomment-1706631722, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCSD34CLUCL3E763GUVO3DXY4SYJANCNFSM6AAAAAA2XM6ZQY . You are receiving this because you were mentioned.Message ID: @.***>

robertlipe commented 1 year ago

And just to cover a wider matrix than the first message...

With the config as posted above:


[board:luatos-esp32s3] extends = mcu:esp32, display:led_matrix_column_major_alternating, config:normal -board = esp32-s3-devkitc-1 +; board = esp32-s3-devkitc-1^M +board = lilygo-t-display-s3^M +^M board_build.partitions = default_16MB.csv board_build.filesystem = littlefs build_flags = ${mcu:esp32.build_flags} ${display:led_matrix_column_major_alternating.build_flags} -D BOARD_HAS_PSRAM

pio run -j8 --upload-port $PORT --target upload -e luatos-esp32s3

acts as above. System kind of working.

Changing ONLY

board = esp32-s3-devkitc-1 ; board = lilygo-t-display-s3

No signs of life at all.

Additionally rolling back

Equally dead. Turning off BOARD_HAS_PSRAM. Still dead.

I turned off ALL the -D flags on the premise that we didn't really have hardware anyway. You're laughing right now because that was a terrible idea. Put the CONFIG_PIN and CONFIG_SENSOR /entries back in...

Also, I haven't found the CAUSE, but I've found the differentiator.

System.println() goes off into outer space. log_e (and obvious relatives) are actually displayed.

The second will print. The first goes away.

On Wed, Sep 6, 2023 at 1:31 AM Robert Lipe @.***> wrote:

Welcome back.

Sometime, you and I will both be firing at the same time and find our collective mojo on this. :-) It doesn't help that I think we're chasing at least three, if not four, different problems.

1) PSRAM configuration. 2) Why do debug prints just go away? 3) Why doesn't this go into the "I'm an AP, connect to me!" mode.

Since we can disable #1 and remove that from the list, if it's not important to your project, maybe we just leave that out.

As I learn more about the ESP parts, the more frustrating it is to find out what I actually HAVE on any given board. When I last poked at this, my working theory was that the dual/quad/octo speed SPI for the PSRAM. I could find that some ESP32-S3's would do octal and some wouldn't and that the symptoms were the same kind of " PSRAM ID read error: 0x00ffffff" read error. There a lot of platformio (ESP-IDF?) gibberish that has to be passed to distinguish between the quad and octal configurations, for example, and I think that's where we're currently stuck. But that's a theory.

The logs start as garbage but "heal". My theory is that something starts writing to the serial port before a Serial.initialize(115200) (whatever) comes along and 'fixes' it. Any characters already transmitted or maybe even in flight tot the part are just trash. That's why we get a differing amount of trash.

If so, that's mystery #4. You're clearly a smart dude and wouldn't write a kilobyte of crap before initializing the UART. You wouldn't do it in two different threads or otherwise separate time domains. Even if you were this silly (you're not) the "fix" would always happen about the same time. So is there maybe something ELSE that's trying to control the serial port? I mean, we're compiling every opcode it can execute so we can't exactly accuse some TSR in your autoexec.bat (from 30 years ago...) or something, but it doesn't make sense that it doesn't resynchronize at one consistent point. Is there maybe a debug and a main thread both controlling the UART?

The 'hostname not found' path makes total sense. It's first boot. There IS no hostname yet. That didn't even raise my curiousity enough to confirm it in the code. Those seem legit.

Nightdriverled.com is not private. 'mesmerizer' is the project, err, 'environment' that's a couple of HUB75 LED matrices. We have other projects (like 'demo') that just light up pin 5 (except when it's a different pin, like lilygo and it's freakin' hard to guess which one until you telnet or use the serial console and find the debug print that SAYS which pin it's using. Or put a #define LED_PIN0 p00kie and then look at the error message and see what set of defines got used for your build. It'll then start spewing WS2812 babble out Pin5. It's also a project using this arduino pio IDE thingy so it SHOULD be familiar. I tend to script a lot of things that look approximately like:

~/.platformio/penv/bin/pio run --target upload -e mesmerizer && && (stty 115200 ; cat ) < /dev/cu.usbserial-101

Well, my ACTUAL scripts are excessively clever to find one of three serial port values or if it's an IP address used for --upload_port then it'll use netcat and so on. But I'm sure you have all those same kinds of developer QOL improvements. The point is that the basic workflow (type programmer stuff into a window, pio run, receive blinking lights) should be similar. Our worlds shouldn't be as alien to each other as parts of this conversation imply. :-)

So let's go back to basics.

esp-rgb-led-matrix git:(e122ffb8) ✗ git diff (which I'm editing by hand for clarity)

--- a/src/StateMachine/ConnectingState.cpp +++ b/src/StateMachine/ConnectingState.cpp @@ -76,9 +76,18 @@ void ConnectingState::entry(StateMachine& sm) / Are remote wifi network informations available? / if (true == settings.open(true)) { +#if 0^M m_wifiSSID = settings.getWifiSSID().getValue(); m_wifiPassphrase = settings.getWifiPassphrase().getValue(); m_isQuiet = settings.getQuietMode().getValue(); +#else^M

  • LOG_INFO("robert is here");^M
  • m_wifiSSID = settings.getWifiSSID().getValue();^M
  • m_wifiSSID = "XXX";^M
  • m_wifiPassphrase = "XXX";^M +^M
  • LOG_INFO("robert was here");^M +#endif^M

     settings.close();

Sidebar: Never have I seen those printfs, but I can "feel" their presence because the device WILL join wifi while without this change, it obvsoiusly can't get an auth tokey or a DHCP grant. So those LOG_INFOs get lost.

As a starting place for this conversation, I have the following leftovers in board.ini

--- a/config/board.ini +++ b/config/board.ini @@ -294,13 +294,17 @@ extra_scripts = ;



[board:luatos-esp32s3] extends = mcu:esp32, display:led_matrix_column_major_alternating, config:normal -board = esp32-s3-devkitc-1 +; board = esp32-s3-devkitc-1^M +board = lilygo-t-display-s3^M +^M board_build.partitions = default_16MB.csv board_build.filesystem = littlefs build_flags = ${mcu:esp32.build_flags} ${display:led_matrix_column_major_alternating.build_flags} -D BOARD_HAS_PSRAM

  • -D ARDUINO_USB_MODE=1^M
  • -D ARDUINO_USB_CDC_ON_BOOT=1^M -D CONFIG_PIN_ONBOARD_LED=10U -D CONFIG_PIN_BUTTON_OK=4U -D CONFIG_PIN_BUTTON_LEFT=IoPin::NC

And here is my build and run: ➜ esp-rgb-led-matrix git:(e122ffb8) ✗ cat doall-lily set -e PORT=/dev/cu.wchusbserial556E0082011 BENV=lilygo-t-display-s3

esptool.py -p $PORT erase_flash ~/.platformio/penv/bin/pio run --upload-port $PORT --target uploadfs -e $BENV ~/.platformio/penv/bin/pio run --upload-port $PORT --target upload -e $BENV

esptool.py --p=$PORT image_info .pio/build/$BENV/firmware.bin (stty 115200 ; cat -u ) < $PORT

And we get:

Writing at 0x00159d26... (98 %) Writing at 0x0015f510... (100 %) Wrote 1395312 bytes (866579 compressed) at 0x00010000 in 21.4 seconds (effective 522.7 kbit/s)... Hash of data verified.

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

Environment Status Duration


lilygo-t-display-s3 SUCCESS 00:01:22.042 ========================= 1 succeeded in 00:01:22.042

esptool.py v4.6.2 File size: 1395312 (bytes) Detected image type: ESP32-S3 Image version: 1 Entry point: 40377288 6 segments

Segment 1: len 0x45c74 load 0x3c100020 file_offs 0x00000018 [DROM] Segment 2: len 0x06148 load 0x3fc97300 file_offs 0x00045c94 [BYTE_ACCESSIBLE,MEM_INTERNAL,DRAM] Segment 3: len 0x0422c load 0x40374000 file_offs 0x0004bde4 [MEM_INTERNAL,IRAM] Segment 4: len 0xf591c load 0x42000020 file_offs 0x00050018 [IROM] Segment 5: len 0x0f0d0 load 0x4037822c file_offs 0x0014593c [MEM_INTERNAL,IRAM] Segment 6: len 0x00024 load 0x600fe000 file_offs 0x00154a14 [RTC_DRAM,RTC_IRAM] Checksum: f0 (valid) Validation Hash: 3208b49ee41c12336a6be32ac7e4b12f76f5384829b47f317bfb20e8f424c8a7 (valid) x���x�xxxx�x�xxx��xx��xxx�x���xx��x�x����x�xxx�xxx�x�xxx��xx��xxx�x��x�xxxx�����x�x�xx��xxxx�x���xx��x�xxx�x����x�xxxx�x�xxx��xx��x��x����x���xx��xxx�x��xx��xxx�xxx�xxx�xxxx�xx�xxx����xx��xxx�x�x�x�x��x�x�xxxx�����x�x[ 4711][E][vfs_api.cpp:105] open(): /littlefs/configuration/sensors.json does not exist, no permits for creation [ 5575][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7626][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7677][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7677][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7687][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7690][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8221][E][vfs_api.cpp:105] open(): /littlefs/configuration/slotConfig.json does not exist, no permits for creation [ 8241][E][vfs_api.cpp:105] open(): /littlefs/configuration/25542.sprite does not exist, no permits for creation [ 8260][E][vfs_api.cpp:105] open(): /littlefs/configuration/25542.bmp does not exist, no permits for creation [ 8273][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8441][E][vfs_api.cpp:182] remove(): /configuration/25542.sprite does not exists or is directory [ 8848][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 10400][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 10400][E][Preferences.cpp:483] getString(): nvs_get_str len fail: notify_url NOT_FOUND

As a bonus little gift, shortly after power up, a LED turns blue. Probably we're configuring the LCD or something on a GPIO pin that happens to be connected to a light I didn't even know this board had until a a week or two ago when we stumbled into this build.

Now, in subsequent builds, I probably won't reflash the FS on each run just because it takes PIO forever for even a "do nothing" build.

Network connection is alive: Nmap scan report for 192.168.2.168 Host is up (0.051s latency). MAC Address: 7C:DF:A1:FA:0A:FC (Espressif)

I can ping it. I cannot open a connection to it via telnet on telnet port or port 80. Nmap shows no open ports of any kind.

So in this configuration: +) The app is kind of running. It clearly logged into my network. It responds to pings. It turns on the blue led. -) debug prints are working too well to be broken, but too broken to be useful. ?) Interestingly, none of those errors are actually yours. I don't see them in your source. "KEY_WIFI_SSID" appears in exactly one file. It's push_backed into m_keyValueList. Whether it's registerSetting or getSettingByKey, the code is traversing the list responsibly and doing its own error checking but not actually printing these. These are printed "below us" somehow, probably by the IDF library. -) It doesn't actually do "app things".

It's a zombie. Both dead and not dead.

OK, no other changes but adding:

  • boot mode message. */
  • Serial.setDebugOutput(true); // RJL from Andreas* Serial.println("\n");

[ time passes. Sooooo much time ]

Nothing. Nothing AT ALL prints: Segment 6: len 0x00024 load 0x600fe000 file_offs 0x00154b30 [RTC_DRAM,RTC_IRAM] Checksum: 38 (valid) Validation Hash: 377f3672d4a5849b8a344133355c3c5e14d60e27e29df8e76e679db2016bc5d5 (valid)

Reset. Try cu instead of cat.

Still nothing.

So I comment out that line and go through the whole process.

Poof. Stuff re-appears. [ ... ] Segment 5: len 0x0f0d0 load 0x4037822c file_offs 0x0014593c [MEM_INTERNAL,IRAM] Segment 6: len 0x00024 load 0x600fe000 file_offs 0x00154a14 [RTC_DRAM,RTC_IRAM] Checksum: 75 (valid) Validation Hash: a41b375c12eeeb1a72a4318b06acfaf91050b6ee47c3b948d70bd626edfebb70 (valid) x���x�xxxx�x�xxx��xx��xxx�x���xx��x�x����x�xxx�xxx�x�xxx��xx��xxx�x��x�xxxx�����x�x�xx��xxxx�x���xx��x�xxx�x����x�xxxx�x�xxx��xx��x��x����x���xx��xxx�x��xx��xxx�xxx�xxx�xxxx�xx�xxx����xx��xxx�x�x�x�x��x�x�xxxx�����x�x[ 4711][E][vfs_api.cpp:105] open(): /littlefs/configuration/sensors.json does not exist, no permits for creation [ 5574][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7625][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 7675][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7676][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 7686][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 7689][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 8220][E][vfs_api.cpp:105] open(): /littlefs/configuration/slotConfig.json does not exist, no permits for creation [ 8240][E][vfs_api.cpp:105] open(): /littlefs/configuration/18517.sprite does not exist, no permits for creation [ 8259][E][vfs_api.cpp:105] open(): /littlefs/configuration/18517.bmp does not exist, no permits for creation [ 8272][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 8440][E][vfs_api.cpp:182] remove(): /configuration/18517.sprite does not exists or is directory [ 8843][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 10432][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 10432][E][Preferences.cpp:483] getString(): nvs_get_str len fail: notify_url NOT_FOUND

That's not At All how I expected that to work.

On a lark, I tried enabling a serial port I don't think I even have:

 * boot mode message.
 */
// Serial.setDebugOutput(true); // RJL from Andreas
Serial.println("\n");
Serial1.setDebugOutput(true); // RJL from Andreas
Serial1.println("Whee! I'm alive on 1!"); // RJL from Andreas
Serial2.setDebugOutput(true); // RJL from Andreas
Serial2.println("Whee! I'm alive on 2!"); // RJL from Andreas

/* Set severity for esp logging system. */

No real difference. I get the debug output that we don't write, but don't get the stuff we do. None of the Whee strings printed, of course.

Some online doc I found says setDebugOutput works only on 8266, but I recognize the trap that I'll bet a lot of old doc didn't see "8266" becoming "493 boards call called esp32something".

So ATM, I'm mystified. I'm going to go ahead and dash this off to you. I'll either fall asleep or keep poking at it.

Best of luck, RJL

On Tue, Sep 5, 2023 at 8:32 AM Andreas Merkle @.***> wrote:

Hi Robert, I am back ... unfortunately :-) ... although the luatos wiki talks about supporting 8 MB PSRAM, it seems not to be available on your board or maybe not compatible with the current pio setup. Lets remove BOARD_HAS_PSRAM. At the moment Pixelix doesn't use PSRAM internally, its planned for the future.

Correct me if I am wrong, but now without PSRAM support the logs are looking similar between the lilygo-t-display-s3 configuration and the luatos-esp32s3 configuration ... except the warning(s) about a pin, but we can skip this for a moment.

The previous logs are all three with the luatos-esp32s3 configuration, right (its mentioned at the begin of every log). But funny with different number of __pinMode(): Invalid pin selected warnings. :-?

We should keep going now only with the luatos-esp32s3 configuration, because it supports the led matrix with WS28xx support. The lilygo-t-display-s3 expects to have a TFT display.

BTW these kind of logs [ 3009][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND are coming from the underlying esp32 Arduino library and although logged as error, they are not. Pixelix reads at startup from a persistent storage partition to check for overwritten default values. If there is no explicit value, this error appears, but Pixelix will just use the default value which is ok.

The mesmerizer/nightdriverled seems to be private, I can not see it.

I will check how to route the Pixelix logs through the right uart, this should give us much better information.

— Reply to this email directly, view it on GitHub https://github.com/BlueAndi/esp-rgb-led-matrix/issues/137#issuecomment-1706631722, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCSD34CLUCL3E763GUVO3DXY4SYJANCNFSM6AAAAAA2XM6ZQY . You are receiving this because you were mentioned.Message ID: @.***>

BlueAndi commented 1 year ago

As I learn more about the ESP parts, the more frustrating it is to find out what I actually HAVE on any given board. When I last poked at this, my working theory was that the dual/quad/octo speed SPI for the PSRAM. I could find that some ESP32-S3's would do octal and some wouldn't and that the symptoms were the same kind of " PSRAM ID read error: 0x00ffffff" read error. There a lot of platformio (ESP-IDF?) gibberish that has to be passed to distinguish between the quad and octal configurations, for example, and I think that's where we're currently stuck. But that's a theory.

I found a bug in the configuration and fixed it. Now we should go with quad i/o (qio) and octal peripheral interface (opi) access. Please pull and clean build. This looks like the difference between the lilygo board config and the devkit config. Its not always straight forward how to overwrite the board configurations.

But yes, you are right. You need to know the detail to configure the stuff correct. This datasheet shows it a little bit: https://www.espressif.com/sites/default/files/documentation/esp32-s3_datasheet_en.pdf

If so, that's mystery #4. You're clearly a smart dude and wouldn't write a kilobyte of crap before initializing the UART. You wouldn't do it in two different threads or otherwise separate time domains. Even if you were this silly (you're not) the "fix" would always happen about the same time. So is there maybe something ELSE that's trying to control the serial port? I mean, we're compiling every opcode it can execute so we can't exactly accuse some TSR in your autoexec.bat (from 30 years ago...) or something, but it doesn't make sense that it doesn't resynchronize at one consistent point. Is there maybe a debug and a main thread both controlling the UART?

The esp32s3 has 3 uart's and for logging its getting more complicated depended on the development board considering the usb part. The luatos board schematic shows this: image image

What we see is, that the log_e() is shown on the console, because it uses uart0 (esp_tx/esp_rx). With the current setup, the Serial object is created by HWCDC Serial;. That means Serial.println() goes with CDC (USB Communication Device Class) and not over uart0.

On your board is this small switch here: image

This is the S2 which should select between uart0 and usb cdc. Did you try to switch it?

The other test is to try (keeping the S2 as it is)

Serial0.println("test test");

As I can see you tested only Serial1 and Serial2 until now, right?

autoexec.bat .... LOL ... installing the TSRs there or handling the emm386 and highmem stuff there ... yeah ... long time ago ...

Nightdriverled.com is not private. 'mesmerizer' is the project, err,

Oh, I see ... I tried https://github.com/mesmerizer/nightdriverled :-)

robertlipe commented 1 year ago

I'm typing from a car outside a Dr. office w/o internet, so there may be some things I'd like to check but can't, but wanted to dash this off to try to reduce our latency.

Before leaving, I did a git stash; ; git checkout support/LuatOS-esp32s3; git pull; and a fresh build - for battery life.

I found a bug in the configuration and fixed it. Now we should go with quad

i/o (qio) and octal peripheral interface

Excellent! I think that's one of our major mysteries down. Thank you. A clean tree, to that tag, now gives a recognizable (to me) stream of log_e's fussing about nvs_get_str keys not found, GPIO pin numbers out of range (big numbers over 31 get <<'ed into outer space) and such. Importantly,

BENV=luatos-esp32s3 ~/.platformio/penv/bin/pio run -j8 --upload-port $PORT --target upload -e $BENV

actually builds and boots now. Yay!

Looking at that diff, I'd have never found it by knowledge. (I might have found it via persistence, but obviously I had not.) Those lines just look the same to me.

-board_build.memory_type = "qio_opi" +board_build.arduino.memory_type = qio_opi^M

config. Its not always straight forward how to overwrite the board configurations.

Indeed. I remember developing disgust with Scons years ago for that very reason. I moved on to other facets of the same project that used a different build system. Then I retired/disabled and find myself now back on projects using a thing coat of lipstick over...scons.

FML.

But yes, you are right. You need to know the detail to configure the stuff correct. This datasheet shows it a little bit: https://www.espressif.com/sites/default/files/documentation/esp32-s3_datasheet_en.pdf

It's super frustrating how sometimes it's the CHIP number and sometimes it's the MODULE number and sometimes the BOARD number. (I get they're three different things and may indeed be different; i'm just explaining frustration.) So board ZZZ might have module number WROOM-E which might have chip ESP32-S3, but somehow, somewhere, there are additional markings somewhere that describe the "DOWD" or "N8R16" traits, which I could see going into any of those three camps - I see empty solder pads for PSRAM, so is the PSRAM that's present small enough to be inside the package, but on a dfferent wafer? I've heard that's a thing, but I can't exactly start delidding things.

Sorry for the rant.

Oh, in vaguely related news, are you in North America? I think the tooth fairy is about to bring me another of these boards and I could forward you one, but if you're not in the US, postage would probably dwarf it. Maybe I should just send you an Amazon gift card to cover one if that doesn't work.

If so, that's mystery #4 https://github.com/BlueAndi/esp-rgb-led-matrix/issues/4. You're clearly a smart dude and wouldn't write a kilobyte of crap before initializing the UART. You wouldn't do it in two different threads or otherwise separate time domains. Even if you were this silly (you're not) the "fix" would always happen about the same time. So is there maybe something ELSE that's trying to control the serial port? I mean, we're compiling every opcode it can execute so we can't exactly accuse some TSR in your autoexec.bat (from 30 years ago...) or something, but it doesn't make sense that it doesn't resynchronize at one consistent point. Is there maybe a debug and a main thread both controlling the UART?

The esp32s3 has 3 uart's and for logging its getting more complicated depended on the development board

Wow, that's super weird. I hadn't even noticed the CH343 on this thing. The S3's claim to fame is integrated USB congtroller and "firmware" that drives CDC/ACM, right? So why would anyone pay for a bolt-on UART? That's wacky.

And I feel pretty silly for never noticing that switch. That's the smallest I've seen and, TBF, it was covered by a mm of kapton-style tape, presumably so they could ultrasonically clean the flux off during manufacture.

What we see is, that the log_e() is shown on the console, because it uses uart0 (esp_tx/esp_rx). With the current setup, the Serial object is created by HWCDC Serial;. That means Serial.println() goes with CDC (USB Communication Device Class) and not over uart0.

Great find. Our mysteries are getting clearer.

Side rant: Damn, this python dependency finder thing is slow. My machine should be able to easily build all the software on the board in less time than it takes to figure out what to build. Activity monitor shows python taking way more CPU than any of the compiler invocations and rarely are we compiling on > 1 core. Six minute "do nothing" build times are just embarrassing. OK, let's try:

  Serial.println("\n");

Seems crazy that it even let me access members for four, but let's go with it...

[ 4007][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND [ 272][E][main.cpp:167] setup(): blah [ 418][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ha_dp NOT_FOUND

OK, let's try this newfound switch. Our dev node names change from WCH-specific ones to more generic /dev/usbmodem101.

It's a whole new world! It's tricky to catch the output before it's over, but that's just some scripting:

while : ; do; (stty 115200 ; cat -u ) < $PORT ; done

Serial-nothing

    11 INFO             InitState.cpp:  489 PIXELIX starts up ...
    11 INFO             InitState.cpp:  490 Target: luatos-esp32s3
    11 INFO             InitState.cpp:  491 SW version: v7.1.1:lc:b
    32 INFO        [   418][E][Preferences.cpp:483] getString():

nvs_get_str len fail: ha_dp NOT_FOUND 157 INFO TopicHandlerService.cpp: 78 Topic handler service started. 157 INFO SettingsService.cpp: 328 Settings service started. 157 INFO AudioDrv.cpp: 143 Audio driver task is up. 157 INFO AudioService.cpp: 103 Audio service started. [ 420][E][Preferences.cpp:483] getString(): nvs_get_str len fail: 579 INFO AudioDrv.cpp: 189 I2S driver illed. mqtt_broker_url NOT_FOUND [ 423][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND 589 INFO MqttService.cpp: 117 MQTT service started. [ 431][E][Preferences.cpp:483] getString(): nvs_get_str len fail: timezone NOT_FOUND [ 438][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ntp_server NOT_FOUND 604 INFO ClockDrv.cpp: 102 No RTC is available. [ 607][E][esp32-hal-gpio.c:102] pinMode(): Invalid pin selected [ 607][E][esp32-hal-gpio.c:102] pinMode(): Invalid pin selected [ 609][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected E (772) gpio: gpio_set_level(226): GPIO output gpio_num error [ 640][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected 899 INFO SensorDataProvider.cpp: 280 Sensor GL5528: available 899 INFO SensorDataProvider.cpp: 280 Sensor SHT3x: - 899 INFO SensorDataProvider.cpp: 280 Sensor DHT11: - 899 INFO SensorDataProvider.cpp: 280 Sensor Battery: - 922 INFO PluginFactory.cpp: 81 Plugin type BTCQuotePlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type CountdownPlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type DateTimePlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type DDPPlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type FirePlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type GameOfLifePlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type GrabViaMqttPlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type GrabViaRestPlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type GruenbeckPlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type IconTextLampPlugin registered. 923 INFO PluginFactory.cpp: 81 Plugin type IconTextPlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type JustTextPlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type MatrixPlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type OpenWeatherPlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type RainbowPlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type SensorPlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type SignalDetectorPlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type SoundReactivePlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type SunrisePlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type SysMsgPlugin registered. 924 INFO PluginFactory.cpp: 81 Plugin type TempHumidPlugin registered. 925 INFO PluginFactory.cpp: 81 Plugin type ThreeIconPlugin registered. 925 INFO PluginFactory.cpp: 81 Plugin type VolumioPlugin registered. 925 INFO PluginFactory.cpp: 81 Plugin type WifiStatusPlugin registered. 925 INFO PluginFactory.cpp: 81 Plugin type WormPlugin registered. 926 DEBUG BrightnessCtrl.cpp: 294 Light: 0.000 (b-thr 0.000 < x < d-thr 0.000) 926 DEBUG BrightnessCtrl.cpp: 313 Change brightness goal to 25. 927 DEBUG DisplayMgr.cpp: 1223 ProcessTask is up. 927 DEBUG DisplayMgr.cpp: 1285 UpdateTask is up. 927 INFO DisplayMgr.cpp: 213 DisplayMgr is up. 942 INFO DisplayMgr.cpp: 326 Start plugin SysMsgPlugin (UID 52673) in slot 0. 942 INFO DisplayMgr.cpp: 341 Plugin SysMsgPlugin (UID 52673) installed in slot 0. [ 784][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND 943 INFO InitState.cpp: 233 Clean up settings. 1028 INFO DisplayMgr.cpp: 1112 Slot 0 (SysMsgPlugin) now active. [ 2844][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 2886][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 2886][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 2896][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 2899][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND 3630 INFO PluginMgr.cpp: 259 JSON document @175 size: 881 3630 INFO DisplayMgr.cpp: 326 Start plugin IconTextPlugin (UID 47208) in slot 1. [ 3489][E][vfs_api.cpp:105] open(): /littlefs/configuration/47208.sprite does not exist, no permits for creation 3648 WARNING BitmapWidget.cpp: 153 File /configuration/47208.sprite doesn't exists. [ 3507][E][vfs_api.cpp:105] open(): /littlefs/configuration/47208.bmp does not exist, no permits for creation 3666 WARNING BitmapWidget.cpp: 102 File /configuration/47208.bmp doesn't exists. 3666 INFO DisplayMgr.cpp: 341 Plugin IconTextPlugin (UID 47208) installed in slot 1. 3667 INFO RestApiTopicHandler.cpp: 180 [IconTextPlugin][47208] Registered: /rest/api/v1/display/uid/47208/text 3667 INFO RestApiTopicHandler.cpp: 180 [IconTextPlugin][47208] Registered: /rest/api/v1/display/alias/_welcome/text... [ 3509][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND 3672 INFO MqttApiTopicHandler.cpp: 284 [IconTextPlugin][47208] Register: pixelix-a1fa0afc/alias/_welcome/text 3673 INFO MqttApiTopicHandler.cpp: 327 [47208] Subscribed: pixelix-a1fa0afc/alias/_welcome/text/set 3673 INFO RestApiTopicHandler.cpp: 180 [IconTextPlugin][47208] Registered: /rest/api/v1/display/uid/47208/bitmap 3674 INFO RestApiTopicHandler.cpp: 180 [IconTextPlugin][47208] Registered: /rest/api/v1/display/alias/_welcome/bitm... 3674 INFO MqttApiTopicHandler.cpp: 284 [IconTextPlugin][47208] Register: pixelix-a1fa0afc/alias/_welcome/bitmap 3675 INFO MqttApiTopicHandler.cpp: 327 [47208] Subscribed: pixelix-a1fa0afc/alias/_welcome/bitmap/set [ 3621][E][vfs_api.cpp:182] remove(): /configuration/47208.sprite does not exists or is directory 3781 INFO UpdateMgr.cpp: 128 OTA hostname: pixelix-a1fa0afc 3930 INFO UpdateMgr.cpp: 129 Sketch size: 1397632 bytes 3930 INFO UpdateMgr.cpp: 130 Free size: 6553600 bytes [ 3784][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND [ 3785][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_passphrase NOT_FOUND 3948 INFO ConnectingState.cpp: 96 Keep button pressed and reboot. Set SSID/password via webserver. 3948 INFO ResetMon.cpp: 108 Reset reason APP CPU: Vbat power on reset 3948 INFO ResetMon.cpp: 109 Reset reason PRO CPU: Vbat power on reset 3948 INFO ResetMon.cpp: 110 Counted resets: 0 3948 INFO IdleState.cpp: 69 Going in idle state.

Finally, stuff that actually looks like your project! :-)

So I think we've learned now that

I'm back home for just a few minutes. Let me graft back in my changes to src/StateMachine/ConnectingState.cpp and try again...

[ brief pause while I rejigger 'doall' to cope with these serial changes ]

Poof. We're on the network:

Serial-nothing

    11 INFO             InitState.cpp:  489 PIXELIX starts up ...
    11 INFO             InitState.cpp:  490 Target: luatos-esp32s3
    12 INFO             InitState.cpp:  491 SW version: v7.1.1:lc:b
    32 INFO               165 INFO              AudioDrv.cpp:  143

Audio driver task is up. 594 INFO AudioDrv.cpp: 189 I2S driver installed. 595 INFO AudioService.cpp: 103 Audio service started. [ 429][E][Preferences.cpp:483] getString(): nvs_get_str len fail: mqtt_broker_url NOT_FOUND [ 430][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND 601 INFO MqttService.cpp: 117 MQTT service started. [ 435][E][Preferences.cpp:483] getString(): nvs_get_str len fail: timezone NOT_FOUND [ 442][E][Preferences.cpp:483] getString(): nvs_get_str len fail: ntp_server NOT_FOUND 616 INFO ClockDrv.cpp: 102 No RTC is available. [ 611][E][esp32-hal-gpio.c:102] pinMode(): Invalid pin selected [ 611][E][esp32-hal-gpio.c:102] pinMode(): Invalid pin selected [ 613][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected E (784) gpio: gpio_set_level(226): GPIO output gpio_num error [ 644][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected 911 INFO SensorDataProvider.cpp: 280 Sensor GL5528: available 911 INFO SensorDataProvider.cpp: 280 Sensor SHT3x: - 911 INFO SensorDataProvider.cpp: 280 Sensor DHT11: - 911 INFO SensorDataProvider.cpp: 280 Sensor Battery: - 934 INFO PluginFactory.cpp: 81 Plugin type BTCQuotePlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type CountdownPlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type DateTimePlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type DDPPlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type FirePlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type GameOfLifePlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type GrabViaMqttPlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type GrabViaRestPlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type GruenbeckPlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type IconTextLampPlugin registered. 935 INFO PluginFactory.cpp: 81 Plugin type IconTextPlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type JustTextPlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type MatrixPlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type OpenWeatherPlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type RainbowPlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type SensorPlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type SignalDetectorPlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type SoundReactivePlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type SunrisePlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type SysMsgPlugin registered. 936 INFO PluginFactory.cpp: 81 Plugin type TempHumidPlugin registered. 937 INFO PluginFactory.cpp: 81 Plugin type ThreeIconPlugin registered. 937 INFO PluginFactory.cpp: 81 Plugin type VolumioPlugin registered. 937 INFO PluginFactory.cpp: 81 Plugin type WifiStatusPlugin registered. 937 INFO PluginFactory.cpp: 81 Plugin type WormPlugin registered. 938 DEBUG BrightnessCtrl.cpp: 294 Light: 0.000 (b-thr 0.000 < x < d-thr 0.000) 938 DEBUG BrightnessCtrl.cpp: 313 Change brightness goal to 25. 939 DEBUG DisplayMgr.cpp: 1223 ProcessTask is up. 939 DEBUG DisplayMgr.cpp: 1285 UpdateTask is up. 939 INFO DisplayMgr.cpp: 213 DisplayMgr is up. 939 INFO DisplayMgr.cpp: 326 Start plugin SysMsgPlugin (UID 56849) in slot 0. 939 INFO DisplayMgr.cpp: 341 Plugin SysMsgPlugin (UID 56849) installed in slot 0. [ 774][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND 941 INFO InitState.cpp: 233 Clean up settings. 1041 INFO DisplayMgr.cpp: 1112 Slot 0 (SysMsgPlugin) now active. [ 2847][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 2894][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 2894][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND [ 2905][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_user NOT_FOUND [ 2908][E][Preferences.cpp:483] getString(): nvs_get_str len fail: web_login_pass NOT_FOUND 3651 INFO PluginMgr.cpp: 259 JSON document @175 size: 881 3651 INFO DisplayMgr.cpp: 326 Start plugin IconTextPlugin (UID 47208) in slot 1. [ 3503][E][vfs_api.cpp:105] open(): /littlefs/configuration/47208.sprite does not exist, no permits for creation 3670 WARNING BitmapWidget.cpp: 153 File /configuration/47208.sprite doesn't exists. [ 3521][E][vfs_api.cpp:105] open(): /littlefs/configuration/47208.bmp does not exist, no permits for creation 3688 WARNING BitmapWidget.cpp: 102 File /configuration/47208.bmp doesn't exists. 3688 INFO DisplayMgr.cpp: 341 Plugin IconTextPlugin (UID 47208) installed in slot 1. 3689 INFO RestApiTopicHandler.cpp: 180 [IconTextPlugin][47208] Registered: /rest/api/v1/display/uid/47208/text 3689 INFO RestApiTopicHandler.cpp: 180 [IconTextPlugin][47208] Registered: /rest/api/v1/display/alias/_welcome/text... [ 3523][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND 3694 INFO MqttApiTopicHandler.cpp: 284 [IconTextPlugin][47208] Register: pixelix-a1fa0afc/alias/_welcome/text 3695 INFO MqttApiTopicHandler.cpp: 327 [47208] Subscribed: pixelix-a1fa0afc/alias/_welcome/text/set 3695 INFO RestApiTopicHandler.cpp: 180 [IconTextPlugin][47208] Registered: /rest/api/v1/display/uid/47208/bitmap 3696 INFO RestApiTopicHandler.cpp: 180 [IconTextPlugin][47208] Registered: /rest/api/v1/display/alias/_welcome/bitm... 3696 INFO MqttApiTopicHandler.cpp: 284 [IconTextPlugin][47208] Register: pixelix-a1fa0afc/alias/_welcome/bitmap 3696 INFO MqttApiTopicHandler.cpp: 327 [47208] Subscribed: pixelix-a1fa0afc/alias/_welcome/bitmap/set [ 3643][E][vfs_api.cpp:182] remove(): /configuration/47208.sprite does not exists or is directory 3810 INFO UpdateMgr.cpp: 128 OTA hostname: pixelix-a1fa0afc 3958 INFO UpdateMgr.cpp: 129 Sketch size: 1397744 bytes 3959 INFO UpdateMgr.cpp: 130 Free size: 6553600 bytes 3972 INFO ConnectingState.cpp: 84 robert is here [ 3806][E][Preferences.cpp:483] getString(): nvs_get_str len fail: sta_ssid NOT_FOUND 3972 INFO ConnectingState.cpp: 89 robert was here 3972 INFO ResetMon.cpp: 108 Reset reason APP CPU: Vbat power on reset 3972 INFO ResetMon.cpp: 109 Reset reason PRO CPU: Vbat power on reset 3973 INFO ResetMon.cpp: 110 Counted resets: 0 3973 INFO ConnectingState.cpp: 143 Connecting to ****. 5526 INFO ConnectedState.cpp: 86 Connected. [ 5360][E][Preferences.cpp:483] getString(): nvs_get_str len fail: hostname NOT_FOUND [ 5361][E][Preferences.cpp:483] getString(): nvs_get_str len fail: notify_url NOT_FOUND 5531 INFO ConnectedState.cpp: 130 Hostname: pixelix-a1fa0afc IP: 192.168.2.168

Nightdriverled.com is not private. 'mesmerizer' is the project, err,

Oh, I see ... I tried https://github.com/mesmerizer/nightdriverled :-)

Oh. There's someone else using 'mesmerizer' as a GitHub ID. That's interesting.

https://github.com/PlummersSoftwareLLC/NightDriverStrip/

'Mesmerizer' is the build of NightDriverStrip that targets the HUB75. 'Demo' (and others) target the WS2812's.

So, we may be coming out of the weeds.

...but there's still no web server coming up on the IP address listed at the end of the posted stnippet.

Are we back into the 'solvable' problems now?

Thanx! RJL

BlueAndi commented 1 year ago

Excellent! I think that's one of our major mysteries down. Thank you.

You are welcome! :-) Thank you for the long breath, sometimes I get github issues and I ask back, but never receive any further answer.

Indeed. I remember developing disgust with Scons years ago for that very reason. I moved on to other facets of the same project that used a different build system. Then I retired/disabled and find myself now back on projects using a thing coat of lipstick over...scons.

I am not that familiar with Scons, so sometimes these kind of mistakes happen. Looks like others try to hide the Scons interface or close some holes there. Did you have an accident, forced you to retire?

It's super frustrating how sometimes it's the CHIP number and sometimes it's the MODULE number and sometimes the BOARD number. (I get they're three different things and may indeed be different; i'm just explaining frustration.) So board ZZZ might have module number WROOM-E which might have chip ESP32-S3, but somehow, somewhere, there are additional markings somewhere that describe the "DOWD" or "N8R16" traits, which I could see going into any of those three camps - I see empty solder pads for PSRAM, so is the PSRAM that's present small enough to be inside the package, but on a dfferent wafer? I've heard that's a thing, but I can't exactly start delidding things. Sorry for the rant.

No problem. In business currently I am dealing with Infineon Aurix MCUs and the chip id is long, but very important to see all the features you have or you miss. Empty solder pads means no PSRAM, because according to the schematic its a esp32-s3fn8 which has no inside-package PSRAM, see this snippet from the datasheet: image

You can modify the code and check whether you really have PSRAM or not.

Oh, in vaguely related news, are you in North America? I think the tooth fairy is about to bring me another of these boards and I could forward you one, but if you're not in the US, postage would probably dwarf it. Maybe I should just send you an Amazon gift card to cover one if that doesn't work.

No, I am living in Germany. I already searched on Amazon (.de) for these development boards, but couldn't find them. They seem to be available only on the .com website. Thanks for the offer.

Side rant: Damn, this python dependency finder thing is slow. My machine should be able to easily build all the software on the board in less time than it takes to figure out what to build. Activity monitor shows python taking way more CPU than any of the compiler invocations and rarely are we compiling on > 1 core. Six minute "do nothing" build times are just embarrassing.

Yes, its slow on my side as well. I am not sure but I guess they do a lot of internet traffic in the background to check for the libs which consumes a lot of time too.

Finally, stuff that actually looks like your project! :-)

Hoorrayyy! :-)

So, we may be coming out of the weeds. ...but there's still no web server coming up on the IP address listed at the end of the posted stnippet. Are we back into the 'solvable' problems now?

Hmm ... a simple http://192.168.2.168 should have done it ... I can't see any error message about. Please try: $ curl -u luke:skywalker -X GET http://192.168.2.168/rest/api/v1/status Just to see whether we get a response this way.

If not, please try to ping it.

robertlipe commented 1 year ago

I am in the mountains in a cabin with family for a few more days before I can craft a proper response but a little birdie just whistled (in German) to me: https://www.amazon.de/dp/B0CC8SC4XZ

Note the presence of the unpopulated PSRAM pads.

Tomorrow, I hope the birds go back to singing in languages I understand, as I know no German. :-)

BlueAndi commented 1 year ago

Enjoy the trip with your family. Didn't know that there are such strange german birds around. LOL

BlueAndi commented 1 month ago

Hi Robert, hope you are back from the mountains, or maybe already there agin? :-D

Is this still an issue or could we close it?

robertlipe commented 1 month ago

I have to admit that debugging it exceeded its value to me. If nobody else ever tried to run on this exact chip inthe subsequent year, it's time to close it.

Thanx for your help anyway.