Open WoeMat opened 2 years ago
just looking at request/response it seems like its not reading enough data (the data length being sent back from the device is 27 (1B hex) yet only 6 bytes (of data) were read (short read) and no checksum bytes.
Check and re-check your serial connection - you definitely need ground and cross TX/RX.
Yes, that's exactly whats wondering me. Can I somehow change the serial timeout settings? Maybe the software stops reading because it takes too long. I also have Node-Red running on that Pi and if I send the command there I recieve the complete Answer without changing anything on the Hardware.
That definitely looks like the correct data being returned. What settings are you using in node-red?
You can set the serial params when specifying the device:
-t serial:(device), baud rate, data bits, parity, stop bits, vmin, vtime
baud = 1200 to 4000000 data bits = 8 parity = N)one, E)ven, O)dd stop bits = 1 to 8 vmin = 0-9999 vtime = 0-9999
VMIN Minimum number of characters for noncanonical read VTIME Timeout in deciseconds for noncanonical read
for example: jbdtool -t serial:/dev/ttyS0,9600,8,N,1,0,15
If all else fails, you can modify serial.c, line 415 and 416:
from: tv.tv_usec = 500000; tv.tv_sec = 0;
to: tv.tv_usec = 0; tv.tv_sec = 1;
and see if that works. I just looked at the serial code ... its kind of messy.
did this work for you?
Hi there. I'm also working on my powerwall and I'm also using some JBD BMS (mine have firmware version 22). I could compile an install jbdtools and if I use the serial connector I can also read data from the BMS but somehow it is not being displayed.
If I read the datat with the -r -a options I get everything on screen.