Description
Hi, I have a CBU module from a AT/Tongou TO_Q_SY1_JWT that gets into bootloop when adding the WIFI
component.
I have flashed many other identical devices with no problem, but this one doesn't start.
I tried with a totally bare config and added a few components, to find the offending one is WIFI
Any suggestion to debug it?
WORKING YAML
substitutions:
node_id: bare-bk
verbose_name: "Bare"
esphome:
#name_add_mac_suffix: true
name: ${node_id}
comment: ${verbose_name}
preferences:
flash_write_interval: 1s
bk72xx:
board: cbu
framework:
loglevel: verbose
debug:
- wifi
- ota
logger:
level: VERY_VERBOSE
hardware_uart: UART1
status_led:
pin:
number: P15
inverted: true
switch:
- platform: gpio
name: ${verbose_name}
pin: P26
id: relay
restore_mode: RESTORE_DEFAULT_ON
binary_sensor:
- platform: gpio
id: hard_button
pin:
number: P17
inverted: true
on_click:
- switch.toggle: relay
- output.turn_on: led_red
- delay: 10s
- output.turn_off: led_red
output:
- platform: gpio
id: led_red
pin:
number: P9
inverted: true
Offending config
Above config boots and works well. It fails if I add:
wifi:
ssid: MY-SSID
password: "MyWifiPswd"
Serial Log Output
I [ 0.022] logger
[C][status_led:014]: Setting up Status LED...
[I][app:029]: Running through setup()...
[V][app:030]: Sorting components by setup priority...
[VV][scheduler:063]: set_interval(name='', interval=1000, offset=466)
[C][switch.gpio:011]: Setting up GPIO Switch 'Bare'...
[VV][lt.preferences:064]: fdb_kv_get_blob: key: 1274655749, len: 1
[D][switch:016]: 'Bare' Turning OFF.
[VV][lt.preferences:041]: s_pending_save: key: 1274655749, len: 1
[D][switch:055]: 'Bare': Sending state OFF
[D][switch:016]: 'Bare' Turning OFF.
[D][binary_sensor:034]: 'hard_button': Sending initial state OFF
[C][wifi:048]: Setting up WiFi...
[C][wifi:061]: Starting WiFi...
[C][wifi:062]: Local MAC: 1C:90:FF:15:07:49
[VV][lt.preferences:061]: NVS length does not match (0!=98)
[V][wifi_lt:035]: Enabling STA.
D [ 0.112] WIFI: Mode changing NULL -> STA
D [ 0.116] WIFI: Initializing func&app
It repeats the loop every 10s or so.
Another weird thing with this chip is that I get a bunch of CRC missmatch while checking chip type!
in ltchiptool while flashing.
After a couple of retries it flash though.
I also tried two different power sources to rule out power issues, but it gets in bootloop with both.
By the way, @kuba2k2 congrats on the great work you've done with this project!!