Closed odis68 closed 8 months ago
Part of the display code
` spi: clk_pin: GPIO18 #SCL -> mosi_pin: GPIO23 #SDA -> interface: software # This is only option that works, hardware, spi, spi1, spi2 do not
display:
Please provide your complete YAML configuration and a ESPHome log which contains the crash/exception causing the boot loop.
Part of the code was made to reduce the occupied memory. ESP32 has 300K RAM and 4MB
substitutions:
name: "jkbms-monitor-ble"
friendly_name: JKBMS_monitor_BLE
device_description: "Monitor and control a JK-BMS via bluetooth"
external_components_source: github://syssi/esphome-jk-bms@main
mac_address: "20:23:04:33:12:10"
# https://github.com/syssi/esphome-jk-bms
# Please use "JK02_24S" if you own a old JK-BMS < hardware version 11.0 (hardware version >= 6.0 and < 11.0)
# Please use "JK02_32S" if you own a new JK-BMS >= hardware version 11.0 (f.e. JK-B2A8S20P hw 11.XW, sw 11.26)
# Please use "JK04" if you have some old JK-BMS <= hardware version 3.0 (f.e. JK-B2A16S hw 3.0, sw. 3.3.0)
protocol_version: JK02_32S
# Моя версия
my_version: 1.0.8_02
esphome:
name: ${name}
comment: ${device_description}
project:
name: "syssi.esphome-jk-bms"
version: 2.0.0
# Включить если делать несколько одинаковых уже полностью готовых
# name_add_mac_suffix: true
esp32:
board: esp32dev
#board: nodemcu-32s
framework:
# type: arduino
type: esp-idf
# Enable logging
logger:
level: DEBUG
# Enable Home Assistant API
# If you don't use Home Assistant please remove this `api` section and uncomment the `mqtt` component!
api:
encryption:
key: "Goc7hS+T/8l/OqbuI8+GA+FwFrfRKkP2TtERPaP+ghk="
ota:
password: "a09fedfe29ff6604beb5508e80305b13"
on_begin:
then:
- switch.turn_off: ble_client_switch0
- logger.log: "BLE connection suspended for OTA update"
wifi:
networks:
- ssid: !secret wifi_ssid
password: !secret wifi_password
- ssid: !secret wifi_ssid1
password: !secret wifi_password1
reboot_timeout: 10min
# Enable fallback hotspot (captive portal) in case wifi connection fails
#ap:
# ssid: "Jk-Bms Fallback Hotspot"
# password: "yYnaXEo3PNzs"
# Example configuration entry
#web_server:
# port: 80
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# captive_portal:
spi:
clk_pin: GPIO18 #SCL ->
mosi_pin: GPIO23 #SDA ->
interface: software # This is only option that works, hardware, spi, spi1, spi2 do not
color:
- id: my_red
red: 100%
green: 0%
blue: 0%
- id: my_yellow
red: 100%
green: 100%
blue: 0%
- id: my_green
red: 0%
green: 100%
blue: 0%
- id: my_blue
red: 0%
green: 0%
blue: 100%
- id: my_gray
red: 50%
green: 50%
blue: 50%
#============================================
#https://github.com/esphome/issues/issues/1491 file: "/homeassistant/esphome/Font/arial.ttf"
font:
- file: "Fonts/arial.ttf"
id: my_font
size: 20
- file: "gfonts://Roboto"
id: my_font2
size: 30
- file: "gfonts://Roboto"
id: my_font3
size: 90
display:
- platform: st7789v
cs_pin: GPIO05
dc_pin: GPIO17
# spi_mode: MODE3
# busy_pin: GPIO04
reset_pin: GPIO16
model: Custom
height: 240
width: 240
offset_height: 0
offset_width: 0
update_interval: 20s
lambda: |-
it.print(40, 30, id(my_font2), Color(id(my_green)),"Hello World!");
it.print(50, 60, id(my_font), "${my_version}!!!!");
# it.strftime(19, 94, id(my_font3), Color(id(my_gray)), "%H:%M", id(esptime).now());
# it.strftime(15, 90, id(my_font3), Color(id(my_yellow)), "%H:%M", id(esptime).now());
# it.print(20, 10, id(my_font), "Hello World!");
# it.rectangle(3, 3, it.get_width(), it.get_height(), id(my_blue));
# it.rectangle(10, 10, it.get_width(), it.get_height(), id(my_green));
#============================================
#============================================
# Example configuration entry interval: 2min
interval:
- interval: 2min
then:
- logger.log: "⚠️ esphome: Boot ${name}-${my_version} - interval: 2min !!!! OK"
#============================================
external_components:
- source: ${external_components_source}
refresh: 0s
#esp32_ble_tracker:
# on_ble_advertise:
# then:
# - lambda: |-
# if (x.get_name().rfind("JK-", 0) == 0) {
# ESP_LOGI("ble_adv", "New JK-BMS found");
# ESP_LOGI("ble_adv", " Name: %s", x.get_name().c_str());
# ESP_LOGI("ble_adv", " MAC address: %s", x.address_str().c_str());
# ESP_LOGD("ble_adv", " Advertised service UUIDs:");
# for (auto uuid : x.get_service_uuids()) {
# ESP_LOGD("ble_adv", " - %s", uuid.to_string().c_str());
# }
# }
ble_client:
- mac_address: ${mac_address}
id: client0
jk_bms_ble:
- ble_client_id: client0
protocol_version: ${protocol_version}
throttle: 5s
id: bms0
binary_sensor:
- platform: jk_bms_ble
balancing:
name: "${name} balancing"
charging:
name: "${name} charging"
discharging:
name: "${name} discharging"
heating:
name: "${name} heating"
online_status:
name: "${name} online status"
button:
- platform: jk_bms_ble
retrieve_settings:
name: "${name} retrieve settings"
retrieve_device_info:
name: "${name} retrieve device info"
number:
- platform: jk_bms_ble
jk_bms_ble_id: bms0
balance_trigger_voltage:
name: "${name} balance trigger voltage"
cell_count:
name: "${name} cell count"
total_battery_capacity:
name: "${name} total battery capacity"
id: total_battery_capacity
cell_voltage_overvoltage_protection:
name: "${name} cell voltage overvoltage protection"
cell_voltage_overvoltage_recovery:
name: "${name} cell voltage overvoltage recovery"
cell_voltage_undervoltage_protection:
name: "${name} cell voltage undervoltage protection"
cell_voltage_undervoltage_recovery:
name: "${name} cell voltage undervoltage recovery"
balance_starting_voltage:
name: "${name} balance starting voltage"
voltage_calibration:
name: "${name} voltage calibration"
current_calibration:
name: "${name} current calibration"
power_off_voltage:
name: "${name} power off voltage"
max_balance_current:
name: "${name} max balance current"
max_charge_current:
name: "${name} max charge current"
max_discharge_current:
name: "${name} max discharge current"
sensor:
- platform: jk_bms_ble
jk_bms_ble_id: bms0
min_cell_voltage:
name: "${name} min cell voltage"
max_cell_voltage:
name: "${name} max cell voltage"
min_voltage_cell:
name: "${name} min voltage cell"
state_class: "measurement"
accuracy_decimals: 0
max_voltage_cell:
name: "${name} max voltage cell"
# state_class: "measurement"
accuracy_decimals: 0
delta_cell_voltage:
name: "${name} delta cell voltage"
average_cell_voltage:
name: "${name} average cell voltage"
cell_voltage_1:
name: "${name} cell voltage 1"
cell_voltage_2:
name: "${name} cell voltage 2"
cell_voltage_3:
name: "${name} cell voltage 3"
cell_voltage_4:
name: "${name} cell voltage 4"
cell_voltage_5:
name: "${name} cell voltage 5"
cell_voltage_6:
name: "${name} cell voltage 6"
cell_voltage_7:
name: "${name} cell voltage 7"
cell_voltage_8:
name: "${name} cell voltage 8"
cell_resistance_1:
name: "${name} cell resistance 1"
cell_resistance_2:
name: "${name} cell resistance 2"
cell_resistance_3:
name: "${name} cell resistance 3"
cell_resistance_4:
name: "${name} cell resistance 4"
cell_resistance_5:
name: "${name} cell resistance 5"
cell_resistance_6:
name: "${name} cell resistance 6"
cell_resistance_7:
name: "${name} cell resistance 7"
cell_resistance_8:
name: "${name} cell resistance 8"
total_voltage:
name: "${name} total voltage"
current:
name: "${name} current"
power:
name: "${name} power"
charging_power:
name: "${name} charging power"
discharging_power:
name: "${name} discharging power"
temperature_sensor_1:
name: "${name} temperature sensor 1"
temperature_sensor_2:
name: "${name} temperature sensor 2"
power_tube_temperature:
name: "${name} power tube temperature"
state_of_charge:
name: "${name} state of charge"
capacity_remaining:
name: "${name} capacity remaining"
total_battery_capacity_setting:
name: "${name} total battery capacity setting"
charging_cycles:
name: "${name} charging cycles"
total_charging_cycle_capacity:
name: "${name} total charging cycle capacity"
total_runtime:
name: "${name} total runtime"
balancing_current:
name: "${name} balancing current"
errors_bitmask:
name: "${name} errors bitmask"
switch:
- platform: jk_bms_ble
charging:
name: "${name} charging"
discharging:
name: "${name} discharging"
balancer:
name: "${name} balancer"
- platform: ble_client
ble_client_id: client0
id: ble_client_switch0
name: "${name} enable bluetooth connection"
text_sensor:
- platform: jk_bms_ble
errors:
name: "${name} errors"
total_runtime_formatted:
name: "${name} total runtime formatted"
#- platform: ble_scanner # розкоментувати якщо потрібен сканер блютуз
# name: "BLE Devices Scanner" # розкоментувати якщо потрібен сканер блютуз
This is what I get by the console
Using 'COM4' as serial port.
Showing logs:
[17:29:34]I (533) cpu_start: Pro cpu up.
[17:29:34]I (534) cpu_start: Starting app cpu, entry point is 0x40082f04
[17:29:34]I (0) cpu_start: App cpu up.
[17:29:34]I (548) cpu_start: Pro cpu start user code
[17:29:34]I (548) cpu_start: cpu freq: 160000000
[17:29:34]I (548) cpu_start: Application information:
[17:29:34]I (552) cpu_start: Project name: jkbms-monitor-ble
[17:29:34]I (558) cpu_start: App version: 2023.12.9
[17:29:34]I (563) cpu_start: Compile time: Jan 31 2024 20:06:30
[17:29:34]I (569) cpu_start: ELF file SHA256: 13ea0e8e9f07d8ca...
[17:29:34]I (575) cpu_start: ESP-IDF: 4.4.5
[17:29:34]I (580) cpu_start: Min chip rev: v0.0
[17:29:34]I (585) cpu_start: Max chip rev: v3.99
[17:29:34]I (590) cpu_start: Chip rev: v1.0
[17:29:34]I (595) heap_init: Initializing. RAM available for dynamic allocation:
[17:29:34]I (602) heap_init: At 3FFAFF10 len 000000F0 (0 KiB): DRAM
[17:29:34]I (608) heap_init: At 3FFB6388 len 00001C78 (7 KiB): DRAM
[17:29:34]I (614) heap_init: At 3FFB9A20 len 00004108 (16 KiB): DRAM
[17:29:34]I (620) heap_init: At 3FFCAED0 len 00015130 (84 KiB): DRAM
[17:29:34]I (626) heap_init: At 3FFE0440 len 00003AE0 (14 KiB): D/IRAM
[17:29:34]I (632) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM
[17:29:34]I (639) heap_init: At 4009E8E4 len 0000171C (5 KiB): IRAM
[17:29:34]I (646) spi_flash: detected chip: generic
[17:29:34]I (650) spi_flash: flash io: dio
[17:29:34]I (655) cpu_start: Starting scheduler on PRO CPU.
[17:29:34]I (0) cpu_start: Starting scheduler on APP CPU.
[17:29:34][I][logger:351]: Log initialized
[17:29:34][C][ota:473]: There have been 9 suspected unsuccessful boot attempts.
[17:29:34][D][esp32.preferences:114]: Saving 1 preferences to flash...
[17:29:34][D][esp32.preferences:143]: Saving 1 preferences to flash: 0 cached, 1 written, 0 failed
[17:29:34][I][app:029]: Running through setup()...
[17:29:34][D][spi:039]: Setting up SPI bus...
[17:29:34][D][esp-idf:000]: I (43) gpio: GPIO[18]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0
[17:29:34]
[17:29:34][D][esp-idf:000]: I (44) gpio: GPIO[23]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0
[17:29:34]
[17:29:34][C][st7789v:011]: Setting up SPI ST7789V...
[17:29:34][D][spi_device:369]: mode 0, data_rate 20000kHz
[17:29:34][D][esp-idf:000]: I (59) gpio: GPIO[5]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0
[17:29:34]
[17:29:34][D][esp-idf:000]: I (80) gpio: GPIO[17]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0
[17:29:34]
[17:29:35][D][esp-idf:000]: I (90) gpio: GPIO[16]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0
[17:29:35]
[17:29:37][E][display:017]: Could not allocate buffer for display!Guru Meditation Error: Core 1 panic'ed (StoreProhibited). Exception was unhandled.
[17:29:37]
[17:29:37]Core 1 register dump:
[17:29:37]PC : 0x4000c46c PS : 0x00060e30 A0 : 0x800e6489 A1 : 0x3ffcd020
[17:29:37]A2 : 0x00000000 A3 : 0x00000000 A4 : 0x0001c200 A5 : 0x00000000
[17:29:37]A6 : 0x000000f1 A7 : 0x00001c20 A8 : 0x801af35c A9 : 0x3ffccff0
[17:29:37]A10 : 0x0000e100 A11 : 0x3f403ecd A12 : 0x00000011 A13 : 0x3f403cb2
[17:29:37]A14 : 0x00000028 A15 : 0x00020000 SAR : 0x00000004 EXCCAUSE: 0x0000001d
[17:29:37]EXCVADDR: 0x00000000 LBEG : 0x4000c46c LEND : 0x4000c477 LCOUNT : 0x00001c1f
[17:29:37]
[17:29:37]
[17:29:37]Backtrace: 0x4000c469:0x3ffcd020 0x400e6486:0x3ffcd030 0x400ea608:0x3ffcd050 0x401af5d5:0x3ffcd070 0x400ea164:0x3ffcd090 0x400eebf7:0x3ffcd0c0 0x400d8c73:0x3ffcd1b0
[17:29:37]
[17:29:37]
[17:29:37]
[17:29:37]
[17:29:37]ELF file SHA256: 13ea0e8e9f07d8ca
[17:29:37]
[17:29:37]Rebooting...
[17:29:37]ets Jun 8 2016 00:22:57
[17:29:37]
[17:29:37]rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[17:29:37]configsip: 0, SPIWP:0xee
[17:29:37]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[17:29:37]mode:DIO, clock div:2
[17:29:37]load:0x3fff0018,len:4
[17:29:37]load:0x3fff001c,len:1044
[17:29:37]load:0x40078000,len:8896
[17:29:37]load:0x40080400,len:5828
[17:29:37]entry 0x400806ac
[17:29:38]I (533) cpu_start: Pro cpu up.
[17:29:38]I (534) cpu_start: Starting app cpu, entry point is 0x40082f04
[17:29:38]I (519) cpu_start: App cpu up.
[17:29:38]I (548) cpu_start: Pro cpu start user code
[17:29:38]I (548) cpu_start: cpu freq: 160000000
[17:29:38]I (548) cpu_start: Application information:
[17:29:38]I (552) cpu_start: Project name: jkbms-monitor-ble
[17:29:38]I (558) cpu_start: App version: 2023.12.9
[17:29:38]I (563) cpu_start: Compile time: Jan 31 2024 20:06:30
[17:29:38]I (569) cpu_start: ELF file SHA256: 13ea0e8e9f07d8ca...
[17:29:38]I (575) cpu_start: ESP-IDF: 4.4.5
[17:29:38]I (580) cpu_start: Min chip rev: v0.0
[17:29:38]I (585) cpu_start: Max chip rev: v3.99
[17:29:38]I (590) cpu_start: Chip rev: v1.0
[17:29:38]I (595) heap_init: Initializing. RAM available for dynamic allocation:
[17:29:38]I (602) heap_init: At 3FFAFF10 len 000000F0 (0 KiB): DRAM
[17:29:38]I (608) heap_init: At 3FFB6388 len 00001C78 (7 KiB): DRAM
[17:29:38]I (614) heap_init: At 3FFB9A20 len 00004108 (16 KiB): DRAM
[17:29:38]I (620) heap_init: At 3FFCAED0 len 00015130 (84 KiB): DRAM
[17:29:38]I (626) heap_init: At 3FFE0440 len 00003AE0 (14 KiB): D/IRAM
[17:29:38]I (632) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM
[17:29:38]I (639) heap_init: At 4009E8E4 len 0000171C (5 KiB): IRAM
[17:29:38]I (646) spi_flash: detected chip: generic
[17:29:38]I (650) spi_flash: flash io: dio
[17:29:38]I (655) cpu_start: Starting scheduler on PRO CPU.
[17:29:38]I (0) cpu_start: Starting scheduler on APP CPU.
[17:29:38][I][logger:351]: Log initialized
[17:29:38][C][ota:473]: There have been 10 suspected unsuccessful boot attempts.
[17:29:38][D][esp32.preferences:114]: Saving 1 preferences to flash...
[17:29:38][D][esp32.preferences:143]: Saving 1 preferences to flash: 0 cached, 1 written, 0 failed
[17:29:38][E][ota:480]: Boot loop detected. Proceeding to safe mode.
[17:29:38][I][app:029]: Running through setup()...
[17:29:38][C][wifi:038]: Setting up WiFi...
[17:29:38][D][esp-idf:000]: I (339) wifi:
[17:29:38][D][esp-idf:000]: wifi driver task: 3ffd152c, prio:23, stack:6656, core=0
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1339) system_api: Base MAC address is not set
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1340) system_api: read default base MAC address from EFUSE
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1355) wifi:
[17:29:38][D][esp-idf:000]: wifi firmware version: 0f80fa0
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1362) wifi:
[17:29:38][D][esp-idf:000]: wifi certification version: v7.0
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1372) wifi:
[17:29:38][D][esp-idf:000]: config NVS flash: enabled
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1392) wifi:
[17:29:38][D][esp-idf:000]: config nano formating: disabled
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1393) wifi:
[17:29:38][D][esp-idf:000]: Init data frame dynamic rx buffer num: 32
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1413) wifi:
[17:29:38][D][esp-idf:000]: Init management frame dynamic rx buffer num: 32
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1423) wifi:
[17:29:38][D][esp-idf:000]: Init management short buffer num: 32
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1434) wifi:
[17:29:38][D][esp-idf:000]: Init dynamic tx buffer num: 32
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1444) wifi:
[17:29:38][D][esp-idf:000]: Init static rx buffer size: 1600
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1464) wifi:
[17:29:38][D][esp-idf:000]: Init static rx buffer num: 10
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1465) wifi:
[17:29:38][D][esp-idf:000]: Init dynamic rx buffer num: 32
[17:29:38][D][esp-idf:000]:
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1476) wifi_init: rx ba win: 6
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1485) wifi_init: tcpip mbox: 32
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1495) wifi_init: udp mbox: 6
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1495) wifi_init: tcp mbox: 6
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1505) wifi_init: tcp tx win: 5744
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1515) wifi_init: tcp rx win: 5744
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1516) wifi_init: tcp mss: 1440
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1526) wifi_init: WiFi IRAM OP enabled
[17:29:38]
[17:29:38][D][esp-idf:000]: I (1536) wifi_init: WiFi RX IRAM OP enabled
[17:29:38]
[17:29:39][C][wifi:051]: Starting WiFi...
[17:29:39][C][wifi:052]: Local MAC: 94:B9:7E:E5:40:78
[17:29:39][D][esp-idf:000]: I (1548) phy_init: phy_version 4670,719f9f6,Feb 18 2021,17:07:07
[17:29:39]
[17:29:39][D][esp-idf:000]: I (1658) wifi:
[17:29:39][D][esp-idf:000]: mode : sta (94:b9:7e:e5:40:78)
[17:29:39][D][esp-idf:000]:
[17:29:39]
[17:29:39][D][esp-idf:000]: I (1659) wifi:
[17:29:39][D][esp-idf:000]: enable tsf
[17:29:39][D][esp-idf:000]:
[17:29:39]
[17:29:39][D][esp-idf:000]: I (1660) wifi:
[17:29:39][D][esp-idf:000]: Set ps type: 1
[17:29:39]
[17:29:39][D][esp-idf:000]:
[17:29:39]
[17:29:39][D][wifi:455]: Starting scan...
[17:29:39][D][esp-idf:000]: I (1675) wifi:
[17:29:39][D][esp-idf:000]: Set ps type: 1
[17:29:39]
[17:29:39][D][esp-idf:000]:
[17:29:39]
[17:29:42][D][wifi:470]: Found networks:
[17:29:42][I][wifi:514]: - 'IoT_01_plus' (9C:9D:7E:57:4B:5E) ▂▄▆█
[17:29:42][D][wifi:515]: Channel: 7
[17:29:42][D][wifi:516]: RSSI: -49 dB
[17:29:42][I][wifi:514]: - 'IoT_01' (A2:F3:C1:7E:D0:56) ▂▄▆█
[17:29:42][D][wifi:515]: Channel: 13
[17:29:42][D][wifi:516]: RSSI: -62 dB
[17:29:42][D][wifi:519]: - '' (A2:9D:7E:57:4B:5E) ▂▄▆█
[17:29:42][D][wifi:519]: - 'Briz137389' (60:32:B1:AE:57:78) ▂▄▆█
[17:29:42][D][wifi:519]: - 'SK' (A0:F3:C1:7E:D0:56) ▂▄▆█
[17:29:42][D][wifi:519]: - 'GUEST' (A6:F3:C1:7E:D0:56) ▂▄▆█
[17:29:42][D][wifi:519]: - 'Gagas_2000' (10:FE:ED:3E:B0:DA) ▂▄▆█
[17:29:42][D][wifi:519]: - 'fan01' (C0:25:2F:8C:E4:70) ▂▄▆█
[17:29:42][D][wifi:519]: - 'pautinaca' (64:EE:B7:04:6B:72) ▂▄▆█
[17:29:42][D][wifi:519]: - 'assa' (C0:25:2F:17:58:71) ▂▄▆█
[17:29:42][I][wifi:300]: WiFi Connecting to 'IoT_01_plus'...
[17:29:42][D][esp-idf:000]: I (5162) wifi:
[17:29:42][D][esp-idf:000]: new:<7,0>, old:<1,0>, ap:<255,255>, sta:<7,0>, prof:1
[17:29:42][D][esp-idf:000]:
[17:29:42]
[17:29:43][D][esp-idf:000]: I (5957) wifi:
[17:29:43][D][esp-idf:000]: state: init -> auth (b0)
[17:29:43][D][esp-idf:000]:
[17:29:43]
[17:29:43][D][esp-idf:000]: I (5969) wifi:
[17:29:43][D][esp-idf:000]: state: auth -> assoc (0)
[17:29:43][D][esp-idf:000]:
[17:29:43]
[17:29:43][D][esp-idf:000]: I (6026) wifi:
[17:29:43][D][esp-idf:000]: state: assoc -> run (10)
[17:29:43][D][esp-idf:000]:
[17:29:43]
[17:29:43][D][esp-idf:000]: I (6039) wifi:
[17:29:43][D][esp-idf:000]: connected with IoT_01_plus, aid = 1, channel 7, BW20, bssid = 9c:9d:7e:57:4b:5e
[17:29:43][D][esp-idf:000]:
[17:29:43]
[17:29:43][D][esp-idf:000]: I (6041) wifi:
[17:29:43][D][esp-idf:000]: security: WPA2-PSK, phy: bgn, rssi: -47
[17:29:43][D][esp-idf:000]:
[17:29:43]
[17:29:43][D][esp-idf:000]: I (6044) wifi:
[17:29:43][D][esp-idf:000]: pm start, type: 1
[17:29:43]
[17:29:43][D][esp-idf:000]:
[17:29:43]
[17:29:43][D][esp-idf:000]: I (6074) wifi:
[17:29:43][D][esp-idf:000]: <ba-add>idx:0 (ifx:0, 9c:9d:7e:57:4b:5e), tid:0, ssn:0, winSize:64
[17:29:43][D][esp-idf:000]:
[17:29:43]
[17:29:43][D][esp-idf:000]: I (6092) wifi:
[17:29:43][D][esp-idf:000]: AP's beacon interval = 102400 us, DTIM period = 1
[17:29:43][D][esp-idf:000]:
[17:29:43]
[17:29:46][D][esp-idf:000]: I (9477) wifi:
[17:29:46][D][esp-idf:000]: <ba-add>idx:1 (ifx:0, 9c:9d:7e:57:4b:5e), tid:6, ssn:2, winSize:64
[17:29:46][D][esp-idf:000]:
[17:29:46]
[17:29:47][D][esp-idf:000]: I (10071) esp_netif_handlers: sta ip: 192.168.22.218, mask: 255.255.255.0, gw: 192.168.22.1
[17:29:47]
[17:29:47][C][wifi:410]: SSID: 'IoT_01_plus'
[17:29:47][C][wifi:411]: IP Address: 192.168.22.218
[17:29:47][C][wifi:413]: BSSID: 9C:9D:7E:57:4B:5E
[17:29:47][C][wifi:414]: Hostname: 'jkbms-monitor-ble'
[17:29:47][C][wifi:416]: Signal strength: -46 dB ▂▄▆█
[17:29:47][C][wifi:420]: Channel: 7
[17:29:47][C][wifi:421]: Subnet: 255.255.255.0
[17:29:47][C][wifi:422]: Gateway: 192.168.22.1
[17:29:47][C][wifi:423]: DNS1: 192.168.22.1
[17:29:47][C][wifi:424]: DNS2: 0.0.0.0
[17:29:47][C][ota:097]: Over-The-Air Updates:
[17:29:47][C][ota:098]: Address: jkbms-monitor-ble.local:3232
[17:29:47][C][ota:101]: Using Password.
[17:29:47][W][ota:107]: Last Boot was an unhandled reset, will proceed to safe mode in 0 restarts
[17:29:47][I][app:062]: setup() finished successfully!
[17:29:47][I][ota:493]: Waiting for OTA attempt.
[17:29:47][I][app:102]: ESPHome version 2023.12.9 compiled on Jan 31 2024, 21:32:48
[17:29:47][I][app:104]: Project syssi.esphome-jk-bms version 2.0.0
[17:29:47][C][wifi:573]: WiFi:
[17:29:47][C][wifi:405]: Local MAC: 94:B9:7E:E5:40:78
[17:29:47][C][wifi:410]: SSID: 'IoT_01_plus'
[17:29:47][C][wifi:411]: IP Address: 192.168.22.218
[17:29:47][C][wifi:413]: BSSID: 9C:9D:7E:57:4B:5E
[17:29:47][C][wifi:414]: Hostname: 'jkbms-monitor-ble'
[17:29:47][C][wifi:416]: Signal strength: -46 dB ▂▄▆█
[17:29:47][C][wifi:420]: Channel: 7
[17:29:47][C][wifi:421]: Subnet: 255.255.255.0
[17:29:47][C][wifi:422]: Gateway: 192.168.22.1
[17:29:47][C][wifi:423]: DNS1: 192.168.22.1
[17:29:47][C][wifi:424]: DNS2: 0.0.0.0
[17:29:47][C][logger:439]: Logger:
[17:29:47][C][logger:440]: Level: DEBUG
[17:29:47][C][logger:441]: Log Baud Rate: 115200
[17:29:47][C][logger:443]: Hardware UART: UART0
[17:29:47][C][mdns:115]: mDNS:
[17:29:47][C][mdns:116]: Hostname: jkbms-monitor-ble
[17:29:47][C][ota:097]: Over-The-Air Updates:
[17:29:47][C][ota:098]: Address: jkbms-monitor-ble.local:3232
[17:29:47][C][ota:101]: Using Password.
[17:29:47][W][ota:107]: Last Boot was an unhandled reset, will proceed to safe mode in 0 restarts
This is the important part:
[16:45:58][E][display:017]: Could not allocate buffer for display!Guru Meditation Error: Core 1 panic'ed (StoreProhibited). Exception was unhandled.
[16:45:58]
[16:45:58]Core 1 register dump:
[16:45:58]PC : 0x4000c46c PS : 0x00060e30 A0 : 0x800e6491 A1 : 0x3ffcf3e0
[16:45:58]A2 : 0x00000000 A3 : 0x00000000 A4 : 0x0001c200 A5 : 0x00000000
[16:45:58]A6 : 0x000000f1 A7 : 0x00001c20 A8 : 0x801af29c A9 : 0x3ffcf3b0
[16:45:58]A10 : 0x0000e100 A11 : 0x3f4013c9 A12 : 0x00000011 A13 : 0x3f4011ae
[16:45:58]A14 : 0x00000028 A15 : 0x00020000 SAR : 0x00000004 EXCCAUSE: 0x0000001d
[16:45:58]EXCVADDR: 0x00000000 LBEG : 0x4000c46c LEND : 0x4000c477 LCOUNT : 0x00001c1f
[16:45:58]
[16:45:58]
[16:45:58]Backtrace: 0x4000c469:0x3ffcf3e0 0x400e648e:0x3ffcf3f0 0x400ea610:0x3ffcf410 0x401af515:0x3ffcf430 0x400ea16c:0x3ffcf450 0x400eeb43:0x3ffcf480 0x400d8c7b:0x3ffcf570
WARNING Found stack trace! Trying to decode it
WARNING Decoded 0x400e648e: esphome::st7789v::ST7789V::setup() at /tmp/.esphome/build/jkbms-monitor-ble/src/esphome/components/st7789v/st7789v.cpp:120
WARNING Decoded 0x400ea610: esphome::PollingComponent::call_setup() at /tmp/.esphome/build/jkbms-monitor-ble/src/esphome/core/component.cpp:189
WARNING Decoded 0x401af515: esphome::Component::call() at /tmp/.esphome/build/jkbms-monitor-ble/src/esphome/core/component.cpp:98
WARNING Decoded 0x400ea16c: esphome::Application::setup() at /tmp/.esphome/build/jkbms-monitor-ble/src/esphome/core/application.cpp:38
WARNING Decoded 0x400eeb43: setup() at /tmp/.esphome/build/jkbms-monitor-ble/<unicode string>:1716
WARNING Decoded 0x400d8c7b: esphome::loop_task(void*) at /tmp/.esphome/build/jkbms-monitor-ble/src/esphome/components/esp32/core.cpp:67
It looks like there is not enough memory available.
RAM?
Yes. The display component tries to allocate some bytes as frame buffer but there is no free RAM available anymore.
Probably this hint could help you: https://github.com/esphome/issues/issues/3877#issuecomment-1338893224
Thank you !!!!!! EightBitcolor: True Helped
display:
- platform: st7789v
cs_pin: GPIO05
dc_pin: GPIO17
eightbitcolor: True
reset_pin: GPIO16
model: Custom
height: 240
width: 240
offset_height: 0
offset_width: 0
update_interval: 20s
lambda: |-
it.print(40, 30, id(my_font2), Color(id(my_green)),"Hello World!");
it.print(50, 60, id(my_font), "${my_version}!!!!");
Please help me solve the problem of simultaneously connecting JK BMS and LCD ST7789V display. Separately, the display works and separately bluetuls interclogation on Esphome. At the same time, the display and Blutuls do not work, they do not work. ESP 32 is constantly rebooted. I would like to make a screen on the battery itself and receive full detailed data on Home Assistant