-
-
Notifications
You must be signed in to change notification settings - Fork 175
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 JK-PB bms compatibility. Target: 1 ESP in a "listening mode" connected to RS485 network. #464
base: main
Are you sure you want to change the base?
Conversation
JK-PB2A16S-20P model jk-bms. Two bms connected to that RS485 internal network. ubuntu connected in a "listening mode" using a USB<->RS485 adaptor.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have installed clang-format (v14 now)
I have created a new component: "jk_rs485". It is for JK-PB HW v14. To compile: Pending:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I have changed erroneusly components/jk_bms_ble/jk_bms_ble.cpp file.
I do know how to solve this error.
Other changes are new files.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Something wrong here?
It is marked as failed.
I will have a look as soon as possible. Please give me some time! :-) |
Sorry!! I am very newbie at github. |
No problem. Feel free to ask any questions. |
Many thanks, Sebastian. Certainly, I do not know how to manage/arrange the "code + configuration.yaml" to demultiplex the info arraiving from RS485. So, I have got the info about every BMS connected to the RS485 network (it does not matter how many are: max 16). I know how to pass the UART information to the jk_rs485 component (but only one). But I have achieve the goal of sharing the same UART with two jk_rs485 components. I would like to:
I do not know if this is possible. Many thanks!! |
any chance you could put a wiring diagram together so I can test with my 3 new JK BMS? |
|
Which Ethernet wires go to tx and rx on the ESP board? |
|
it is not ethernet. It is RS485, ok? |
USB plugs into the ESP32 dev board and RJ45 into the RS485 port in the inverter? |
Sorry my mistake. Forget my previous answer.
ESP TXRX to a serial2RS485 converter. From this converter to the right (any
of the two) existing RJ45 connectors.
|
Can you point to a code that should be loaded to ESPHome please? |
@txubelaxu Hi! I'm trying to understand your project and if I understood correctly, you connect the inverter to the battery via rs485 via CAN bus and simultaneously receive data from the inverter also via rs485 or is it not quite like that? |
See esp32-S3-example-jkpb-rs485_0master_2slaves.yaml or esp32-S3-example-jkpb-rs485_0master_7slaves.yaml. Those examples has been adapted with this change.
Since the last changes I cannot update: Compiling .pioenvs/jkbms/src/esphome/components/jk_rs485_bms/jk_rs485_bms.o Please also update your 1 master multiple slave examples, seems those are not working anymore either |
@brycelarge Did you try a |
Yes I did but still get that issue. INFO ESPHome 2024.8.0 Compiling .pioenvs/jkbms/src/esphome/components/esp32/gpio.o |
same here: i added for the last updates "broadcast_to_all_bms: True" and that was fine but after the latest updates of ESPHome it is an invalid option. But commenting this offers more errors :( |
Im still getting this error: In file included from src/esphome/components/jk_rs485_bms/jk_rs485_bms.cpp:1: I'm using 1 master and multiple slaves. I have cleaned build files, also physically SSH into esphome container and deleted all the files in the components dir but still the same error persists. Any ideas? |
…) of BMS at address 0x01???
… elements array in jk_rs485_bms.h, despite that array is unused...
…ettings info to cell info to avoid availability problems.
…ded to put a BMS device unavailable.
… from uint32_t to uint16_t and from int32_t to int16_t
JK-PB2A16S-20P model jk-bms.
Two bms connected to that RS485 internal network.
ubuntu connected in a "listening mode" using a USB<->RS485 adaptor.