Coulomb counter on the MSBA2

Hey folks,

does anyone happen to know how to use the coulomb counter on the MSBA2? I’ve been told it has one, but haven’t been able to find any examples on its usage :confused:

Cheers, Lucas

Hi Lucas!

does anyone happen to know how to use the coulomb counter on the MSBA2? I’ve been told it has one, but haven’t been able to find any examples on its usage :confused:

The device is called ltc4150. Take a look at http://doc.riot-os.org/group__drivers__ltc4150.html

Basically, ltc4150_start() and ltc4150_get_X() would do the trick. However, there's a little "but". The board specific part (see RIOT/boards/msba2-common/drivers/msba2-ltc4150.c at b0045b21df1fc6eae291569814a77cc117b8e061 · RIOT-OS/RIOT · GitHub) has been factored out a while ago, but I guess it shouldn't be too difficult (TM) to re-import this.

Cheers, Oleg

P.S. There's even a shell command for it.

Awesome, thanks :slight_smile: