bmspy/README.md

29 lines
1.1 KiB
Markdown
Raw Normal View History

2021-02-03 11:19:58 +00:00
# bmspy
bmspy is a tool to get information from a [xiaoxiang-type](https://www.lithiumbatterypcb.com/product/4s-or-3s-12v-li-ion-or-lifepo4-battery-smart-bms-with-bluetooth-function-uart-and-rs485-communication-with-60a-to-120a-constant-current/?attribute_specification-selection=4S+Lifepo4+120A+with+UART+and+RS485) BMS system, using some sort of serial connection.
2021-02-03 11:23:18 +00:00
It can display the information as text, in JSON, or export the data continuously to a Prometheus exporter.
2024-03-19 20:28:06 +00:00
To install:
git clone https://git.treehouse.org.za/tim/bmspy
cd bmspy
poetry install
Or, to install with influxdb and/or prometheus support:
poetry install -E influxdb -E prometheus
To run:
poetry run bmspyd &
Or to run via systemd, copy bmspyd.service to /etc/systemd/system, adjust WorkingDirectory to point to the installation location, and enable and start the service:
cp bmspy-server.service /etc/systemd/system
$EDITOR /etc/systemd/system/bmspy-server.service
systemctl daemon-reload
systemctl enable bmspy-server
systemctl start bmspy-server
To run a client to get the data, choose one of the following options:
2024-03-19 20:28:06 +00:00
poetry run bmspy
poetry run bmspy-influxdb --url ...