Sleeper85 / esphome-jk-bms-can

GNU General Public License v3.0
94 stars 22 forks source link

Install failed #69

Closed dmsims closed 2 months ago

dmsims commented 3 months ago

Windows 11, Atom S3 lite

Prerequisites installed (all today) - Python, ESPhome, Git

Entered command:

David@DavidPC MINGW64 ~/esphome-jk-bms-can (main) $ esphome run ESP32_LFP_Wire_jk-bms-can.yaml INFO ESPHome 2024.7.3

Error: Failed config At least one platform must be specified for 'ota'; add 'platform: esphome' for original OTA functionality

Edited ESP32_LFP_Wire_jk-bms-can.yaml

added platform: esphome after line 167 (ota:)

Re ran install command and it proceeded until:

Tool Manager: Installing platformio/tool-idf @ ~1.0.1 INFO Installing platformio/tool-idf @ ~1.0.1 Downloading [####################################] 100% Unpacking [####################################] 100% Tool Manager: tool-idf@1.0.1 has been installed! INFO tool-idf@1.0.1 has been installed! Tool Manager: Installing platformio/tool-scons @ ~4.40700.0 INFO Installing platformio/tool-scons @ ~4.40700.0 Downloading [####################################] 100% Unpacking [####################################] 100% Tool Manager: tool-scons@4.40700.0 has been installed! INFO tool-scons@4.40700.0 has been installed! Verbose mode can be enabled via -v, --verbose option CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32doit-devkit-v1.html PLATFORM: Espressif 32 (5.4.0) > DOIT ESP32 DEVKIT V1 HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa) PACKAGES:

David@DavidPC MINGW64 ~/esphome-jk-bms-can (main)

Sleeper85 commented 3 months ago

You need to install the pkg_resources module.

dmsims commented 3 months ago

You need to install the pkg_resources module.

Thank you - I used:

pip install setuptools

Now the error message is about the chip version:

INFO Successfully compiled program. Found multiple options for uploading, please choose one: [1] COM4 (USB Serial Device (COM4)) [2] Over The Air (jk-bms-can.local) (number): 1 esptool.py v4.7.0 Serial port COM4 Connecting... ERROR Running command failed: This chip is ESP32-S3 not ESP32. Wrong --chip argument?

dmsims commented 3 months ago

OK I found the esphome-jk-bms-can\config\config_atom-s3-lite-esp32-s3.yaml file and updated both the main Wire and BLE yaml files with the info from that file

It flashes both Wire and BLE OK but constantly resets:

Auto-detected Flash size: 8MB Flash will be erased from 0x00010000 to 0x000d1fff... Flash will be erased from 0x00000000 to 0x00005fff... Flash will be erased from 0x00008000 to 0x00008fff... Flash will be erased from 0x00009000 to 0x0000afff... Compressed 792976 bytes to 505797... Wrote 792976 bytes (505797 compressed) at 0x00010000 in 5.3 seconds (effective 1186.2 kbit/s)... Hash of data verified. Warning: Image file at 0x0 is protected with a hash checksum, so not changing the flash size setting. Use the --flash_size=keep option instead of --flash_size=8MB in order to remove this warning, or use the --dont-append-digest option for the elf2image command in order to generate an image file without a hash checksum Compressed 20848 bytes to 13067... Wrote 20848 bytes (13067 compressed) at 0x00000000 in 0.3 seconds (effective 508.2 kbit/s)... Hash of data verified. Compressed 3072 bytes to 134... Wrote 3072 bytes (134 compressed) at 0x00008000 in 0.0 seconds (effective 558.1 kbit/s)... Hash of data verified. Compressed 8192 bytes to 31... Wrote 8192 bytes (31 compressed) at 0x00009000 in 0.1 seconds (effective 866.2 kbit/s)... Hash of data verified.

Leaving... Hard resetting via RTS pin... INFO Successfully uploaded program. INFO Starting log output from COM4 with baud rate 115200 [23:23:05]ESP-ROM:esp32s3-20210327 [23:23:05]Build:Mar 27 2021 [23:23:05]rst:0x7 (TG0WDT_SYS_RST),boot:0x28 (SPI_FAST_FLASH_BOOT) [23:23:05]Saved PC:0x400454d5 [23:23:05]SPIWP:0xee [23:23:05]mode:QIO, clock div:1 [23:23:05]load:0x3fce3808,len:0x16c4 [23:23:05]ets_loader.c 78 [23:23:06]ESP-ROM:esp32s3-20210327 [23:23:06]Build:Mar 27 2021 [23:23:06]rst:0x7 (TG0WDT_SYS_RST),boot:0x28 (SPI_FAST_FLASH_BOOT) [23:23:06]Saved PC:0x400454d5 [23:23:06]SPIWP:0xee [23:23:06]mode:QIO, clock div:1 [23:23:06]load:0x3fce3808,len:0x16c4 [23:23:06]ets_loader.c 78 [23:23:07]ESP-ROM:esp32s3-20210327 [23:23:07]Build:Mar 27 2021 [23:23:07]rst:0x7 (TG0WDT_SYS_RST),boot:0x28 (SPI_FAST_FLASH_BOOT) [23:23:07]Saved PC:0x400454d5 [23:23:07]SPIWP:0xee [23:23:07]mode:QIO, clock div:1 [23:23:07]load:0x3fce3808,len:0x16c4 [23:23:07]ets_loader.c 78 [23:23:09]ESP-ROM:esp32s3-20210327 [23:23:09]Build:Mar 27 2021 [23:23:09]rst:0x7 (TG0WDT_SYS_RST),boot:0x28 (SPI_FAST_FLASH_BOOT) [23:23:09]Saved PC:0x400454d5 [23:23:09]SPIWP:0xee [23:23:09]mode:QIO, clock div:1 [23:23:09]load:0x3fce3808,len:0x16c4 [23:23:09]ets_loader.c 78 [23:23:10]ESP-ROM:esp32s3-20210327 [23:23:10]Build:Mar 27 2021 [23:23:10]rst:0x7 (TG0WDT_SYS_RST),boot:0x28 (SPI_FAST_FLASH_BOOT) [23:23:10]Saved PC:0x400454d5 [23:23:10]SPIWP:0xee [23:23:10]mode:QIO, clock div:1 [23:23:10]load:0x3fce3808,len:0x16c4 [23:23:10]ets_loader.c 78 [23:23:11]ESP-ROM:esp32s3-20210327 [23:23:11]Build:Mar 27 2021 [23:23:11]rst:0x7 (TG0WDT_SYS_RST),boot:0x28 (SPI_FAST_FLASH_BOOT) [23:23:11]Saved PC:0x400454d5 [23:23:11]SPIWP:0xee [23:23:11]mode:QIO, clock div:1 [23:23:11]load:0x3fce3808,len:0x16c4 [23:23:11]ets_loader.c 78 [23:23:13]ESP-ROM:esp32s3-20210327 [23:23:13]Build:Mar 27 2021 [23:23:13]rst:0x7 (TG0WDT_SYS_RST),boot:0x28 (SPI_FAST_FLASH_BOOT)

Sleeper85 commented 3 months ago

I think the problem is that you don't have this option : board_build.flash_mode: dio

# Atom S3 Lite - SKU:C124
# https://docs.m5stack.com/en/core/AtomS3%20Lite
esp32:
  board: esp32-s3-devkitc-1
  variant: esp32s3
  framework:
    type: esp-idf

esphome:
  platformio_options:
    board_build.flash_mode: dio # Standard uses a single line for data, Dual IO uses 2 lines for data (prevent reboot loop)
dmsims commented 3 months ago

Success! thank you so much

dmsims commented 3 months ago

S3 Lite keeps going in to Safe mode (with Wire version) - log attached safe mode log.txt

dmsims commented 3 months ago

Ok thought I would update this:

I Flashed this many times and eventually it worked

Symptoms of it not working:

Remote logs fail OTA fails Integration into HA fails or works and show no entities but Ping works HA discovery works

Sleeper85 commented 3 months ago

This looks like @ChrisG's problem but you flashed the old one BMS version 1.17.5 right?

dmsims commented 3 months ago

Yes 1 BMS 1.17.5

Just trying YamBMS 1.4.3 and HA integration does not work :(

Logger: homeassistant.components.esphome.manager Source: components/esphome/manager.py:408 integration: ESPHome (documentation, issues) First occurred: 17:00:25 (188 occurrences) Last logged: 20:35:08

Error getting setting up connection for 192.168.1.125: Timeout waiting for ListEntitiesDoneResponse, ListEntitiesAlarmControlPanelResponse, ListEntitiesBinarySensorResponse, ListEntitiesButtonResponse, ListEntitiesCameraResponse, ListEntitiesClimateResponse, ListEntitiesCoverResponse, ListEntitiesDateResponse, ListEntitiesDateTimeResponse, ListEntitiesEventResponse, ListEntitiesFanResponse, ListEntitiesLightResponse, ListEntitiesLockResponse, ListEntitiesMediaPlayerResponse, ListEntitiesNumberResponse, ListEntitiesSelectResponse, ListEntitiesSensorResponse, ListEntitiesServicesResponse, ListEntitiesSirenResponse, ListEntitiesSwitchResponse, ListEntitiesTextResponse, ListEntitiesTextSensorResponse, ListEntitiesTimeResponse, ListEntitiesUpdateResponse, ListEntitiesValveResponse after 60s Error getting setting up connection for 192.168.1.125: Connection closed

Sleeper85 commented 3 months ago

But you confirm having had the same problem with one bms version 1.17.5?

Can you test YamBMS 1.4.1 ? (see my post on the forum).

dmsims commented 3 months ago

Yes confirm same issue with 1.17.5

luckylinux commented 3 months ago

@dmsims: looking at your Log there is something blocking the LoopTask and the Watchdog is triggered.

[10:15:17][W][component:238]: Components should block for at most 30 ms.
[10:15:17][I][main:1597]: send can id: 0x373 hex: ff ff ff ff ff ff ff ff
[10:15:18][I][main:1610]: send can id: 0x374 [ASCII] Min cell voltage ID : 2147483647
[10:15:19][I][main:1640]: send can id: 0x375 [ASCII] Max cell voltage ID : 2147483647
[10:15:20][I][main:1674]: send can id: 0x376 [ASCII] Min Temp. Sensor ID : 1
[10:15:21][I][main:1692]: send can id: 0x377 [ASCII] Max Temp. Sensor ID : 2
[10:15:22]E (19634) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
[10:15:22]E (19634) task_wdt:  - loopTask (CPU 1)
[10:15:22]E (19634) task_wdt: Tasks currently running:
[10:15:22]E (19634) task_wdt: CPU 0: IDLE0
[10:15:22]E (19634) task_wdt: CPU 1: IDLE1
[10:15:22]E (19634) task_wdt: Aborting.
[10:15:22]

I had an "edge case" (I described it in the Forum) where the only Thing left to do was to increase the Watchdog Timeout (I increased mine to 30s which is somewhat risky):

 esp32:
  board: {{board}}
  variant: {{variant}}
  framework:
    type: esp-idf

    # Introduced on 2024-05-17 while trying to solve a Watchdog Triggering on WiFi Connection Loss Issue
    sdkconfig_options:
      CONFIG_ESP_TASK_WDT: y
      CONFIG_ESP_TASK_WDT_TIMEOUT_S: "30"
      CONFIG_BT_BLE_42_FEATURES_SUPPORTED: y

You might want a Value < 30s for your use Case though ...

You also seem to have a weird WiFi Authentication Failed Issue though, are you sure you don't have some "Prefer 5G / Band Steering", WPA3/WPA2 Transition (or WPA3 only), etc Setting/Features enabled in your Router/AP?

[10:15:09][W][wifi_esp32:670]: Event: Disconnected ssid='thesims' bssid=E4:FA:C4:B3:73:23 reason='Authentication Failed'

EDIT: you might want to add this in the WiFi Section and see if they improve your Situation

wifi:
# Reintroduced on 2024-05-17 while attempting to solve a WiFi Signal Loss triggering Device Watchdog Issue
  power_save_mode: light # Reducing Power Saving Could help reduce issues with OTA

  # Set Reboot Timeout somewhat
  # !! Reboot timeout only works with AP disabled !!
  # !! https://github.com/esphome/issues/issues/1679 !!
  reboot_timeout: 24h

  # Introduced on 2024-05-17 while attempting to solve a WiFi Signal Loss triggering Device Watchdog Issue
  fast_connect: true
luckylinux commented 3 months ago

@Sleeper85 I wonder if what @dmsims experiences is some Component "Loop Task" taking too long, as you can see the following in the Log as well (probable Reason why the Watchdog go triggered):

# Initial WiFi Connection Attempt
[10:14:29][W][component:237]: Component interval took a long time for an operation (4006 ms).

# Just before Wifi Disconnect / Authentication Failed
[10:14:10][W][component:237]: Component interval took a long time for an operation (1002 ms).

# Before WiFi Conneting successfully
[10:14:12][W][component:237]: Component interval took a long time for an operation (1002 ms).
Sleeper85 commented 3 months ago

@luckylinux

Not connecting a canbus board has the effect of slowing down the execution of the code when sending frames, it is possible that this comes from there.

luckylinux commented 3 months ago

@Sleeper85: I see you are setting the default Protocol in https://github.com/Sleeper85/esphome-jk-bms-can/blob/development/packages/yambms/yambms_canbus.yaml#L72 to Pylon + (in the Forum I see you just changed to "Disabled") ...

Do you mean that the ESP32 is in some state of Queueing up the CAN Frames but, without "Driver" Board (CAN Adapter) Connected, it basically fills up the Queue and/or simply it causes the CAN messages to "Time Out" ?

That sounds kinda similar to what I had using an USB CANbus Adapter (CAN Frames queueing up indefinitively and ifconfig swhowing them as Transmitted/Received), but the CAN Adapter (which was installed on an AC-Powered USB Hub) didn't do anything. Only solution was to remove the AC-Power Cable from the USB Hub and reboot the Raspberry Pi.

Unrelated I know, but I guess it's generic CAN bus "Issue" (or Feature).

Sleeper85 commented 3 months ago

@luckylinux

Selecting Disabled protocol does not send any frames.

Sleeper85 commented 3 months ago

https://github.com/esphome/issues/issues/3317

To avoid this problem, sending CAN bus frames is paused for 120s if the inverter does not send any responses...

luckylinux commented 3 months ago

@luckylinux

Selecting Disabled protocol does not send any frames.

Yes but you just changed that now. Before it defaulted to Pylon+, didn't it ?

Sleeper85 commented 3 months ago

@luckylinux Selecting Disabled protocol does not send any frames.

Yes but you just changed that now. Before it defaulted to Pylon+, didn't it ?

Yes just now for testing...

luckylinux commented 3 months ago

If you can link me to the 1.4.3 Version the other People tested ... I'll be giving it a quick Try on the Atom S3 Lite.

I'll use latest from "development" Branch otherwise.

Sleeper85 commented 3 months ago

The version tested and causing problems is the one from the development branch and probably all the old versions too because @dmsims has the same problem with 1.17.5.

But we should not exclude a different behavior following all the latest updates of esphome.

luckylinux commented 3 months ago

I'm currently on ESPHome 2024.7.3 but 2024.8.0 is also just out !

luckylinux commented 3 months ago

@Sleeper85

Uhm not sure what is going on ... Probably my Routing (I am doing a test with a Test AP here in the House while Home Assistant in on a Subnet 3 Hops away in the Garage).

And of course the more Local Homeassistant Server is full and has been shut down :disappointed: .

2024-08-26 23:36:26.789 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_temperature_sensor_1, topic: 'yambms/sensor/yambms_jk-bms_1_temperature_sensor_1/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_temperature_sensor_1 has device class 'temperature', state class 'measurement' unit '°C' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.805 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_temperature_sensor_2, topic: 'yambms/sensor/yambms_jk-bms_1_temperature_sensor_2/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_temperature_sensor_2 has device class 'temperature', state class 'measurement' unit '°C' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.814 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_min_cell_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_min_cell_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_min_cell_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.816 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_max_cell_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_max_cell_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_max_cell_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.819 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_min_voltage_cell, topic: 'yambms/sensor/yambms_jk-bms_1_min_voltage_cell/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_min_voltage_cell has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.824 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_max_voltage_cell, topic: 'yambms/sensor/yambms_jk-bms_1_max_voltage_cell/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_max_voltage_cell has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.830 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_delta_cell_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_delta_cell_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_delta_cell_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.832 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_average_cell_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_average_cell_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_average_cell_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.835 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_total_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_total_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_total_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.837 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_current, topic: 'yambms/sensor/yambms_jk-bms_1_current/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_current has device class 'current', state class 'measurement' unit 'A' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.841 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_power, topic: 'yambms/sensor/yambms_jk-bms_1_power/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_power has device class 'power', state class 'measurement' unit 'W' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.845 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_charging_power, topic: 'yambms/sensor/yambms_jk-bms_1_charging_power/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_charging_power has device class 'power', state class 'measurement' unit 'W' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.851 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_discharging_power, topic: 'yambms/sensor/yambms_jk-bms_1_discharging_power/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_discharging_power has device class 'power', state class 'measurement' unit 'W' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.857 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_power_tube_temperature, topic: 'yambms/sensor/yambms_jk-bms_1_power_tube_temperature/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_power_tube_temperature has device class 'temperature', state class 'measurement' unit '°C' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.862 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_state_of_charge, topic: 'yambms/sensor/yambms_jk-bms_1_state_of_charge/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_state_of_charge has device class 'battery', state class 'measurement' unit '%' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.865 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_capacity_remaining, topic: 'yambms/sensor/yambms_jk-bms_1_capacity_remaining/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_capacity_remaining has device class 'None', state class 'measurement' unit 'Ah' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.867 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_total_battery_capacity_setting, topic: 'yambms/sensor/yambms_jk-bms_1_total_battery_capacity_setting/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_total_battery_capacity_setting has device class 'None', state class 'measurement' unit 'Ah' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.877 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_charging_cycles, topic: 'yambms/sensor/yambms_jk-bms_1_charging_cycles/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_charging_cycles has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.884 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_total_charging_cycle_capacity, topic: 'yambms/sensor/yambms_jk-bms_1_total_charging_cycle_capacity/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_total_charging_cycle_capacity has device class 'None', state class 'measurement' unit 'Ah' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.887 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_balancing_current, topic: 'yambms/sensor/yambms_jk-bms_1_balancing_current/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_balancing_current has device class 'current', state class 'measurement' unit 'A' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-26 23:36:26.893 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_errors_bitmask, topic: 'yambms/sensor/yambms_jk-bms_1_errors_bitmask/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_errors_bitmask has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'

The Device is claimed to be added to Home Assistant but it isn't Visible anywhere in "ESPHome" -> "Devices".

So I cannot add it and cannot delete it from the GUI I guess. Already tried to restart Home Assistant ...

20240826_esphome_logs_from_METEO-STATION_to_ROCK-5B.log

Let me see if I can manage to get the local Development Server back up. Otherwise I'll do a quick test in the Garage tomorrow ...

MQTT & MQTT Explorer (also in the Garage) seems to receive the Data without Issues though so maybe the Networking is Fine ... image

To be clear: the Data is nan but that is hardly a Surprise. No BMS is connected. No Inverter is Connected. Only the Atom S3 Lite with CANbus Unit CA IS3050G SKU U085 (plus the Termination Resistor) is connected - not sure if the latter made any Difference though.

EDIT 1: My Configuration -> https://github.com/luckylinux/esphome-jk-bms-can/commit/4f33cc75f932fef8081eb62436e2fc4bf0ce1058

luckylinux commented 3 months ago

@Sleeper85: I managed to give it another go on the other Local Home Assistant Server.

Device is successfully added and listed, BUT no Entities available.

image

Slighly different Logs I guess ...

s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service legacy-services: starting
services-up: info: copying legacy longrun home-assistant (no readiness notification)
s6-rc: info: service legacy-services successfully started
2024-08-27 00:20:47.892 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration ltss which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-08-27 00:20:47.894 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration danfoss_ally which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-08-27 00:20:47.895 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration eloverblik which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-08-27 00:20:50.929 WARNING (MainThread) [homeassistant.helpers.frame] Detected that custom integration 'eloverblik' calls async_forward_entry_setup for integration, eloverblik with title: Eloverblik 571313113160422714 and entry_id: 75962ca868d4ae901845c6b75104c09c, which is deprecated and will stop working in Home Assistant 2025.6, await async_forward_entry_setups instead at custom_components/eloverblik/__init__.py, line 40: hass.async_create_task(, please report it to the author of the 'eloverblik' custom integration
2024-08-27 00:20:53.513 WARNING (MainThread) [homeassistant.helpers.frame] Detected code that calls async_forward_entry_setup for integration eloverblik with title: Eloverblik 571313113160422714 and entry_id: 75962ca868d4ae901845c6b75104c09c, during setup without awaiting async_forward_entry_setup, which can cause the setup lock to be released before the setup is done. This will stop working in Home Assistant 2025.1. Please report this issue.
Stack (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/usr/src/homeassistant/homeassistant/__main__.py", line 223, in <module>
    sys.exit(main())
  File "/usr/src/homeassistant/homeassistant/__main__.py", line 209, in main
    exit_code = runner.run(runtime_conf)
  File "/usr/src/homeassistant/homeassistant/runner.py", line 190, in run
    return loop.run_until_complete(setup_and_run_hass(runtime_config))
  File "/usr/local/lib/python3.12/asyncio/base_events.py", line 674, in run_until_complete
    self.run_forever()
  File "/usr/local/lib/python3.12/asyncio/base_events.py", line 641, in run_forever
    self._run_once()
  File "/usr/local/lib/python3.12/asyncio/base_events.py", line 1990, in _run_once
    handle._run()
  File "/usr/local/lib/python3.12/asyncio/events.py", line 88, in _run
    self._context.run(self._callback, *self._args)
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 2161, in async_forward_entry_setup
    _report_non_awaited_platform_forwards(entry, "async_forward_entry_setup")
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 1201, in _report_non_awaited_platform_forwards
    report(
  File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 151, in report
    _LOGGER.warning(msg, stack_info=True)
2024-08-27 00:20:53.564 WARNING (Recorder) [homeassistant.components.recorder.migration] The database is about to upgrade from schema version 43 to 45
2024-08-27 00:20:53.697 WARNING (Recorder) [homeassistant.components.recorder.migration] Modifying columns data_id, event_type_id in table events. Note: this can take several minutes on large databases and slow machines. Please be patient!
2024-08-27 00:20:54.031 WARNING (Recorder) [homeassistant.components.recorder.migration] Modifying columns event_id, old_state_id, attributes_id, metadata_id in table states. Note: this can take several minutes on large databases and slow machines. Please be patient!
2024-08-27 00:20:54.042 ERROR (SyncWorker_0) [aiodhcpwatcher] Cannot watch for dhcp packets: [Errno 1] Operation not permitted
2024-08-27 00:20:54.111 ERROR (MainThread) [homeassistant.components.button] Platform mqtt does not generate unique IDs. ID ESPbuttonjk-bms_esp32_restart already exists - ignoring button.jk_bms_bat02_jk_bms_esp32_restart
2024-08-27 00:20:54.819 ERROR (MainThread) [homeassistant.components.select] Platform mqtt does not generate unique IDs. ID ESPselectcan_bms_name already exists - ignoring select.jk_bms_bat02_can_bms_name
2024-08-27 00:20:54.820 ERROR (MainThread) [homeassistant.components.select] Platform mqtt does not generate unique IDs. ID ESPselectcan_protocol already exists - ignoring select.jk_bms_bat02_can_protocol
2024-08-27 00:20:55.407 WARNING (MainThread) [homeassistant.components.mqtt.sensor] Invalid state message '1723564032.0' from 'jk-bms-bat02/sensor/jk-bms-bat02_last_complete_charge/state'
2024-08-27 00:20:55.433 WARNING (MainThread) [homeassistant.components.mqtt.sensor] Invalid state message '1724686336.0' from 'jk-bms-bat01/sensor/jk-bms-bat01_last_complete_charge/state'
2024-08-27 00:20:55.435 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.yambms_yambms_esp32_wifi_power_2 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement '%' which is not a valid unit for the device class ('signal_strength') it is using; expected one of ['dB', 'dBm']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2024-08-27 00:20:55.439 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.yambms_yambms_yambms_1_capacity_remaining_s (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'Ah' which is not a valid unit for the device class ('energy_storage') it is using; expected one of ['MWh', 'MJ', 'kWh', 'GJ', 'Wh']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2024-08-27 00:20:55.441 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.yambms_yambms_yambms_1_battery_capacity_s (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'Ah' which is not a valid unit for the device class ('energy_storage') it is using; expected one of ['MWh', 'MJ', 'kWh', 'GJ', 'Wh']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2024-08-27 00:20:55.450 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_temperature_sensor_1, topic: 'yambms/sensor/yambms_jk-bms_1_temperature_sensor_1/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_temperature_sensor_1 has device class 'temperature', state class 'measurement' unit '°C' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.459 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_temperature_sensor_2, topic: 'yambms/sensor/yambms_jk-bms_1_temperature_sensor_2/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_temperature_sensor_2 has device class 'temperature', state class 'measurement' unit '°C' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.463 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_min_cell_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_min_cell_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_min_cell_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.466 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_max_cell_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_max_cell_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_max_cell_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.468 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_min_voltage_cell, topic: 'yambms/sensor/yambms_jk-bms_1_min_voltage_cell/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_min_voltage_cell has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.469 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_max_voltage_cell, topic: 'yambms/sensor/yambms_jk-bms_1_max_voltage_cell/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_max_voltage_cell has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.471 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_delta_cell_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_delta_cell_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_delta_cell_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.472 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_average_cell_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_average_cell_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_average_cell_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.474 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_total_voltage, topic: 'yambms/sensor/yambms_jk-bms_1_total_voltage/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_total_voltage has device class 'voltage', state class 'measurement' unit 'V' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.475 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_current, topic: 'yambms/sensor/yambms_jk-bms_1_current/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_current has device class 'current', state class 'measurement' unit 'A' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.476 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_power, topic: 'yambms/sensor/yambms_jk-bms_1_power/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_power has device class 'power', state class 'measurement' unit 'W' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.478 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_charging_power, topic: 'yambms/sensor/yambms_jk-bms_1_charging_power/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_charging_power has device class 'power', state class 'measurement' unit 'W' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.480 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_discharging_power, topic: 'yambms/sensor/yambms_jk-bms_1_discharging_power/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_discharging_power has device class 'power', state class 'measurement' unit 'W' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.482 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_power_tube_temperature, topic: 'yambms/sensor/yambms_jk-bms_1_power_tube_temperature/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_power_tube_temperature has device class 'temperature', state class 'measurement' unit '°C' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.483 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_state_of_charge, topic: 'yambms/sensor/yambms_jk-bms_1_state_of_charge/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_state_of_charge has device class 'battery', state class 'measurement' unit '%' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.485 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_capacity_remaining, topic: 'yambms/sensor/yambms_jk-bms_1_capacity_remaining/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_capacity_remaining has device class 'None', state class 'measurement' unit 'Ah' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.489 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_total_battery_capacity_setting, topic: 'yambms/sensor/yambms_jk-bms_1_total_battery_capacity_setting/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_total_battery_capacity_setting has device class 'None', state class 'measurement' unit 'Ah' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.492 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_charging_cycles, topic: 'yambms/sensor/yambms_jk-bms_1_charging_cycles/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_charging_cycles has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.494 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_total_charging_cycle_capacity, topic: 'yambms/sensor/yambms_jk-bms_1_total_charging_cycle_capacity/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_total_charging_cycle_capacity has device class 'None', state class 'measurement' unit 'Ah' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.496 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_balancing_current, topic: 'yambms/sensor/yambms_jk-bms_1_balancing_current/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_balancing_current has device class 'current', state class 'measurement' unit 'A' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:55.497 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.yambms_yambms_jk_bms_1_errors_bitmask, topic: 'yambms/sensor/yambms_jk-bms_1_errors_bitmask/state' with payload: b'nan'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 383, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1005, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1130, in _async_write_ha_state
    self.__async_calculate_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1067, in __async_calculate_state
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1011, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 675, in state
    raise ValueError(
ValueError: Sensor sensor.yambms_yambms_jk_bms_1_errors_bitmask has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-finite value: 'nan'
2024-08-27 00:20:58.572 WARNING (MainThread) [homeassistant.components.mqtt.sensor] Invalid state message '1724686336.0' from 'jk-bms-bat01/sensor/jk-bms-bat01_last_complete_charge/state'
2024-08-27 00:21:14.992 WARNING (MainThread) [homeassistant.components.mqtt.sensor] Invalid state message '1723564032.0' from 'jk-bms-bat02/sensor/jk-bms-bat02_last_complete_charge/state'

20240826_esphome_logs_from_METEO-STATION_to_Local_Podman_Container_Same_Subnet.log

(Same Configuration)

Not sure if this Helps you or ...

At least it's NOT triggering the Watchdog in my Case (but I'm also NEITHER reading the BMS NOR talking to the Inverter).

The Entities don't show Up in Home Assistant ...

Sleeper85 commented 3 months ago

I will do another test tonight by adding a can board and then a second one. I have a SN65HVD230 and a MCP2515 on my PVbrain2 PCB.

luckylinux commented 3 months ago

It's just to see if it's a CAN Controller Issue (CAN Controller of the ESP32[-S3]) or if it also happens over SPI. But like ChrisG said on the Forum, apparently also the MCP2515 causes the Issue.

I would have thought that with the MCP2515 the "onboard" ESP32[-S3] CAN/TWAI Controller would NOT be used since then the communication would only happen over SPI with the MCP2515.

But maybe I'm wrong ...

Your Idea about doing a "single" (or at least a limited amount) "Ping" might work. I still think there is some "Queue" getting filled on the CAN Controller if not on the CAN Board, thus all Frames/Data Messages are attempted to be sent over and over again.

Thus limiting the Queue should also limit the Timeout / "Load" on the MCU (or Controller).

(The other Option to test would be to switch to Ethernet instead of WiFi and see if that improves Things - although many/most people will use WiFi in the End - since WiFi and/or api Connection seem to be affected, if not directly partially causing the Issue)

Sleeper85 commented 2 months ago

CANBUS 2.3.4 : Fixed bug of canbus link validation without inverter connected