Skip to content

JK-PB2 #529

@GrinchUA

Description

@GrinchUA

Hi, JK-PB2A16S-20P BMS appeared

I'm trying to connect to it using:

jkbms -P JKPB -p 98:DA:20:06:30:AA

But I was getting an error

2025-04-07 15:58:05,565:DEBUG:abstractprotocol:get_command_defn@73: Found command getBalancerData in protocol b'JKPB' Traceback (most recent call last): File "/home/barbitura/.env/bin/jkbms", line 8, in <module> sys.exit(main()) ^^^^^^ File "/home/barbitura/.env/lib/python3.11/site-packages/mppsolar/__init__.py", line 442, in main results = _device.run_command(command=_command) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/barbitura/.env/lib/python3.11/site-packages/mppsolar/devices/device.py", line 92, in run_command raw_response = self._port.send_and_receive( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/barbitura/.env/lib/python3.11/site-packages/mppsolar/inout/jkbleio.py", line 38, in send_and_receive record_type = command_defn["record_type"] ~~~~~~~~~~~~^^^^^^^^^^^^^^^ KeyError: 'record_type'

After I added "record_type": "2", in to https://github.com/jblance/mpp-solar/blob/0.16.55/mppsolar/protocols/jkpb.py#L22
I started getting an error

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions