Tonight I was working a bit more on the BMS. Yesterday I received the Arduino Mega 2560 to replace the Arduino UNO. The reason is that the Uno is limited with IO pins, I was using the IO extender, and has less memory for program and variables than the Mega.

I can remove the extender shield now. The top image shows a more compact setup, the horizontal extender keeps the configuration low and gives me space to mount the custom circuits. The picture shows 2 relays on one side of the extender. The other side will be used for the resistor divider visible in the background. This little test board will be obsolete when the resistors are mounted on the extender board.

Much neater now. The display works ok with the mega and I have also added the CAN bus interface. Now I have enough space for programming and can easily implement the battery monitor with energy measurement for load and charge. With the UNO programming is harder, due to less space.

The relays in the picture are latching relays and once switched do not use current. I will use the contacts to drive high current contactors which need higher currents on their coils. These contactors are also latching, so no energy is wasted on holding relays.