vovaconnect.blogg.se

Arduino battery monitoring system
Arduino battery monitoring system






Thus, a single voltage value is stored over two registers. If we look at page 21 of the datasheet, the voltage value is spread over 12bits but the values of the voltage registers read with the RDCV command are 8 bit.

#Arduino battery monitoring system code#

The last part of the code needs some explaining.

arduino battery monitoring system

We can also read the registers to check if they are properly set.įor(int i = 0 i > 4 | (volt & 0xFF) > 4 | (volt & 0xFF) << 4)*1.5*0.001) Next we start the WRITE command after which the value of each configuration register is written. Since we’re using only one in our configuration the address is 0 or 0x80, defined by the address pins on the chip (A0,A1,A2,A3). We start by giving the address of the LTC6802 chip. *Many other options of configuration are available. First we need to setup the registers with the values of the Over and Under voltage conditions. (*Note: the LTC 6802-2 works with minimum 4 batteries to achieve complete power ON) Now, the next step is to write the Arduino code. It will be much nicer if all the components were placed on a PCB but this works for the initial design and testing. *Visit the Arduino website for more on the SPI interface. In this case we use the Arduino Uno as the microcontroller. The diagram below shows the typical setup for a single monitoring chip connected to a microcontroller.

arduino battery monitoring system

Once set-up, the LTC6802-2 chip sends the voltage data to the microcontroller via the SPI interface. A digital isolator such as the Si8441AB ( ) between the monitoring chip and the microcontroller can also be included for extra protection. However, the chip registers need to be programmed via a microcontroller. This chip can monitor as well as balance a lithium battery pack consisting of no more than 12 cells. The battery management system (BMS) consists of an LTC6802-2 ( ) battery stack monitoring chip.

arduino battery monitoring system

Now I’m back at it and I finally have it working. I started designing a BMS a while back but I ran into problems and I paused the project for a while. For a while now I’ve been looking into battery management systems as part of the Solar Car club at the university.






Arduino battery monitoring system