battmon2
2.0.0.0
|
BATT-MON 2 Click is a compact add-on board representing a battery monitoring solution. This board features the MAX17262, an ultra-low power I2C-configurable fuel-gauge IC which implements the ModelGauge⢠m5 algorithm from Analog Devices. The MAX17262 monitors a single-cell battery pack (best performance for batteries with 100mAhr to 6Ahr capacity), providing precision measurements of current, voltage, and temperature, and supporting internal current sensing for up to 3.1A pulse current. The battery pack's temperature is measured using an internal temperature sensor or external thermistor.
We provide a library for the BATT-MON 2 Click as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Package can be downloaded/installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on Mikroe github account.
This library contains API for BATT-MON 2 Click driver.
battmon2_cfg_setup
Config Object Initialization function. battmon2_init
Initialization function. battmon2_get_battery_voltage
This function reads the battery voltage in mV. battmon2_get_battery_current
This function reads the battery current in mA. battmon2_get_battery_percentage
This function reads the battery remaining SOC percentage. This example demonstrates the use of BATT-MON 2 click board by monitoring
the measurements of battery voltage, current, capacity, percentage, time-to-empty or time-to-full, as well as the chip internal temperature.
The demo application is composed of two sections :
Initializes the driver and checks the communication by reading and verifying the device ID.
Reads and displays on the USB UART the measurements of battery voltage, current, capacity, percentage,
time-to-empty or time-to-full, as well as the chip internal temperature approximately once per second.
The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on Mikroe github account.
Other Mikroe Libraries used in the example:
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 Click or RS232 Click to connect to your PC, for development systems with no UART to USB interface available on the board. UART terminal is available in all MikroElektronika compilers.