Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Seplos V3 SP5* detection pattern #143

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ This integration allows to monitor Bluetooth Low Energy (BLE) battery management
- Offgridtec LiFePo4 Smart Pro: type A & B (show up as `SmartBat-A`… or `SmartBat-B`…)
- LiTime, Power Queen, and Redodo batteries
- Seplos v2 (show up as `BP0?`)
- Seplos v3 (show up as `SP0`…, `SP1`…, or `SP6`…)
- Seplos v3 (show up as `SP0`…, `SP1`…, `SP5`…, or `SP6`…)
- TDT BMS (show up as e.g., `XDZN`…)

> [!TIP]
Expand Down
4 changes: 4 additions & 0 deletions custom_components/bms_ble/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@
"local_name": "SP1*",
"service_uuid": "0000fff0-0000-1000-8000-00805f9b34fb"
},
{
"local_name": "SP5*",
"service_uuid": "0000fff0-0000-1000-8000-00805f9b34fb"
},
{
"local_name": "SP6*",
"service_uuid": "0000fff0-0000-1000-8000-00805f9b34fb"
Expand Down
2 changes: 1 addition & 1 deletion custom_components/bms_ble/plugins/seplos_bms.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def matcher_dict_list() -> list[dict[str, Any]]:
"service_uuid": BMS.uuid_services()[0],
"connectable": True,
}
for pattern in ["SP0*", "SP1*", "SP6*"]
for pattern in ["SP0*", "SP1*", "SP5*", "SP6*"]
]

@staticmethod
Expand Down
13 changes: 13 additions & 0 deletions tests/advertisement_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,19 @@
),
"seplos_bms",
),
( # source bluetoothctl (https://github.com/patman15/BMS_BLE-HA/issues/142)
generate_advertisement_data(
local_name="SP51B2407270006 ",
service_uuids=[
"00001800-0000-1000-8000-00805f9b34fb",
"00001801-0000-1000-8000-00805f9b34fb",
"0000fff0-0000-1000-8000-00805f9b34fb",
"02f00000-0000-0000-8000-00000000fe00"
],
rssi=-46,
),
"seplos_bms",
),
( # source LOG
generate_advertisement_data(
local_name="SP66B2404270002 ",
Expand Down
Loading