Skip to content
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

Daly BMS to Solis inverter. #81

Open
DMIINC opened this issue Nov 10, 2024 · 96 comments
Open

Daly BMS to Solis inverter. #81

DMIINC opened this issue Nov 10, 2024 · 96 comments

Comments

@DMIINC
Copy link
Contributor

DMIINC commented Nov 10, 2024

As a title say. What can be done and what would you need?
Nice project you got going. Sorry if I did not read everything and possibly asking this question the wrong way.

Thanks,

@ai-republic
Copy link
Owner

Which communication (CAN/RS485/ModBus) does your Solis inverter support?

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 11, 2024

CAN/RS485
Solis S6-EH1P11.4K-H-US
I do have what appears to be communication manual
Thank you

@ai-republic
Copy link
Owner

@DMIINC could you please attach the communications protocol so that I can check?

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 14, 2024

@ai-republic
Copy link
Owner

ai-republic commented Nov 16, 2024

Hi @DMIINC,
I had a look at the communication specification but it does not specify any BMS data that is passed.
I also had a look at the inverter data sheet and the battery compatibility sheet:
Compatibility_List_Solis_S6_Hybrid_v2,4_08,23,23.pdf

This states that it supports the Pylontech. Have you tried to configure the PYLON_HV_CAN binding for your inverter? I think that should work. You might have to do a corresponding configuration in your Solis inverter.

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 19, 2024

Ok. Will try here in day or two. I will report my findings here. Thank you .

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 22, 2024

2024-11-21 20:33:27.904 | INFO | Thread-2 | toinverter.core.Port:111 | Opening can_0 ...
2024-11-21 20:33:27.905 | ERROR | Thread-2 | toinverter.core.Port:116 | Opening port can_0 FAILED!
tel.schich.javacan.platform.linux.LinuxNativeOperationException: Failed to resolve the interface: can_0 - errorNumber=19, errorMessage='No such device'
at tel.schich.javacan.platform.linux.LinuxNetworkDevice.resolveInterfaceName(Native Method) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.platform.linux.LinuxNetworkDevice.lookup(LinuxNetworkDevice.java:70) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.NetworkDevice.lookup(NetworkDevice.java:53) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.CanChannels.newRawChannel(CanChannels.java:73) ~[javacan-core-3.2.4.jar:?]
at com.airepublic.bmstoinverter.protocol.can.JavaCANPort.open(JavaCANPort.java:60) ~[protocol-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.core.Port.ensureOpen(Port.java:112) ~[core-api-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.protocol.can.JavaCANPort.sendExtendedFrame(JavaCANPort.java:100) ~[protocol-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.can.DalyBmsCANProcessor.sendMessage(DalyBmsCANProcessor.java:47) ~[bms-daly-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.common.AbstractDalyBmsProcessor.collectData(AbstractDalyBmsProcessor.java:74) ~[bms-daly-common-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.core.BMS.process(BMS.java:173) ~[core-api-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.BmsToInverter.lambda$start$2(BmsToInverter.java:269) ~[bms-to-inverter-main-0.0.1-SNAPSHOT.jar:?]
at java.lang.Thread.run(Thread.java:840) [?:?]
2024-11-21 20:33:27.906 | DEBUG | Thread-2 | ocol.can.JavaCANPort:115 | CAN frame sending: Buffer (HEX): [0x40, 0x02, 0x90, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-21 20:33:27.907 | ERROR | Thread-2 | stoinverter.core.BMS:192 | Error requesting data!
java.lang.NullPointerException: Cannot invoke "tel.schich.javacan.RawCanChannel.write(tel.schich.javacan.CanFrame)" because "this.canChannel" is null
at com.airepublic.bmstoinverter.protocol.can.JavaCANPort.sendExtendedFrame(JavaCANPort.java:117) ~[protocol-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.can.DalyBmsCANProcessor.sendMessage(DalyBmsCANProcessor.java:47) ~[bms-daly-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.common.AbstractDalyBmsProcessor.collectData(AbstractDalyBmsProcessor.java:74) ~[bms-daly-common-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.core.BMS.process(BMS.java:173) ~[core-api-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.BmsToInverter.lambda$start$2(BmsToInverter.java:269) ~[bms-to-inverter-main-0.0.1-SNAPSHOT.jar:?]
at java.lang.Thread.run(Thread.java:840) [?:?]

Tried can0 also but no dice. What you think. Thanks, Using board from your recommend list Waveshare 2CH-CAN hats. Anything special for it?

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 22, 2024

2024-11-21 21:44:59.909 | INFO | Thread-2 | toinverter.core.Port:111 | Opening can0 ...
2024-11-21 21:44:59.910 | ERROR | Thread-2 | toinverter.core.Port:116 | Opening port can0 FAILED!
tel.schich.javacan.platform.linux.LinuxNativeOperationException: Failed to resolve the interface: can0 - errorNumber=19, errorMessage='No such device'
at tel.schich.javacan.platform.linux.LinuxNetworkDevice.resolveInterfaceName(Native Method) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.platform.linux.LinuxNetworkDevice.lookup(LinuxNetworkDevice.java:70) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.NetworkDevice.lookup(NetworkDevice.java:53) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.CanChannels.newRawChannel(CanChannels.java:73) ~[javacan-core-3.2.4.jar:?]
at com.airepublic.bmstoinverter.protocol.can.JavaCANPort.open(JavaCANPort.java:60) ~[protocol-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.core.Port.ensureOpen(Port.java:112) ~[core-api-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.protocol.can.JavaCANPort.sendExtendedFrame(JavaCANPort.java:100) ~[protocol-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.can.DalyBmsCANProcessor.sendMessage(DalyBmsCANProcessor.java:47) ~[bms-daly-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.common.AbstractDalyBmsProcessor.collectData(AbstractDalyBmsProcessor.java:74) ~[bms-daly-common-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.core.BMS.process(BMS.java:173) ~[core-api-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.BmsToInverter.lambda$start$2(BmsToInverter.java:269) ~[bms-to-inverter-main-0.0.1-SNAPSHOT.jar:?]
at java.lang.Thread.run(Thread.java:840) [?:?]
2024-11-21 21:44:59.911 | DEBUG | Thread-2 | ocol.can.JavaCANPort:115 | CAN frame sending: Buffer (HEX): [0x40, 0x02, 0x90, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-21 21:44:59.912 | ERROR | Thread-2 | stoinverter.core.BMS:192 | Error requesting data!
java.lang.NullPointerException: Cannot invoke "tel.schich.javacan.RawCanChannel.write(tel.schich.javacan.CanFrame)" because "this.canChannel" is null
at com.airepublic.bmstoinverter.protocol.can.JavaCANPort.sendExtendedFrame(JavaCANPort.java:117) ~[protocol-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.can.DalyBmsCANProcessor.sendMessage(DalyBmsCANProcessor.java:47) ~[bms-daly-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.common.AbstractDalyBmsProcessor.collectData(AbstractDalyBmsProcessor.java:74) ~[bms-daly-common-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.core.BMS.process(BMS.java:173) [core-api-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.BmsToInverter.lambda$start$2(BmsToInverter.java:269) [bms-to-inverter-main-0.0.1-SNAPSHOT.jar:?]
at java.lang.Thread.run(Thread.java:840) [?:?]
^C2024-11-21 21:45:00.175 | INFO | Thread-1 | verter.BmsToInverter:426 | Shutting down BMS and inverter threads...FAILED
2024-11-21 21:45:00.179 | INFO | Thread-1 | verter.BmsToInverter:458 | Shutting down ports...OK
Weld SE container 162ddb10-1104-431e-a516-81639b049a92 shut down by shutdown hook
dalibor@powerwall2:
$ ^C
dalibor@powerwall2:
$

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 22, 2024

Or how would you setup this board. Please do tell. Thanks

@ai-republic
Copy link
Owner

Hi @DMIINC,
it definitely looks like your 2CH-CAN hat is not properly set up. Did you follow the instructions on the Waveshare Wiki?
You do not need to install the Python or the example/wiring PI code.
Which model exactly did you get? The 2-CH-CAN-FD-HAT or the 2-CH-CAN-HAT?

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 23, 2024

I think I solved that issue. I have another one. What do you think? I got this one https://www.waveshare.com/wiki/2-CH_CAN_HAT%2B

024-11-23 06:12:48.119 | ERROR | Thread-2 | stoinverter.core.BMS:192 | Error requesting data!
tel.schich.javacan.platform.linux.LinuxNativeOperationException: Unable to write to the socket - errorNumber=100, errorMessage='Network is down'
at tel.schich.javacan.SocketCAN.write(Native Method) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.AbstractCanChannel.writeSocket(AbstractCanChannel.java:237) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.RawCanChannelImpl.writeUnsafe(RawCanChannelImpl.java:102) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.RawCanChannelImpl.write(RawCanChannelImpl.java:92) ~[javacan-core-3.2.4.jar:?]
at com.airepublic.bmstoinverter.protocol.can.JavaCANPort.sendExtendedFrame(JavaCANPort.java:117) ~[protocol-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.can.DalyBmsCANProcessor.sendMessage(DalyBmsCANProcessor.java:47) ~[bms-daly-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.bms.daly.common.AbstractDalyBmsProcessor.collectData(AbstractDalyBmsProcessor.java:74) ~[bms-daly-common-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.core.BMS.process(BMS.java:173) ~[core-api-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.BmsToInverter.lambda$start$2(BmsToInverter.java:269) ~[bms-to-inverter-main-0.0.1-SNAPSHOT.jar:?]
at java.lang.Thread.run(Thread.java:840) [?:?]

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 23, 2024

We are getting somewhere.

dalibor@powerwall2:~ $ sudo ./start.sh
2024-11-23 07:08:01.145 | INFO | main | til.SystemProperties:22 | Loading config.properties from: config/config.properties
2024-11-23 07:08:02.224 | INFO | main | ore.InverterProducer:76 | Created inverter binding: PYLON_HV_CAN
2024-11-23 07:08:02.280 | INFO | main | verter.core.Inverter:53 | Using plugins: []
2024-11-23 07:08:02.304 | INFO | main | core.BMSListProducer:105 | Intialized BMS #0[DALY_CAN] on port can0
2024-11-23 07:08:02.315 | INFO | main | verter.BmsToInverter:261 | Starting BMS receiver...
2024-11-23 07:08:02.327 | INFO | Thread-2 | verter.BmsToInverter:268 | Reading BMS #0 DALY_CAN on can0...
2024-11-23 07:08:02.334 | INFO | Thread-2 | toinverter.core.Port:111 | Opening can0 ...
2024-11-23 07:08:02.405 | INFO | Thread-2 | toinverter.core.Port:113 | Opening port can0 SUCCESSFUL
2024-11-23 07:08:02.461 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:03.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:04.458 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:05.458 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:06.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:07.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:08.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:09.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:10.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:11.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:12.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:13.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:14.459 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:14.460 | INFO | main | verter.BmsToInverter:290 | Starting inverter sender...
2024-11-23 07:08:14.462 | INFO | Thread-3 | verter.BmsToInverter:294 | Sending to inverter PYLON_HV_CAN on can1...
2024-11-23 07:08:14.463 | INFO | Thread-3 | toinverter.core.Port:111 | Opening can1 ...
2024-11-23 07:08:14.464 | INFO | Thread-3 | toinverter.core.Port:113 | Opening port can1 SUCCESSFUL
2024-11-23 07:08:14.477 | INFO | Thread-2 | verter.BmsToInverter:320 |
BMS SOC V A CellMinV CellMaxV CellDiff
#1 -0.1 0.0 0.0 0.0(#0) 0.0(#0) 0.0

2024-11-23 07:08:14.479 | INFO | Thread-2 | verter.BmsToInverter:390 | BMS alarms:
NONE
2024-11-23 07:08:15.480 | INFO | Thread-2 | verter.BmsToInverter:268 | Reading BMS #0 DALY_CAN on can0...
2024-11-23 07:08:15.481 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-23 07:08:15.495 | ERROR | Thread-3 | verter.core.Inverter:198 | Failed to send frame to inverter PYLON_HV_CAN :Buffer (HEX): [null]

tel.schich.javacan.platform.linux.LinuxNativeOperationException: Unable to read from the socket - errorNumber=11, errorMessage='Resource temporarily unavailable'
at tel.schich.javacan.SocketCAN.read(Native Method) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.AbstractCanChannel.readSocket(AbstractCanChannel.java:213) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.RawCanChannelImpl.readUnsafe(RawCanChannelImpl.java:85) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.RawCanChannelImpl.read(RawCanChannelImpl.java:79) ~[javacan-core-3.2.4.jar:?]
at tel.schich.javacan.RawCanChannelImpl.read(RawCanChannelImpl.java:74) ~[javacan-core-3.2.4.jar:?]
at com.airepublic.bmstoinverter.protocol.can.JavaCANPort.receiveFrame(JavaCANPort.java:77) ~[protocol-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.inverter.pylonhv.can.PylonHVInverterCANProcessor.readRequest(PylonHVInverterCANProcessor.java:41) ~[inverter-pylon-hv-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.core.Inverter.process(Inverter.java:147) ~[core-api-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.inverter.pylonhv.can.PylonHVInverterCANProcessor$Proxy$_$$_WeldClientProxy.process(Unknown Source) ~[inverter-pylon-hv-can-0.0.1-SNAPSHOT.jar:?]
at com.airepublic.bmstoinverter.BmsToInverter.lambda$start$4(BmsToInverter.java:295) ~[bms-to-inverter-main-0.0.1-SNAPSHOT.jar:?]
at java.lang.Thread.run(Thread.java:840) [?:?]

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 23, 2024

dalibor@powerwall2:~ $ ifconfig
can0: flags=193<UP,RUNNING,NOARP> mtu 16
unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen 65536 (UNSPEC)
RX packets 3318 bytes 26544 (25.9 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 430 bytes 3440 (3.3 KiB)
TX errors 1 dropped 1 overruns 0 carrier 1 collisions 0

can1: flags=193<UP,RUNNING,NOARP> mtu 16
unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen 65536 (UNSPEC)
RX packets 2931 bytes 23448 (22.8 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.182 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::280d:a310:ae22:2ce8 prefixlen 64 scopeid 0x20
ether 2c:cf:67:3d:fc:bb txqueuelen 1000 (Ethernet)
RX packets 715702 bytes 105858836 (100.9 MiB)
RX errors 0 dropped 5494 overruns 0 frame 0
TX packets 1146920 bytes 1406731872 (1.3 GiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device interrupt 106

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10
loop txqueuelen 1000 (Local Loopback)
RX packets 23 bytes 2543 (2.4 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 23 bytes 2543 (2.4 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.185 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::ed58:290a:5acc:18f prefixlen 64 scopeid 0x20
ether 2c:cf:67:3d:fc:bc txqueuelen 1000 (Ethernet)
RX packets 22585 bytes 2971051 (2.8 MiB)
RX errors 0 dropped 5430 overruns 0 frame 0
TX packets 423 bytes 40551 (39.6 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

dalibor@powerwall2:~ $

@ai-republic
Copy link
Owner

ai-republic commented Nov 24, 2024

Hi @DMIINC,
it looks better now. It has initialized the CAN interface now. This is the start script that I use to start/configure my 2-CH-CAN-FD hat:

#!/usr/bin/env bash
sudo ip link set down can0
sudo ip link set down can1
sudo ip link set can0 type can bitrate 500000 restart-ms 100 fd off
sudo ip link set can1 type can bitrate 500000 restart-ms 100 fd off
sudo ifconfig can0 txqueuelen 65536
sudo ifconfig can1 txqueuelen 65536
sudo ip link set up can0
sudo ip link set up can1

But sometimes I get the same error that

tel.schich.javacan.platform.linux.LinuxNativeOperationException: Unable to read from the socket - errorNumber=11, errorMessage='Resource temporarily unavailable'

if the device is not connected properly.

For now - to test the BMS - I would recommend to set the inverter to the NONE binding.
My guess is that your BMS Id is not configured correctly. The Daly BMS usually starts with ID 1. You'll need to set that in the configuration. Do you just have one Daly BMS? Do you use the interface board or are you connected straight to the Daly CAN port? And does your Daly really support CAN (you often need to contact a Daly salesperson to get a CAN activated BMS)?

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 24, 2024

Thanks for the reply. I can use either interface board or can lines from BMS itself. I know I get canbus data out from BMS since in some combinations on inverter and BMS i will get at least correct SOC. I will try above script and see if it helps. Thank you.

@ai-republic
Copy link
Owner

ok, great. Yes, then I think its either the BMS id or a wrong CAN configuration (e.g. baudrate). You can set the BMS id via the DIP switches on the interface board.

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 24, 2024

Dip switches on interface board are all in off position. Do you suggest something different. What baud rate would you try?

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 24, 2024

no previous error as of now. I do get this

G | Thread-2 | .DalyBmsCANProcessor:75 | RECEIVED: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:20.281 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:20.281 | DEBUG | Thread-2 | .DalyBmsCANProcessor:46 | SEND: Buffer (HEX): [0x40, 0x01, 0x98, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:20.282 | DEBUG | Thread-2 | ocol.can.JavaCANPort:115 | CAN frame sending: Buffer (HEX): [0x40, 0x01, 0x98, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:20.282 | DEBUG | Thread-2 | ocol.can.JavaCANPort:76 | CAN frame read...
2024-11-24 08:07:21.280 | DEBUG | Thread-2 | ocol.can.JavaCANPort:82 | CAN read frame Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:21.281 | DEBUG | Thread-2 | .DalyBmsCANProcessor:75 | RECEIVED: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:21.281 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:21.281 | INFO | Thread-2 | verter.BmsToInverter:320 |
BMS SOC V A CellMinV CellMaxV CellDiff
#1 -0.1 0.0 0.0 0.0(#0) 0.0(#0) 0.0

2024-11-24 08:07:21.282 | INFO | Thread-2 | verter.BmsToInverter:390 | BMS alarms:
NONE
2024-11-24 08:07:21.513 | INFO | Thread-3 | verter.BmsToInverter:294 | Sending to inverter PYLON_HV_CAN on can1...
2024-11-24 08:07:21.513 | DEBUG | Thread-3 | ocol.can.JavaCANPort:76 | CAN frame read...
2024-11-24 08:07:21.514 | DEBUG | Thread-3 | ocol.can.JavaCANPort:82 | CAN read frame Buffer (HEX): [0x59, 0x03, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x50, 0x4E, 0x00]

2024-11-24 08:07:21.514 | DEBUG | Thread-3 | verter.core.Inverter:150 | Inverter PYLON_HV_CAN received: Buffer (HEX): [0x59, 0x03, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x50, 0x4E, 0x00]

2024-11-24 08:07:21.514 | DEBUG | Thread-3 | verter.core.Inverter:160 | Inverter PYLON_HV_CAN received (after running plugins): Buffer (HEX): [0x59, 0x03, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x50, 0x4E, 0x00]

2024-11-24 08:07:22.282 | INFO | Thread-2 | verter.BmsToInverter:268 | Reading BMS #1 DALY_CAN on can0...
2024-11-24 08:07:22.283 | DEBUG | Thread-2 | .DalyBmsCANProcessor:46 | SEND: Buffer (HEX): [0x40, 0x01, 0x90, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:22.283 | DEBUG | Thread-2 | ocol.can.JavaCANPort:115 | CAN frame sending: Buffer (HEX): [0x40, 0x01, 0x90, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:22.283 | DEBUG | Thread-2 | ocol.can.JavaCANPort:76 | CAN frame read...
2024-11-24 08:07:22.284 | DEBUG | Thread-2 | ocol.can.JavaCANPort:82 | CAN read frame Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:22.284 | DEBUG | Thread-2 | .DalyBmsCANProcessor:75 | RECEIVED: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:22.284 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:22.284 | DEBUG | Thread-2 | .DalyBmsCANProcessor:46 | SEND: Buffer (HEX): [0x40, 0x01, 0x91, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:22.284 | DEBUG | Thread-2 | ocol.can.JavaCANPort:115 | CAN frame sending: Buffer (HEX): [0x40, 0x01, 0x91, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:22.285 | DEBUG | Thread-2 | ocol.can.JavaCANPort:76 | CAN frame read...
2024-11-24 08:07:23.281 | DEBUG | Thread-2 | ocol.can.JavaCANPort:82 | CAN read frame Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:23.281 | DEBUG | Thread-2 | .DalyBmsCANProcessor:75 | RECEIVED: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:23.281 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:23.282 | DEBUG | Thread-2 | .DalyBmsCANProcessor:46 | SEND: Buffer (HEX): [0x40, 0x01, 0x92, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:23.282 | DEBUG | Thread-2 | ocol.can.JavaCANPort:115 | CAN frame sending: Buffer (HEX): [0x40, 0x01, 0x92, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:23.282 | DEBUG | Thread-2 | ocol.can.JavaCANPort:76 | CAN frame read...
2024-11-24 08:07:23.514 | INFO | Thread-3 | verter.BmsToInverter:294 | Sending to inverter PYLON_HV_CAN on can1...
2024-11-24 08:07:23.515 | DEBUG | Thread-3 | ocol.can.JavaCANPort:76 | CAN frame read...
2024-11-24 08:07:23.515 | DEBUG | Thread-3 | ocol.can.JavaCANPort:82 | CAN read frame Buffer (HEX): [0x5C, 0x03, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:23.515 | DEBUG | Thread-3 | verter.core.Inverter:150 | Inverter PYLON_HV_CAN received: Buffer (HEX): [0x5C, 0x03, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:23.515 | DEBUG | Thread-3 | verter.core.Inverter:160 | Inverter PYLON_HV_CAN received (after running plugins): Buffer (HEX): [0x5C, 0x03, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:24.281 | DEBUG | Thread-2 | ocol.can.JavaCANPort:82 | CAN read frame Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:24.282 | DEBUG | Thread-2 | .DalyBmsCANProcessor:75 | RECEIVED: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:24.282 | WARN | Thread-2 | .DalyBmsCANProcessor:94 | Message has wrong address and command id: Buffer (HEX): [0x00, 0x42, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:24.282 | DEBUG | Thread-2 | .DalyBmsCANProcessor:46 | SEND: Buffer (HEX): [0x40, 0x01, 0x93, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:24.283 | DEBUG | Thread-2 | ocol.can.JavaCANPort:115 | CAN frame sending: Buffer (HEX): [0x40, 0x01, 0x93, 0x18, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

2024-11-24 08:07:24.283 | DEBUG | Thread-2 | ocol.can.JavaCANPort:76 | CAN frame read...
^C2024-11-24 08:07:25.209 | INFO | Thread-1 | verter.BmsToInverter:426 | Shutting down BMS and inverter threads...FAILED
2024-11-24 08:07:25.210 | INFO | Thread-1 | ocol.can.JavaCANPort:127 | Shutting down port 'can0'...OK
2024-11-24 08:07:25.211 | INFO | Thread-1 | ocol.can.JavaCANPort:127 | Shutting down port 'can1'...OK
2024-11-24 08:07:25.211 | INFO | Thread-1 | verter.BmsToInverter:458 | Shutting down ports...OK
Weld SE container 04ba2258-9fcd-499d-8a28-497a0d58e605 shut down by shutdown hook

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 24, 2024

It do not feel like it is transmitting to inverter at all

dalibor@powerwall2:~ $ ifconfig
can0: flags=193<UP,RUNNING,NOARP> mtu 16
unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen 65536 (UNSPEC)
RX packets 73 bytes 584 (584.0 B)
RX errors 0 dropped 39 overruns 0 frame 0
TX packets 35 bytes 280 (280.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

can1: flags=193<UP,RUNNING,NOARP> mtu 16
unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen 65536 (UNSPEC)
RX packets 442 bytes 3528 (3.4 KiB)
RX errors 0 dropped 238 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.182 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::280d:a310:ae22:2ce8 prefixlen 64 scopeid 0x20
ether 2c:cf:67:3d:fc:bb txqueuelen 1000 (Ethernet)
RX packets 16783 bytes 1901627 (1.8 MiB)
RX errors 0 dropped 368 overruns 0 frame 0
TX packets 24838 bytes 29186064 (27.8 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device interrupt 106

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10
loop txqueuelen 1000 (Local Loopback)
RX packets 20 bytes 2311 (2.2 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 20 bytes 2311 (2.2 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.185 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::ed58:290a:5acc:18f prefixlen 64 scopeid 0x20
ether 2c:cf:67:3d:fc:bc txqueuelen 1000 (Ethernet)
RX packets 848 bytes 86229 (84.2 KiB)
RX errors 0 dropped 255 overruns 0 frame 0
TX packets 73 bytes 8556 (8.3 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 24, 2024

but I think inverter is listening

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 24, 2024

image

@ai-republic
Copy link
Owner

I think you need to set your DIP with the no. 1 switch to ON. Then you should received data from your BMS. Also select the BMS binding DALY_CAN and the ID 1 and baudrate 500000.

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 25, 2024

I think you need to set your DIP with the no. 1 switch to ON. Then you should received data from your BMS. Also select the BMS binding DALY_CAN and the ID 1 and baudrate 500000.

Tried that and it does not work. Same outcome as before.

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 25, 2024

Tried reversing call from can0 to can and it worked. Either can outputs on the boar are misprinted or software is coded reverse

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 25, 2024

image

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 25, 2024

image

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 25, 2024

However what is read by your software and what inverter is seeing different. Do you suggest different settings. Amps are high and it throws errors

image

@ai-republic
Copy link
Owner

Great! You're getting data. That's a start 😄
The current looks like its x10. Is that on the latest version? Can you confirm this? Then I could have a look at it and fix it.

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 26, 2024

Yes. The latest version. Thank you.

@DMIINC
Copy link
Contributor Author

DMIINC commented Nov 26, 2024

image

Additional information that might help.

@ai-republic
Copy link
Owner

Right, I made some changes to process the received data if it is valid response but not necessarily the requested response. Could you please try again and attach the log file?

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 26, 2024

Here you go....

BMS-to-Inverter.log

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 26, 2024

image

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 26, 2024

BMS-to-Inverter.log

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 27, 2024

Attached logs includes me running my power wall today. Charging and discharging. Just FYI.

@ai-republic
Copy link
Owner

So here are my findings:
Daly reads dis-/charge current limits (seemingly correct)

image

but were actually mixed up so max discharge current held the value of max charge current and vice versa
and are sent to the inverter:

image

as per spec the dis-/charge current limits are offset by 3000A (with unit 0.1A = 30000).
So charge current limit of 100.0A = 1000 + 30000 = 31000
and discharge current limit of -100.0A = -1000 + 30000 = 29000
So the values transmitted are actually correct according to the spec.

The inverter then does this for:
Charge current limit:
29000 - 30000 = -1000 (which should be 1000)
wrong value: -1000 as unsigned int_16 = 64536 -> 6453.6A
correct value: 1000 as unsigned int_16 = 1000 -> 100.0A

Disharge current limit:
31000 - 30000 = 1000 (which should be -1000)
1000 * -1 = -1000 (converts the negative value to be displayed as positive and should really be -1000 * -1 = 1000)

wrong value: -1000 as unsigned int_16 = 64536 -> 6453.6A
correct value: 1000 as unsigned int_16 = 1000 -> 100.0A

So long story short, I fixed the Daly dis-/charge current limits. Now you should get the correct values if my assumptions are correct 😄

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 27, 2024

lol. I will test in a moment and let you know.

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 27, 2024

image

Charge and discharge current is correct. Amps and temps are wrong.

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 27, 2024

In ./configurator.sh I switched from Solis_hv to Pylon_hv and it is ok except Amps.

image

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 27, 2024

BMS-to-Inverter.log
Pylon_HV log

@ai-republic
Copy link
Owner

Hi @DMIINC,
please update try the Solis binding again. I think I found the bug. Now for the amps I'm still not sure. It doesn't seem to read the value from CAN id 0x4210 bytes 3 and 4 as described in the spec.

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 27, 2024

I do not know what you did but we have amps correct. Double checked it with amp probe too. Inverter is behaving much better. See images.
Thank you so much. Beer will be on me.
Few remaining things. Errors reported to Inverter (important), Amp hour capacity and Discharge current.

Screenshot 2024-12-27 120806

20241227_120355000_iOS

20241227_120345000_iOS

20241227_120601000_iOS

20241227_120527000_iOS

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 28, 2024

BMS-to-Inverter.log

@ai-republic
Copy link
Owner

Hi @DMIINC,
thanks for the beer 😆 🥂
I fixed the error messages and the hopefully the rated capacity. I think it takes it from the module capacity value which the Daly does not provide so I summed up the battery rated capacity of all packs. Wasn't the max discharge current working? Otherwise I think I need to pass it as a posivite value, e.g. 100A instead of -100A. Please update and retest. If the max discharge current is still wrong I can fix that easily.

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 28, 2024

You are welcome on the beer. Enjoy.
Error messages are gone. :) which makes inverter very happy.

I have one more request since I am not software guru like you. I am more of mechanical/electrical engineer.

On Raspberry Pi how do I get CANBUS and your software to auto start upon boot:

#!/usr/bin/env bash
sudo ip link set down can0
sudo ip link set down can1
sudo ip link set can0 type can bitrate 500000
sudo ip link set can1 type can bitrate 500000
sudo ifconfig can0 txqueuelen 65536
sudo ifconfig can1 txqueuelen 65536
sudo ip link set up can0
sudo ip link set up can1

and

./start.sh

20241228_044642000_iOS

@ai-republic
Copy link
Owner

ai-republic commented Dec 29, 2024

@DMIINC I've updated the Wiki How-to-use with another chapter on how to configure it for automatic start
see here

Let me know how it goes 😄

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 30, 2024

I can not get CANBUS command to execute at all. I have been fighting this for couple of weeks now. Actually since we started this. I am not software guru like you but I know know enough to get PI going. LOL. I am doing something wrong but do not know what.

@DMIINC
Copy link
Contributor Author

DMIINC commented Dec 30, 2024

Unless I manually execute

sudo ip link set down can0
sudo ip link set down can1
sudo ip link set can0 type can bitrate 500000
sudo ip link set can1 type can bitrate 500000
sudo ifconfig can0 txqueuelen 65536
sudo ifconfig can1 txqueuelen 65536
sudo ip link set up can0
sudo ip link set up can1

./start.sh will have errors.

@ai-republic
Copy link
Owner

Copy this to a file called startcan.sh to your home folder:

#!/usr/bin/env bash
sudo ip link set down can0
sudo ip link set down can1
sudo ip link set can0 type can bitrate 500000
sudo ip link set can1 type can bitrate 500000
sudo ifconfig can0 txqueuelen 65536
sudo ifconfig can1 txqueuelen 65536
sudo ip link set up can0
sudo ip link set up can1

Give the read and execute permissions to the file:

sudo chmod 755 /home/pi/startcan.sh

Open the rc.local file to add the calls to start the CAN interfaces and the application

sudo nano /etc/rc.local

Add the following two calls at the end of the rc.local file but before the exit 0:

cd /home/pi/bms-to-inverter
/home/pi/startcan.sh
/home/pi/bms-to-inverter/start.sh &

exit 0

Save and exit the nano editor with Ctrl+X and confirm saving with Y and reboot. That should do it really.

@ai-republic
Copy link
Owner

Did you get it to start at boot time now?

@DMIINC
Copy link
Contributor Author

DMIINC commented Jan 5, 2025

Unfortunately no. I have done exactly as you said but it does not start.

@ai-republic
Copy link
Owner

Hmm, that is strange. Which PI version and OS do you have?

@DMIINC
Copy link
Contributor Author

DMIINC commented Jan 8, 2025

Latest from November/24 Fully up to date. Raspberry Pi4b

@DMIINC
Copy link
Contributor Author

DMIINC commented Jan 8, 2025

Hello. Upon further testing I have found that Multi BMS per inverter causes invalid information to be seen by inverter. See attache d pic and log file..No matter what setting I use in regards to communication the outcome is the same. I am using interface/parallel boards.

@DMIINC
Copy link
Contributor Author

DMIINC commented Jan 8, 2025

BMS-to-Inverter.log

@DMIINC
Copy link
Contributor Author

DMIINC commented Jan 8, 2025

image

@ai-republic
Copy link
Owner

I will check that. Maybe something is wrong during aggregation or the BMSes. But the total current and minimum cell voltage should really be working. I have also 8 Daly's in my setup.

@DMIINC
Copy link
Contributor Author

DMIINC commented Jan 17, 2025

@ai-republic could you please share Pylon_HV can protocol document? Thank you.

@ai-republic
Copy link
Owner

@DMIINC
Copy link
Contributor Author

DMIINC commented Jan 20, 2025

Thank you very much

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants