Feature: add daren 485v2 / SNS01 BMS support #168
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
So apparently PAPOOL switched either the supplier who they are sourcing complete battery modules from or the BMS manufacturer they are putting in their batteries. The first batteries they shipped were Daren based but the newer batteries they are shipping now indicate:
INFO:SerialBattery:get_serial: CER2408-04
INFO:SerialBattery:set hardware_version: SNS01 16S100A Ho20-T1 02.02.01
Other notable differences are 2 RS485 ports and a third 485/CAN port. RJ45 Wiring pinout is slightly different to the older Daren BMS as well but they are cross compatible (share pins 1 and 7 commonality). The OSD has changed as well:
I'm not sure if we should call these new bms SNS01, Ho20, or something else but for now this WIP PR proposes to add a new module which is fully working and based on the Daren485 module because this new BMS is largely similar just with some data moved around and placed slightly differently than the Daren boards.
I have not opened up this new battery yet so I really don't have a clue if the board is the same manufacturer as the Daren boards so I am not exactly sure how to call it. I basically figured out how to get communication working with it by sniffing commands sent from the new DrStartApp to the newer module and then sort of reverse engineered it from there to realize that there were only very minor differences between the Daren protocol and this one. Hence my decision to name it Daren485v2.
Mainly the differences are what seems to me to be a possible abandonment of the CID1 relevance (other than something needs to fill that byte) and a new SOI byte. There are some other subtle differences that might escape me but generally i think the protocol is mostly compatible other than the most important thing:
They switched from 19200 to 9600 baud ???
So... the need for a new module for these boards seems necessary to me. And here it is...
I will mark this PR as a draft PR for now so that the maintainers can suggest nomenclature changes if desired and give feedback.. but this module has been running stable now for about 12 hours now... seems quite happy and stable.
Just diff the daren_485.py file against this sns01_485.py one if you want to understand how this battery slightly differs from the older ones. 👍
PS. I will add the other MD file updates after we decide what to call this battery etc...