Loading...
Searching...
No Matches
3#define BQ27220_ADDRESS (0xAAu)
4#define BQ27220_I2C_TIMEOUT (50u)
6#define CommandControl (0x00u)
7#define CommandAtRate (0x02u)
8#define CommandAtRateTimeToEmpty (0x04u)
9#define CommandTemperature (0x06u)
10#define CommandVoltage (0x08u)
11#define CommandBatteryStatus (0x0Au)
12#define CommandCurrent (0x0Cu)
13#define CommandRemainingCapacity (0x10u)
14#define CommandFullChargeCapacity (0x12u)
15#define CommandAverageCurrent (0x14u)
16#define CommandTimeToEmpty (0x16u)
17#define CommandTimeToFull (0x18u)
18#define CommandStandbyCurrent (0x1Au)
19#define CommandStandbyTimeToEmpty (0x1Cu)
20#define CommandMaxLoadCurrent (0x1Eu)
21#define CommandMaxLoadTimeToEmpty (0x20u)
22#define CommandRawCoulombCount (0x22u)
23#define CommandAveragePower (0x24u)
24#define CommandInternalTemperature (0x28u)
25#define CommandCycleCount (0x2Au)
26#define CommandStateOfCharge (0x2Cu)
27#define CommandStateOfHealth (0x2Eu)
28#define CommandChargeVoltage (0x30u)
29#define CommandChargeCurrent (0x32u)
30#define CommandBTPDischargeSet (0x34u)
31#define CommandBTPChargeSet (0x36u)
32#define CommandOperationStatus (0x3Au)
33#define CommandDesignCapacity (0x3Cu)
34#define CommandSelectSubclass (0x3Eu)
35#define CommandMACData (0x40u)
36#define CommandMACDataSum (0x60u)
37#define CommandMACDataLen (0x61u)
38#define CommandAnalogCount (0x79u)
39#define CommandRawCurrent (0x7Au)
40#define CommandRawVoltage (0x7Cu)
41#define CommandRawIntTemp (0x7Eu)
43#define Control_CONTROL_STATUS (0x0000u)
44#define Control_DEVICE_NUMBER (0x0001u)
45#define Control_FW_VERSION (0x0002u)
46#define Control_HW_VERSION (0x0003u)
47#define Control_BOARD_OFFSET (0x0009u)
48#define Control_CC_OFFSET (0x000Au)
49#define Control_CC_OFFSET_SAVE (0x000Bu)
50#define Control_OCV_CMD (0x000Cu)
51#define Control_BAT_INSERT (0x000Du)
52#define Control_BAT_REMOVE (0x000Eu)
53#define Control_SET_SNOOZE (0x0013u)
54#define Control_CLEAR_SNOOZE (0x0014u)
55#define Control_SET_PROFILE_1 (0x0015u)
56#define Control_SET_PROFILE_2 (0x0016u)
57#define Control_SET_PROFILE_3 (0x0017u)
58#define Control_SET_PROFILE_4 (0x0018u)
59#define Control_SET_PROFILE_5 (0x0019u)
60#define Control_SET_PROFILE_6 (0x001Au)
61#define Control_CAL_TOGGLE (0x002Du)
62#define Control_SEALED (0x0030u)
63#define Control_RESET (0x0041u)
64#define Control_OERATION_STATUS (0x0054u)
65#define Control_GAUGING_STATUS (0x0056u)
66#define Control_EXIT_CAL (0x0080u)
67#define Control_ENTER_CAL (0x0081u)
68#define Control_ENTER_CFG_UPDATE (0x0090u)
69#define Control_EXIT_CFG_UPDATE_REINIT (0x0091u)
70#define Control_EXIT_CFG_UPDATE (0x0092u)
71#define Control_RETURN_TO_ROM (0x0F00u)
73#define UnsealKey1 (0x0414u)
74#define UnsealKey2 (0x3672u)
76#define FullAccessKey (0xffffu)