question

stundenblume avatar image
stundenblume asked

VenusOS on RasPi don't recognize Pylontech battery via CAN-HAT [solved]

Hi together,
since one week I'm proud owner of a MultiPlus-II and two Pylontech batteries. I use VenusOS on a RasPi.
The main things are working well, but the batteries are not showing up in the remote console GUI.

Hardware: RasPi 3+, Waveshare CAN-HAT
Firmware: 2.82-large-30

Recources used: https://github.com/victronenergy/venus/wiki/RaspberryPi-CAN-Interfaces

  1. Installed CAN-HAT on RasPi
  2. connected battery to CAN-HAT
  3. added line to /u-boot/config.txt
  4. reboot
  5. checked output of "dmesg | grep -i '\(can\|spi\)'"
  6. response: mcp251x spi0.0 can0: MCP2515 successfully initialized.
  7. "ip link set can0 up type can bitrate 250000"
  8. checked "candump can0"
  9. output: empty
  10. reboot
  11. "ip link set can0 up type can bitrate 500000"
  12. checked "candump can0"
  13. output: data are flowing in
  14. created "/etc/venus/canbus_ports" with can0 inside
  15. reboot
  16. "ip link set can0 up type can bitrate 500000"
  17. output: RTNETLINK answers: Device or resource busy
  18. candump can0
  19. output: empty
  20. copied and modified vecan-dbus & mqtt-n2k as stated in the documentation
  21. reboot
  22. venusOS still did't recognize the battery, no data via candump

Maybe the driver uses a wrong bitrate? But where can I change it?

Any help is welcome.

Thank you very much,
Sebastian

Pylontechvenus os v2.80
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

2 Answers
dirkmuc avatar image
dirkmuc answered ·

Hello Sebastian,

Reading your nickname I think you can read German ;-)

In a RV forum I posted the steps to integrate my CAN-Bus BMS into Venus OS.

https://www.kastenwagenforum.de/forum/threads/rec-bms-mit-victron-integration.46404/#post-664959

May be it helps to solve your issue.

Cheers

Dirk


2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

stundenblume avatar image
stundenblume answered ·

Moin Dirk,
thank you very much.
German is no problem! After reading "[...] change bitrate in GUI [...]" I checked my GUI again, because yesterday I didn't find any place to change CAN bitrate and thought that is maybe something the RasPi image didn't offer...

Finally I found it under: settings > services > CAN-bus > CAN-bus profile

After changing it to "CAN-bus BMS (500kbit/s)" the GUI crashed. After a reboot the battery is recognized from the Victron system and everything works as expected!


One questions:
1. what is "dtoverlay=spi-bcm2835-overlay" in "/u-boot/config.txt" for?

Sebastian

1 comment
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

dirkmuc avatar image dirkmuc commented ·

To your question.

The spi-bcm2835-overlay was used to specify a newer bcm2835 SPI driver. In Linux distributions using a kernel >4.4 it is not needed anymore to my knowledge as it is the default driver now. I do not know if it is strictly necessary with Dunfell which is the basis for Venus 2.8x.

0 Likes 0 ·

Related Resources

Victron Pylontech battery compatibility guide

Additional resources still need to be added for this topic