Texas Instruments BQ769x2 Application Note

Texas Instruments BQ769x2 Application Note

Control based on mspm0 through i2c
Table of Contents

Advertisement

Quick Links

www.ti.com
Application Note
BQ769x2 Control Based on MSPM0 Through I2C
Adrian Liu, Eason Zhou, Helic Chi
The MSPM0 series microcontroller (MCU) portfolio offers a wide variety of 32-bit MCUs with ultra-low power
and integrated analog and digital peripherals for sensing, measurement, and control applications. Reducing
power consumption while performing complex real-time applications presents a major challenge for the recent
embedded applications. This article was created to build a simple framework to help developers quickly setup
the communication between MSPM0 and BQ769x2. Currently, the MSPM0 L series and G series are supported,
and sample code is provided based on LP-MSPM0G3507 and LP-MSPM0L1306 LaunchPad
1
Introduction.............................................................................................................................................................................3
Connection.............................................................................................................................................................3
3.1 System Initialization...........................................................................................................................................................
3.3 High-Level Function...........................................................................................................................................................
4.1 Read Alarm Status...........................................................................................................................................................
4.2 Read Safety Status..........................................................................................................................................................
4.3 Read PF Status................................................................................................................................................................
Current....................................................................................................................................................................12
Temperatures.....................................................................................................................................................12
Voltages.............................................................................................................................................................14
5 References............................................................................................................................................................................
6 Revision History...................................................................................................................................................................
Figure 2-1. System Block Diagram..............................................................................................................................................
Figure 2-3. 3.3V Pullup for SDA and SCL on BQ76952EVM......................................................................................................
Figure 3-1. Software Project View...............................................................................................................................................
Figure 3-2. SYSCFG_DL_init () Function....................................................................................................................................
Figure 3-5. Basic Communication Functions...............................................................................................................................
Figure 3-6. Basic Functions of BQ769x2.....................................................................................................................................
Figure 3-7. Measurement Commands of BQ769x2.....................................................................................................................
Figure 4-2. Captured I2C Waveform for Safety Status Reading................................................................................................
Figure 4-3. Captured I2C Waveform for PF Status Reading.....................................................................................................
Figure 4-4. Captured I2C Waveform for Current Reading.........................................................................................................
Figure 4-5. I2C Waveform for TS Temperature Reading...........................................................................................................
Figure 4-6. Register Values for TS Temperature Reading.........................................................................................................
Figure 4-7. Captured I2C Waveform for Cell Voltage Reading..................................................................................................
SLAAEB3A - MAY 2023 - REVISED JULY 2024
Submit Document Feedback
ABSTRACT

Table of Contents

Functions.......................................................................................................................6
Control.............................................................................................................................................8
Functions.....................................................................................................................................10
List of Figures
MSPM0L1306.......................................................................................................5
Function.........................................................................................................................7
Interface........................................................................................................................................7
BQ769x2.........................................................................................................................................9
Reading.................................................................................................10
Reading................................................................................................................15
Copyright © 2024 Texas Instruments Incorporated
Board......................................................................................4
BQ769x2 Control Based on MSPM0 Through I2C
Table of Contents
.
6
8
10
10
11
15
15
3
5
6
6
8
8
9
11
12
12
13
13
14
1

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the BQ769x2 and is the answer not in the manual?

Questions and answers

Summary of Contents for Texas Instruments BQ769x2

  • Page 1: Table Of Contents

    This article was created to build a simple framework to help developers quickly setup the communication between MSPM0 and BQ769x2. Currently, the MSPM0 L series and G series are supported, and sample code is provided based on LP-MSPM0G3507 and LP-MSPM0L1306 LaunchPad ™...
  • Page 2 Code Composer Studio ™ are trademarks of Texas Instruments. All trademarks are the property of their respective owners. BQ769x2 Control Based on MSPM0 Through I2C SLAAEB3A – MAY 2023 – REVISED JULY 2024 Submit Document Feedback Copyright © 2024 Texas Instruments Incorporated...
  • Page 3: Introduction

    The MSPM0L1306 and MSPM0G3507 devices are highly-integrated, ultra-low-power 32-bit MCU of the MSPM0 family. In practice, the BQ769x2 monitor can measure battery cell voltage, temperature, and current, and reports this information to the MCU(MSPM0) through an I2C interface. The MCU can then make decisions based on the information provided by the monitor.
  • Page 4: Figure 2-2. Lp-Mspm0G3507 And Lp-Mspm0L1306 Hardware

    BQ76952 device is communicating successfully. After confirming the BQ76952EVM board works successfully, start setting up the I2C bridge between MSPM0 and BQ769x2. If the USB on BQ769x2 EVM is not powered, remember to remove the connectors on uC_SCL(J19) and uC_SDA(J16).
  • Page 5: Figure 2-3. 3.3V Pullup For Sda And Scl On Bq76952Evm

    LP-MSPM0L1306 LaunchPad User’s Guide LP-MSPM0G3507 LaunchPad User's Guide for instructions to the other parts that are not mentioned. SLAAEB3A – MAY 2023 – REVISED JULY 2024 BQ769x2 Control Based on MSPM0 Through I2C Submit Document Feedback Copyright © 2024 Texas Instruments Incorporated...
  • Page 6: Software Structure And Important Functions

    The I2C_Communication mainly includes the write and read registers function based on I2C protocol for M0. The main includes the highest system function code. After pressing the button (PA14 of LP-MSPM0L1306 or PB21 of MSPM0G3507), the MSPM0 starts communicating with BQ769x2. More details about the software are shown in the following section.
  • Page 7: Figure 3-3. Syscfg_Dl_I2C_0_Init ()

    CCS Sysconfig page. Figure 3-4. Sysconfig Setting Interface SLAAEB3A – MAY 2023 – REVISED JULY 2024 BQ769x2 Control Based on MSPM0 Through I2C Submit Document Feedback Copyright © 2024 Texas Instruments Incorporated...
  • Page 8: Low-Level Command Control

    The input parameters are similar to the BQ769x2 SetRegister function, but the last input is typed instead. This input can either be the defined macros R for read, W for write, or W2 for write two bytes.
  • Page 9: Figure 3-7. Measurement Commands Of Bq769X2

    All of the read results are saved in these parameters in the protocol file (Figure 3-8). Figure 3-8. Read Results of BQ769x2 SLAAEB3A – MAY 2023 – REVISED JULY 2024 BQ769x2 Control Based on MSPM0 Through I2C Submit Document Feedback Copyright © 2024 Texas Instruments Incorporated...
  • Page 10: Test Result Of Important Functions

    4 Test Result of Important Functions 4.1 Read Alarm Status Table 4-1 shows how to read the alarm status of BQ76952. The BQ769x2 ReadAlarmStatus function can be used to retrieve the alarm bits. As Figure 4-1 shows, the read back value is zero before configuring the BQ76952, and related bits change after BQ769x2_Init.
  • Page 11: Read Pf Status

    Provides individual fault signals when enabled Permanent Fail faults have 0x0F PF Status C triggered. Bit descriptions can be found in PF Status C Register. SLAAEB3A – MAY 2023 – REVISED JULY 2024 BQ769x2 Control Based on MSPM0 Through I2C Submit Document Feedback Copyright © 2024 Texas Instruments Incorporated...
  • Page 12: Read Current

    24.15℃. The reading of TS3 is 0x0B9A, representing a decimal value of 2970 (297.0K), and then converts the value to about 23.85℃. BQ769x2 Control Based on MSPM0 Through I2C SLAAEB3A – MAY 2023 – REVISED JULY 2024 Submit Document Feedback Copyright ©...
  • Page 13: Figure 4-5. I2C Waveform For Ts Temperature Reading

    Figure 4-5. I2C Waveform for TS Temperature Reading Figure 4-6. Register Values for TS Temperature Reading SLAAEB3A – MAY 2023 – REVISED JULY 2024 BQ769x2 Control Based on MSPM0 Through I2C Submit Document Feedback Copyright © 2024 Texas Instruments Incorporated...
  • Page 14: Read All Voltages

    LD Pin Voltage 16-bit voltage on LD pin Figure 4-7. Captured I2C Waveform for Cell Voltage Reading BQ769x2 Control Based on MSPM0 Through I2C SLAAEB3A – MAY 2023 – REVISED JULY 2024 Submit Document Feedback Copyright © 2024 Texas Instruments Incorporated...
  • Page 15: References

    Changed the names of Command-Only Subcommands and Subcommands according to data in the BQ76942 and the BQ76952 TRM..........................8 • Added reference documentation........................15 SLAAEB3A – MAY 2023 – REVISED JULY 2024 BQ769x2 Control Based on MSPM0 Through I2C Submit Document Feedback Copyright © 2024 Texas Instruments Incorporated...
  • Page 16 TI products. TI’s provision of these resources does not expand or otherwise alter TI’s applicable warranties or warranty disclaimers for TI products. TI objects to and rejects any additional or different terms you may have proposed. IMPORTANT NOTICE Mailing Address: Texas Instruments, Post Office Box 655303, Dallas, Texas 75265 Copyright © 2024, Texas Instruments Incorporated...

Table of Contents