261 Commits
Author SHA1 Message Date
Sleeper85 06d2b0fda0 YamBMS 1.5.6 changelog update 2025-06-19 21:49:16 +02:00
Sleeper85 74e36b5a4f YamBMS 1.5.6 - RP20450 RPi Pico Shunts Modbus Server 2025-06-19 08:42:12 +02:00
Sleeper85 fa0f1960cc Merge pull request #51 from GHswitt/PR_RP2040_Shunts
Support for RP2040
2025-06-19 02:46:00 +02:00
Sebastian e6e31c165c Add RP2040 example as Modbus server node for five Victron shunts 2025-06-18 23:20:09 +02:00
Sebastian b7c3eddee4 Add RP2040 support 2025-06-18 23:19:57 +02:00
Sleeper85 92ce28c041 New shunt_base_minimal.yaml for SmartShunt UART minimal version 2025-06-18 08:57:48 +02:00
Sleeper85 9d9769a205 YamBMS 1.5.6 - BASEN RS485 2025-06-17 20:52:24 +02:00
Sleeper85 60c875df23 BMS BASEN RS485 1.1.2 2025-06-17 20:50:28 +02:00
Sleeper85 a10e0085d8 Delete YamBMS_LP_BASEN-RS485.yaml 2025-06-17 20:49:49 +02:00
Sleeper85 d487b756bf Merge pull request #56 from GHswitt/PR_BasengreenBMS
Add support for Basengreen BMS
2025-06-17 20:22:09 +02:00
Sleeper85 9b4596bc43 BMS SEPLOS V1 V2 - Remove bms_combine.yaml 2025-06-17 01:20:49 +02:00
Sleeper85 7a447450cc Improved YamBMS template sensors ( device_class / state_class ) 2025-06-17 00:56:01 +02:00
Sleeper85 0ecc1df3e0 BMS JBD - Fixed issue #65 and added YAML examples 2025-06-16 19:54:50 +02:00
Sleeper85 e9fee50967 BMS EPLOS V1 V2 - splitting the combine YAML to sensors and adding an example YAML 2025-06-16 19:50:10 +02:00
Sleeper85 39543e8b9f Restore shunt_sensors_Junctek_KHF_UART.yaml 1.1.4 2025-06-15 13:10:33 +02:00
Sebastian 88c64f6ba4 Add example for Basengreen BMS 2025-06-15 12:55:19 +02:00
Sebastian 27649631fb Add support for Basengreen BMS
This add support for Basengreen BMS connected via RS485.
See https://github.com/GHswitt/esphome-basen
2025-06-15 12:55:16 +02:00
Sleeper85 e5fc628957 Fixing unit_of_measurement and state_class (bms_base.yaml) 2025-06-15 11:20:24 +02:00
Sleeper85 e6896837de Update README.md 2025-06-14 10:27:16 +02:00
Sleeper85 a353a63ade Update LilyGo T-Connect Pro 2025-06-14 10:18:26 +02:00
Sleeper85 9c5a87fbe7 YamBMS 1.5.6 - Adding LilyGo T-Connect Pro 2025-06-14 10:17:52 +02:00
Sleeper85 9ccbeb6b94 Merge pull request #44 from GHswitt/T-Connect-Pro
Add support for LilyGo T-Connect Pro
2025-06-14 09:51:37 +02:00
Sebastian 1d3a195d9a Add support for LilyGo T-Connect Pro
Add board configuration for https://lilygo.cc/products/t-connect-pro
See also: https://github.com/Xinyuan-LilyGO/T-Connect-Pro/tree/main

Display is disabled by default as updating it is slow and increases
the loop time to >100ms.
2025-06-13 22:00:31 +02:00
Sleeper85 d9cddd2461 Dashboard 1.5.6 - Fixed SoH 2025-06-13 10:12:49 +02:00
Sleeper85 3f50bc224b YamBMS 1.5.6 changelog
n
2025-06-12 23:29:09 +02:00
Sleeper85 777aa40339 Dashboards 1.5.6 2025-06-12 23:11:58 +02:00
Sleeper85 37e65b3036 Merge branch 'main' of https://github.com/Sleeper85/esphome-yambms 2025-06-12 21:51:19 +02:00
Sleeper85 660ff99b5c YamBMS 1.5.6 2025-06-12 21:51:06 +02:00
Sleeper85 214568c6ff Board 1.5.6 2025-06-12 20:51:18 +02:00
Sleeper85 665c25619c Fake charging cycles not internal 2025-06-12 20:49:38 +02:00
Sleeper85 7547ddb780 Max cycles offset to 3000 2025-06-12 20:48:06 +02:00
Sleeper85 6c4e710f45 Base 1.5.6 2025-06-12 20:46:27 +02:00
Sleeper85 a14452eb8e Create MCU_ESP32-S3_YBoard.png 2025-06-12 20:45:01 +02:00
Sleeper85 60291dee68 Merge pull request #61 from GHswitt/PR_Modbus0
Set Modbus BMS values to 0 when BMS goes offline
2025-06-12 20:41:48 +02:00
Sebastian 4a2f6aace1 Set Modbus BMS values to 0 when BMS goes offline 2025-06-12 20:23:10 +02:00
Sleeper85 dec2f7e4f8 Merge pull request #62 from GHswitt/PR_Modbus_Charging_Cycles
Modbus client: Make charging cycles available again
2025-06-12 07:51:06 +02:00
Sebastian 4a8f60817d Modbus client: Make charging cycles available again 2025-06-11 23:22:52 +02:00
Sleeper85 d727463717 Updating Charging Cycles Offset function 2025-06-11 16:58:48 +02:00
Sleeper85 d7ed15c557 Requirements ESPHome 2025.5.0 2025-06-10 21:59:39 +02:00
Sleeper85 1bc7bdfd67 Merge pull request #60 from k2dp2k/main - YamBMS 1.5.6
* Compatibility with `esphome 2025.5.0`
  * Fixed [issue #55](https://github.com/Sleeper85/esphome-yambms/issues/55)
  * Added [feature #32](https://github.com/Sleeper85/esphome-yambms/issues/35) 
  * Added [feature #32](https://github.com/Sleeper85/esphome-yambms/issues/35)
  * New `board_ESP32-S3_YBoard_DJK.yaml` board
2025-06-10 21:57:31 +02:00
Sleeper85 5159e75d62 Update YamBMS 1.5.6 changelog 2025-06-10 21:54:26 +02:00
Sleeper85 8afc7d1eb4 YamBMS 1.5.6 changelog 2025-06-10 21:50:55 +02:00
Sleeper85 ee919ad1f0 Update yambms_canbus.yaml version 2025-06-10 21:45:21 +02:00
Sleeper85 95e0b240ca Update bms_sensors_DEYE_CAN_module_full.yaml version 2025-06-10 21:42:05 +02:00
Sleeper85 a4ccbde14a Update bms_charging_cycles_base.yaml version 2025-06-10 21:40:05 +02:00
Sleeper85 297eb96363 Update bms_battery_soh.yaml version 2025-06-10 21:38:36 +02:00
Sleeper85 82fbdd29f2 Update and rename YamBMS_RP_YBoard_JK-PB_RS485_Modbus_BLE_Shunt.yaml to YamBMS_LP_YBoard_JK-PB_RS485_Modbus.yaml 2025-06-10 21:36:08 +02:00
Sleeper85 0b9eb99e33 Delete .github/workflows/yamllint.yml 2025-06-10 21:31:13 +02:00
Sleeper85 b312d3eb3e Update yambms_config.yaml version 2025-06-10 21:30:03 +02:00
Sleeper85 3209ec910b Update device_base.yaml version 2025-06-10 21:28:58 +02:00
Sleeper85 9da27a5a8b Update yambms_auto_dcl.yaml version 2025-06-10 21:27:54 +02:00
Sleeper85 31260f3ace Update yambms_auto_cvl.yaml version 2025-06-10 21:27:21 +02:00
Sleeper85 0c731d52fc Update yambms_auto_cvl.yaml version 2025-06-10 21:26:21 +02:00
Sleeper85 afec9413dd Update yambms_auto_ccl.yaml version 2025-06-10 21:25:40 +02:00
Sleeper85 a2da3ac19c Update shunt_sensors_Junctek_KHF_UART.yaml version 2025-06-10 21:24:38 +02:00
Sleeper85 afc259c62c Update board_options_rgb_led_status.yaml version 2025-06-10 21:23:39 +02:00
Sleeper85 c2943bac36 Update board_options_cpu_freq_240_esp32.yaml version 2025-06-10 21:22:55 +02:00
Sleeper85 76ed9e0d48 Update board_options_cpu_freq_240_esp32-s3.yaml version 2025-06-10 21:22:28 +02:00
Sleeper85 f3e35028b8 Update board_ESP32_DevKitC_espBerry_2-CH-CAN.yaml version 2025-06-10 21:20:51 +02:00
Sleeper85 e1dd4202ae Update board_ESP32-S3_YBoard_DJK.yaml version 2025-06-10 21:20:20 +02:00
Sleeper85 1ea2e7d66f Update board_ESP32-S3_Touch-LCD-7.yaml version 2025-06-10 21:19:29 +02:00
Sleeper85 15179db113 Update board_ESP32-S3_Touch-LCD-4.3.yaml version 2025-06-10 21:19:01 +02:00
Sleeper85 83e74563b6 Update board_ESP32-S3_AtomS3_ili9xxx.yaml version 2025-06-10 21:18:26 +02:00
Sleeper85 f858597a2b Update board_ESP32-S3_AtomS3_WOD.yaml version 2025-06-10 21:17:57 +02:00
Sleeper85 5c20e87f50 Update board_ESP32-S3_AtomS3R.yaml version 2025-06-10 21:17:23 +02:00
Sleeper85 a67202a70f Update board_ESP32-S3_AtomS3.yaml version 2025-06-10 21:16:43 +02:00
Sleeper85 bdd8e234d9 Update bms_temperature_sensor_6.yaml version 2025-06-10 21:15:58 +02:00
Sleeper85 6d56f796a1 Update bms_temperature_sensor_5.yaml version 2025-06-10 21:15:28 +02:00
Sleeper85 76f6046961 Update bms_temperature_sensor_4.yaml version 2025-06-10 21:14:17 +02:00
Sleeper85 7c7097fa0b Update bms_temperature_sensor_2.yaml version 2025-06-10 21:13:32 +02:00
Sleeper85 86f39195e8 Update bms_sensors_JK_UART_4G-GPS_full.yaml version 2025-06-10 21:12:47 +02:00
Sleeper85 42973d9c9d Update bms_sensors_JK_RS485_Modbus_bms_standard.yaml version 2025-06-10 21:12:16 +02:00
Sleeper85 592274bc59 Update bms_sensors_JK_RS485_Modbus_bms_full.yaml version 2025-06-10 21:11:41 +02:00
Sleeper85 ab04cc92db Update bms_sensors_JK_RS485_Modbus_JK-B_standard.yaml version 2025-06-10 21:11:05 +02:00
Sleeper85 33056b2437 Update bms_sensors_JK_BLE_standard.yaml version 2025-06-10 21:10:09 +02:00
Sleeper85 c1597bd502 Update bms_sensors_JBD_UART_full.yaml version 2025-06-10 21:09:23 +02:00
Sleeper85 d65226a1f9 Update bms_sensors_JBD_BLE_full.yaml version 2025-06-10 21:08:28 +02:00
Sleeper85 558f1bfa47 Update bms_sensors_FAKE.yaml version 2025-06-10 21:07:39 +02:00
Sleeper85 1d71cf895e Update bms_sensors_DEYE_CAN_top_minimal.yaml version 2025-06-10 21:06:05 +02:00
Sleeper85 506e019d6f Update bms_sensors_DEYE_CAN_top_full.yaml 2025-06-10 21:05:22 +02:00
Sleeper85 2284b7db51 Update bms_sensors_DEYE_CAN_module_minimal.yaml version 2025-06-10 21:04:31 +02:00
Sleeper85 cf874f0a0f Update bms_errors_bitmask_JK_UART_4G-GPS.yaml version 2025-06-10 21:03:36 +02:00
Sleeper85 e76a7b4695 Update bms_errors_bitmask_JK_RS485_Modbus.yaml version 2025-06-10 21:02:33 +02:00
Sleeper85 844a74887e Update bms_errors_bitmask_JK_BLE.yaml version 2025-06-10 21:02:04 +02:00
Sleeper85 623c66839a Update bms_errors_bitmask_JBD.yaml version 2025-06-10 21:01:14 +02:00
Sleeper85 726fafd79f Update bms_errors_bitmask_DEYE_CAN.yaml version 2025-06-10 21:00:39 +02:00
Sleeper85 e60f802a68 Update bms_combine_modbus_client.yaml version 2025-06-10 21:00:17 +02:00
Sleeper85 60ed5c132c Update bms_combine_SEPLOS_V1_V2_RS485_bms_full.yaml version 2025-06-10 20:59:43 +02:00
Sleeper85 cd9bd987df Update bms_combine_JK_UART_4G-GPS_minimal.yaml version 2025-06-10 20:59:07 +02:00
Sleeper85 f7a39d6b55 Update bms_combine_JK_RS485_Modbus_sniffer_talk_pin.yaml version 2025-06-10 20:57:22 +02:00
Sleeper85 cea0d98e62 Update bms_combine_JK_RS485_Modbus_sniffer.yaml version 2025-06-10 20:56:41 +02:00
Sleeper85 ada25f475b Update bms_combine_JK_RS485_Modbus_bms_minimal.yaml version 2025-06-10 20:55:49 +02:00
Sleeper85 d0f252265e Update bms_combine_JK_RS485_DISPLAY_full.yaml version 2025-06-10 20:55:15 +02:00
Sleeper85 308ec5f032 Update bms_combine_JK_BLE_V14_full.yaml version 2025-06-10 20:54:14 +02:00
Sleeper85 e9d1239c01 Update bms_combine_DEYE_CAN_module_minimal.yaml version 2025-06-10 20:52:57 +02:00
Sleeper85 58c6429d9c Update bms_combine_DEYE_CAN_module_full.yaml version 2025-06-10 20:51:45 +02:00
Sleeper85 9c747934a4 Update bms_combine_JK_BLE_full.yaml version 2025-06-10 20:50:58 +02:00
Sleeper85 58c50ffe8b Update bms_combine_JK_BLE_minimal.yaml version 2025-06-10 20:48:55 +02:00
k2dp2k 43d70f647f Update YamBMS_RP_YBoard_JK-PB_RS485_Modbus_BLE_Shunt.yaml 2025-06-10 20:30:53 +02:00
k2dp2k 30d428c4fc Rename yam-board.yaml to YamBMS_RP_YBoard_JK-PB_RS485_Modbus_BLE_Shunt.yaml 2025-06-10 20:29:49 +02:00
k2dp2k b4887912af Merge pull request #11 from k2dp2k/codex/zustandsklasse-für-yambms-wiederherstellen
Fix state_class for BMS charging cycle sensor
2025-06-10 20:26:16 +02:00
k2dp2k c9b12fbe87 Set charging cycle sensor state_class to total 2025-06-10 20:25:31 +02:00
k2dp2k 060e44c07d Update device_base.yaml 2025-06-10 20:24:57 +02:00
k2dp2k c3b5f5f88a Update board_options_cpu_freq_240_esp32.yaml 2025-06-10 20:24:05 +02:00
k2dp2k 0272cea3ca Update board_options_cpu_freq_240_esp32-s3.yaml 2025-06-10 20:23:43 +02:00
k2dp2k 64e4c7f0e0 Update device_base.yaml 2025-06-10 20:22:34 +02:00
k2dp2k 7a1d68a3f3 Update device_base.yaml 2025-06-10 20:21:34 +02:00
k2dp2k 1939298992 Merge pull request #10 from k2dp2k/codex/header-in-geänderte-dateien-aktualisieren
Update headers after recent changes
2025-06-10 20:17:26 +02:00
k2dp2k 71a7643ca2 chore: update headers for recent changes 2025-06-10 20:16:56 +02:00
k2dp2k 2a26d7822d Update YamBMS_HA_Dashboard_JK_RS485_3xBMS.yaml 2025-06-08 23:41:10 +02:00
k2dp2k 492c81b9a3 Update YamBMS_HA_Dashboard_JK_RS485_3xBMS.yaml 2025-06-08 23:27:22 +02:00
k2dp2k 45c9cd2efc Merge pull request #9 from k2dp2k/codex/begrenze-charging-cycles-auf-200-und-update-cycle-capacity
Fix cycle capacity calculation
2025-06-08 23:09:20 +02:00
k2dp2k 124688e83f Limit cycle base and improve cycle capacity 2025-06-08 23:09:04 +02:00
k2dp2k 309b43b565 Merge pull request #8 from k2dp2k/codex/füge-manuelle-anpassung-des-cyclecounts-hinzu
Add manual cycle count adjustment
2025-06-08 22:45:56 +02:00
k2dp2k 7a78cf5672 Add adjustable cycle capacity 2025-06-08 22:45:08 +02:00
k2dp2k a11f2b75c8 Add adjustable charging cycles 2025-06-08 22:36:01 +02:00
k2dp2k c83d93874b Merge pull request #7 from k2dp2k/codex/restlaufzeit-zähler-hinzufügen
Add remaining time sensor
2025-06-08 22:30:22 +02:00
k2dp2k c426efa321 Add template sensor for remaining time 2025-06-08 22:30:10 +02:00
k2dp2k 0cabeeced8 Add remaining time sensor for Junctek shunt 2025-06-08 22:22:23 +02:00
k2dp2k 75e2ac8155 Merge pull request #6 from k2dp2k/codex/code-optimieren-im-verzeichnis-packages
Optimize display update timing
2025-06-08 22:11:23 +02:00
k2dp2k 7ca041c8c6 Improve display refresh rate 2025-06-08 22:10:58 +02:00
k2dp2k 0834b934d7 Merge pull request #5 from k2dp2k/codex/probleme-mit-yamllint-beheben
Fix yamllint issues
2025-06-08 22:05:07 +02:00
k2dp2k 679baa2068 chore: remove trailing whitespace for yamllint 2025-06-08 22:04:16 +02:00
k2dp2k 197ecd0957 Update yam-board.yaml 2025-06-08 22:01:06 +02:00
k2dp2k 37d2b3b320 Merge pull request #4 from k2dp2k/codex/datei-umbenennen-in-board_esp32-s3_yboard_djk.yaml
Rename board file
2025-06-08 21:58:36 +02:00
k2dp2k ce351bf7e8 Rename board_YamBoard_Deye_JK.yaml to board_ESP32-S3_YBoard_DJK.yaml 2025-06-08 21:58:10 +02:00
k2dp2k 2f53ed1eb2 meine configfile 2025-06-08 21:57:40 +02:00
k2dp2k 9e9024225d Merge pull request #3 from k2dp2k/codex/finde-probleme-und-mache-vorschläge
Fix docs typo and update DEYE CAN sensors
2025-06-08 21:52:45 +02:00
k2dp2k a74a69a740 Fix typo and DEYE CAN module calculation 2025-06-08 21:52:02 +02:00
k2dp2k 358a87ca2f Merge pull request #2 from k2dp2k/codex/fix-deprecation-warnings-in-esphome-configuration
Update to new ESPHome schema
2025-06-08 21:33:01 +02:00
k2dp2k 2139aee6d8 Update for ESPHome 2025.5 2025-06-08 21:32:49 +02:00
k2dp2k f0b79ad78c Merge pull request #1 from k2dp2k/codex/fehler-in-codebasis-suchen-und-beheben
Fix typo in modbus baud rate comments
2025-06-08 21:27:56 +02:00
k2dp2k a5ae54f8ad Fix Modbus baud rate comments and nominal voltage variable 2025-06-08 21:27:20 +02:00
k2dp2k 933003c4a9 Add files via upload 2025-06-08 21:19:12 +02:00
Sleeper85 c51e694197 Update board_ESP32-S3_Touch-LCD-4.3.yaml 2025-05-30 14:49:36 +02:00
Sleeper85 802511f4d6 Adds Waveshare LCD Touch boards 2025-05-30 14:22:49 +02:00
Sleeper85 c83eddecd0 Merge branch 'main' of https://github.com/Sleeper85/esphome-yambms 2025-05-30 09:15:53 +02:00
Sleeper85 cf95333a36 Update README.md 2025-05-30 09:15:40 +02:00
Sleeper85 5bb5eb99ad Merge pull request #50 from GHswitt/PR/Deye_Throttle
DEYE: Add throttle to some values
2025-05-21 00:32:26 +02:00
Sebastian f5592a005e Deye: Throttle operating mode 2025-05-20 22:59:57 +02:00
Sebastian b1e6af7a57 Deye: Throttle charge/discharge current as it fluctuates 2025-05-20 22:59:13 +02:00
Sleeper85 5e8ac7f3b1 Fixed Shunt SoC sensor name 2025-05-19 15:15:08 +02:00
Sleeper85 34722c13ce Merge branch 'main' of https://github.com/Sleeper85/esphome-yambms 2025-05-16 10:17:51 +02:00
Sleeper85 b3445c5e3c Important notes regarding BMS configuration. 2025-05-16 10:16:46 +02:00
Sleeper85 9859d4b0be Merge pull request #45 from GHswitt/PR_Modbus
Add Modbus server files for JK BMS (RS485) and DEYE (CAN)
2025-05-15 12:02:01 +02:00
Sebastian 6926f9ef9b Add Modbus server file for DEYE connected via CAN 2025-05-15 11:57:34 +02:00
Sebastian fca0b6848d Add Modbus server file for JK BMS connected via RS485 2025-05-15 11:57:30 +02:00
Sleeper85 9b22639405 Update README.md 2025-05-15 09:16:34 +02:00
Sleeper85 692eb525ca Merge pull request #49 from GHswitt/SmartShunt_Minimal
Add minimal versions for Victron SmartShunt via Modbus
2025-05-14 17:34:33 +02:00
Sleeper85 d56c2f1457 Merge pull request #48 from GHswitt/PR_README_Data_Collection
Inform in README.md about statistics collection
2025-05-14 17:20:54 +02:00
Sleeper85 884d4219a6 Create board_ESP32-S3_AtomS3_WOD.yaml 2025-05-14 09:25:43 +02:00
Sleeper85 9c4897d87e YamBMS 1.5.5 - Fix double name issue after HA PR #143049
https://github.com/home-assistant/core/pull/143049
2025-05-13 12:11:36 +02:00
Sleeper85 6b7c178093 Fix double name issue after HA PR #143049
https://github.com/home-assistant/core/pull/143049
2025-05-11 16:07:40 +02:00
Sebastian 557721f7f7 Add minimal versions for Victron SmartShunt via Modbus 2025-04-30 22:33:00 +02:00
Sebastian be71ac9340 Inform in README.md about statistics collection 2025-04-27 23:31:02 +02:00
Sleeper85 74587aa5f7 Update BMS_JK-B.md 2025-04-25 13:33:57 +02:00
Sleeper85 ec10e09c18 Update JK-B readme 2025-04-23 17:20:50 +02:00
Sleeper85 0b5773c9c9 JK RS485 Modbus JK-B standard version 2025-04-21 14:35:12 +02:00
Sleeper85 82493b0a6a Update README 2025-04-20 22:37:27 +02:00
Sleeper85 e0ccd7d07d Merge pull request #37 from GHswitt/Deye_CAN_PCS
Add support for Deye CAN PCS batteries
2025-04-16 15:20:55 +02:00
Sebastian 525436db44 Add support for Deye CAN PCS batteries
This adds support for Deye batteries using the CAN PCS port of
the battery.
Via the PCS port the battery sends out the overall status and status
frames for each installed module. This commit was tested with
a battery with two Deye AI-W5.1 modules.

bms_combine_DEYE_CAN_module_full.yaml:
  Combination of the BMS parts. For each module.
bms_combine_DEYE_CAN_module_minimal.yaml:
  Minimum number of sensors.
bms_sensors_DEYE_CAN_top_full.yaml:
  Deye top unit data, required.
bms_sensors_DEYE_CAN_top_minimal.yaml:
  Deye top unit data with reduced number of sensors.
bms_can_DEYE_module_full.yaml:
  Deye battery module data.
bms_can_DEYE_module_minimal.yaml:
  Deye battery module data with reduced number of sensors.
bms_errors_bitmask_DEYE_CAN.yaml:
  Error mapping Deye -> yambms.
YamBMS_LP_DEYE-PCS_CAN.yaml:
  Example using LilyGo T-CAN485
  with MCP2515 as secondary CAN bus.

Signed-off-by: Sebastian Witt <seb.witt@googlemail.com>
2025-04-16 15:09:01 +02:00
Sebastian 5aed8e6267 Allow substitions for can_id and bit_rate for MCP2515
Signed-off-by: Sebastian Witt <seb.witt@googlemail.com>
2025-04-14 20:54:27 +02:00
Sleeper85 5fe8583799 Rounding the SoC 2025-04-14 20:01:50 +02:00
Sleeper85 01462622d5 Don't limit the flash size to 2MB for ETH01-EVO 2025-04-13 14:27:33 +02:00
Sleeper85 d0601905e6 Update README 2025-04-07 20:29:00 +02:00
Sleeper85 3775c108ee YamBMS Remote Packages 1.5.5 2025-04-07 19:25:49 +02:00
Sleeper85 b3bcfdef7e YamBMS Local Packages 1.5.5 2025-04-07 19:25:29 +02:00
Sleeper85 3c716fd085 ESP32-S3 DevKitC-1 with RGB LED on GPIOs 38 and 48 2025-04-07 19:23:12 +02:00
Sleeper85 7815119183 YamBMS 1.5.5 (fix Force Float charge status) 2025-04-07 16:40:24 +02:00
Sleeper85 3b490821fe Turn on BMS charge switch if EOC or Float 2025-04-07 16:37:50 +02:00
Sleeper85 1b6c28e954 YamBMS 1.5.5 (bms charging logic fix) 2025-04-07 10:22:34 +02:00
Sleeper85 2046f44507 Update README.md 2025-04-07 08:35:07 +02:00
Sleeper85 098546b65d Local Packages examples 1.5.5 (AtomS3 display_rotation) 2025-04-07 08:24:59 +02:00
Sleeper85 eeee80faa7 Remote Packages examples 1.5.5 (AtomS3 display_rotation) 2025-04-07 08:24:45 +02:00
Sleeper85 c0240d44ed AtomS3 display_rotation option 2025-04-07 08:23:25 +02:00
Sleeper85 822b3394f6 Update bms_base.yaml 2025-04-04 23:22:25 +02:00
Sleeper85 a538ba3e6e Remote Packages examples 1.5.5 2025-04-04 23:16:19 +02:00
Sleeper85 95b69225ea Local Packages examples 1.5.5 2025-04-04 23:15:38 +02:00
Sleeper85 eb9663b840 Remove LP RP examples 2025-04-04 23:14:36 +02:00
Sleeper85 d5df679b9a YamBMS Remote Packages 1.5.5 2025-04-04 23:07:14 +02:00
Sleeper85 669dee91d4 YamBMS Local Packages 1.5.5 2025-04-04 23:06:55 +02:00
Sleeper85 0424392349 Create yambms_custom.yaml 2025-04-04 22:58:52 +02:00
Sleeper85 c78bb0c465 Create yambms_config.yaml 2025-04-04 22:58:49 +02:00
Sleeper85 1f3231df5f Delete config folder 2025-04-04 22:57:27 +02:00
Sleeper85 264b83ea8b YamBMS Remote Packages 1.5.5 2025-04-04 01:46:05 +02:00
Sleeper85 529334683b Update README.md 2025-04-04 01:41:48 +02:00
Sleeper85 1c4634c820 YamBMS Remote Packages 1.5.5 2025-04-04 01:36:07 +02:00
Sleeper85 06ed27e8f0 YamBMS Local Packages 1.5.5 2025-04-04 01:15:18 +02:00
Sleeper85 de8927ce36 YamBMS 1.5.5 2025-04-04 01:13:49 +02:00
Sleeper85 3c846ea24a Board 1.5.5 2025-04-04 01:12:38 +02:00
Sleeper85 a5e6423d03 BMS 1.5.5 2025-04-04 01:08:10 +02:00
Sleeper85 44cb8504d3 Delete old YAML 2025-04-04 00:51:33 +02:00
Sleeper85 63bce3f027 Update README 2025-04-04 00:48:56 +02:00
Sleeper85 84c90c11d3 YamBMS Remote Packages example 2025-04-01 23:24:40 +02:00
Sleeper85 3dde676dd8 YamBMS Remote Packages JK-BMS RS485 Modbus 2025-04-01 23:22:56 +02:00
Sleeper85 42151934bf JK-PB RS485 bms sensors version 2025-04-01 22:32:54 +02:00
Sleeper85 a8233ea8c6 Update yambms_remote_packages_example.yaml 2025-03-26 20:09:31 +01:00
Sleeper85 01c443e321 Create board_ESP32_Generic_3xUART.yaml 2025-03-26 20:05:37 +01:00
Sleeper85 9977cc5963 Update yambms_remote_packages_example.yaml 2025-03-24 17:17:39 +01:00
Sleeper85 f357d23751 YamBMS remote packages example 2025-03-21 21:28:15 +01:00
Sleeper85 ae276bb0eb Set min_version to 2025.3.0 2025-03-21 19:44:25 +01:00
Sleeper85 f8b677a2b8 Merge pull request #31 from shvmm/main
Update device_base.yaml remove external component PR#7547 after merge
2025-03-21 19:38:45 +01:00
Shivam Maurya 17d5edb2f0 Update device_base.yaml 2025-03-21 17:24:41 +05:30
Shivam Maurya 3de5f0e080 Merge branch 'Sleeper85:main' into main 2025-03-21 17:20:34 +05:30
Sleeper85 c4313cc577 Fixed configuration error regarding RGB LED with ESP-IDF V5 2025-03-12 22:36:33 +01:00
Sleeper85 ea1859068d Create yambms_custom.yaml 2025-03-12 12:47:56 +01:00
Sleeper85 4115a33d87 Merge pull request #33 from 20after4/olimex-evb
Board package for olimex ESP32-EVB
2025-03-09 22:30:22 +01:00
Sleeper85 4d52c3bbf8 Merge pull request #30 from ogremustcrush/main
Update Supported_devices.md to add SRNE HESP48120U200-H
2025-03-09 22:25:54 +01:00
Mukunda Modell 3f9956f4d5 Board package for olimex ESP32-EVB 2025-03-08 05:35:15 -06:00
Shivam Maurya 3127c7b3d7 Update device_base.yaml
removed external component PR#7547 after merge
2025-02-25 13:30:08 +05:30
Sleeper85 da658defd8 Update README 2025-02-20 16:43:04 +01:00
ogremustcrush 4a0f3c6090 Update Supported_devices.md to add SRNE HESP48120U200-H 2025-02-07 12:05:34 -07:00
Sleeper85 d889d091f7 T-CAN485 chips SN65HVD231DR / MAX13487E 2025-02-07 14:56:09 +01:00
Sleeper85 bb764ceb01 Merge pull request #29 from andrewfraley/patch-1
Add LilyGo T-CAN485 w/ EG4 12000XP and JBD
2025-02-07 14:52:59 +01:00
Andy Fraley 7ec5fc02ac Add afraley 12000XP 2025-02-06 21:57:28 -05:00
Sleeper85 df3d9353b6 Fixed JK-PB dashboard min/max cells coloring bug 2025-02-06 18:11:29 +01:00
Sleeper85 8777dc8688 device_class warnings fixed 2025-01-30 23:33:00 +01:00
Sleeper85 c47b768573 Merge pull request #27 from MrPabloUK/Updated-Auto-Functions
Updated Auto Functions
2025-01-29 18:12:56 +01:00
MrPabloUK e336ac315c Corrected deadband check 2025-01-29 12:20:49 +00:00
Sleeper85 56fd51e5d4 Create RS485-protocol-pylon-low-voltage-V3.3-20180821.pdf 2025-01-29 02:25:17 +01:00
Sleeper85 edd3beb0de Note regarding charging settings 2025-01-28 18:22:10 +01:00
Sleeper85 5e1d7ac48e Update JK-ALL BLE BMS YAMLs 2025-01-28 18:21:14 +01:00
Sleeper85 c552360fe0 Added JBD BMS over Bluetooth 2025-01-28 18:18:42 +01:00
MrPabloUK 088caecd47 Formatting 2025-01-28 12:33:43 +00:00
MrPabloUK af59e4307c Updated version & update date 2025-01-28 12:10:51 +00:00
MrPabloUK b303244b77 Update yambms.yaml 2025-01-28 11:57:33 +00:00
MrPabloUK 91f961fcd6 Updated Auto CCL, DCL, CVL
Updated Auto CCL, DCL and CVL functions to return a delta value instead of absolute value
2025-01-28 11:55:17 +00:00
Sleeper85 f22ab83e19 Update bms_options_charging_logic.yaml 2025-01-27 22:58:39 +01:00
Sleeper85 97f9e38031 Update bms_options_charging_logic.yaml 2025-01-27 22:11:11 +01:00
Sleeper85 b4cd402337 BMS charging logic 1.1.2 2025-01-27 22:07:25 +01:00
Sleeper85 25a2a88366 Dashboard JK-PB battery_capacity_total_setting fixed 2025-01-27 19:25:17 +01:00
Sleeper85 bdda35a837 YamBMS DEMO firmware 1.5.4 2025-01-26 20:36:10 +01:00
Sleeper85 7af47f5b2e YamBMS 1.5.4 2025-01-26 19:22:56 +01:00
Sleeper85 0fa4c61667 Force errors_bitmask to 0 for JK_RS485 component (avoid a bug) 2025-01-21 19:22:41 +01:00
Sleeper85 e9e3600686 YamBMS 1.5.3 2025-01-20 08:47:24 +01:00
Sleeper85 28323c7b29 YamBMS dashboard 1.5.3 2025-01-19 19:23:01 +01:00
Sleeper85 2cb7ba3c6d YamBMS DEMO firmware 1.5.3 2025-01-19 19:22:25 +01:00
Sleeper85 91df96d70c Don't count a uncombined BMS as blocking charge/discharge 2025-01-19 17:33:13 +01:00
Sleeper85 6d67b2677c Fix battery_capacity issue #14 2025-01-19 16:31:58 +01:00
Sleeper85 29e25e36b6 YamBMS 1.5.3 2025-01-18 06:35:01 +01:00
Sleeper85 5b36fac1b9 Merge pull request #19 from shvmm/patch-2
Update README.md to include 8MB flash size recommendation
2025-01-14 18:12:31 +01:00
Sleeper85 58d9ebc02e Merge pull request #18 from shvmm/patch-1
Create board_xiao-s3.yaml
2025-01-14 18:10:22 +01:00
Shivam Maurya 203911fc36 Update README.md to include 8MB flash size recommendation 2025-01-14 20:13:57 +05:30
Shivam Maurya 0b980a7f42 Create board_xiao-s3.yaml 2025-01-14 20:00:43 +05:30
Sleeper85 0455cba2da New packages vars name bms_address for JK-PB and SEPLOS 2025-01-07 16:44:07 +01:00
Sleeper85 cee37cd5b0 Remove logger baud_rate: 0 line 2025-01-06 21:42:17 +01:00
Sleeper85 c7b8c29fbf Update Supported_devices.md 2025-01-06 21:37:30 +01:00
Sleeper85 d7de61c675 Update of supported devices 2025-01-05 22:40:05 +01:00
Sleeper85 402d895a48 Update of supported devices 2025-01-05 22:05:20 +01:00
Sleeper85 485c6cc5fb AtomS3 display rollback to st7789v platform 2025-01-04 16:55:17 +01:00
Sleeper85 43f995a7a9 Merge branch 'main' of https://github.com/Sleeper85/esphome-yambms 2024-12-27 10:26:57 +01:00
Sleeper85 9b207b5484 Update YamBMS_behavior.md 2024-12-27 10:26:55 +01:00
Sleeper85 13d4d78123 Create FUNDING.yml 2024-12-26 11:14:52 +01:00
Sleeper85 70a00ff733 YamBMS 1.5.2 2024-12-23 22:42:35 +01:00
Sleeper85 f193e27e83 Auto CCL-DCL based on OVP-UVP 2024-12-21 15:49:21 +01:00
Sleeper85 f79aca0a22 CANBUS 2.4.1 2024-12-09 16:12:31 +01:00
Sleeper85 408ebb5116 Victron SmartShunt HowTo 2024-12-09 14:03:18 +01:00
Sleeper85 f55b2d6601 Update images 2024-11-25 17:34:25 +01:00
Sleeper85 c151f575dc Update BMS_JK-PB_RS485_solution.md 2024-11-22 16:59:43 +01:00
Sleeper85 b1c26c48dd Create Jikong BMS RS485 modbus protocol V1.1.pdf 2024-11-19 14:00:00 +01:00
Sleeper85 24b90f4bd1 Update README files 2024-11-16 21:37:30 +01:00
252 changed files with 20232 additions and 8509 deletions

No files matched your search

+1
View File
@@ -0,0 +1 @@
buy_me_a_coffee: sleeper85
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -1,5 +1,5 @@
# Updated : 2024.11.11
# Version : 1.5.1
# Updated : 2025.06.12
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
@@ -26,7 +26,7 @@ views:
cards:
- graph: line
type: sensor
entity: sensor.yambms_yambms_1_total_voltage_o
entity: sensor.yambms_yambms_1_total_voltage
detail: 2
layout_options:
grid_columns: 2
@@ -40,7 +40,7 @@ views:
name: SoC
hours_to_show: 8
- type: gauge
entity: sensor.yambms_yambms_1_current_s
entity: sensor.yambms_yambms_1_current
needle: true
severity:
green: 0
@@ -53,7 +53,7 @@ views:
grid_columns: 2
grid_rows: 3
- type: gauge
entity: sensor.yambms_yambms_1_power_s
entity: sensor.yambms_yambms_1_power
needle: true
severity:
green: 0
@@ -66,16 +66,16 @@ views:
grid_columns: 2
grid_rows: 3
- type: tile
entity: sensor.yambms_yambms_1_installed_battery_capacity_s
entity: sensor.yambms_yambms_1_installed_battery_capacity
name: Installed Battery Capacity
- type: tile
entity: sensor.yambms_yambms_1_battery_soh
name: Battery SoH
- type: tile
entity: sensor.yambms_yambms_1_battery_capacity_s
entity: sensor.yambms_yambms_1_battery_capacity
name: Battery Capacity
- type: tile
entity: sensor.yambms_yambms_1_capacity_remaining_s
entity: sensor.yambms_yambms_1_capacity_remaining
name: Capacity Remaining
- type: tile
entity: sensor.yambms_yambms_1_delta_cell_voltage
+123 -18
View File
@@ -8,7 +8,15 @@
[!["Buy Me A Coffee"](https://img.shields.io/badge/buy%20me%20a%20coffee-donate-yellow.svg)](https://www.buymeacoffee.com/sleeper85)
> [!TIP]
> If compiling the source code is too difficult for you, I can provide you a `custom firmware` that is easy to install from a web page. You can [contact me privately](https://diysolarforum.com/direct-messages/add?to=Sleeper85) on the DIY solar forum.
> Not sure which YAML to choose ? ... `YamBMS_Remote_Packages_example.yaml` is a good basis for creating your custom YAML.
> Examples of BMS and Shunt imports can be found in the [configuration_examples](configuration_examples/) folder.
> You can mix different BMS models, the only condition is that they are numbered in order starting from `1`.
> [!IMPORTANT]
> The most important thing for proper functioning of YamBMS is that **the voltage of your BMS is well calibrated**.
> YamBMS logic is based on the `min_cell_voltage` and `max_cell_voltage` voltages of your BMS.
> If you use YamBMS, the internal charging logic of the `JK-PB BMS` will not be used.
> Please read the [documentation](README.md#contents) and the [setup instructions](documents/README/Schematic_and_setup_instructions.md).
| ESPHome application to monitor BMS and communicate with inverters<br>supporting CAN bus protocol compatible with Pylontech, GoodWe, SMA,<br>Victron or Luxpower (EG4). | <a href="https://www.buymeacoffee.com/Sleeper85" target="_blank"><img src="https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png" alt="Buy Me A Coffee" style="height: 60px !important;width: 217px !important;" ></a> |
| :--- | --- |
@@ -35,14 +43,6 @@
[Dedicated topic on DIY Solar Forum](https://diysolarforum.com/threads/yambms-jk-bms-can-with-new-cut-off-charging-logic-open-source.79325/)
## YamBMS
![Image](images/YamBMS_packaged_version.png "YamBMS packaged version")
## Home Assistant
![Image](images/YamBMS_HA_Dashboard.png "YamBMS HA Dashboard")
## Contents
1) [Supported devices](documents/README/Supported_devices.md)
@@ -55,14 +55,52 @@
8) [Installation procedure](documents/README/Installation_procedure.md)
9) [Troubleshooting](documents/README/Troubleshooting.md)
## YamBMS
![Image](images/YamBMS_packaged_version.png "YamBMS packaged version")
### Single-node
You install `YamBMS` on a single ESP32 connected to your BMS and your inverter.
* Max 3x BMS BLE
* Max 3x BMS UART
* several RS485 BMS on the same bus
### Multi-node
Each BMS/Shunt turns into a `modbus server` with its own address.
> [!IMPORTANT]
> The max number of `UART` BMS/Shunt per ESP32 is `2` (unless you use a UART expander) because you need to keep the last `UART` for the `RS485` network.
> The max number of `BLE` BMS/Shunt per ESP32 is `2`, ESP32-S3 / AtomS3 can supervise `3` BLE devices.
YamBMS installs on `node1` as a `modbus client` to collect information from all your BMS.
The `node1` is also connected to your inverter via the `CAN bus`.
The BMS/Shunt are connected to other ESP32 nodes connected on a dedicated RS485 bus for YamBMS. Each BMS/Shunt becomes a `modbus server`.
The theoretical limit is `256` modbus server (BMS/Shunt) per `RS485 bus` but in reality this will depend on the capabilities of `node1` (YamBMS) which will have to combine all the BMS/Shunt together.
[You can find more information about creating your YAML in this How To.](documents/README/YamBMS_main_YAML_HowTo.md)
> [!TIP]
> If you have a lot of `BMS/Shunt` to combine, using an `ESP32-S3` or `AtomS3` for `node1` is recommended.
![Image](images/YamBMS_multi-node_RS485_modbus.png "YamBMS multi-node RS485 modbus")
## Home Assistant
![Image](images/YamBMS_HA_Dashboard.png "YamBMS HA Dashboard")
## Try YamBMS with the DEMO firmware
You can simply test the application with a `generic ESP32` without compiling and connecting anything on your ESP32.<br>
You can simply test the application with a `generic ESP32` without compiling and connecting anything on your ESP32.
The DEMO firmware is composed of `3x BMS` and `1x Shunt` (fake) for a `48V LFP` system.
> [!IMPORTANT]
> `YamBMS_DEMO_ESP32.factory.bin` is intended for a generic ESP32, does not work with ESP32-S3.
> If you want to test `YamBMS DEMO` with another board you need to compile the firmware with the `multi-bms_DEMO.yaml`.
> If you want to test `YamBMS DEMO` with another board you need to compile the firmware with the `YamBMS_RP_DEMO.yaml`.
1) Download [YamBMS_DEMO_ESP32.factory.bin](firmware/YamBMS_DEMO_ESP32.factory.bin)
2) Follow the [procedure explained in this document](https://docs.google.com/document/d/12pOpaG4Iyw3DjC_kB1q0jjBeSKJHK2FvXI1swebL2RI/edit?usp=sharing).
@@ -75,16 +113,83 @@ rx_pin: 22 # to CAN board CRX (with 4.7K resistor except for SN65HVD230)
## Requirements
* [ESPHome 2024.6.0 or higher](https://github.com/esphome/esphome/releases)
* ESP32 MCU
* CAN Transceiver (only with TJA1050/TJA1051 : 4.7K resistor for 5V to 3V3 level shifing)
* BMS JK-B*, JK-PB* (other BMS brands already integrated with ESPhome can be added easily)
* Inverters supporting CAN PYLON/Goodwe/SMA/Victron Low Voltage protocol
* [ESPHome 2025.5.0 or higher](https://github.com/esphome/esphome/releases)
* ESP32 MCU (buying a board with ≥8MB flash is advised if you intend to monitor multiple BMS)
* CAN transceiver (only with TJA1050/TJA1051 => 4.7K resistor for 5V to 3V3 level shifing)
* BMS JK, JBD, Seplos (other BMS brands already integrated with ESPhome can be added easily)
* Inverters supporting CAN PYLON/GoodWe/SMA/Victron Low Voltage protocol
* Optional: 48V to 5V DC-DC converter to power the ESP32 from the JK-BMS VBAT pin (URB4805YMD-10WR3 or VRB4805S-6WR3)
* Optional: JK RS485 adaptor and RS485 to TTL 3V3 adaptor (see schematic section)
## Data collection
> [!NOTE]
> For your information, in June 2025 there were `100` YamBMS users.
If the ESP32 has an internet connection, the following data is sent to [this script](http://script.opentel.be/yambms.post.php)
for statistics collection. Only [@Sleeper85](https://github.com/Sleeper85) have access to this information for the production of statistics, the support and the update service.
- ESP32 MAC address
- YamBMS version
- Board chip
- Board name
- BMS model
- BMS count
- CAN bus name
- CAN bus protocol
- Uptime
- Current date and time
## Changelog
* YamBMS 1.5.6 :
* Fixed [issue 58](https://github.com/Sleeper85/esphome-yambms/issues/58) Compilation problem with `esphome 2025.5.0`
* Fixed [issue 55](https://github.com/Sleeper85/esphome-yambms/issues/55) New CPU frequency option
* Fixed [issue 65](https://github.com/Sleeper85/esphome-yambms/issues/65) JBD Circular dependency error
* Fixed [issue 35](https://github.com/Sleeper85/esphome-yambms/issues/35) BMS Charging Cycles Offset
* Merged [PR 51](https://github.com/Sleeper85/esphome-yambms/pull/51) Support for RP2040 RPi Pico
* Merged [PR 56](https://github.com/Sleeper85/esphome-yambms/pull/56) Add support for Basengreen BMS
* Merged [PR 60](https://github.com/Sleeper85/esphome-yambms/pull/60) Fixes for new ESPHome and add of BMS Cycle Count offset
* Merged [PR 61](https://github.com/Sleeper85/esphome-yambms/pull/61) Set Modbus BMS values to 0 when BMS goes offline
* New `board_ESP32-S3_Touch-LCD-4.3.yaml` board
* New `board_ESP32-S3_Touch-LCD-7.yaml` board
* New `board_ESP32-S3_YBoard_DJK.yaml` board
* New `board_RP2040_RPi_Pico.yaml` board
* YamBMS 1.5.5 :
* New `main.yaml` with LP (local packages) and RP (remote packages) versions
* New `board.yaml` with modular UART/CAN interfaces
* The name of the JK `bms.yaml` is no longer linked to a specific model
* SoC calculation is now based on remaining capacity for more accuracy (BMS only) [issues #39](https://github.com/Sleeper85/esphome-yambms/issues/39)
* SoH calculation is moved to BMS level (for those who do not provide this information)
* Improvement of the Victron SmartShunt doc [issues #38](https://github.com/Sleeper85/esphome-yambms/issues/38)
* YamBMS 1.5.4 :
* New low SoC corrected at each BMS level (the corrected SoC is the one transmitted to YamBMS)
* New BMS dashboard
* New end of charge logic at each BMS level, the charge switch turns off when the cells are equalized (disabled by default)
* Fixed `errors_bitamsk` for JK-PB RS485, test OK with YamBMS (forked component)
* YamBMS 1.5.3 :
* Broadcasting JK-PB settings to all BMS set to OFF by default
* Reorganizing the `board` folder and YAMLs (device_base.yaml moved to board.yaml)
* `device_base.yaml` should no longer be part of `YamBMS_main.yaml`
* New `RGB LED status` light effects (red, green, blue, cyan) as an `options` packages for `board.yaml`
* Increased CPU frequency to `240Mhz` as an `options` packages for `board.yaml`
* Added `ESP32 Generic`, `LilyGo T-CAN485`, `LilyGo T-Connect` and `XIAO` boards
* Fixed SoC logic (low SoC will be detected at BMS level and no longer at YamBMS level)
* Simplified combination logic (removal of the combine switch) + dashboard update
* Check `Battery Capacity` is `> 0` before combining info (see [issue #14](https://github.com/Sleeper85/esphome-yambms/issues/14))
* Improved alarm logic with a common `YamBMS errors bitmask` for all BMS models (see OTP vs UTP bug reported by @ChrisG)
* Added [PR #7547](https://github.com/esphome/esphome/pull/7547) regarding publishing entities via the API
* Removed `captive_portal` because it increases the `loop time` too much
* `PSRAM` will no longer be enabled by default as this has a bad impact on `BLE BMS`
* YamBMS 1.5.2 :
* Added shunt `Online Status` binary_sensor
* Shunt combine condition based on the new binary_sensor `Online Status`
* Logger `baud_rate: 0` by default (frees the 3rd UART and avoids some bugs like "WK2168 with canbus" or "BLE client with RS485 modbus")
* Changed names of `bms` and `shunt` YAMLs for modbus `multi-node` solution
* Added shared configuration file to simplify main YAML (centralization of parameters)
* Simplification (fewer options) when importing `BMS / Shunt` YAMLs
* New `multi-node` solution using `RS485 modbus` to communicate information to YamBMS
* New board `espBerry` with `2-CH-CAN HAT`
* YamBMS 1.5.1 :
* The conditions for `combining` BMS and the `charging` and `discharging` instructions no longer have any relation with the `errors_bitmask` sensor, the new system relies on the three **binary_sensor** `online status`, `charging allowed` and `discharging allowed` being linked to the status of alarms and switches.
* The BMS combination procedure has been completely rewritten.
@@ -117,6 +222,6 @@ rx_pin: 22 # to CAN board CRX (with 4.7K resistor except for SN65HVD230)
## References
* Thanks to [@syssi](https://github.com/syssi/esphome-jk-bms) for help and making the original JK-B UART and BLE code.
* Thanks to [@txubelaxu](https://github.com/txubelaxu/esphome-jk-bms) for help and making the original JK-PB RS485 code.
* Thanks to [@syssi](https://github.com/syssi/esphome-jk-bms) for help and making many BMS components (JK, JBD, Seplos, Pace, etc.)
* Thanks to [@txubelaxu](https://github.com/txubelaxu/esphome-jk-bms) for help and making the `JK-PB RS485` component.
* Thanks to [@uksa007](https://www.patreon.com/Uksa007Codedevelopment) for making the original CANBUS code.
+221
View File
@@ -0,0 +1,221 @@
# Updated : 2025.06.17
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# Don't forget to configure your WiFi credentials in the secrets.yaml
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
# This list is incomplete, other board.yaml are available in the board folder
# device_board: !include 'packages/board/board_ESP32_Generic.yaml'
# device_board: !include 'packages/board/board_ESP32_DevKit-V1.yaml'
# device_board: !include 'packages/board/board_ESP32_Atom-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32_EVB.yaml'
device_board: !include 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_XIAO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_YBoard.yaml'
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
uart_esp_1: !include packages/board/board_options_itf_uart_esp_1.yaml
# uart_esp_2: !include packages/board/board_options_itf_uart_esp_2.yaml
# uart_esp_3: !include packages/board/board_options_itf_uart_esp_3.yaml
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
canbus_node_1: !include
file: packages/board/board_options_itf_canbus_esp32_can.yaml
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# canbus_node_2: !include
# file: packages/board/board_options_itf_canbus_mcp2515.yaml
# vars:
# canbus_node_id: 'canbus_inverter_1'
# captive_portal: !include packages/board/board_options_captive_portal.yaml
############################################################
# Basen controller
controller: !include
file: packages/bms/bms_combine_BASEN_RS485_controller.yaml
vars:
basen_uart_id: 'uart_esp_1'
basen_uart_baud_rate: '9600'
basen_controller_id: "basen_controller_1"
# Basen module 1
bms1: !include
file: packages/bms/bms_combine_BASEN_RS485_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'BASEN-BMS 1'
bms_address: '0x01'
# Basen module 2
bms2: !include
file: packages/bms/bms_combine_BASEN_RS485_full.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'BASEN-BMS 2'
bms_address: '0x02'
yambms: !include packages/yambms/yambms.yaml
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+300
View File
@@ -0,0 +1,300 @@
# Updated : 2025.06.12
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# Don't forget to configure your WiFi credentials in the secrets.yaml
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS Demo' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
# This list is incomplete, other board.yaml are available in the board folder
device_board: !include 'packages/board/board_ESP32_Generic.yaml'
# device_board: !include 'packages/board/board_ESP32_DevKit-V1.yaml'
# device_board: !include 'packages/board/board_ESP32_Atom-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32_EVB.yaml'
# device_board: !include 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_XIAO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_YBoard.yaml'
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
captive_portal: !include packages/board/board_options_captive_portal.yaml
# uart_esp_1: !include packages/board/board_options_itf_uart_esp_1.yaml
# uart_esp_2: !include packages/board/board_options_itf_uart_esp_2.yaml
# uart_esp_3: !include packages/board/board_options_itf_uart_esp_3.yaml
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
canbus_node_1: !include
file: packages/board/board_options_itf_canbus_esp32_can.yaml
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# canbus_node_2: !include
# file: packages/board/board_options_itf_canbus_mcp2515.yaml
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
shunt1: !include
file: packages/shunt/shunt_combine_FAKE.yaml
vars:
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
# Shunt sensors values
shunt_voltage: '53.41' # V
shunt_current: '37.5' # A
shunt_power: '2003' # W
shunt_soc: '86' # %
bms1: !include
file: packages/bms/bms_combine_FAKE.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '243' # Ah
bms_voltage: '53.45' # V
bms_current: '9.2' # A
bms_power: '492' # W
bms_soc: '87' # %
bms_soh: '99' # %
bms_min_cell_voltage: '3.339' # V
bms_min_voltage_cell: '2' # cell number 1~16
bms_max_cell_voltage: '3.341' # V
bms_max_voltage_cell: '11' # cell number 1~16
bms_temperature_sensor_1: '21.1' # °C
bms_temperature_sensor_2: '21.3' # °C
bms_temperature_sensor_3: '21.5' # °C
bms_temperature_sensor_4: '21.7' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '178' # charging cycles number Used to calculate the SoH
bms2: !include
file: packages/bms/bms_combine_FAKE.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '238' # Ah
bms_voltage: '53.41' # V
bms_current: '11.3' # A
bms_power: '604' # W
bms_soc: '85' # %
bms_soh: '89' # %
bms_min_cell_voltage: '3.337' # V
bms_min_voltage_cell: '14' # cell number 1~16
bms_max_cell_voltage: '3.339' # V
bms_max_voltage_cell: '3' # cell number 1~16
bms_temperature_sensor_1: '21.8' # °C
bms_temperature_sensor_2: '21.6' # °C
bms_temperature_sensor_3: '21.4' # °C
bms_temperature_sensor_4: '21.2' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '226' # charging cycles number Used to calculate the SoH
bms3: !include
file: packages/bms/bms_combine_FAKE.yaml
vars:
bms_id: '3' # must be a number
bms_name: 'BMS 3'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '232' # Ah
bms_voltage: '53.37' # V
bms_current: '15.7' # A
bms_power: '838' # W
bms_soc: '83' # %
bms_soh: '79' # %
bms_min_cell_voltage: '3.334' # V
bms_min_voltage_cell: '7' # cell number 1~16
bms_max_cell_voltage: '3.336' # V
bms_max_voltage_cell: '9' # cell number 1~16
bms_temperature_sensor_1: '21.9' # °C
bms_temperature_sensor_2: '22.0' # °C
bms_temperature_sensor_3: '22.1' # °C
bms_temperature_sensor_4: '22.2' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '194' # charging cycles number Used to calculate the SoH
yambms: !include packages/yambms/yambms.yaml
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+236
View File
@@ -0,0 +1,236 @@
# Updated : 2025.06.12
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# Don't forget to configure your WiFi credentials in the secrets.yaml
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
# This list is incomplete, other board.yaml are available in the board folder
# device_board: !include 'packages/board/board_ESP32_Generic.yaml'
# device_board: !include 'packages/board/board_ESP32_DevKit-V1.yaml'
# device_board: !include 'packages/board/board_ESP32_Atom-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32_EVB.yaml'
device_board: !include 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_XIAO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_YBoard.yaml'
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
# RS485
uart_esp_1: !include packages/board/board_options_itf_uart_esp_1.yaml
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
canbus_node_1: !include
file: packages/board/board_options_itf_canbus_esp32_can.yaml
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
canbus_node_2: !include
file: packages/board/board_options_itf_canbus_mcp2515.yaml
vars:
canbus_node_id: 'canbus_bms_1'
# If you do not want to use the default settings, uncomment the options below :
# canbus_can_id: '4'
# canbus_bitrate: '500kbps'
# spi_mosi_pin: '12'
# spi_miso_pin: '5'
# spi_clk_pin: '18'
# mcp2515_cs_pin: '32'
############################################################
# Deye BMS top unit (required)
bms_top: !include
file: packages/bms/bms_sensors_DEYE_CAN_top_full.yaml
vars:
# CAN BUS ID
canbus_id: 'canbus_bms_1'
deye_name: 'DEYE-Top 1'
deye_id: '1'
# Deye module 1
bms1: !include
file: packages/bms/bms_combine_DEYE_CAN_module_full.yaml
vars:
# CAN BUS ID
canbus_id: 'canbus_bms_1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'DEYE-BMS 1'
deye_id: '1'
deye_module_id: '0' # Modules are numbered with 0-9
# Deye module 2
bms2: !include
file: packages/bms/bms_combine_DEYE_CAN_module_full.yaml
vars:
# CAN BUS ID
canbus_id: 'canbus_bms_1'
# BMS vars
deye_id: '1'
bms_id: '2' # must be a number
bms_name: 'DEYE-BMS 2'
deye_module_id: '1' # Second module
yambms: !include packages/yambms/yambms.yaml
# yambms_custom: !include yambms_custom.yaml
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+257
View File
@@ -0,0 +1,257 @@
# Updated : 2025.06.16
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# Don't forget to configure your WiFi credentials in the secrets.yaml
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
# This list is incomplete, other board.yaml are available in the board folder
device_board: !include 'packages/board/board_ESP32_Generic.yaml'
# device_board: !include 'packages/board/board_ESP32_DevKit-V1.yaml'
# device_board: !include 'packages/board/board_ESP32_Atom-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32_EVB.yaml'
# device_board: !include 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_XIAO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_YBoard.yaml'
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
uart_esp_1: !include packages/board/board_options_itf_uart_esp_1.yaml
# uart_esp_2: !include packages/board/board_options_itf_uart_esp_2.yaml
# uart_esp_3: !include packages/board/board_options_itf_uart_esp_3.yaml
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
canbus_node_1: !include
file: packages/board/board_options_itf_canbus_esp32_can.yaml
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# canbus_node_2: !include
# file: packages/board/board_options_itf_canbus_mcp2515.yaml
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# shunt1: !include
# file: packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# shunt1: !include
# file: packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms1: !include
file: packages/bms/bms_combine_JBD_UART_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_uart_id: 'uart_esp_1'
bms_rx_timeout: '150ms'
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
bms2: !include
file: packages/bms/bms_combine_JBD_BLE_full.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_ble_mac_address: 'C8:47:8C:10:7E:AA' # Your MAC address
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
yambms: !include packages/yambms/yambms.yaml
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+319
View File
@@ -0,0 +1,319 @@
# Updated : 2025.06.12
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# Don't forget to configure your WiFi credentials in the secrets.yaml
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
# This list is incomplete, other board.yaml are available in the board folder
# device_board: !include 'packages/board/board_ESP32_Generic.yaml'
# device_board: !include 'packages/board/board_ESP32_DevKit-V1.yaml'
# device_board: !include 'packages/board/board_ESP32_Atom-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32_EVB.yaml'
# device_board: !include 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
device_board: !include 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_XIAO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_YBoard.yaml'
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
uart_esp_1: !include packages/board/board_options_itf_uart_esp_1.yaml
# uart_esp_2: !include packages/board/board_options_itf_uart_esp_2.yaml
# uart_esp_3: !include packages/board/board_options_itf_uart_esp_3.yaml
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
canbus_node_1: !include
file: packages/board/board_options_itf_canbus_esp32_can.yaml
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# canbus_node_2: !include
# file: packages/board/board_options_itf_canbus_mcp2515.yaml
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# shunt1: !include
# file: packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# shunt1: !include
# file: packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
# The sniffer represents the ESP node connected to the JK-BMS PB RS485 bus
# If address 0x00 is not detected on the RS485 bus, the sniffer will act directly as a master BMS (mode 2, max 15 BMS)
# sniffer1: !include
# file: packages/bms/bms_combine_JK_RS485_Modbus_sniffer_talk_pin.yaml
# vars:
# sniffer_id: 'sniffer1'
# sniffer_protocol: 'JK02_32S'
# sniffer_uart_id: 'uart_esp_1'
# sniffer_talk_pin: 8 # ESP32: 4, ESP32-S3: 8, ESP32-C3: 10
sniffer1: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_sniffer.yaml
vars:
sniffer_id: 'sniffer1'
sniffer_protocol: 'JK02_32S'
sniffer_uart_id: 'uart_esp_1'
# Mode2 : configure the DIP switches of your BMS from 0x01 to 0x0F (don't use the 0x00 address, maximum 15 BMS)
bms1: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_address: '0x01' # BMS 1 DIP switch
bms2: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_address: '0x02' # BMS 2 DIP switch
bms3: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '3' # must be a number
bms_name: 'JK-BMS 3'
bms_address: '0x03' # BMS 3 DIP switch
bms4: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '4' # must be a number
bms_name: 'JK-BMS 4'
bms_address: '0x04' # BMS 4 DIP switch
bms5: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '5' # must be a number
bms_name: 'JK-BMS 5'
bms_address: '0x05' # BMS 5 DIP switch
bms6: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '6' # must be a number
bms_name: 'JK-BMS 6'
bms_address: '0x06' # BMS 6 DIP switch
bms7: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '7' # must be a number
bms_name: 'JK-BMS 7'
bms_address: '0x07' # BMS 7 DIP switch
bms8: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '8' # must be a number
bms_name: 'JK-BMS 8'
bms_address: '0x08' # BMS 8 DIP switch
yambms: !include packages/yambms/yambms.yaml
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+208
View File
@@ -0,0 +1,208 @@
# Updated : 2025.06.12
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# Don't forget to configure your WiFi credentials in the secrets.yaml
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'pvbrain2' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | WK2168 UART expander |
# +--------------------------------------+
uart0_baudrate: '2400' #WKS {RJ45-UART0}
uart1_baudrate: '38400' #JSY193
uart2_baudrate: '19200' #SmartShunt
uart3_baudrate: '9600' #SRNE {RJ45-UART3}
uart4_baudrate: '115200' #JK-BMS 1
uart5_baudrate: '115200' #JK-BMS 2
uart6_baudrate: '115200' #Pylontech
uart7_baudrate: '9600' #EPEVER {RJ45-UART7}
# +--------------------------------------+
# | PVbrain2 packages |
# +--------------------------------------+
packages:
device_board: !include packages/board/board_ESP32-S3_DevKitC-1_PVbrain2.yaml
# BUS
# bus_i2c0: !include pvbrain2/base/device_bus_i2c0.yaml # SX1509 and BME280/BMP280
bus_spi1: !include pvbrain2/base/device_bus_spi1.yaml # MCP2515
# bus_one_wire: !include pvbrain2/base/device_bus_one_wire.yaml # Dallas
# Devices
# device_uart_esp: !include pvbrain2/base/device_uart_esp.yaml
device_wk2168_spi: !include pvbrain2/base/device_wk2168_spi.yaml
# device_wk2168_i2c: !include pvbrain2/base/device_wk2168_i2c.yaml
# device_sx1509: !include pvbrain2/base/device_sx1509.yaml
device_canbus_node1: !include pvbrain2/base/device_canbus_esp32can.yaml # canbus_node1
device_canbus_node2: !include pvbrain2/base/device_canbus_mcp2515.yaml # canbus_node2
# +--------------------------------------+
# | YamBMS packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
# You don't have to import a shunt but you must import at least one BMS.
# shunt1: !include
# file: packages/shunt/shunt_combine_Victron_SmartShunt_UART_expander.yaml # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_${uart_hub_bus}_2'
bms1: !include
file: packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_uart_id: 'uart_${uart_hub_bus}_4'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
bms2: !include
file: packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_uart_id: 'uart_${uart_hub_bus}_5'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
yambms: !include packages/yambms/yambms.yaml
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_node1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+116
View File
@@ -0,0 +1,116 @@
# Updated : 2025.06.19
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '5s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | Modbus Settings |
# +--------------------------------------+
modbus_update_interval: '5s' # frequency with which BMS/Shunt modbus servers are queried
modbus_baud_rate: '19200' # 9600 / 19200 / 11520
modbus_command_throttle: '0ms' # minimum time in between 2 requests to the device
modbus_send_wait_time: '250ms' # time in milliseconds before the next ModBUS command is sent if an answer from a previous command is pending
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############################################################
device_board: !include packages/board/board_RP2040_RPi_Pico.yaml
uart_1: !include packages/board/board_options_itf_uart_1.yaml
uart_2: !include packages/board/board_options_itf_uart_2.yaml
uart_3: !include packages/board/board_options_itf_uart_3.yaml
uart_4: !include packages/board/board_options_itf_uart_4.yaml
uart_5: !include packages/board/board_options_itf_uart_5.yaml
uart_6: !include packages/board/board_options_itf_uart_6.yaml
modbus: !include
file: packages/base/device_modbus.yaml
vars:
modbus_role: 'server' # client / server
modbus_uart_id: 'uart_1' # RS485 board
shunt1: !include
file: packages/shunt/shunt_modbus_Victron_SmartShunt_UART_minimal.yaml
vars:
shunt_id: '1'
shunt_name: 'Shunt 1'
shunt_uart_id: 'uart_2'
shunt2: !include
file: packages/shunt/shunt_modbus_Victron_SmartShunt_UART_minimal.yaml
vars:
shunt_id: '2'
shunt_name: 'Shunt 2'
shunt_uart_id: 'uart_3'
shunt3: !include
file: packages/shunt/shunt_modbus_Victron_SmartShunt_UART_minimal.yaml
vars:
shunt_id: '3'
shunt_name: 'Shunt 3'
shunt_uart_id: 'uart_4'
shunt4: !include
file: packages/shunt/shunt_modbus_Victron_SmartShunt_UART_minimal.yaml
vars:
shunt_id: '4'
shunt_name: 'Shunt 4'
shunt_uart_id: 'uart_5'
shunt5: !include
file: packages/shunt/shunt_modbus_Victron_SmartShunt_UART_minimal.yaml
vars:
shunt_id: '5'
shunt_name: 'Shunt 5'
shunt_uart_id: 'uart_6'
+205
View File
@@ -0,0 +1,205 @@
# Updated : 2025.06.12
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# Don't forget to configure your WiFi credentials in the secrets.yaml
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
#web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# ESP32 name / hostname
name: ''
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS'
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '60'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '300'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
device_board: !include packages/board/board_ESP32-S3_YBoard.yaml
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
uart_esp_1: !include packages/board/board_options_itf_uart_esp_1.yaml
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
canbus_node_1: !include
file: packages/board/board_options_itf_canbus_esp32_can.yaml
vars:
canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
shunt1: !include
file: packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml
vars:
shunt_id: '1' # must be a number
shunt_name: 'Shunt'
shunt_mac_address: 'c0960b5d8cba'
shunt_encryption_key: '1e196f635d4e5b0777afa79b47904937'
sniffer1: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_sniffer.yaml
vars:
sniffer_id: 'sniffer1'
sniffer_protocol: 'JK02_32S'
sniffer_uart_id: 'uart_esp_1'
# Mode2 : configure the DIP switches of your BMS from 0x01 to 0x0F (don't use the 0x00 address, maximum 15 BMS)
bms1: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_address: '0x01' # BMS 1 DIP switch
bms2: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_address: '0x02' # BMS 2 DIP switch
yambms: !include packages/yambms/yambms.yaml
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+240
View File
@@ -0,0 +1,240 @@
# Updated : 2025.06.12
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Local Packages Version #########################
# You need to copy the `packages` folder into the same folder as this YAML in order to compile it.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# Don't forget to configure your WiFi credentials in the secrets.yaml
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
# This list is incomplete, other board.yaml are available in the board folder
device_board: !include 'packages/board/board_ESP32_Generic.yaml'
# device_board: !include 'packages/board/board_ESP32_DevKit-V1.yaml'
# device_board: !include 'packages/board/board_ESP32_Atom-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32_EVB.yaml'
# device_board: !include 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# device_board: !include 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_XIAO.yaml'
# device_board: !include 'packages/board/board_ESP32-S3_YBoard.yaml'
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# device_board: !include
# file: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
uart_esp_1: !include packages/board/board_options_itf_uart_esp_1.yaml
uart_esp_2: !include packages/board/board_options_itf_uart_esp_2.yaml
uart_esp_3: !include packages/board/board_options_itf_uart_esp_3.yaml
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
canbus_node_1: !include
file: packages/board/board_options_itf_canbus_esp32_can.yaml
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# canbus_node_2: !include
# file: packages/board/board_options_itf_canbus_mcp2515.yaml
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# shunt1: !include
# file: packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# shunt1: !include
# file: packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms1: !include
file: packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_uart_id: 'uart_esp_1'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
bms2: !include
file: packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_uart_id: 'uart_esp_2'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
yambms: !include packages/yambms/yambms.yaml
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+286
View File
@@ -0,0 +1,286 @@
# Updated : 2025.06.17
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
board:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# - path: 'packages/board/board_ESP32_Generic.yaml'
# - path: 'packages/board/board_ESP32_DevKit-V1.yaml'
# - path: 'packages/board/board_ESP32_Atom-Lite.yaml'
# - path: 'packages/board/board_ESP32_EVB.yaml'
- path: 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# - path: 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# - path: 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# - path: 'packages/board/board_ESP32-S3_XIAO.yaml'
# - path: 'packages/board/board_ESP32-S3_YBoard.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# - path: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# LilyGo T-Connect Pro
# Importing the display also activates PSRAM.
# Also note that the display update takes about 120 ms, as indicated in the logs:
# "Component display took a long time for an operation (124 ms)."
# Board
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect-Pro.yaml'
# Display
# - path: 'packages/board/board_options_display_480x222.yaml'
# vars:
# display_auto_next_page_interval: '5s'
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
board_options:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# UART 1
- path: 'packages/board/board_options_itf_uart_esp_1.yaml'
# UART 2
# - path: 'packages/board/board_options_itf_uart_esp_2.yaml'
# UART 3
# - path: 'packages/board/board_options_itf_uart_esp_3.yaml'
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
- path: 'packages/board/board_options_itf_canbus_esp32_can.yaml'
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# - path: 'packages/board/board_options_itf_canbus_mcp2515.yaml'
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# UART Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml' # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# BLE Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml'
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# Basen controller
- path: packages/bms/bms_combine_BASEN_RS485_controller.yaml
vars:
basen_uart_id: 'uart_esp_1'
basen_uart_baud_rate: '9600'
basen_controller_id: "basen_controller_1"
# Basen module 1
- path: packages/bms/bms_combine_BASEN_RS485_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'BASEN-BMS 1'
bms_address: '0x01'
# Basen module 2
- path: packages/bms/bms_combine_BASEN_RS485_full.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'BASEN-BMS 2'
bms_address: '0x02'
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+338
View File
@@ -0,0 +1,338 @@
# Updated : 2025.06.14
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS Demo' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
board:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/board/board_ESP32_Generic.yaml'
# - path: 'packages/board/board_ESP32_DevKit-V1.yaml'
# - path: 'packages/board/board_ESP32_Atom-Lite.yaml'
# - path: 'packages/board/board_ESP32_EVB.yaml'
# - path: 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# - path: 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# - path: 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# - path: 'packages/board/board_ESP32-S3_XIAO.yaml'
# - path: 'packages/board/board_ESP32-S3_YBoard.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# - path: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# LilyGo T-Connect Pro
# Importing the display also activates PSRAM.
# Also note that the display update takes about 120 ms, as indicated in the logs:
# "Component display took a long time for an operation (124 ms)."
# Board
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect-Pro.yaml'
# Display
# - path: 'packages/board/board_options_display_480x222.yaml'
# vars:
# display_auto_next_page_interval: '5s'
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
board_options:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# Captive Portal
- path: 'packages/board/board_options_captive_portal.yaml'
# UART 1
# - path: 'packages/board/board_options_itf_uart_esp_1.yaml'
# UART 2
# - path: 'packages/board/board_options_itf_uart_esp_2.yaml'
# UART 3
# - path: 'packages/board/board_options_itf_uart_esp_3.yaml'
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
- path: 'packages/board/board_options_itf_canbus_esp32_can.yaml'
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# - path: 'packages/board/board_options_itf_canbus_mcp2515.yaml'
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
shunt:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# Shunt 1
- path: 'packages/shunt/shunt_combine_FAKE.yaml'
vars:
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
# Shunt sensors values
shunt_voltage: '53.41' # V
shunt_current: '37.5' # A
shunt_power: '2003' # W
shunt_soc: '86' # %
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# BMS 1
- path: 'packages/bms/bms_combine_FAKE.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '243' # Ah
bms_voltage: '53.45' # V
bms_current: '9.2' # A
bms_power: '492' # W
bms_soc: '87' # %
bms_soh: '98' # %
bms_min_cell_voltage: '3.339' # V
bms_min_voltage_cell: '2' # cell number 1~16
bms_max_cell_voltage: '3.341' # V
bms_max_voltage_cell: '11' # cell number 1~16
bms_temperature_sensor_1: '21.1' # °C
bms_temperature_sensor_2: '21.3' # °C
bms_temperature_sensor_3: '21.5' # °C
bms_temperature_sensor_4: '21.7' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '178' # charging cycles number Used to calculate the SoH
# BMS 2
- path: 'packages/bms/bms_combine_FAKE.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '238' # Ah
bms_voltage: '53.41' # V
bms_current: '11.3' # A
bms_power: '604' # W
bms_soc: '85' # %
bms_soh: '89' # %
bms_min_cell_voltage: '3.337' # V
bms_min_voltage_cell: '14' # cell number 1~16
bms_max_cell_voltage: '3.339' # V
bms_max_voltage_cell: '3' # cell number 1~16
bms_temperature_sensor_1: '21.8' # °C
bms_temperature_sensor_2: '21.6' # °C
bms_temperature_sensor_3: '21.4' # °C
bms_temperature_sensor_4: '21.2' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '226' # charging cycles number Used to calculate the SoH
# BMS 3
- path: 'packages/bms/bms_combine_FAKE.yaml'
vars:
bms_id: '3' # must be a number
bms_name: 'BMS 3'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '232' # Ah
bms_voltage: '53.37' # V
bms_current: '15.7' # A
bms_power: '838' # W
bms_soc: '83' # %
bms_soh: '79' # %
bms_min_cell_voltage: '3.334' # V
bms_min_voltage_cell: '7' # cell number 1~16
bms_max_cell_voltage: '3.336' # V
bms_max_voltage_cell: '9' # cell number 1~16
bms_temperature_sensor_1: '21.9' # °C
bms_temperature_sensor_2: '22.0' # °C
bms_temperature_sensor_3: '22.1' # °C
bms_temperature_sensor_4: '22.2' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '194' # charging cycles number Used to calculate the SoH
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+303
View File
@@ -0,0 +1,303 @@
# Updated : 2025.06.16
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
board:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/board/board_ESP32_Generic.yaml'
# - path: 'packages/board/board_ESP32_DevKit-V1.yaml'
# - path: 'packages/board/board_ESP32_Atom-Lite.yaml'
# - path: 'packages/board/board_ESP32_EVB.yaml'
# - path: 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# - path: 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# - path: 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# - path: 'packages/board/board_ESP32-S3_XIAO.yaml'
# - path: 'packages/board/board_ESP32-S3_YBoard.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# - path: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# LilyGo T-Connect Pro
# Importing the display also activates PSRAM.
# Also note that the display update takes about 120 ms, as indicated in the logs:
# "Component display took a long time for an operation (124 ms)."
# Board
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect-Pro.yaml'
# Display
# - path: 'packages/board/board_options_display_480x222.yaml'
# vars:
# display_auto_next_page_interval: '5s'
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
board_options:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# UART 1
- path: 'packages/board/board_options_itf_uart_esp_1.yaml'
# UART 2
# - path: 'packages/board/board_options_itf_uart_esp_2.yaml'
# UART 3
# - path: 'packages/board/board_options_itf_uart_esp_3.yaml'
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
- path: 'packages/board/board_options_itf_canbus_esp32_can.yaml'
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# - path: 'packages/board/board_options_itf_canbus_mcp2515.yaml'
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# UART Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml' # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# BLE Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml'
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# BMS 1
- path: 'packages/bms/bms_combine_JBD_UART_full.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_uart_id: 'uart_esp_1'
bms_rx_timeout: '150ms'
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# BMS 2
- path: 'packages/bms/bms_combine_JBD_BLE_full.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_ble_mac_address: 'C8:47:8C:10:7E:AA' # Your MAC address
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+346
View File
@@ -0,0 +1,346 @@
# Updated : 2025.06.14
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
board:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# - path: 'packages/board/board_ESP32_Generic.yaml'
# - path: 'packages/board/board_ESP32_DevKit-V1.yaml'
# - path: 'packages/board/board_ESP32_Atom-Lite.yaml'
# - path: 'packages/board/board_ESP32_EVB.yaml'
# - path: 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# - path: 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# - path: 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
- path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# - path: 'packages/board/board_ESP32-S3_XIAO.yaml'
# - path: 'packages/board/board_ESP32-S3_YBoard.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# - path: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# LilyGo T-Connect Pro
# Importing the display also activates PSRAM.
# Also note that the display update takes about 120 ms, as indicated in the logs:
# "Component display took a long time for an operation (124 ms)."
# Board
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect-Pro.yaml'
# Display
# - path: 'packages/board/board_options_display_480x222.yaml'
# vars:
# display_auto_next_page_interval: '5s'
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
board_options:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# UART 1
- path: 'packages/board/board_options_itf_uart_esp_1.yaml'
# UART 2
# - path: 'packages/board/board_options_itf_uart_esp_2.yaml'
# UART 3
# - path: 'packages/board/board_options_itf_uart_esp_3.yaml'
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
- path: 'packages/board/board_options_itf_canbus_esp32_can.yaml'
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# - path: 'packages/board/board_options_itf_canbus_mcp2515.yaml'
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# UART Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml' # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# BLE Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml'
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# RS485 Sniffer
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_sniffer.yaml'
vars:
sniffer_id: 'sniffer1'
sniffer_protocol: 'JK02_32S'
sniffer_uart_id: 'uart_esp_1'
# BMS 1
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_JK-B_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_address: '0x01' # BMS 1 ( JK app `Device Addr.` setting )
# BMS 2
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_JK-B_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_address: '0x02' # BMS 2 ( JK app `Device Addr.` setting )
# BMS 3
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_JK-B_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '3' # must be a number
bms_name: 'JK-BMS 3'
bms_address: '0x03' # BMS 3 ( JK app `Device Addr.` setting )
# BMS 4
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_JK-B_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '4' # must be a number
bms_name: 'JK-BMS 4'
bms_address: '0x04' # BMS 4 ( JK app `Device Addr.` setting )
# BMS 5
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_JK-B_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '5' # must be a number
bms_name: 'JK-BMS 5'
bms_address: '0x05' # BMS 5 ( JK app `Device Addr.` setting )
# BMS 6
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_JK-B_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '6' # must be a number
bms_name: 'JK-BMS 6'
bms_address: '0x06' # BMS 6 ( JK app `Device Addr.` setting )
# BMS 7
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_JK-B_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '7' # must be a number
bms_name: 'JK-BMS 7'
bms_address: '0x07' # BMS 7 ( JK app `Device Addr.` setting )
# BMS 8
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_JK-B_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '8' # must be a number
bms_name: 'JK-BMS 8'
bms_address: '0x08' # BMS 8 ( JK app `Device Addr.` setting )
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+346
View File
@@ -0,0 +1,346 @@
# Updated : 2025.06.14
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
board:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# - path: 'packages/board/board_ESP32_Generic.yaml'
# - path: 'packages/board/board_ESP32_DevKit-V1.yaml'
# - path: 'packages/board/board_ESP32_Atom-Lite.yaml'
# - path: 'packages/board/board_ESP32_EVB.yaml'
# - path: 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# - path: 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# - path: 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
- path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# - path: 'packages/board/board_ESP32-S3_XIAO.yaml'
# - path: 'packages/board/board_ESP32-S3_YBoard.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# - path: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# LilyGo T-Connect Pro
# Importing the display also activates PSRAM.
# Also note that the display update takes about 120 ms, as indicated in the logs:
# "Component display took a long time for an operation (124 ms)."
# Board
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect-Pro.yaml'
# Display
# - path: 'packages/board/board_options_display_480x222.yaml'
# vars:
# display_auto_next_page_interval: '5s'
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
board_options:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# UART 1
- path: 'packages/board/board_options_itf_uart_esp_1.yaml'
# UART 2
# - path: 'packages/board/board_options_itf_uart_esp_2.yaml'
# UART 3
# - path: 'packages/board/board_options_itf_uart_esp_3.yaml'
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
- path: 'packages/board/board_options_itf_canbus_esp32_can.yaml'
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# - path: 'packages/board/board_options_itf_canbus_mcp2515.yaml'
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# UART Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml' # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# BLE Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml'
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# RS485 Sniffer
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_sniffer.yaml'
vars:
sniffer_id: 'sniffer1'
sniffer_protocol: 'JK02_32S'
sniffer_uart_id: 'uart_esp_1'
# BMS 1
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_address: '0x01' # BMS 1 DIP switch
# BMS 2
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_address: '0x02' # BMS 2 DIP switch
# BMS 3
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '3' # must be a number
bms_name: 'JK-BMS 3'
bms_address: '0x03' # BMS 3 DIP switch
# BMS 4
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '4' # must be a number
bms_name: 'JK-BMS 4'
bms_address: '0x04' # BMS 4 DIP switch
# BMS 5
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '5' # must be a number
bms_name: 'JK-BMS 5'
bms_address: '0x05' # BMS 5 DIP switch
# BMS 6
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '6' # must be a number
bms_name: 'JK-BMS 6'
bms_address: '0x06' # BMS 6 DIP switch
# BMS 7
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '7' # must be a number
bms_name: 'JK-BMS 7'
bms_address: '0x07' # BMS 7 DIP switch
# BMS 8
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '8' # must be a number
bms_name: 'JK-BMS 8'
bms_address: '0x08' # BMS 8 DIP switch
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+302
View File
@@ -0,0 +1,302 @@
# Updated : 2025.06.14
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
board:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/board/board_ESP32_Generic.yaml'
# - path: 'packages/board/board_ESP32_DevKit-V1.yaml'
# - path: 'packages/board/board_ESP32_Atom-Lite.yaml'
# - path: 'packages/board/board_ESP32_EVB.yaml'
# - path: 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# - path: 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# - path: 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# - path: 'packages/board/board_ESP32-S3_XIAO.yaml'
# - path: 'packages/board/board_ESP32-S3_YBoard.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# - path: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# LilyGo T-Connect Pro
# Importing the display also activates PSRAM.
# Also note that the display update takes about 120 ms, as indicated in the logs:
# "Component display took a long time for an operation (124 ms)."
# Board
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect-Pro.yaml'
# Display
# - path: 'packages/board/board_options_display_480x222.yaml'
# vars:
# display_auto_next_page_interval: '5s'
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
board_options:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# UART 1
# - path: 'packages/board/board_options_itf_uart_esp_1.yaml'
# UART 2
# - path: 'packages/board/board_options_itf_uart_esp_2.yaml'
# UART 3
# - path: 'packages/board/board_options_itf_uart_esp_3.yaml'
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
- path: 'packages/board/board_options_itf_canbus_esp32_can.yaml'
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# - path: 'packages/board/board_options_itf_canbus_mcp2515.yaml'
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# UART Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml' # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_1'
# BLE Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml'
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# BMS 1
- path: 'packages/bms/bms_combine_JK_BLE_standard.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_ble_protocol_version: 'JK02_32S' # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: 'C8:47:8C:10:7E:AA'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# BMS 2
- path: 'packages/bms/bms_combine_JK_BLE_standard.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_ble_protocol_version: 'JK02_32S' # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: 'C8:47:8C:EE:16:EA'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# bms_options:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # BMS 1
# - path: 'packages/bms/bms_options_charging_logic.yaml'
# vars:
# bms_id: '1' # must be a number
# # BMS 2
# - path: 'packages/bms/bms_options_charging_logic.yaml'
# vars:
# bms_id: '2' # must be a number
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+234
View File
@@ -0,0 +1,234 @@
# Updated : 2025.06.12
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'pvbrain2' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | WK2168 UART expander |
# +--------------------------------------+
uart0_baudrate: '2400' #WKS {RJ45-UART0}
uart1_baudrate: '38400' #JSY193
uart2_baudrate: '19200' #SmartShunt
uart3_baudrate: '9600' #SRNE {RJ45-UART3}
uart4_baudrate: '115200' #JK-BMS 1
uart5_baudrate: '115200' #JK-BMS 2
uart6_baudrate: '115200' #Pylontech
uart7_baudrate: '9600' #EPEVER {RJ45-UART7}
# +--------------------------------------+
# | PVbrain2 packages |
# +--------------------------------------+
packages:
pvbrain2:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/board/board_ESP32-S3_DevKitC-1_PVbrain2.yaml'
# BUS
# - path: 'pvbrain2/base/device_bus_i2c0.yaml' # SX1509 and BME280/BMP280
- path: 'pvbrain2/base/device_bus_spi1.yaml' # MCP2515
- path: 'pvbrain2/base/device_bus_one_wire.yaml' # Dallas
# Devices
# - path: 'pvbrain2/base/device_uart_esp.yaml'
- path: 'pvbrain2/base/device_wk2168_spi.yaml'
# - path: 'pvbrain2/base/device_wk2168_i2c.yaml'
# - path: 'pvbrain2/base/device_sx1509.yaml'
- path: 'pvbrain2/base/device_canbus_esp32can.yaml' # canbus_node1
- path: 'pvbrain2/base/device_canbus_mcp2515.yaml' # canbus_node2
# +--------------------------------------+
# | YamBMS packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_UART_expander.yaml' # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_${uart_hub_bus}_2'
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# BMS 1
- path: 'packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_uart_id: 'uart_${uart_hub_bus}_4'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# BMS 2
- path: 'packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_uart_id: 'uart_${uart_hub_bus}_5'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_node1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+312
View File
@@ -0,0 +1,312 @@
# Updated : 2025.06.16
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
board:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/board/board_ESP32_Generic.yaml'
# - path: 'packages/board/board_ESP32_DevKit-V1.yaml'
# - path: 'packages/board/board_ESP32_Atom-Lite.yaml'
# - path: 'packages/board/board_ESP32_EVB.yaml'
# - path: 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# - path: 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# - path: 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# - path: 'packages/board/board_ESP32-S3_XIAO.yaml'
# - path: 'packages/board/board_ESP32-S3_YBoard.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# - path: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# LilyGo T-Connect Pro
# Importing the display also activates PSRAM.
# Also note that the display update takes about 120 ms, as indicated in the logs:
# "Component display took a long time for an operation (124 ms)."
# Board
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect-Pro.yaml'
# Display
# - path: 'packages/board/board_options_display_480x222.yaml'
# vars:
# display_auto_next_page_interval: '5s'
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
board_options:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# UART 1
- path: 'packages/board/board_options_itf_uart_esp_1.yaml'
# UART 2
# - path: 'packages/board/board_options_itf_uart_esp_2.yaml'
# UART 3
# - path: 'packages/board/board_options_itf_uart_esp_3.yaml'
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
- path: 'packages/board/board_options_itf_canbus_esp32_can.yaml'
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# - path: 'packages/board/board_options_itf_canbus_mcp2515.yaml'
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# UART Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml' # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# BLE Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml'
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# Seplos Modbus 1
- path: 'packages/bms/bms_combine_SEPLOS_V1_V2_RS485_modbus.yaml'
vars:
seplos_modbus_id: 'seplos_modbus1'
seplos_modbus_uart_id: 'uart_esp_1'
seplos_modbus_baud_rate: '9600' # 9600 / 19200 ; please set the baudrate of your Seplos BMS model here
seplos_modbus_rx_timeout: '150ms'
# BMS 1
- path: 'packages/bms/bms_combine_SEPLOS_V1_V2_RS485_bms_full.yaml'
vars:
# Seplos modbus ID
seplos_modbus_id: 'seplos_modbus1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_address: '0x01' # BMS 1 DIP switch
bms_protocol_version: '0x20' # Known protocol versions: 0x20 (Seplos), 0x26 (Boqiang)
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# BMS 2
- path: 'packages/bms/bms_combine_SEPLOS_V1_V2_RS485_bms_full.yaml'
vars:
# Seplos modbus ID
seplos_modbus_id: 'seplos_modbus1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_address: '0x02' # BMS 2 DIP switch
bms_protocol_version: '0x20' # Known protocol versions: 0x20 (Seplos), 0x26 (Boqiang)
bms_uart_id: uart_esp_2
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
+300
View File
@@ -0,0 +1,300 @@
# Updated : 2025.06.14
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
######################## YamBMS Remote Packages Version ########################
# You can compile this YAML directly without the `packages` folder.
# The packages will be automatically downloaded from GitHub.
# Don't forget to configure your WiFi credentials in the secrets.yaml
################################################################################
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: INFO # VERBOSE / DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
# web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Global Settings |
# +--------------------------------------+
substitutions:
# Name
name: '' # Name that can be added as a second prefix after the friendly name, you can leave it blank.
hostname: 'yambms' # This is the name of the node. It should always be unique in your ESPHome network.
friendly_name : 'YamBMS' # Prefix added in front of all entity names and also to classify them.
# +--------------------------------------+
# | YamBMS Settings |
# +--------------------------------------+
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# +--------------------------------------+
# | Shunt Settings |
# +--------------------------------------+
shunt_update_interval: '3s' # frequency at which Shunt data is refreshed
shunt_combine_interval: '1s' # frequency at which Shunt data is combined in YamBMS
# +--------------------------------------+
# | BMS Settings |
# +--------------------------------------+
bms_update_interval: '3s' # frequency at which BMS data is refreshed, going below '3s' can cause problems
bms_combine_interval: '1s' # frequency at which BMS data is combined in YamBMS
bms_cutoff_timer: '50s' # time during which the end of charge conditions must be respected (cut-off + cells not equalizing)
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
################ >>> CONFIG & CUSTOM LP <<< ################
# Local Packages intended for creating custom codes
# or sharing settings between several main.yaml
# yambms_config: !include yambms_config.yaml
# yambms_custom: !include yambms_custom.yaml
############### >>> UNCOMMENT YOUR BOARD <<< ###############
############### >>> ONLY ONE BOARD ! <<< ###############
board:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/board/board_ESP32_Generic.yaml'
# - path: 'packages/board/board_ESP32_DevKit-V1.yaml'
# - path: 'packages/board/board_ESP32_Atom-Lite.yaml'
# - path: 'packages/board/board_ESP32_EVB.yaml'
# - path: 'packages/board/board_ESP32_LilyGo-T-CAN485.yaml'
# - path: 'packages/board/board_ESP32-C3_DevKitM-1.yaml'
# - path: 'packages/board/board_ESP32-C3_ETH01-EVO.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3-Lite.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-38.yaml'
# - path: 'packages/board/board_ESP32-S3_DevKitC-1_LED-48.yaml'
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-4.3.yaml'
# - path: 'packages/board/board_ESP32-S3_Touch-LCD-7.yaml'
# - path: 'packages/board/board_ESP32-S3_XIAO.yaml'
# - path: 'packages/board/board_ESP32-S3_YBoard.yaml'
# - path: 'packages/board/board_ESP32-S3_AtomS3.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# - path: 'packages/board/board_ESP32-S3_AtomS3R.yaml'
# vars:
# display_auto_next_page_interval: '5s'
# display_rotation: '0' # 0/90/180/270 rotation angle in degrees
# LilyGo T-Connect Pro
# Importing the display also activates PSRAM.
# Also note that the display update takes about 120 ms, as indicated in the logs:
# "Component display took a long time for an operation (124 ms)."
# Board
# - path: 'packages/board/board_ESP32-S3_LilyGo-T-Connect-Pro.yaml'
# Display
# - path: 'packages/board/board_options_display_480x222.yaml'
# vars:
# display_auto_next_page_interval: '5s'
########### >>> UNCOMMENT YOUR BOARD OPTIONS <<< ###########
board_options:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# UART 1
- path: 'packages/board/board_options_itf_uart_esp_1.yaml'
# UART 2
- path: 'packages/board/board_options_itf_uart_esp_2.yaml'
# UART 3
- path: 'packages/board/board_options_itf_uart_esp_3.yaml'
# ESP32_CAN (TJA105x, SN65HVD230, M5Stack CAN base/unit)
- path: 'packages/board/board_options_itf_canbus_esp32_can.yaml'
vars:
canbus_node_id: 'canbus_inverter_1'
# MCP2515
# - path: 'packages/board/board_options_itf_canbus_mcp2515.yaml'
# vars:
# canbus_node_id: 'canbus_inverter_1'
############################################################
# You don't have to import a shunt but you must import at least one BMS.
# UART Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml' # shunt_combine_Junctek_KHF_UART.yaml
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_uart_id: 'uart_esp_3'
# BLE Shunt
# shunt:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # Shunt 1
# - path: 'packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml'
# vars:
# shunt_id: '1' # must be a number
# shunt_name: 'Shunt 1'
# shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
# shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# BMS 1
- path: 'packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_uart_id: 'uart_esp_1'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# BMS 2
- path: 'packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_uart_id: 'uart_esp_2'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# bms_options:
# url: https://github.com/Sleeper85/esphome-yambms
# ref: main
# refresh: 0s
# files:
# # BMS 1
# - path: 'packages/bms/bms_options_charging_logic.yaml'
# vars:
# bms_id: '1' # must be a number
# # BMS 2
# - path: 'packages/bms/bms_options_charging_logic.yaml'
# vars:
# bms_id: '2' # must be a number
yambms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms.yaml'
canbus:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: 'packages/yambms/yambms_canbus.yaml'
vars:
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (0x305 frame) for 5s
# The Deye inverter sends the ACK 0x305 only when it receives the 0x356 frame.
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
debug:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
- path: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
@@ -0,0 +1,63 @@
# Updated : 2025.04.01
# Version : 1.5.5
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Local Packages Example ############################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
bms1: !include
file: packages/bms/bms_combine_JBD_UART_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_uart_id: 'uart_esp_1'
bms_rx_timeout: '150ms'
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
bms2: !include
file: packages/bms/bms_combine_JBD_BLE_full.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_ble_mac_address: 'C8:47:8C:10:7E:AA' # Your MAC address
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,48 @@
# Updated : 2025.04.01
# Version : 1.5.5
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Local Packages Example ############################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
bms1: !include
file: packages/bms/bms_combine_JK_BLE_standard.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_ble_protocol_version: 'JK02_32S' # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: 'C8:47:8C:10:7E:AA'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
bms2: !include
file: packages/bms/bms_combine_JK_BLE_standard.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_ble_protocol_version: 'JK02_32S' # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: 'C8:47:8C:EE:16:EA'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,125 @@
# Updated : 2025.06.10
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Local Packages Example ############################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
# The sniffer represents the ESP node connected to the JK-BMS PB RS485 bus
# If address 0x00 is not detected on the RS485 bus, the sniffer will act directly as a master BMS (mode 2, max 15 BMS)
# sniffer1: !include
# file: packages/bms/bms_combine_JK_RS485_Modbus_sniffer_talk_pin.yaml
# vars:
# sniffer_id: 'sniffer1'
# sniffer_protocol: 'JK02_32S'
# sniffer_uart_id: 'uart_esp_1'
# sniffer_talk_pin: 8 # ESP32: 4, ESP32-S3: 8, ESP32-C3: 10
sniffer1: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_sniffer.yaml
vars:
sniffer_id: 'sniffer1'
sniffer_protocol: 'JK02_32S'
sniffer_uart_id: 'uart_esp_1'
# Mode2 : configure the DIP switches of your BMS from 0x01 to 0x0F (don't use the 0x00 address, maximum 15 BMS)
bms1: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_address: '0x01' # BMS 1 DIP switch
bms2: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_address: '0x02' # BMS 2 DIP switch
bms3: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '3' # must be a number
bms_name: 'JK-BMS 3'
bms_address: '0x03' # BMS 3 DIP switch
bms4: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '4' # must be a number
bms_name: 'JK-BMS 4'
bms_address: '0x04' # BMS 4 DIP switch
bms5: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '5' # must be a number
bms_name: 'JK-BMS 5'
bms_address: '0x05' # BMS 5 DIP switch
bms6: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '6' # must be a number
bms_name: 'JK-BMS 6'
bms_address: '0x06' # BMS 6 DIP switch
bms7: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '7' # must be a number
bms_name: 'JK-BMS 7'
bms_address: '0x07' # BMS 7 DIP switch
bms8: !include
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '8' # must be a number
bms_name: 'JK-BMS 8'
bms_address: '0x08' # BMS 8 DIP switch
@@ -0,0 +1,46 @@
# Updated : 2025.04.01
# Version : 1.5.5
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Local Packages Example ############################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
bms1: !include
file: packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_uart_id: 'uart_esp_1'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
bms2: !include
file: packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_uart_id: 'uart_esp_2'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,73 @@
# Updated : 2025.06.10
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Local Packages Example ############################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
seplos_modbus1: !include
file: packages/bms/bms_combine_SEPLOS_V1_V2_RS485_modbus.yaml
vars:
seplos_modbus_id: 'seplos_modbus1'
seplos_modbus_uart_id: 'uart_esp_1'
seplos_modbus_baud_rate: '9600' # 9600 / 19200 ; please set the baudrate of your Seplos BMS model here
seplos_modbus_rx_timeout: '150ms'
bms1: !include
file: packages/bms/bms_combine_SEPLOS_V1_V2_RS485_bms_full.yaml
vars:
# Seplos modbus ID
seplos_modbus_id: 'seplos_modbus1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_address: '0x01' # BMS 1 DIP switch
bms_protocol_version: '0x20' # Known protocol versions: 0x20 (Seplos), 0x26 (Boqiang)
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
bms2: !include
file: packages/bms/bms_combine_SEPLOS_V1_V2_RS485_bms_full.yaml
vars:
# Seplos modbus ID
seplos_modbus_id: 'seplos_modbus1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_address: '0x02' # BMS 2 DIP switch
bms_protocol_version: '0x20' # Known protocol versions: 0x20 (Seplos), 0x26 (Boqiang)
bms_uart_id: uart_esp_2
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
@@ -0,0 +1,104 @@
# Updated : 2025.06.10
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Local Packages Example ############################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
substitutions:
modbus_update_interval: '5s' # frequency with which BMS/Shunt modbus servers are queried
modbus_baud_rate: '19200' # 9600 / 19200 / 115200
modbus_command_throttle: '0ms' # minimum time in between 2 requests to the device
modbus_send_wait_time: '250ms' # time in milliseconds before the next ModBUS command is sent if an answer from a previous command is pending
packages:
modbus: !include
file: packages/base/device_modbus.yaml
vars:
modbus_role: 'client' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
shunt1: !include
file: packages/shunt/shunt_combine_modbus_client.yaml
vars:
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
bms1: !include
file: packages/bms/bms_combine_modbus_client.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms2: !include
file: packages/bms/bms_combine_modbus_client.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms3: !include
file: packages/bms/bms_combine_modbus_client.yaml
vars:
bms_id: '3' # must be a number
bms_name: 'BMS 3'
# bms4: !include
# file: packages/bms/bms_combine_modbus_client.yaml
# vars:
# bms_id: '4' # must be a number
# bms_name: 'BMS 4'
# bms5: !include
# file: packages/bms/bms_combine_modbus_client.yaml
# vars:
# bms_id: '5' # must be a number
# bms_name: 'BMS 5'
# bms6: !include
# file: packages/bms/bms_combine_modbus_client.yaml
# vars:
# bms_id: '6' # must be a number
# bms_name: 'BMS 6'
# bms7: !include
# file: packages/bms/bms_combine_modbus_client.yaml
# vars:
# bms_id: '7' # must be a number
# bms_name: 'BMS 7'
# bms8: !include
# file: packages/bms/bms_combine_modbus_client.yaml
# vars:
# bms_id: '8' # must be a number
# bms_name: 'BMS 8'
# bms9: !include
# file: packages/bms/bms_combine_modbus_client.yaml
# vars:
# bms_id: '9' # must be a number
# bms_name: 'BMS 9'
# bms10: !include
# file: packages/bms/bms_combine_modbus_client.yaml
# vars:
# bms_id: '10' # must be a number
# bms_name: 'BMS 10'
@@ -0,0 +1,55 @@
# Updated : 2025.06.10
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Local Packages Example ############################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
substitutions:
modbus_update_interval: '5s' # frequency with which BMS/Shunt modbus servers are queried
modbus_baud_rate: '19200' # 9600 / 19200 / 115200
modbus_command_throttle: '0ms' # minimum time in between 2 requests to the device
modbus_send_wait_time: '250ms' # time in milliseconds before the next ModBUS command is sent if an answer from a previous command is pending
packages:
modbus: !include
file: packages/base/device_modbus.yaml
vars:
modbus_role: 'server' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
shunt1: !include
file: packages/shunt/shunt_modbus_Victron_SmartShunt_UART.yaml
vars:
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
shunt_uart_id: 'uart_esp_2'
bms1: !include
file: packages/bms/bms_modbus_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_uart_id: 'uart_esp_3'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,60 @@
# Updated : 2025.06.10
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Local Packages Example ############################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
substitutions:
modbus_update_interval: '5s' # frequency with which BMS/Shunt modbus servers are queried
modbus_baud_rate: '19200' # 9600 / 19200 / 115200
modbus_command_throttle: '0ms' # minimum time in between 2 requests to the device
modbus_send_wait_time: '250ms' # time in milliseconds before the next ModBUS command is sent if an answer from a previous command is pending
packages:
modbus: !include
file: packages/base/device_modbus.yaml
vars:
modbus_role: 'server' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
bms2: !include
file: packages/bms/bms_modbus_JK_BLE_standard.yaml
vars:
bms_id: '2' # must be a number, also represents the modbus server number !
bms_name: 'JK-BMS 2'
bms_ble_protocol_version: JK02_32S # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: C8:47:8C:10:7E:AA
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
bms3: !include
file: packages/bms/bms_modbus_JK_BLE_standard.yaml
vars:
bms_id: '3' # must be a number, also represents the modbus server number !
bms_name: 'JK-BMS 3'
bms_ble_protocol_version: JK02_32S # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: C8:47:8C:EE:16:EA
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,67 @@
# Updated : 2025.04.01
# Version : 1.5.5
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Remote Packages Example ###########################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# BMS 1
- path: 'packages/bms/bms_combine_JBD_UART_full.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_uart_id: 'uart_esp_1'
bms_rx_timeout: '150ms'
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# BMS 2
- path: 'packages/bms/bms_combine_JBD_BLE_full.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_ble_mac_address: 'C8:47:8C:10:7E:AA' # Your MAC address
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,52 @@
# Updated : 2025.04.01
# Version : 1.5.5
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Remote Packages Example ###########################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# BMS 1
- path: 'packages/bms/bms_combine_JK_BLE_standard.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_ble_protocol_version: 'JK02_32S' # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: 'C8:47:8C:10:7E:AA'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# BMS 2
- path: 'packages/bms/bms_combine_JK_BLE_standard.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_ble_protocol_version: 'JK02_32S' # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: 'C8:47:8C:EE:16:EA'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,113 @@
# Updated : 2025.04.01
# Version : 1.5.5
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Remote Packages Example ###########################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
# The sniffer represents the ESP node connected to the JK-BMS PB RS485 bus
# If address 0x00 is not detected on the RS485 bus, the sniffer will act directly as a master BMS (mode 2, max 15 BMS)
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# RS485 Sniffer
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_sniffer.yaml'
vars:
sniffer_id: 'sniffer1'
sniffer_protocol: 'JK02_32S'
sniffer_uart_id: 'uart_esp_1'
# BMS 1
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_address: '0x01' # BMS 1 DIP switch
# BMS 2
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_address: '0x02' # BMS 2 DIP switch
# BMS 3
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '3' # must be a number
bms_name: 'JK-BMS 3'
bms_address: '0x03' # BMS 3 DIP switch
# BMS 4
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '4' # must be a number
bms_name: 'JK-BMS 4'
bms_address: '0x04' # BMS 4 DIP switch
# BMS 5
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '5' # must be a number
bms_name: 'JK-BMS 5'
bms_address: '0x05' # BMS 5 DIP switch
# BMS 6
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '6' # must be a number
bms_name: 'JK-BMS 6'
bms_address: '0x06' # BMS 6 DIP switch
# BMS 7
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '7' # must be a number
bms_name: 'JK-BMS 7'
bms_address: '0x07' # BMS 7 DIP switch
# BMS 8
- path: 'packages/bms/bms_combine_JK_RS485_Modbus_bms_standard.yaml'
vars:
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '8' # must be a number
bms_name: 'JK-BMS 8'
bms_address: '0x08' # BMS 8 DIP switch
@@ -0,0 +1,50 @@
# Updated : 2025.04.01
# Version : 1.5.5
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Remote Packages Example ###########################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# BMS 1
- path: 'packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_uart_id: 'uart_esp_1'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# BMS 2
- path: 'packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'JK-BMS 2'
bms_uart_id: 'uart_esp_2'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,76 @@
# Updated : 2025.04.01
# Version : 1.5.5
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Remote Packages Example ###########################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
packages:
bms:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# Seplos Modbus 1
- path: 'packages/bms/bms_combine_SEPLOS_V1_V2_RS485_modbus.yaml'
vars:
seplos_modbus_id: 'seplos_modbus1'
seplos_modbus_uart_id: 'uart_esp_1'
seplos_modbus_baud_rate: '9600' # 9600 / 19200 ; please set the baudrate of your Seplos BMS model here
seplos_modbus_rx_timeout: '150ms'
# BMS 1
- path: 'packages/bms/bms_combine_SEPLOS_V1_V2_RS485_bms_full.yaml'
vars:
# Seplos modbus ID
seplos_modbus_id: 'seplos_modbus1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_address: '0x01' # BMS 1 DIP switch
bms_protocol_version: '0x20' # Known protocol versions: 0x20 (Seplos), 0x26 (Boqiang)
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# BMS 2
- path: 'packages/bms/bms_combine_SEPLOS_V1_V2_RS485_bms_full.yaml'
vars:
# Seplos modbus ID
seplos_modbus_id: 'seplos_modbus1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_address: '0x02' # BMS 2 DIP switch
bms_protocol_version: '0x20' # Known protocol versions: 0x20 (Seplos), 0x26 (Boqiang)
bms_uart_id: uart_esp_2
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
@@ -0,0 +1,98 @@
# Updated : 2025.06.10
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Remote Packages Example ###########################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
substitutions:
modbus_update_interval: '5s' # frequency with which BMS/Shunt modbus servers are queried
modbus_baud_rate: '19200' # 9600 / 19200 / 115200
modbus_command_throttle: '0ms' # minimum time in between 2 requests to the device
modbus_send_wait_time: '250ms' # time in milliseconds before the next ModBUS command is sent if an answer from a previous command is pending
packages:
yambms_modbus_client:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# Modbus client
- path: 'packages/base/device_modbus.yaml'
vars:
modbus_role: 'client' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
# Shunt 1
- path: 'packages/shunt/shunt_combine_modbus_client.yaml'
vars:
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
# BMS 1
- path: 'packages/bms/bms_combine_modbus_client.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
# BMS 2
- path: 'packages/bms/bms_combine_modbus_client.yaml'
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
# BMS 3
- path: 'packages/bms/bms_combine_modbus_client.yaml'
vars:
bms_id: '3' # must be a number
bms_name: 'BMS 3'
# # BMS 4
# - path: 'packages/bms/bms_combine_modbus_client.yaml'
# vars:
# bms_id: '4' # must be a number
# bms_name: 'BMS 4'
# # BMS 5
# - path: 'packages/bms/bms_combine_modbus_client.yaml'
# vars:
# bms_id: '5' # must be a number
# bms_name: 'BMS 5'
# # BMS 6
# - path: 'packages/bms/bms_combine_modbus_client.yaml'
# vars:
# bms_id: '6' # must be a number
# bms_name: 'BMS 6'
# # BMS 7
# - path: 'packages/bms/bms_combine_modbus_client.yaml'
# vars:
# bms_id: '7' # must be a number
# bms_name: 'BMS 7'
# # BMS 8
# - path: 'packages/bms/bms_combine_modbus_client.yaml'
# vars:
# bms_id: '8' # must be a number
# bms_name: 'BMS 8'
# # BMS 9
# - path: 'packages/bms/bms_combine_modbus_client.yaml'
# vars:
# bms_id: '9' # must be a number
# bms_name: 'BMS 9'
# # BMS 10
# - path: 'packages/bms/bms_combine_modbus_client.yaml'
# vars:
# bms_id: '10' # must be a number
# bms_name: 'BMS 10'
@@ -0,0 +1,58 @@
# Updated : 2025.06.10
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Remote Packages Example ###########################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
substitutions:
modbus_update_interval: '5s' # frequency with which BMS/Shunt modbus servers are queried
modbus_baud_rate: '19200' # 9600 / 19200 / 115200
modbus_command_throttle: '0ms' # minimum time in between 2 requests to the device
modbus_send_wait_time: '250ms' # time in milliseconds before the next ModBUS command is sent if an answer from a previous command is pending
packages:
yambms_modbus_server:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# Modbus server
- path: 'packages/base/device_modbus.yaml'
vars:
modbus_role: 'server' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
# Shunt 1
- path: 'packages/shunt/shunt_modbus_Victron_SmartShunt_UART.yaml'
vars:
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
shunt_uart_id: 'uart_esp_2'
# BMS 1
- path: 'packages/bms/bms_modbus_JK_UART_4G-GPS_full.yaml'
vars:
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_uart_id: 'uart_esp_3'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -0,0 +1,63 @@
# Updated : 2025.06.10
# Version : 1.5.6
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
############################ Remote Packages Example ###########################
# This is not a working YAML but just code ready to copy into your main YAML.
################################################################################
substitutions:
modbus_update_interval: '5s' # frequency with which BMS/Shunt modbus servers are queried
modbus_baud_rate: '19200' # 9600 / 19200 / 115200
modbus_command_throttle: '0ms' # minimum time in between 2 requests to the device
modbus_send_wait_time: '250ms' # time in milliseconds before the next ModBUS command is sent if an answer from a previous command is pending
packages:
yambms_modbus_server:
url: https://github.com/Sleeper85/esphome-yambms
ref: main
refresh: 0s
files:
# Modbus server
- path: 'packages/base/device_modbus.yaml'
vars:
modbus_role: 'server' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
# BMS 2
- path: 'packages/bms/bms_modbus_JK_BLE_standard.yaml'
vars:
bms_id: '2' # must be a number, also represents the modbus server number !
bms_name: 'JK-BMS 2'
bms_ble_protocol_version: JK02_32S # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: C8:47:8C:10:7E:AA
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
# BMS 3
- path: 'packages/bms/bms_modbus_JK_BLE_standard.yaml'
vars:
bms_id: '3' # must be a number, also represents the modbus server number !
bms_name: 'JK-BMS 3'
bms_ble_protocol_version: JK02_32S # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: C8:47:8C:EE:16:EA
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
@@ -1,4 +1,4 @@
# YamBMS - JK-B BMS UART Solution
# YamBMS - JK-B BMS
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
@@ -6,9 +6,46 @@
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
## External component
> [!IMPORTANT]
> The most important thing for proper functioning of YamBMS is that **the voltage of your BMS is well calibrated**.
> YamBMS logic is based on the `min_cell_voltage` and `max_cell_voltage` voltages of your BMS.
[esphome-jk-bms](https://github.com/syssi/esphome-jk-bms) by [@syssi](https://github.com/syssi)
## JK-B BMS overview
### UART1 (GPS) port
The `GPS` port sometimes called `RS485` is not an `RS485` port but `3V3 UART-TTL` port.
```
# UART-TTL GPS port on JK-BMS (4 pin, JST 1.25mm pitch)
┌─── ─────── ────┐
│ │
│ O O O O │
│GND RX TX VBAT│
└────────────────┘
│ │ │ └ VBAT is full battery voltage eg. 56V (possible to use it via an isolated DC-DC converter)
│ │ └──── TX to TTL-isolator AI (input)
│ └──────── RX to TTL-isolator AO (output)
└──────────── GND to TTL-isolator GND
```
The `UART1` (labeled as `GPS`) socket of the BMS can be attached to any UART pins of the ESP32.<br>
A hardware UART should be preferred because of the high baudrate (115200 baud).<br>
The connector is called 4 pin JST with 1.25mm pitch.
![Image](../../images/JK-BMS_24S_GPS_port.png "JK-B BMS GPS port")
## JK-B BMS protocol
Historically it was not possible to change the protocol of the `UART1 (GPS)` port and the protocol used was `4G-GPS Remote module Common protocol V4.2` with the component [esphome-jk-bms](https://github.com/syssi/esphome-jk-bms) of [@syssi](https://github.com/syssi).
If you cannot change the protocol of the `UART1 (GPS)` port you can only monitor one BMS per UART port of the ESP32, so a maximum of `3x BMS` without adding a UART expander.
If you have a recent BMS, it is now possible to change the protocol of the `UART1 (GPS)` port and with the `JK BMS RS485 Modbus V1.0` protocol you can assign an address (via JK app) to your BMS and monitor several of them from a single `UART-RS485` connection in the same way as the [JK-PB](BMS_JK-PB.md). To use this protocol and monitor all your BMS on a single `RS485 bus` you will need to add the `UART to RS485 adapter` sold by JK or another RS485 board of your choice.
<img src="../../images/BMS_JK_RS485_Modbus_protocol.png" width="600">
![Image](../../images/BMS_JK_RS485_adapter.png "JK RS485 adapter")
## Schematic and setup instructions
@@ -19,34 +56,7 @@
## Galvanic isolation of the `UART-TTL` connection
> [!CAUTION]
> `V1` and `V2` must be isolated and cannot come from the same source. `V1` (JK GPS port side) can be powered by the `3V3` of the ESP32 via a `DC-DC isolator` (**B0303S = 3V3-to-3V3**), `V2` (ESP32 side) is powered directly by the `3V3` of the ESP32.
```
┌────────────┐ | ┌──────────┐ ┌───────────┐
│ | └─3V3--V1>│ |<V2---3V3---<| |
│ DEVICE │<RX-------AO<│ UART-TTL │<AI-------TX<| ESP32 |
│ JK BMS │>TX-------AI>│ ISOLATOR │>BO-------RX>| |
│ │<----GND---->│ │<----GND---->| |
└────────────┘ └──────────┘ └───────────┘
```
Here are some components available on the market allowing you to set up galvanic isolation. The `UART-TTL isolator 2` seems a little better isolated with more space below the chip.
* [UART-TTL isolator 1](https://a.aliexpress.com/_EuXszn7)
* [UART-TTL isolator 2](https://a.aliexpress.com/_EItDRvX)
* [UART-TTL isolator](https://a.aliexpress.com/_EItDRvX)
![Image](../../images/UART-TTL_isolator_1.png "UART-TTL isolator example")
| [UART-TTL isolator](https://a.aliexpress.com/_EItDRvX) | [DC-DC isolator](https://a.aliexpress.com/_EIsPAoh) |
| --- | --- |
| <img src="../../images/UART-TTL_isolator_2.png" width="400"> | <img src="../../images/DC-DC_3V3-to-3V3_isolator.png" width="400"> |
### Another solution would be the use of M5Stack's isolated RS485 unit.
| [M5Stack RS485 unit (isolated)](https://docs.m5stack.com/en/unit/iso485) |
| --- |
| <img src="../../images/RS485_Transceiver_M5stack_SKU-U094_RS485_Isolated_Unit.png" width="400"> |
> [Please read this page about setting up galvanic isolation of the `UART-TTL` connection.](Galvanic_isolation.md)
### Atom S3 (ESP32-S3)
@@ -59,8 +69,8 @@ You need to import this YAML into the main YAML.
```
UART-TTL RS232-TTL CAN BUS
┌──────────┐ ┌──────────┐ ┌────────────┐ ┌──────────┐
│ │<TX------RX>│2 5│<TX-------TX>| | | |
│ JK-BMS │<RX------TX>│1 6│<RX-------RX>| CA-IS3050G |<---CAN H --->| Inverter |
│ │<TX------RX>│1 5│<TX-------TX>| | | |
│ JK-BMS │<RX------TX>│2 6│<RX-------RX>| CA-IS3050G |<---CAN H --->| Inverter |
│ │<----GND--->│ ESP32 │ | CAN |<---CAN L --->| |
│ │ 5V---->│5V 3V3| | | | |
└──────────┘ └──────────┘ └────────────┘ └──────────┘
@@ -78,8 +88,8 @@ You need to import this YAML into the main YAML.
```
UART-TTL RS232-TTL CAN BUS
┌──────────┐ ┌──────────┐ ┌────────────┐ ┌──────────┐
│ │<TX------RX>│26 22│<TX-------TX>| | | |
│ JK-BMS │<RX------TX>│32 19│<RX-------RX>| CA-IS3050G |<---CAN H --->| Inverter |
│ │<TX------RX>│32 22│<TX-------TX>| | | |
│ JK-BMS │<RX------TX>│26 19│<RX-------RX>| CA-IS3050G |<---CAN H --->| Inverter |
│ │<----GND--->│ ESP32 │ | CAN |<---CAN L --->| |
│ │ 5V---->│5V 3V3| | | | |
└──────────┘ └──────────┘ └────────────┘ └──────────┘
@@ -132,25 +142,3 @@ You need to import this YAML into the main YAML.
```
### JK-B BMS UART-TTL GPS port
The `GPS` port sometimes called `RS485` is not an `RS485` port but `3V3 UART-TTL`.
```
# UART-TTL GPS port on JK-BMS (4 pin, JST 1.25mm pitch)
┌─── ─────── ────┐
│ │
│ O O O O │
│GND RX TX VBAT│
└────────────────┘
│ │ │ | VBAT is full battery volatge eg 51.2V (possible to use it via an isolated DC-DC converter)
│ │ └──── to TTL-isolator AI (input)
│ └──────── to TTL-isolator AO (output)
└──────────── to TTL-isolator GND
```
The UART-TTL (labeled as `GPS`) socket of the BMS can be attached to any UART pins of the ESP.<br>
A hardware UART should be preferred because of the high baudrate (115200 baud).<br>
The connector is called 4 pin JST with 1.25mm pitch.
![Image](../../images/JK-BMS_24S_GPS_port.png "JK-B BMS GPS port")
@@ -1,4 +1,4 @@
# YamBMS - JK-PB BMS RS485 Solution
# YamBMS - JK-PB Inverter BMS
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
@@ -6,68 +6,98 @@
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
## External component
> [!IMPORTANT]
> The most important thing for proper functioning of YamBMS is that **the voltage of your BMS is well calibrated**.
> YamBMS logic is based on the `min_cell_voltage` and `max_cell_voltage` voltages of your BMS.
> If you use YamBMS, the internal charging logic of the `JK-PB BMS` will not be used.
[JK_RS485](https://github.com/txubelaxu/esphome-jk-bms/blob/main/components/jk_rs485_bms/README.md) by [@txubelaxu](https://github.com/txubelaxu)
## JK-PB BMS overview
## ESP32 board
|![Image](../../images/BMS_JK-PB_Inverter_BMS.png)|
|-|
|![Image](../../images/BMS_JK-PB_communication_connectors.jpg)|
|![Image](../../images/BMS_JK-PB_communication_board.png)|
Hardware wise, [Atom S3](https://docs.m5stack.com/en/core/AtomS3) solution is easier and cleaner but [ESP32-S3 DevKitC-1](https://docs.espressif.com/projects/esp-idf/en/v5.3/esp32s3/hw-reference/esp32s3/user-guide-devkitc-1.html) has more GPIOs and PSRAM.
## JK-PB BMS protocol
### Atom S3
The datas from this BMS can be retrieved from the `RS485-2 (UART2)` network using the component [JK_RS485](https://github.com/txubelaxu/esphome-jk-bms/blob/main/components/jk_rs485_bms/README.md) of [@txubelaxu](https://github.com/txubelaxu).
- [Atom S3 - SKU:C123](https://docs.m5stack.com/en/core/AtomS3)
- [Atom S3 Lite - SKU:C124](https://docs.m5stack.com/en/core/AtomS3%20Lite)
- [Atomic CAN Base - SKU:A103](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base)
The BMS DIP switches must be set from `1` to `15` (server mode) and connected to each other using the `RS485-2` network available on the **two ports at the right ends**. `YamBMS` also connects to one of these two ports.
Note: `Atom S3 Lite` does not have a display.
### **UART2 configuration**
### ESP32-S3 DevKitC-1
> [!NOTE]
> The protocol of the `UART2` port is not selectable from the JK application.
> It is automatically set based on the address (DIP switch) of the BMS.
- [ESP32-S3 N16R8](https://a.aliexpress.com/_EzFdrw3)
- [SN65HVD230 3V3 CAN transceiver](https://a.aliexpress.com/_Evq9Ra7)
In the last software version only two protocols are available on the **RS485-2 (UART2)** ports:
## RS485 unisolated board (not recommanded)
- **001** - JK BMS RS485 Modbus V1.0 **(DIP switch 1 to 15)**
- **015** - UART Protocol 015 **(DIP switch 0)**
This board is the one used by [@txubelaxu](https://github.com/txubelaxu) the developer of the RS485 component for the new JK-PB series BMS.<br>
This board is certainly not the best, it does not have galvanic isolation and requires a `TALK PIN`.
### **UART1 configuration**
![Image](../../images/RS485_Transceiver_MAX485_TALK_PIN_board.jpg "MAX485 UART-RS485")
The following protocols are supported on the **RS485-1 (UART1)** port:
## RS485 isolated board (recommended for making your own PCB)
(*italic options ane not settable*)
This board has galvanic isolation and does not require a `TALK PIN` (this avoids having to solder a wire to the Atomic CAN base of the Atom S3).
- **000** - 4G-GPS Remote module Common protocol V4.2
- **001** - **JK BMS RS485 Modbus V1.0**
- **002** - NIU U SERIES
- **003** - China tower shared battery cabinet V1.1
- **004** - PACE_RS485_Modbus_V1.3
- **005** - PYLON_low_voltage_Protocol_RS485_V3.5
- **006** - Growatt_BMS_RS485_Protocol_1xSxxP_ESS_Rev2.01
- **007** - Voltronic_Inverter_and_BMS_485_communication_protocol_20200...
- **008** - China tower shared battery cabinet V2.0
- **009** - WOW_RS485_Modbus_V1.3
- **010** - JK BMS LCD Protocol V2.0
- **011** - *UART1 User customization*
- **012** - *UART2 User customization*
- **013** - (9600)JK BMS RS485 Modbus V1.0
- **014** - (9600)PYLON_low_voltage_Protocol_RS485_V3.5
- **015** - *UART Protocol 015*
![Image](../../images/RS485_Transceiver_isolated_high_speed_dual_board.png "ADUM3201 B0505XT TTL to RS485")
### **CAN port configuration**
[RS485 isolated board (high speed dual)](https://a.aliexpress.com/_EueIZT5)
The following CAN protocols are supported on the CAN port:
Note: choose the `high speed dual` version !
(*italic options ane not settable*)
## M5stack RS485 isolated unit [SKU:U094] (recommended with M5stack Atom S3 solution)
- **000** - JK BMS CAN Protocol (250K) V2.0
- **001** - Deye Low-voltage hybrid inverter CAN communication protocol V1.0
- **002** - PYLON-Low-voltage-V1.2
- **003** - Growatt BMS CAN-Bus-protocol-low-voltage_Rev_05
- **004** - Victron_CANbus_BMS_protocol_20170717
- **005** - MEGAREVO_Hybird_BMSCAN_Protocol_V1.0
- **006** - JK BMS CAN Protocol (500K) V2.0
- **007** - INVT BMS CAN Bus protocol V1.02
- **008** - GoodWe LV BMS Protocol (EX/EM/S-BP/BP)
- **009** - FSS-ConnectingBat-Tl-en-10 | Version 1.0
- **010** - MUST PV1800F-CAN communication Protocol1.04.04
- **011** - LuxpowerTek Battery CAN protocol V01
- **012** - *CAN BUS User customization*
- **013** - *CAN BUS Protocol 013*
- **014** - *CAN BUS Protocol 014*
If you are using M5stack solution with Atom S3, this [RS485 unit](https://docs.m5stack.com/en/unit/iso485) is the simplest solution without soldering.
## YamBMS hardware
![Image](../../images/RS485_Transceiver_M5stack_SKU-U094_RS485_Isolated_Unit.png "M5stack RS485 isolated unit (SKU:U094)")
> [!TIP]
> This solution only requires an ESP32 with a CAN transceiver and a RS485 transceiver.
## M5stack Atom S3 with CAN base and RS485 unit
You are free to choose the hardware you want, the list below are 3 easy to use examples :
If soldering or creating your own board seems complicated to you, know that it is possible to use the Atom S3 solution from M5Stack.
- `AtomS3` with the isolated `Atomic CAN base` and `RS485 unit`
- [`LilyGo T-Connect`, ESP32-S3 with 3x RS485 and 1x CAN](https://github.com/Xinyuan-LilyGO/T-Connect)
- [`LilyGo T-CAN485`, ESP32 with 1x RS485 and 1x CAN](https://github.com/Xinyuan-LilyGO/T-CAN485)
**Choose Atom S3 (display) or Atom S3 Lite + Atomic CAN base + RS485 unit**
See the [documentation about supported hardware](Supported_devices.md).
- [Atom S3 - SKU:C123](https://docs.m5stack.com/en/core/AtomS3)
- [Atom S3 Lite - SKU:C124](https://docs.m5stack.com/en/core/AtomS3%20Lite)
- [Atomic CAN Base - SKU:A103](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base)
- [RS485 Isolated Unit - SKU:U094](https://docs.m5stack.com/en/unit/iso485)
### M5Stack AtomS3 example (no welding)
| Atomic S3 Lite | Atomic CAN Base | RS485 isolated Unit |
| --- | --- | --- |
| <img src="../../images/Atom_S3_Lite.png" width="300"> | <img src="../../images/CAN_Transceiver_Atomic_CAN_Base.png" width="300"> | <img src="../../images/RS485_Transceiver_M5stack_SKU-U094_RS485_Isolated_Unit.png" width="300"> |
The example below uses an `AtomS3` (display) with the `Atomic CAN base` and `RS485 unit`.
The example below uses an Atom S3 (display) with the CAN base and RS485 unit.
![Image](../../images/Solution_M5stack_AtomS3_CAN_base_RS485_unit.png "M5stack Atom S3 solution")
![Image](../../images/Solution_M5stack_AtomS3_CAN_base_RS485_unit.png "M5stack AtomS3 solution")
## Schematic and setup instructions
@@ -75,19 +105,15 @@ The example below uses an Atom S3 (display) with the CAN base and RS485 unit.
> Galvanic isolation of the `RS485` connection is strongly recommended.
> The diagrams below does not show the galvanic isolation of the `RS485` connection !
> [!IMPORTANT]
> The boards `uart` are configured by default with an `rx_buffer_size` of `512` which **normally** is fine for all components. Only one user reported to me an instability problem with his `Atom S3` which he solved by increasing the `rx_buffer_size` to `1024`, this user is also the only one currently using the isolated RS485 unit of M5Stack.
> If you encounter a similar problem, let me know.
**Note:** the choice of RS485 board is not related to the chosen ESP32.
### Atom S3 with unisolated RS485 board
### AtomS3 with unisolated RS485 board
```
┌──────────┐ ┌───────────┐ ┌──────────┐
│ │ │ UART │<-VCC--------------5V--│ │<---5V
│ BMS │ │ TO │ │ ESP32 │
│ JK-PB │<-RJ45-P1-----B->│ RS485 │<-DI-----------TX--G1--│ ATOM S3 │
│ JK-PB │<-RJ45-P1-----B->│ RS485 │<-DI-----------TX--G1--│ Atom S3 │
│ │<-RJ45-P2-----A->│ │--RO-----------RX--G2->│ │ ┌────────────┐ ┌────────────┐
│ RS485 │ │ CONVERTER │<-DE--+ │ │--G5--TX-----CTX->| | | |
│ NETWORK │ │ │<-RE--└--TALK PIN--G8--│ │<-G6--RX-----CRX--| Atomic |<---CAN H--->| Inverter |
@@ -125,8 +151,8 @@ With mode 2, the sniffer (ESP32) will automatically take the address 0x00 and ac
## JK-PB RS485 functions
### Sniffer Broadcast changes to all BMS
### Broadcasting JK-PB settings to all BMS
![Image](../../images/YamBMS_JK-PB_RS485_Sniffer_Broadcast.png "YamBMS_JK-PB_RS485_Sniffer_Broadcast")
![Image](../../images/YamBMS_JK-PB_RS485_Sniffer_Broadcast.png "Broadcasting JK-PB settings to all BMS")
When enabled, this function synchronizes the settings of all your BMS connected to the same RS485 network as soon as you make parameter changes.
@@ -1,4 +1,4 @@
# YamBMS - JK-B BMS RS485 DISPLAY Solution
# YamBMS - JK RS485 DISPLAY
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
@@ -6,6 +6,10 @@
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
> [!IMPORTANT]
> The most important thing for proper functioning of YamBMS is that **the voltage of your BMS is well calibrated**.
> YamBMS logic is based on the `min_cell_voltage` and `max_cell_voltage` voltages of your BMS.
## External component
[esphome-jk-bms](https://github.com/syssi/esphome-jk-bms) by [@syssi](https://github.com/syssi)
+3
View File
@@ -6,6 +6,9 @@
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
> [!NOTE]
> Please read the documentation regarding the [charging settings](YamBMS_functions.md#charging-settings).
## Charging Logic Diagram
The charging voltage and current correspond to the default values in the YAML script and can be modified.
+39
View File
@@ -0,0 +1,39 @@
# YamBMS - Galvanic isolation
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
![GitHub stars](https://img.shields.io/github/stars/Sleeper85/esphome-yambms)
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
## Galvanic isolation of the `UART-TTL` connection
> [!CAUTION]
> `V1` and `V2` (3V3 or 5V) must be isolated and cannot come from the same source. `V1` can be powered by the device or the `3V3` of the ESP32 via a `DC-DC isolator` (**B0303S = 3V3-to-3V3**), `V2` (ESP32 side) is powered directly by the `3V3` of the ESP32.
```
┌─────────────┐ ┌──────────┐ ┌───────────┐
│ | 3V3/5V--V1>│ |<V2---3V3---<| |
│ DEVICE │<RX-------AO<│ UART-TTL │<AI-------TX<| ESP32 |
│ BMS / Shunt │>TX-------AI>│ ISOLATOR │>BO-------RX>| |
│ │<----GND---->│ │<----GND---->| |
└─────────────┘ └──────────┘ └───────────┘
```
Here are some components available on the market allowing you to set up galvanic isolation. The `UART-TTL isolator 2` seems a little better isolated with more space below the chip.
* [UART-TTL isolator 1](https://a.aliexpress.com/_EuXszn7)
* [UART-TTL isolator 2](https://a.aliexpress.com/_EItDRvX)
* [DC-DC isolator](https://a.aliexpress.com/_EIsPAoh)
![Image](../../images/UART-TTL_isolator_1.png "UART-TTL isolator example")
| [UART-TTL isolator](https://a.aliexpress.com/_EItDRvX) | [DC-DC isolator](https://a.aliexpress.com/_EIsPAoh) |
| --- | --- |
| <img src="../../images/UART-TTL_isolator_2.png" width="400"> | <img src="../../images/DC-DC_3V3-to-3V3_isolator.png" width="400"> |
### Another solution would be the use of M5Stack's isolated RS485 unit.
| [M5Stack RS485 unit (isolated)](https://docs.m5stack.com/en/unit/iso485) |
| --- |
| <img src="../../images/RS485_Transceiver_M5stack_SKU-U094_RS485_Isolated_Unit.png" width="400"> |
+44 -37
View File
@@ -8,20 +8,40 @@
## Installation procedure
1. **Install ESPHome on your computer**<br>
Before you can flash your ESP32 you need to install the [ESPHome 2024.6.0 or higher](https://github.com/esphome/esphome/releases) command line application.<br>
### 1. Install ESPHome on your computer
Before you can flash your ESP32 you need to install the [ESPHome 2025.3.0 or higher](https://github.com/esphome/esphome/releases) command line application.<br>
[Follow these instructions for installation on Windows, Mac or Linux.](https://esphome.io/guides/installing_esphome)
2. **Download all YAML files to your computer**<br>
> [!TIP]
> If you are using Windows install the `setuptools` package in addition to `wheel` and `esphome`.
```bash
pip3 install setuptools
pip3 install wheel
pip3 install esphome
```
### 2. Download all YAML files to your computer
> [!TIP]
> This step is not necessary if you are compiling the `Remote Packages` version of the YAML.
You can do this from the command line or in your preferred method.
You need to gather the following three points in the same folder. If you are compiling from your HA server use the `Samba Share` add-on so that you can copy the `packages` folder to the `esphome` folder on the HA server.
1) the `packages` folder
2) your `secrets.yaml`
3) your [custom](YamBMS_main_YAML_HowTo.md) `main.yaml`
```bash
# Clone this external component
git clone https://github.com/Sleeper85/esphome-yambms.git
cd esphome-yambms
```
3. **Enter your WiFi credentials in the secrets.yaml files**
### 3. Enter your WiFi credentials in the secrets.yaml files
```yaml
wifi_ssid: YourSSID
@@ -29,62 +49,49 @@ wifi_password: YourPassword
domain : .local
```
4. **Install the YamBMS application into your ESP32**<br>
Choose the main YAML that best suits your needs like for example `multi-bms_JK-ALL_BLE.yaml`.<br>
Validate the configuration, create a binary, upload it, and start logs.<br>
**The only YAML that needs to be checked and configured is the main one like for example `multi-bms_JK-ALL_BLE.yaml` but you can modify other YAMLs if you want.<br>
The goal is that the main YAML which contains all your specific parameters can be preserved and reused each time the other YAMLs classified in the `packaged` folder are updated.**
### 4. Install the YamBMS application into your ESP32
Create a copy of `YamBMS_Remote_Packages_example.yaml` and modify it to match your configuration.
Examples of BMS imports can be found in the [configuration_examples](configuration_examples/) folder.
You can mix different BMS models, the only condition is that they are numbered in order starting from `1`.
```bash
# To install the multi-bms JK-ALL Bluetooth version
esphome run multi-bms_JK-ALL_BLE.yaml
# To install the multi-bms JK-B UART version
esphome run multi-bms_JK-B_UART.yaml
# To install the multi-bms JK-PB RS485 version
esphome run multi-bms_JK-PB_RS485_mode2.yaml
# install your YamBMS.yaml
# validate the configuration, create a binary, upload it, and start logs.
esphome run YamBMS.yaml
# upgrade via OTA by specifying the IP address of the ESP32
esphome run multi-bms_JK-ALL_BLE.yaml --device 192.168.x.x
esphome run YamBMS.yaml --device 192.168.x.x
```
5. **Optional but recommended: add the ESP32 in your Home Assistant server**<br>
### 5. Optional but recommended, add the ESP32 in your Home Assistant server
In Home Assistant under **" Settings > Devices and services > Add Intergration "** select ESPHome add device `yambms` if found or supply ip address of ESP32.
## ESPHome other bash command
## Other ESPHome command-line
```bash
# clean files before compiling again
esphome clean multi-bms_JK-ALL_BLE.yaml
esphome clean YamBMS.yaml
# test the config
esphome config multi-bms_JK-ALL_BLE.yaml
esphome config YamBMS.yaml
# install the config in ESP32
esphome run multi-bms_JK-ALL_BLE.yaml
esphome run YamBMS.yaml
# compile the firmware.bin
esphome compile multi-bms_JK-ALL_BLE.yaml
esphome compile YamBMS.yaml
# check the logs (the --device option is not required)
esphome logs multi-bms_JK-ALL_BLE.yaml --device 192.168.x.x
esphome logs YamBMS.yaml --device 192.168.x.x
```
## Debugging
If this component doesn't work out of the box for your device please update your configuration to enable the debug output of the UART component and increase the log level to the see outgoing and incoming serial traffic:
If this component doesn't work out of the box for your device please update your configuration to increase the log level to `DEBUG`.
```
```YAML
logger:
level: DEBUG
uart:
id: uart_0
baud_rate: 115200
rx_buffer_size: 384
tx_pin: ${tx_pin}
rx_pin: ${rx_pin}
debug:
direction: BOTH
```
```
@@ -8,6 +8,8 @@
## Contents
1) [JK-B BMS UART (GPS port) solution](BMS_JK-B_UART_solution.md)
2) [JK-B BMS RS485 (Display port) solution](BMS_JK-B_RS485_DISPLAY_solution.md)
3) [JK-PB BMS RS485 solution](BMS_JK-PB_RS485_solution.md)
1) [Galvanic isolation](Galvanic_isolation.md)
2) [JK-B BMS](BMS_JK-B.md)
3) [JK-PB BMS](BMS_JK-PB.md)
4) [JK RS485 DISPLAY](BMS_JK_RS485_DISPLAY.md)
5) [Victron SmartShunt](Shunt_Victron_SmartShunt.md)
@@ -0,0 +1,59 @@
# Victron SmartShunt
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
![GitHub stars](https://img.shields.io/github/stars/Sleeper85/esphome-yambms)
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
## UART : Schematic
> [!CAUTION]
> [Please read this page about setting up galvanic isolation of the `UART-TTL` connection.](Galvanic_isolation.md)
> [!TIP]
> If you are unsure about to pin order please measure the voltage between GND and VCC (5V). If you measure a positive voltage you know the position of VCC and GND!
```
┌─────────────────┐ ┌──────────┐ ┌───────────┐
│ 5V o│<----5V---V1>│ |<V2---3V3--->| |
│ Victron RX o│<---------AO<│ UART-TTL │<AI-------TX<| ESP32 |
│ SmartShunt TX o│>---------AI>│ ISOLATOR │>BO-------RX>| |
│ GND o│<----GND---->│ │<----GND---->| |
└─────────────────┘ └──────────┘ └───────────┘
# UART-TTL VE.Direct port (JST-PH 2.0mm pinch)
┌─── ─────── ────┐
│ │
│ O O O O │
│GND RX TX VCC │
└────────────────┘
│ │ │ └ 5V
│ │ └──── TX to TTL-isolator AI (input)
│ └──────── RX to TTL-isolator AO (output)
└──────────── GND to TTL-isolator GND
```
## Bluetooth : How to retrieve MAC address and encryption key
To connect to your Victron device with BLE component you must have two information :
- `mac_address` - Bluetooth mac address of device.
- `encryption_key` - AES encryption key.
Use [VictronConnect App v5.93](https://www.victronenergy.com/live/victronconnect:beta) (or later) released on 2023-08-25.
Connect to the SmartShunt via Bluetooth under the `Local` tab.
![VictronConnect App Local page](../../images/Victron_SmartShunt_App_00_Local.jpg)
![VictronConnect App Settings page](../../images/Victron_SmartShunt_App_01_Settings.png)
![VictronConnect App Product info page](../../images/Victron_SmartShunt_App_02_ProductInfo.png)
![VictronConnect App Instant readout encryption data](../../images/Victron_SmartShunt_App_03_EncryptionData.png)
1. Open `Settings` of Device.
2. Open `Product Info` page.
3. Ensure `Instant readout via Bluetooth` is enabled.
4. Bottom of page press `SHOW` for Instant readout details Encryption data.
When connected to the device via VictronConnect App no Instant readout (Bluetooth advertising) data is generated.
+37 -15
View File
@@ -6,43 +6,61 @@
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
## Supported ESP32
**Recommended: ESP32-S3 or Atom S3**
* [M5Stack Atom S3](Supported_devices_M5Stack_Atom_S3.md)
* [PVbrain2 with ESP32-S3](https://github.com/SeByDocKy/pvbrain2) (up to 11 BMS monitored with `UART`)
* [Build your own PCB with ESP32 or ESP32-S3](Supported_devices_Build_your_own_PCB.md)
## Supported BMS
All `JK-B` and `JK-PB` models with software@ version `>=6.0` are using the implemented protocol and should be supported.
See the [@syssi](https://github.com/syssi) [esphome-jk-bms](https://github.com/syssi/esphome-jk-bms) repository for more information.
* All `JK-B` BMS models with software version `>=6.0`, see [esphome-jk-bms](https://github.com/syssi/esphome-jk-bms)
* `JK-PB` BMS, see [esphome-jk-bms](https://github.com/txubelaxu/esphome-jk-bms/)
* `JBD` BMS, see [esphome-jbd-bms](https://github.com/syssi/esphome-jbd-bms)
* `Seplos V1 V2` BMS, see [esphome-seplos-bms](https://github.com/syssi/esphome-seplos-bms)
**Note: other BMS brands already integrated with ESPhome can be added easily.**
## Supported shunt
`Victron Smartshunt` and `Junctek KH-F`.
* `Victron Smartshunt` (UART)
* `Victron Smartshunt` (BLE)
* `Junctek KH-F` (UART/RS485)
**Note: other Shunt brands already integrated with ESPhome can be added easily.**
## Supported ESP32
**Recommended: AtomS3 or ESP32-S3**
* [M5Stack AtomS3 dedicated documentation](Supported_devices_M5Stack_AtomS3.md)
* [PVbrain2 with ESP32-S3](https://github.com/SeByDocKy/pvbrain2) (up to 11 BMS monitored with `UART`)
* [Build your own PCB with ESP32 or ESP32-S3](Supported_devices_Build_your_own_PCB.md)
| [AtomS3 Lite](https://docs.m5stack.com/en/core/AtomS3%20Lite) | [AtomS3](https://docs.m5stack.com/en/core/AtomS3) | [AtomS3R (8MB PSRAM)](https://docs.m5stack.com/en/core/AtomS3R) |
| --- | --- | --- |
| <img src="../../images/MCU_AtomS3_Lite.png" width="300"> | <img src="../../images/MCU_AtomS3.png" width="300"> | <img src="../../images/MCU_AtomS3R.png" width="300"> |
| [ESP32 DevKit-V1](https://a.aliexpress.com/_EG12CJ2) | [ESP32-S3 DevKitC-1](https://a.aliexpress.com/_EzFdrw3) | [ESP32-C3 ETH01-EVO](https://a.aliexpress.com/_Ey29fog) |
| --- | --- | --- |
| <img src="../../images/MCU_ESP32-DevKit-V1.jpg" width="300"> | <img src="../../images/MCU_ESP32-S3-DevKitC-1.png" width="300"> | <img src="../../images/MCU_ESP32-C3_ETH01-EVO.png" width="300"> |
| [espBerry + Waveshare 2-CH CAN HAT](https://copperhilltech.com/esp32-development-board-with-dual-isolated-can-bus-hat/) | [LilyGo T-CAN485 (ESP32)](https://github.com/Xinyuan-LilyGO/T-CAN485) | [LilyGo T-Connect (ESP32-S3)](https://github.com/Xinyuan-LilyGO/T-Connect) |
| --- | --- | --- |
| <img src="../../images/MCU_ESP32-DevKitC_espBerry_2-CH-CAN.png" width="300"> | <img src="../../images/MCU_ESP32_LilyGo-T-CAN485.jpg" width="300"> | <img src="../../images/MCU_ESP32-S3_LilyGo-T-Connect.jpg" width="300"> |
| [Olimex ESP32-EVB](https://github.com/OLIMEX/ESP32-EVB) |
| --- |
| <img src="../../images/MCU_ESP32-EVB.jpg" width="300">|
## Supported CAN bus transceiver
**Note: some inverters only accept a CAN bus at 3.3V in this case please choose the SN65HVD230 chip.**
| TJA1050 | TJA1051 | SN65HVD230 |
| TJA1050 (5V) | [TJA1051T (5V)](https://a.aliexpress.com/_EIdl3b5) | [SN65HVD230 (3V3)](https://a.aliexpress.com/_Evq9Ra7) |
| --- | --- | --- |
| <img src="../../images/CAN_Transceiver_TJA1050.png" width="300"> | <img src="../../images/CAN_Transceiver_TJA1051.jpg" width="300"> | <img src="../../images/CAN_Transceiver_SN65HVD230.jpg" width="300"> |
| [M5Stack Atomic CAN Base (isolated)](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base) | [M5Stack CAN Unit (isolated)](https://docs.m5stack.com/en/unit/can) | MCP2515 |
| [M5Stack Atomic CAN Base (isolated)](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base) | [M5Stack CAN Unit (isolated)](https://docs.m5stack.com/en/unit/can) | [MCP2515 (5V)](https://a.aliexpress.com/_EGPcjhZ) |
| --- | --- | --- |
| <img src="../../images/CAN_Transceiver_M5Stack_Atomic_CAN_Base.png" width="300"> | <img src="../../images/CAN_Transceiver_M5Stack_CAN_Unit.png" width="300"> | <img src="../../images/CAN_Transceiver_MCP2515.png" width="300"> |
## Supported RS485 transceiver
| [M5Stack RS485 unit (isolated)](https://docs.m5stack.com/en/unit/iso485) | [RS485 isolated board (high speed dual)](https://a.aliexpress.com/_EueIZT5) | [RS485 Two-way Converter](https://electronics.stackexchange.com/questions/244425/how-is-this-rs485-module-working) |
| [M5Stack RS485 Unit (isolated)](https://docs.m5stack.com/en/unit/iso485) | [RS485 isolated board (high speed dual)](https://a.aliexpress.com/_EueIZT5) | [RS485 Two-way Converter](https://electronics.stackexchange.com/questions/244425/how-is-this-rs485-module-working) |
| --- | --- | --- |
| <img src="../../images/RS485_Transceiver_M5stack_SKU-U094_RS485_Isolated_Unit.png" width="300"> | <img src="../../images/RS485_Transceiver_isolated_high_speed_dual_board.png" width="300"> | <img src="../../images/RS485_Transceiver_Two-way_Converter.jpg" width="300"> |
@@ -85,8 +103,12 @@ The following are confirmed and known to work:
| LuxPower | LXP-LB-US 10K | Working | [@Henny101](https://diysolarforum.com/members/henny101.67026/) | Lithium 6 | JK-PB (2) | RS485 | ESP32-S3 DevKitC-1 | Automatic | LuxPower | SN65HVD230 | [Isolated RS485 (high speed dual)](https://a.aliexpress.com/_EueIZT5) | yes | --- |
| EG4 | 6000XP | Working | [@ChrisG](https://diysolarforum.com/members/chrisg.483/) | Lithium 2 | JK-B (2) | BLE | ESP32 DevKit V1 / ESP32-S3 DevKitC-1 | PYLON | PYLON 1.2 | MCP2515 | --- | yes | --- |
| EG4 | 6000XP (2) | Working | [@SGB](https://diysolarforum.com/members/scrotpusgobblebottom.100804/) | Lithium 6 | JK-B (1) JK-PB (1) | BLE | Atom S3 (display) | Automatic | LuxPower | [Atomic CAN base (SKU:A103)](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base) | --- | yes | --- |
| EG4 | 12000XP | Working | [@andrewfraley](https://github.com/andrewfraley) | Lithium 6 | JBD | RS485 | LilyGo T-CAN485 | Automatic | LuxPower | T-CAN485 (SN65HVD231DR) | T-CAN485 (MAX13487E) | no | set UART baud to 9600 |
| EG4 | 18kPV | Working | [@Maintman](https://diysolarforum.com/members/maintman.19007/) | Lithium 6 | JK-B | BLE | ESP32 DevKit V1 | Automatic | LuxPower | MCP2515 | --- | yes | Connected via Bluetooth to Victron SmartShunt. |
| Victron | MultiPlus-II 48/10000/140 | Working | [@cali-clim](https://diysolarforum.com/members/cali-clim.54284/) | CAN-bus BMS LV (500 kbit/s) | JK-PB (2) | RS485 | Atom S3 (display) | Automatic | Victron | [Atomic CAN base (SKU:A103)](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base) | [Isolated RS485 Unit (SKU:U094)](https://docs.m5stack.com/en/unit/iso485) | yes | --- |
| Victron | MultiPlus-II 48/10000/140 | Working | [@20after4](https://github.com/20after4) | CAN-bus BMS LV (500 kbit/s) | JBD-BMS (2) | BLE | Olimex ESP32-EVB | Automatic | Victron | SIT1050T (Integrated) | --- | yes | Works well with the integrated Ethernet and CANBus hardware |
| Victron | Multiplus 24/1200/25-16 | Working | [@dmsims](https://diysolarforum.com/members/dmsims.23417/) | CAN-bus BMS LV (500 kbit/s) | JK-B (1) | BLE | Atom S3 Lite | Automatic | Victron | [Atomic CAN base (SKU:A103)](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base) | --- | no | Plugged into Cerbo Can port (must use supplied Victron terminator in the other port) |
| MidNite Solar | MN15-12KW-AIO | Working | [@goldserve](https://diysolarforum.com/members/goldserve.52541/) | PYLON | JK-B | BLE | ESP32-S3 | Automatic | PYLON 1.2 | MCP2515 | --- | no | Stable with Victron Smartshunt, MQTT, BLE, Neopixel LED, Display also working. |
| MidNite Solar | MN15-12KW-AIO | Working | [@jahyde](https://diysolarforum.com/members/jahyde.7475/) | PYLON | JK-PB | BLE | ESP32-S3 | Automatic | PYLON 1.2 | MCP2515 | --- | yes | --- |
| SMA | Sunny Island | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| SRNE | HESP48120U200-H | Working | [@ogremustcrush](https://diysolarforum.com/members/ogremustcrush.116979/) | UZE | JK-PB | RS485 | Atom S3 Lite | Automtic | PYLON V2 | [Atomic CAN Base (SKU:A103)](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base) | [Isolated RS485 Unit (SKU:U094)](https://docs.m5stack.com/en/unit/iso485) | Yes | Most of the YamBMS PYLON based protocols show same results on inverter. Inverter itself does not work when it is set to PYLON protocol, but UZE works. Incorrect temp reported on inverter |
@@ -6,12 +6,13 @@
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
> [!IMPORTANT]
> BMS monitoring with `UART` or `RS485` is recommended.
## Number of BMS supported
**Warning:** BMS monitoring with `UART` or `RS485` is recommended, however, if you want to monitor your BMS with `Bluetooth`, please choose an `ESP32-S3`.
* 3x BMS with `Bluetooth` (BLE stack consumes significant amount of RAM on device and can cause crash and reboot)
* 3x `JK-B` BMS with `UART`
* 2x BMS with `Bluetooth` (BLE stack consumes significant amount of RAM on device and can cause crash and reboot)
* 3x `JK-B` BMS with `UART/RS485`
* several `JK-PB` BMS with `RS485` (already tested with 7 BMS)
Note: these are theoretical limits, not all combinations have been tested.
@@ -22,8 +23,12 @@ It would be possible to add one or more [WK2168 4x UART expander](https://esphom
## Build your own PCB
This is an example of an ESP32 DevKit V1 30 pin board powered by the BMS.
> [!CAUTION]
> The `GND` of the `JK-B GPS port` is directly connected with the `B-` of your battery. Even if your BMS is in protection or stopped you can measure the `full voltage` between this `GND` and `B+`. This therefore presents a risk of `bypass` of the BMS `P-` and can be dangerous if the GND of your ESP32 is connected to the GND of your inverter or a measurement shunt for example.
> I therefore strongly advise you to achieve [galvanic isolation](BMS_JK-B_UART_solution.md#galvanic-isolation-of-the-uart-ttl-connection) between your ESP32 and the `UART-TTL` of the `JK-B GPS port`.
This is an example of an `ESP32 DevKit V1` 30 pin board powered by the `JK-B` BMS. **This example uses an RS485 board for the `multi-node` solution which is not mandatory.**
![Image](../../images/PCB_ESP32_JK-BMS-CAN_powered_by_JK-BMS.png "PCB ESP32 JK-BMS-CAN powered by JK-BMS")
![Image](../../images/PCB_ESP32_JK-BMS-CAN_Prototype.jpg "PCB ESP32 JK-BMS-CAN powered by JK-BMS")
![Image](../../images/PCB_ESP32_JK-BMS-CAN_Prototype.png "PCB ESP32 JK-BMS-CAN powered by JK-BMS")
@@ -0,0 +1,56 @@
# YamBMS - M5Stack AtomS3, the Plug & Play solution (no welding)
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
![GitHub stars](https://img.shields.io/github/stars/Sleeper85/esphome-yambms)
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
> [!IMPORTANT]
> AtomS3 provides very few GPIOs.
> This solution is not the best for supervising a large number of `JK-B BMS` via `UART` but it works very well for supervising a large number of `JK-PB BMS` via `RS485`.
> [!TIP]
> If you have `JK-PB BMS` (inverter BMS) and want to monitor them via `RS485`, please read the [BMS JK-PB RS485](BMS_JK-PB_RS485_solution.md) dedicated topic.
## Number of BMS supported
* 3x BMS with `Bluetooth` (BLE stack consumes significant amount of RAM on device and can cause crash and reboot)
* 2x `JK-B` BMS with `UART/RS485` (the second UART must be soldered on the Atomic CAN base on GPIOs G7 and G8)
* several `JK-PB` BMS with `RS485` (already tested with 7 BMS)
Note: these are theoretical limits, not all combinations have been tested.
## List of M5Stack components that can be used depending on needs
> [!TIP]
> Choose an `AtomS3` to clip onto the `Atomic CAN Base`.
> Feel free to ask your question on the [DIY solar forum](https://diysolarforum.com/threads/yambms-jk-bms-can-with-new-cut-off-charging-logic-open-source.79325/) if you don't know what to choose.
- [AtomS3 Lite - SKU:C124](https://docs.m5stack.com/en/core/AtomS3%20Lite)
- [AtomS3 - SKU:C123](https://docs.m5stack.com/en/core/AtomS3)
- [AtomS3R - SKU:C126 (8MB PSRAM)](https://docs.m5stack.com/en/core/AtomS3R)
- [Atomic CAN Base - SKU:A103 (recommended)](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base)
- [CAN Unit - SKU:U085](https://docs.m5stack.com/en/unit/can)
- [RS485 Unit - SKU:U094](https://docs.m5stack.com/en/unit/iso485)
| [AtomS3 Lite](https://docs.m5stack.com/en/core/AtomS3%20Lite) | [AtomS3](https://docs.m5stack.com/en/core/AtomS3) | [AtomS3R (8MB PSRAM)](https://docs.m5stack.com/en/core/AtomS3R) |
| --- | --- | --- |
| <img src="../../images/MCU_AtomS3_Lite.png" width="300"> | <img src="../../images/MCU_AtomS3.png" width="300"> | <img src="../../images/MCU_AtomS3R.png" width="300"> |
| [Atomic CAN Base (isolated)](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base) | [CAN Unit (isolated)](https://docs.m5stack.com/en/unit/can) | [RS485 Unit (isolated)](https://docs.m5stack.com/en/unit/iso485) |
| --- | --- | --- |
| <img src="../../images/CAN_Transceiver_M5Stack_Atomic_CAN_Base.png" width="300"> | <img src="../../images/CAN_Transceiver_M5Stack_CAN_Unit.png" width="300"> | <img src="../../images/RS485_Transceiver_M5stack_SKU-U094_RS485_Isolated_Unit.png" width="300"> |
## Note regarding the sensors managing the display backlight (ili9xxx platform)
* **Backlight control** : manual brightness control
* **Backlight max level** : limit the max brightness in general
* **Backlight Autodim level** : the desired brightness when dimmed down (set to 0 to switch off screen completely instead of dimming down)
* **Backlight Autodim time in min** : time in minutes, after the screen will dim down (set to 0 to disable Auto dimming)
Device will restore last screen brightness after boot, but the timer script does not get start automatically.
The auto dim timer gets initially started by pressing the screen button (which bumps up the brightness to 100% until the timer dims down then).
That seems to be the easiest and lightweight solution.
But i guess some user could be confused and expect from the device to react immediately after changing some parameters.
@@ -1,38 +0,0 @@
# YamBMS - M5Stack Atom S3 (ESP32-S3FN8)
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
![GitHub stars](https://img.shields.io/github/stars/Sleeper85/esphome-yambms)
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
## Number of BMS supported
**Warning:** Atom S3 provides very few GPIOs without UART expander. BMS monitoring with `UART` or `RS485` is recommended.
* 3x BMS with `Bluetooth` (BLE stack consumes significant amount of RAM on device and can cause crash and reboot)
* 2x `JK-B` BMS with `UART` (the second UART must be soldered on the Atomic CAN base on GPIOs G7 and G8)
* several `JK-PB` BMS with `RS485` (already tested with 7 BMS)
Note: these are theoretical limits, not all combinations have been tested.
## UART/IO Expander
Theoretically, with the 4 GPIOs available, it would be possible to add one [WK2168 4x UART expander](https://esphome.io/components/weikai.html) for a total of 4x `JK-B` BMS monitored with `UART`.
## M5Stack Atom CAN Kit (the Plug & Play solution)
> [!IMPORTANT]
> If you have JK-PB series BMS (inverter BMS) and want to monitor them via RS485, please read the [README](BMS_JK-PB_RS485_solution.md) dedicated to this topic.
If soldering or creating your own board seems complicated to you, know that it is possible to use the Atom CAN Kit from M5Stack.<br>
**Choose Atom S3 (display) or Atom S3 Lite + Atomic CAN base.**
- [Atom S3 - SKU:C123](https://docs.m5stack.com/en/core/AtomS3)
- [Atom S3 Lite - SKU:C124](https://docs.m5stack.com/en/core/AtomS3%20Lite)
- [Atomic CAN Base - SKU:A103](https://docs.m5stack.com/en/atom/Atomic%20CAN%20Base)
| Atomic S3 Lite | Atomic CAN Base |
| --- | --- |
| <img src="../../images/Atom_S3_Lite.png" width="450"> | <img src="../../images/CAN_Transceiver_M5Stack_Atomic_CAN_Base.png" width="450"> |
+26 -17
View File
@@ -23,23 +23,28 @@ The various counters above allow you to see what state your system is in.
Combine condition :
1) the `Combine` switch is enabled
2) the `Voltage` supplied by the shunt is `> 0V`
2) Shunt `Online Status` is `ON` (the shunt `Voltage` is `> 0`)
If one of these two conditions is not respected, the shunt is automatically decombined.
If one of these two conditions is not respected, the shunt is automatically uncombined.
> [!IMPORTANT]
> In RS485 modbus `multi-node`, if a server does not respond (cable or hardware failure) the `Online Status` of the shunt will be set to `OFF` and it will be uncombined.
As soon as you import a `Shunt` and it can be combined (see condition) the values ​​`Voltage`, `Current`, `Power` and `SoC` of the shunt(s) will take precedence over the BMS values.
> [!TIP]
> [!NOTE]
> If all BMS are `uncombined` the shunt data will no longer be published.
### BMS
Combine condition :
1) the `Combine` switch is enabled
2) BMS `Online Status` is `ON` (to detect a loss of connection with the BMS e.g. cable, BMS OFF or dead)
3) BMS `Charging` or `Discharging` is allowed (based on `binary_sensor`, related to the state of `switches/alarms`)
1) BMS `Online Status` is `ON / Connected` (to detect a loss of connection with the BMS e.g. cable, BMS OFF or dead)
2) The BMS `Battery Capacity` is `> 0` (to ensure that the data received is correct)
If one of these three conditions is not met, the BMS is automatically decombined.
If one of these two conditions is not met, the BMS is automatically uncombined.
> [!IMPORTANT]
> In RS485 modbus `multi-node`, if a server does not respond (cable or hardware failure) the `Online Status` of the BMS will be set to `OFF` and it will be uncombined.
From YamBMS `1.5.1` :
@@ -59,11 +64,20 @@ The `SoC` is slightly manipulated before reaching `0%` or `100%`.
SoC `100%` will be sent to your inverter only when the battery is `fully charged` (useful for some inverters stopping charging when the SoC reaches 100%).
SoC behavior:
1) If `min_cell_v <= cell_uvpr` SoC 0% is sent
2) Else if `SOC < 1%` SoC 2% is sent (false 0% sending 2%)
3) Else if `SOC < 99%` real SoC is sent
4) Else if `the battery is fully charged` real SoC is sent
5) Else SoC `98%` is sent
1) If `SOC < 99%` real SoC is sent
2) Else if `the battery is fully charged` real SoC is sent
3) Else SoC `98%` is sent
## RGB LED status
This only applies to boards with an `RGB LED`.
| Color | Status |
| --- | --- |
| $${\color{red}Red}$$ | HA or MQTT KO + CANBUS KO |
| $${\color{green}Green}$$ | HA or MQTT OK + CANBUS KO |
| $${\color{blue}Flashing-Blue}$$ | HA or MQTT KO + CANBUS OK |
| $${\color{cyan}Flashing-Cyan}$$ | HA or MQTT OK + CANBUS OK |
## CAN bus link
@@ -85,9 +99,6 @@ This `5s` delay can be modified in the configuration when importing the canbus p
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# CANBUS vars
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_node1'
@@ -102,8 +113,6 @@ If the inverter does not respond with an `ACK 0x305` within this `5s` delay the
![Image](../../images/YamBMS_BMS_alarms.png "YamBMS_BMS_alarms")
The BMS `errors_bitmask` values ​​are merged and then analyzed continuously **even if the BMS is uncombined**.
If all BMS have alarms, the alarms are sent to the **CAN bus** as `Protection Alarms`.
If at least one BMS has no alarms, the alarms are sent to the CAN bus as `Warning`.
+4 -4
View File
@@ -101,8 +101,8 @@ You can compare `Auto CVL` to cruise control in a car.
## Auto CCL & DCL
> [!IMPORTANT]
> The `Auto CCL` function uses the `OVPR` value of your BMS which must be higher than `cell_bulk_voltage` to work properly. `e.g. for LFP` : CVL=3.45V / OVPR=3.55V / OVP=3.65V.
> The `Auto DCL` function uses the `UVPR` value of your BMS. `e.g. for LFP` : UVPR=3.00V
> The `Auto CCL` function uses the `OVP` value of your BMS.
> The `Auto DCL` function uses the `UVP` value of your BMS.
Regarding the new `Auto Charge/Discharge Current Limit`, this features has been introduced to hopefully prevent `OVP` and `UVP` alarms.
@@ -111,7 +111,7 @@ This should prevent the runner cell from exceeding the max voltage cutoff, but d
You can compare `Auto CCL` to a max speed limiter in a car.
`Auto DCL` works the same way when a cell approaching `UVPR`.
`Auto DCL` works the same way when a cell approaching `UVP + 0.2`.
Current control should work with any inverter that uses `CAN` control.
@@ -123,7 +123,7 @@ These 4 sensors allow you to see what is being requested of your inverter.
In the example below, we are in the `Float` phase at a voltage of `53.6V` and an `Inverter Offset V.` of `0.1V`. The `Requested Charge Voltage` is therefore `53.7V`.
The `Requested Discharge Voltage` is the `UVPR` value of your BMS multiplied by the number of cells, in this example (3V * 16).
The `Requested Discharge Voltage` is the `UVP + 0.2` value of your BMS multiplied by the number of cells, in this example (3V * 16).
The `Requested Charge/Discharge Current` is the `OCP` value of your BMS multiplied by the `Max current` percentage, in this example (150A * 80%).
+250 -148
View File
@@ -1,4 +1,4 @@
# YamBMS - How to create your YamBMS YAML
# YamBMS - How to create your YamBMS YAML (Local Packages examples)
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
@@ -6,6 +6,10 @@
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
> [!TIP]
> Not sure which YAML to choose ? ... `YamBMS_Remote_Packages_example.yaml` is a good basis for creating your custom YAML.
> Examples of BMS imports can be found in the [configuration_examples](configuration_examples/) folder.
> You can mix different BMS models, the only condition is that they are numbered in order starting from `1`.
> [!IMPORTANT]
> BMS monitoring with `Bluetooth` as well as the `Web server` are RAM-intensive components.
@@ -66,7 +70,7 @@ api:
If you don't use `Home Assistant`, you can activate the `Web Server` and have access to YamBMS information and also interact with the application.
[ESPHome Web Server Componenet](https://esphome.io/components/web_server.html)
[ESPHome Web Server Component](https://esphome.io/components/web_server.html)
## Importing YamBMS packages
@@ -76,46 +80,36 @@ Package imports are done below this line:
packages:
```
## Base
In any case, you need to import the base package.
### Base for WiFi
```YAML
device_base: !include packages/base/device_base.yaml
```
### Base for Ethernet
```YAML
device_base: !include packages/base/device_base_ethernet.yaml
```
## Board
Next you need to import the package that corresponds to the `board` you are going to use.
First you need to import the package that corresponds to the `board` you are going to use.
There are other `board.yaml` not mentioned here, see in the [board](../../packages/board/) folder.
So just one of the packages below :
### ESP32 Generic
```YAML
device_board: !include packages/board/board_ESP32_Generic.yaml
```
### ESP32 DevKit-V1
```YAML
device_board: !include packages/board/board_esp32-devkit-v1.yaml
device_board: !include packages/board/board_ESP32_DevKit-V1.yaml
```
### ESP32-S3 DevKitC-1
```YAML
device_board: !include packages/board/board_esp32-s3-devkitc-1.yaml
device_board: !include packages/board/board_ESP32-S3_DevKitC-1.yaml
```
### Atom S3 Lite
```YAML
device_board: !include packages/board/board_atom-s3-lite.yaml
device_board: !include packages/board/board_ESP32-S3_AtomS3-Lite.yaml
```
### Atom S3 / S3R (display)
@@ -124,26 +118,22 @@ In this case you need to specify the `yambms` and `canbus` IDs to display the in
```YAML
device_board: !include
file: packages/board/board_atom-s3.yaml
file: packages/board/board_ESP32-S3_AtomS3.yaml
vars:
yambms_id: 'yambms1'
canbus_id: 'canbus1'
display_auto_next_page_interval: '5s'
```
```YAML
device_board: !include
file: packages/board/board_atom-s3r.yaml
file: packages/board/board_ESP32-S3_AtomS3R.yaml
vars:
yambms_id: 'yambms1'
canbus_id: 'canbus1'
display_auto_next_page_interval: '5s'
```
### ESP32-C3 DevKitM-1
```YAML
device_board: !include packages/board_esp32-c3-devkitm-1.yaml
device_board: !include packages/board_ESP32-C3_DevKitM-1.yaml
```
### ESP32-C3 ETH01-EVO
@@ -151,55 +141,155 @@ In this case you need to specify the `yambms` and `canbus` IDs to display the in
This board has an `Ethernet` port and can be powered from `POE` (optional).
```YAML
device_board: !include packages/board/board_esp32-c3-eth01-evo.yaml
device_board: !include packages/board/board_ESP32-C3_ETH01-EVO.yaml
```
### ESP32 LilyGo T-CAN485
```YAML
device_board: !include packages/board/board_ESP32_LilyGo-T-CAN485.yaml
```
### ESP32-S3 LilyGo T-Connect
```YAML
device_board: !include packages/board/board_ESP32-S3_LilyGo-T-Connect.yaml
```
## YamBMS single-node example
```YAML
shunt1: !include
file: packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml
vars:
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
# other settings
# ...
bms1: !include
file: packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
# other settings
# ...
bms2: !include
file: packages/bms/bms_combine_JBD_UART_full.yaml
vars:
bms_id: '2' # must be a number
bms_name: 'BMS 2'
# other settings
# ...
```
## YamBMS multi-node RS485 modbus example
> [!IMPORTANT]
> The BMS/Shunt IDs of the `modbus client` must match exactly with the BMS/Shunt IDs of the `modbus server` as in the example below.
### YamBMS modbus client `node1`
```YAML
modbus: !include
file: packages/base/device_modbus.yaml
vars:
modbus_role: 'client' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
shunt1: !include
file: packages/shunt/shunt_combine_modbus_client.yaml # a Shunt connected to a node of the RS485 bus
vars:
shunt_id: '1' # must be a number, also represents the modbus server number (200 + shunt_id) !
shunt_name: 'Shunt 1'
bms1: !include
file: packages/bms/bms_combine_modbus_client.yaml # a BMS connected to a node of the RS485 bus
vars:
bms_id: '1' # must be a number, also represents the modbus server number !
bms_name: 'BMS 1'
bms2: !include
file: packages/bms/bms_combine_modbus_client.yaml # a BMS connected to a node of the RS485 bus
vars:
bms_id: '2' # must be a number, also represents the modbus server number !
bms_name: 'BMS 2'
bms3: !include
file: packages/bms/bms_combine_modbus_client.yaml # a BMS connected to a node of the RS485 bus
vars:
bms_id: '3' # must be a number, also represents the modbus server number !
bms_name: 'BMS 3'
```
### ESP32 modbus server `node2`
```YAML
modbus: !include
file: packages/base/device_modbus.yaml
vars:
modbus_role: 'server' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
shunt1: !include
file: packages/shunt/shunt_modbus_Victron_SmartShunt_UART.yaml
vars:
shunt_id: '1' # must be a number, also represents the modbus server number (200 + shunt_id) !
shunt_name: 'Shunt 1'
# other settings
# ...
bms1: !include
file: packages/bms/bms_modbus_JK_UART_4G-GPS_full.yaml
vars:
bms_id: '1' # must be a number, also represents the modbus server number !
bms_name: 'BMS 1'
# other settings
# ...
```
### ESP32 modbus server `node3`
```YAML
modbus: !include
file: packages/base/device_modbus.yaml
vars:
modbus_role: 'server' # client / server
modbus_uart_id: 'uart_esp_1' # RS485 board
bms2: !include
file: packages/bms/bms_modbus_JK_BLE_standard.yaml
vars:
bms_id: '2' # must be a number, also represents the modbus server number !
bms_name: 'BMS 2'
# other settings
# ...
bms3: !include
file: packages/bms/bms_modbus_JK_BLE_standard.yaml
vars:
bms_id: '3' # must be a number, also represents the modbus server number !
bms_name: 'BMS 3'
# other settings
# ...
```
## BMS
> [!IMPORTANT]
> You must number your `BMS` in order starting with the number `1`.
> [!TIP]
> YAML files whose name starts with `bms_combine` are to be used on the main `YamBMS` node connected to your inverter, those whose name starts with `bms_modbus` are to be used on the other nodes connected to the `RS485` bus.
The example YAMLs are just examples, you can mix different BMS models without problems.
There are other `bms.yaml` not mentioned here, see in the [bms](../../packages/bms/) folder.
The `full` / `standard` versions contain all available sensors while the `minimal` version contains the basic sensors without the voltages of each cell and other superfluous sensors.
### Multi-BMS example
```YAML
bms1: !include
file: packages/bms/bms_model.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
# other settings
# ...
bms2: !include
file: packages/bms/bms_model.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# BMS vars
bms_id: '2' # must be a number
bms_name: 'BMS 2'
# other settings
# ...
bms3: !include
file: packages/bms/bms_model.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# BMS vars
bms_id: '3' # must be a number
bms_name: 'BMS 3'
# other settings
# ...
```
### [JK-ALL (BLE)](https://github.com/syssi/esphome-jk-bms)
### [JK-BMS (BLE)](https://github.com/syssi/esphome-jk-bms)
> [!IMPORTANT]
> The BLE software stack on the ESP32 consumes a significant amount of RAM on the device.
@@ -208,54 +298,49 @@ The `full` / `standard` versions contain all available sensors while the `minima
```YAML
bms1: !include
file: packages/bms/bms_JK-ALL_BLE_standard.yaml
file: packages/bms/bms_combine_JK_BLE_standard.yaml # bms_modbus_JK_BLE_standard.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_update_interval: '3s'
bms_combine_interval: '1s'
bms_ble_protocol_version: JK02_32S # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: C8:47:8C:10:7E:AA
bms_ble_protocol_version: 'JK02_32S' # JK02_24S < hardware version 11.0 >= JK02_32S
bms_ble_mac_address: 'C8:47:8C:10:7E:AA' # Your MAC address
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
```
### [JK-B (UART)](https://github.com/syssi/esphome-jk-bms)
### [JK-BMS (UART 4G-GPS)](https://github.com/syssi/esphome-jk-bms)
[How to make the UART connection with the ESP32.](BMS_JK-B_UART_solution.md)
```YAML
bms1: !include
file: packages/bms/bms_JK-B_UART_full.yaml
file: packages/bms/bms_combine_JK_UART_4G-GPS_full.yaml # bms_modbus_JK_UART_4G-GPS_full.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_update_interval: '3s'
bms_combine_interval: '1s'
bms_uart_id: uart_esp_1
bms_uart_id: 'uart_esp_1'
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
```
### [JK-B (RS485 DISPLAY)](https://github.com/syssi/esphome-jk-bms)
### [JK-BMS (RS485 DISPLAY)](https://github.com/syssi/esphome-jk-bms)
> [!CAUTION]
> The `jk_bms_display` component does not provide all the information needed for an optimal operation of `YamBMS`.
> The missing information has been added in the code by fixed values.
> e.g. it's not possible to know if the BMS is `online` or if the BMS is `equalizing` the cells.
[How to make the RS485 connection with the ESP32.](BMS_JK-B_RS485_DISPLAY_solution.md)
```YAML
bms1: !include
file: packages/bms/bms_JK-B_RS485_DISPLAY_full.yaml
file: packages/bms/bms_combine_JK_RS485_DISPLAY_full.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_update_interval: '3s'
bms_combine_interval: '1s'
bms_uart_id: uart_esp_1
bms_uart_id: 'uart_esp_1'
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
@@ -264,13 +349,21 @@ The `full` / `standard` versions contain all available sensors while the `minima
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
```
### [JK-PB (RS485)](https://github.com/txubelaxu/esphome-jk-bms/)
### [JK-BMS (RS485 Modbus)](https://github.com/txubelaxu/esphome-jk-bms/)
> [!TIP]
> Compatible with JK-PB, JK-B HW. >= 11A
A single `RS485 bus` allows you to monitor up to `16` BMS.
#### JK-PB sniffer
[How to make the RS485 connection with the ESP32.](BMS_JK-PB_RS485_solution.md)
#### JK sniffer
> [!IMPORTANT]
> You need to import only one `sniffer` package of your choice.
@@ -283,7 +376,7 @@ Sniffer without `talk_pin` :
```YAML
sniffer1: !include
file: packages/bms/bms_JK-PB_RS485_sniffer.yaml
file: packages/bms/bms_combine_JK_RS485_Modbus_sniffer.yaml
vars:
sniffer_id: 'sniffer1'
sniffer_protocol: 'JK02_32S'
@@ -294,7 +387,7 @@ If your `RS485` board requires a `talk_pin` you must specify which `GPIO` will b
```YAML
sniffer1: !include
file: packages/bms/bms_JK-PB_RS485_sniffer_talk_pin.yaml
file: packages/bms/bms_combine_JK_RS485_Modbus_sniffer_talk_pin.yaml
vars:
sniffer_id: 'sniffer1'
sniffer_protocol: 'JK02_32S'
@@ -302,40 +395,31 @@ If your `RS485` board requires a `talk_pin` you must specify which `GPIO` will b
sniffer_talk_pin: 8 # ESP32: 4, ESP32-S3: 8, ESP32-C3: 10
```
#### JK-PB BMS
#### JK-BMS (JK-PB, JK-B HW. >= 11A)
```YAML
# Mode2 : configure the DIP switches of your BMS from 0x01 to 0x0F (don't use the 0x00 address, maximum 15 BMS)
bms1: !include
file: packages/bms/bms_JK-PB_RS485_bms_full.yaml
file: packages/bms/bms_combine_JK_RS485_Modbus_bms_full.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# Sniffer ID
sniffer_id: 'sniffer1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'JK-BMS 1'
bms_rs485_address: '0x01' # BMS 1 DIP switch
bms_update_interval: '3s' # going below '3s' can cause problems
bms_combine_interval: '1s'
bms_address: '0x01' # BMS 1 DIP switch
```
### [JBD (UART)](https://github.com/syssi/esphome-jbd-bms)
```YAML
bms1: !include
file: packages/bms/bms_JBD_UART_full.yaml
file: packages/bms/bms_combine_JBD_UART_full.yaml # bms_modbus_JBD_UART_full.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_update_interval: '3s'
bms_combine_interval: '1s'
bms_uart_id: uart_esp_1
bms_rx_timeout: 150ms
bms_uart_id: 'uart_esp_1'
bms_rx_timeout: '150ms'
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
@@ -344,6 +428,31 @@ If your `RS485` board requires a `talk_pin` you must specify which `GPIO` will b
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
```
### [JBD (BLE)](https://github.com/syssi/esphome-jbd-bms)
```YAML
bms1: !include
file: packages/bms/bms_combine_JBD_BLE_full.yaml # bms_modbus_JBD_UART_full.yaml
vars:
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_ble_mac_address: 'C8:47:8C:10:7E:AA' # Your MAC address
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
bms_max_charge_current: '100' # A. Used to calculate maximum charge current
bms_max_discharge_current: '100' # A. Used to calculate maximum discharge current
bms_cell_ovp: '3.650' # V. Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V. Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V. Used by 'Auto CVL' functions
# Maximum cell charging cycles is used to calculate the battey SoH.
# MB31=8000.0, LF280K v3=8000.0, LF280K v2=6000.0, LF280=3000.0 (decimal is required)
bms_cell_max_cycles: '6000.0'
```
### [Seplos V1/V2 (RS485)](https://github.com/syssi/esphome-seplos-bms)
@@ -363,31 +472,27 @@ A single `RS485 bus` allows you to monitor up to `16` BMS.
```YAML
seplos_modbus1: !include
file: packages/bms/bms_SEPLOS_V1_V2_RS485_modbus.yaml
file: packages/bms/bms_combine_SEPLOS_V1_V2_RS485_modbus.yaml
vars:
seplos_modbus_id: 'seplos_modbus1'
seplos_modbus_uart_id: 'uart_esp_1'
seplos_modbus_baud_rate: '9600' # Please set the baudrate of your Seplos BMS model here. It's sometimes 19200 baud instead of 9600.
seplos_modbus_rx_timeout: 150ms
seplos_modbus_baud_rate: '9600' # 9600 / 19200 ; please set the baudrate of your Seplos BMS model here
seplos_modbus_rx_timeout: '150ms'
```
#### Seplos V1/V2 BMS
```YAML
bms1: !include
file: packages/bms/bms_SEPLOS_V1_V2_RS485_bms_full.yaml
file: packages/bms/bms_combine_SEPLOS_V1_V2_RS485_bms_full.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# Seplos modbus ID
seplos_modbus_id: 'seplos_modbus1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_rs485_address: '0x01' # BMS 1 DIP switch
bms_address: '0x01' # BMS 1 DIP switch
bms_protocol_version: '0x20' # Known protocol versions: 0x20 (Seplos), 0x26 (Boqiang)
bms_update_interval: '3s' # 10s @syssi example
bms_combine_interval: '1s'
# Required settings cannot be retrieved from BMS
# These values ​​must match your BMS settings
# LFP values example
@@ -400,22 +505,26 @@ A single `RS485 bus` allows you to monitor up to `16` BMS.
## Shunt
> [!IMPORTANT]
> You must number your `Shunt` in order starting with the number `1`.
> [!TIP]
> YAML files whose name starts with `shunt_combine` are to be used on the main `YamBMS` node connected to your inverter, those whose name starts with `shunt_modbus` are to be used on the other nodes connected to the `RS485` bus.
As soon as you import a `Shunt` and it can be combined ([see condition](YamBMS_behavior.md#shunt)) the values ​​`Voltage`, `Current`, `Power` and `SoC` of the shunt(s) will take precedence over the BMS values.
### [Victron Smartshunt (UART)](https://github.com/KinDR007/VictronMPPT-ESPHOME)
[How to make the UART connection with the ESP32.](Shunt_Victron_SmartShunt_HowTo.md)
```YAML
shunt1: !include
file: packages/shunt/shunt_victron_smartshunt_UART.yaml # shunt_junctek_khf_UART.yaml
file: packages/shunt/shunt_combine_Victron_SmartShunt_UART.yaml # shunt_modbus_Victron_SmartShunt_UART.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# Shunt vars
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
shunt_update_interval: '3s'
shunt_combine_interval: '1s'
shunt_uart_id: uart_esp_1
shunt_uart_id: 'uart_esp_1'
```
### [Victron Smartshunt (BLE)](https://github.com/Fabian-Schmidt/esphome-victron_ble)
@@ -425,18 +534,15 @@ As soon as you import a `Shunt` and it can be combined ([see condition](YamBMS_b
> Crashes are likely to occur if you include too many additional components in your device’s configuration.
> I recommend using `UART` or `RS485` if possible.
[How to make the BLE connection with the ESP32.](Shunt_Victron_SmartShunt_HowTo.md)
```YAML
shunt1: !include
file: packages/shunt/shunt_victron_smartshunt_BLE.yaml
file: packages/shunt/shunt_combine_Victron_SmartShunt_BLE.yaml # shunt_modbus_Victron_SmartShunt_BLE.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# Shunt vars
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
shunt_update_interval: '3s'
shunt_combine_interval: '1s'
shunt_mac_address: '60:A4:23:91:8F:55'
shunt_mac_address: '60:A4:23:91:8F:55' # Your MAC address
shunt_encryption_key: '0df4d0395b7d1a876c0c33ecb9e70dcd' # Your encryption key
```
@@ -444,20 +550,18 @@ As soon as you import a `Shunt` and it can be combined ([see condition](YamBMS_b
```YAML
shunt1: !include
file: packages/shunt/shunt_junctek_khf_UART.yaml
file: packages/shunt/shunt_combine_Junctek_KHF_UART.yaml # shunt_modbus_Junctek_KHF_UART.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to send information to
# Shunt vars
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
shunt_update_interval: '3s'
shunt_combine_interval: '1s'
shunt_uart_id: uart_esp_1
shunt_uart_id: 'uart_esp_1'
```
## YamBMS
> [!TIP]
> This package is only used with the `YamBMS` main node.
> [!CAUTION]
> By default, `YamBMS` is configured with the values ​​for a 16S LFP battery !
@@ -468,8 +572,6 @@ Take the time to configure `YamBMS` correctly according to your battery chemistr
file: packages/yambms/yambms.yaml
vars:
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
@@ -491,12 +593,14 @@ Take the time to configure `YamBMS` correctly according to your battery chemistr
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# Maximum charging cycles is used to calculate the battey SOH, LF280K v3 =8000.0, LF280K v2 =6000.0, LF280=3000.0 (decimal is required)
yambms_max_cycles: '6000.0'
```
## CAN bus
> [!TIP]
> This package is only used with the `YamBMS` main node.
> It's possible to use this package multiple times in order to send information on two different CAN bus.
The CAN bus connected to your inverter via the CAN transceiver `canbus_node1`.
You can keep the default configuration.
@@ -505,12 +609,10 @@ You can keep the default configuration.
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to retrieve information from
# CANBUS vars
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_node1'
canbus_node_id: 'canbus_inverter_1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
@@ -0,0 +1,11 @@
# YamBMS - JK-PB BMS RS485 Solution
[![Badge License: GPLv3](https://img.shields.io/badge/License-GPLv3-brightgreen.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Badge Version](https://img.shields.io/github/v/release/Sleeper85/esphome-yambms?include_prereleases&color=yellow&logo=DocuSign&logoColor=white)](https://github.com/Sleeper85/esphome-yambms/releases/latest)
![GitHub stars](https://img.shields.io/github/stars/Sleeper85/esphome-yambms)
![GitHub forks](https://img.shields.io/github/forks/Sleeper85/esphome-yambms)
![GitHub watchers](https://img.shields.io/github/watchers/Sleeper85/esphome-yambms)
## Titre
Each shunt/bms turns into a modbus server with its own address. The max number of BMS per ESP32 (UART/BLE) is 2 but you can use one ESP32 per battery if you want.
Binary file not shown.
Binary file not shown.

Before

Width:  |  Height:  |  Size: 441 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 387 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 371 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 587 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 176 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 527 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 223 KiB

After

Width:  |  Height:  |  Size: 239 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 600 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 500 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 424 KiB

After

Width:  |  Height:  |  Size: 424 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 423 KiB

After

Width:  |  Height:  |  Size: 423 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 352 KiB

After

Width:  |  Height:  |  Size: 352 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 431 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 339 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 575 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 90 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 468 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 486 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 408 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 185 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 197 KiB

After

Width:  |  Height:  |  Size: 184 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 364 KiB

After

Width:  |  Height:  |  Size: 486 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 152 KiB

After

Width:  |  Height:  |  Size: 154 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 154 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 100 KiB

-246
View File
@@ -1,246 +0,0 @@
# Updated : 2024.11.11
# Version : 1.5.1
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
substitutions:
name: yambms-demo
# Don't forget to configure your WiFi credentials in the secrets.yaml file
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: DEBUG # DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
#web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
device_base: !include packages/base/device_base.yaml
# Board : uncomment your board
device_board: !include packages/board/board_esp32-devkit-v1.yaml
# device_board: !include packages/board/board_esp32-s3-devkitc-1.yaml
# device_board: !include packages/board/board_atom-s3-lite.yaml
# device_board: !include
# file: packages/board/board_atom-s3.yaml # board_atom-s3r.yaml
# vars:
# yambms_id: 'yambms1'
# canbus_id: 'canbus1'
# display_auto_next_page_interval: '5s'
shunt1: !include
file: packages/shunt/shunt_fake.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# Shunt vars
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
shunt_update_interval: '3s'
shunt_combine_interval: '1s'
# Shunt sensors values
shunt_voltage: '53.41' # V
shunt_current: '37.5' # A
shunt_power: '2003' # W
shunt_soc: '86' # %
bms1: !include
file: packages/bms/bms_FAKE.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_update_interval: '3s'
bms_combine_interval: '1s'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '243' # Ah
bms_voltage: '53.45' # V
bms_current: '9.2' # A
bms_power: '492' # W
bms_soc: '87' # %
bms_min_cell_voltage: '3.339' # V
bms_min_voltage_cell: '2' # cell number 1~16
bms_max_cell_voltage: '3.341' # V
bms_max_voltage_cell: '11' # cell number 1~16
bms_temperature_sensor_1: '21.1' # °C
bms_temperature_sensor_2: '21.3' # °C
bms_temperature_sensor_3: '21.5' # °C
bms_temperature_sensor_4: '21.7' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '178' # charging cycles number Used to calculate the SoH
bms2: !include
file: packages/bms/bms_FAKE.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_update_interval: '3s'
bms_combine_interval: '1s'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '238' # Ah
bms_voltage: '53.41' # V
bms_current: '11.3' # A
bms_power: '604' # W
bms_soc: '85' # %
bms_min_cell_voltage: '3.337' # V
bms_min_voltage_cell: '14' # cell number 1~16
bms_max_cell_voltage: '3.339' # V
bms_max_voltage_cell: '3' # cell number 1~16
bms_temperature_sensor_1: '21.8' # °C
bms_temperature_sensor_2: '21.6' # °C
bms_temperature_sensor_3: '21.4' # °C
bms_temperature_sensor_4: '21.2' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '226' # charging cycles number Used to calculate the SoH
bms3: !include
file: packages/bms/bms_FAKE.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# BMS vars
bms_id: '3' # must be a number
bms_name: 'BMS 3'
bms_update_interval: '3s'
bms_combine_interval: '1s'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '232' # Ah
bms_voltage: '53.37' # V
bms_current: '15.7' # A
bms_power: '838' # W
bms_soc: '83' # %
bms_min_cell_voltage: '3.334' # V
bms_min_voltage_cell: '7' # cell number 1~16
bms_max_cell_voltage: '3.336' # V
bms_max_voltage_cell: '9' # cell number 1~16
bms_temperature_sensor_1: '21.9' # °C
bms_temperature_sensor_2: '22.0' # °C
bms_temperature_sensor_3: '22.1' # °C
bms_temperature_sensor_4: '22.2' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '194' # charging cycles number Used to calculate the SoH
yambms1: !include
file: packages/yambms/yambms.yaml
vars:
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# Maximum charging cycles is used to calculate the battey SOH, LF280K v3 =8000.0, LF280K v2 =6000.0, LF280=3000.0 (decimal is required)
yambms_max_cycles: '6000.0'
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to retrieve information from
# CANBUS vars
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_node1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
-242
View File
@@ -1,242 +0,0 @@
# Updated : 2024.11.11
# Version : 1.5.1
# GitHub : https://github.com/Sleeper85/esphome-yambms
# YamBMS ( Yet another multi-BMS Merging Solution )
# This YAML is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/gpl.html>.
substitutions:
name: yambms-demo
# Don't forget to configure your WiFi credentials in the secrets.yaml file
#
# If needed, configure a static IP here
# wifi:
# manual_ip:
# static_ip: 192.168.0.85
# gateway: 192.168.0.1
# subnet: 255.255.255.0
# dns1: 8.8.8.8
# dns2: 8.8.4.4
logger:
level: DEBUG # DEBUG / INFO / WARN
ota:
platform: esphome
# Please use the native `api` component instead of the `mqtt` section.
# If you use Home Assistant, the native API is more lightweight.
# If there is no HA server connected to this API, the ESP32 reboots every 15 minutes to try to resolve the problem.
# The "reboot_timeout: 0s" option will keep your ESP32 up and running even if you lose connection to your HA server.
api:
reboot_timeout: 0s
# If you don't want to use ESPHome's native API you can use MQTT instead.
# In this case don't forget to remove the 'api:' section.
# mqtt:
# broker: !secret mqtt_host
# username: !secret mqtt_username
# password: !secret mqtt_password
# id: mqtt_client
# Please note that enabling this component will take up a lot of memory and may decrease
# stability and be the cause of reboot depending on the capabilities of the board used.
#web_server:
# port: 80
# log: false
# ota: false
# +--------------------------------------+
# | Packages |
# +--------------------------------------+
# PLEASE READ : https://github.com/Sleeper85/esphome-yambms/blob/main/documents/README/YamBMS_main_YAML_HowTo.md
packages:
device_base: !include packages/base/device_base.yaml
device_board: !include
file: packages/board/board_atom-s3.yaml # board_atom-s3r.yaml
vars:
yambms_id: 'yambms1'
canbus_id: 'canbus1'
display_auto_next_page_interval: '5s'
shunt1: !include
file: packages/shunt/shunt_fake.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# Shunt vars
shunt_id: '1' # must be a number
shunt_name: 'Shunt 1'
shunt_update_interval: '3s'
shunt_combine_interval: '1s'
# Shunt sensors values
shunt_voltage: '53.41' # V
shunt_current: '37.5' # A
shunt_power: '2003' # W
shunt_soc: '86' # %
bms1: !include
file: packages/bms/bms_FAKE.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# BMS vars
bms_id: '1' # must be a number
bms_name: 'BMS 1'
bms_update_interval: '3s'
bms_combine_interval: '1s'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '243' # Ah
bms_voltage: '53.45' # V
bms_current: '9.2' # A
bms_power: '492' # W
bms_soc: '87' # %
bms_min_cell_voltage: '3.339' # V
bms_min_voltage_cell: '2' # cell number 1~16
bms_max_cell_voltage: '3.341' # V
bms_max_voltage_cell: '11' # cell number 1~16
bms_temperature_sensor_1: '21.1' # °C
bms_temperature_sensor_2: '21.3' # °C
bms_temperature_sensor_3: '21.5' # °C
bms_temperature_sensor_4: '21.7' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '178' # charging cycles number Used to calculate the SoH
bms2: !include
file: packages/bms/bms_FAKE.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# BMS vars
bms_id: '2' # must be a number
bms_name: 'BMS 2'
bms_update_interval: '3s'
bms_combine_interval: '1s'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '238' # Ah
bms_voltage: '53.41' # V
bms_current: '11.3' # A
bms_power: '604' # W
bms_soc: '85' # %
bms_min_cell_voltage: '3.337' # V
bms_min_voltage_cell: '14' # cell number 1~16
bms_max_cell_voltage: '3.339' # V
bms_max_voltage_cell: '3' # cell number 1~16
bms_temperature_sensor_1: '21.8' # °C
bms_temperature_sensor_2: '21.6' # °C
bms_temperature_sensor_3: '21.4' # °C
bms_temperature_sensor_4: '21.2' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '226' # charging cycles number Used to calculate the SoH
bms3: !include
file: packages/bms/bms_FAKE.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1'
# BMS vars
bms_id: '3' # must be a number
bms_name: 'BMS 3'
bms_update_interval: '3s'
bms_combine_interval: '1s'
# BMS sensors values
bms_battery_capacity: '280' # Ah
bms_battery_capacity_remaining: '232' # Ah
bms_voltage: '53.37' # V
bms_current: '15.7' # A
bms_power: '838' # W
bms_soc: '83' # %
bms_min_cell_voltage: '3.334' # V
bms_min_voltage_cell: '7' # cell number 1~16
bms_max_cell_voltage: '3.336' # V
bms_max_voltage_cell: '9' # cell number 1~16
bms_temperature_sensor_1: '21.9' # °C
bms_temperature_sensor_2: '22.0' # °C
bms_temperature_sensor_3: '22.1' # °C
bms_temperature_sensor_4: '22.2' # °C
bms_max_charge_current: '100' # A
bms_max_discharge_current: '100' # A
bms_cell_ovp: '3.650' # V Used by 'Auto CCL' functions
bms_cell_uvp: '2.800' # V Used by 'Auto DCL' functions and to calculate maximum discharge voltage
bms_balance_trigger_voltage: '0.010' # V Used by 'Auto CVL' functions
bms_charging_cycles: '194' # charging cycles number Used to calculate the SoH
yambms1: !include
file: packages/yambms/yambms.yaml
vars:
# Please read the cut-off charging logic README to understand how the YamBMS works
yambms_id: 'yambms1'
yambms_name: 'YamBMS 1'
yambms_update_interval: '1s'
# Input numbers can be displayed as a slider or an input box, options are 'slider' or 'box'.
yambms_input_number_mode: 'slider'
# Please check and fill in the options below correctly according to your battery chemistry and number of cells in series.
# These parameters are important and used for charging logic.
# Battery Chemistry
yambms_battery_chemistry: '1' # 1-LFP | 2-Li-ion | 3-LTO
# Number of cells in series
yambms_cell_count: '16'
# Bulk / Absorption Voltage : corresponds to the Bulk voltage that will be used to charge the battery. (LFP : 55.2V = 3.45V/Cell for 16S battery)
yambms_bulk_v: '55.2'
# Float Voltage : corresponds to the voltage at which the battery would be maintained at the end of charge. (LFP : 53.6V = 3.35V/Cell for 16S battery)
yambms_float_v: '53.6'
# Rebulk voltage, voltage from which a new Bulk charge can start. (LFP : 52.8V = 3.3V/Cell for 16S battery)
yambms_rebulk_v: '52.8'
# Maximum time in minutes that the cut-off step can last before charging is complete
# If your cells are properly balanced this step ends at the fastest after the `cut-off timer`
# This timer can be deactivated with a switch
yambms_eoc_timer: '30'
# Time in seconds during which the end of charge conditions must be respected (cut-off + cells not equalizing)
yambms_cutoff_timer: '60'
# Maximum charging cycles is used to calculate the battey SOH, LF280K v3 =8000.0, LF280K v2 =6000.0, LF280=3000.0 (decimal is required)
yambms_max_cycles: '6000.0'
canbus1: !include
file: packages/yambms/yambms_canbus.yaml
vars:
# YamBMS ID
yambms_id: 'yambms1' # YamBMS ID to retrieve information from
# CANBUS vars
canbus_id: 'canbus1'
canbus_name: 'CANBUS 1'
canbus_node_id: 'canbus_node1'
canbus_light_id: 'esp_light'
# The CANBUS link will be considered down if no response from the inverter (ID 0x305) for 5s
# The Deye inverter sends the ACK (can_id 0x305) only when it receives the can_id 0x356
canbus_link_timer: '5s'
# +--------------------------------------+
# | DEBUG ( logger level must be DEBUG ) |
# +--------------------------------------+
device_debug: !include
file: packages/base/device_debug_ESP32.yaml
vars:
debug_name: 'Debug'
debug_update_interval: '5s'
Loaded 100 of 252 files, more files were not shown because too many files have changed in this diff. Show more