Linduino  1.3.0
Linear Technology Arduino-Compatible Demonstration Board

Library for LTC6811-1 Multicell Battery Monitor. More...

Detailed Description

Library for LTC6811-1 Multicell Battery Monitor.

Definition in file LTC6811.cpp.

Go to the source code of this file.

Functions

void LTC6811_init_reg_limits (uint8_t total_ic, cell_asic *ic)
 Initialize the Register limits. More...
 
void LTC6811_wrcfg (uint8_t total_ic, cell_asic *ic)
 Write the LTC6811 configuration register. More...
 
int8_t LTC6811_rdcfg (uint8_t total_ic, cell_asic *ic)
 Reads configuration registers of a LTC6811. More...
 
void LTC6811_adcv (uint8_t MD, uint8_t DCP, uint8_t CH)
 Starts cell voltage conversion. More...
 
void LTC6811_adax (uint8_t MD, uint8_t CHG)
 Start a GPIO and Vref2 Conversion. More...
 
void LTC6811_adstat (uint8_t MD, uint8_t CHST)
 Start a Status ADC Conversion. More...
 
void LTC6811_adcvax (uint8_t MD, uint8_t DCP)
 Starts cell voltage and GPIO 1&2 conversion. More...
 
void LTC6811_adcvsc (uint8_t MD, uint8_t DCP)
 Starts cell voltage and SOC conversion. More...
 
uint8_t LTC6811_rdcv (uint8_t reg, uint8_t total_ic, cell_asic *ic)
 Reads and parses the LTC6811 cell voltage registers. More...
 
int8_t LTC6811_rdaux (uint8_t reg, uint8_t total_ic, cell_asic *ic)
 Reads and parses the LTC6811 auxiliary registers. More...
 
int8_t LTC6811_rdstat (uint8_t reg, uint8_t total_ic, cell_asic *ic)
 Reads and parses the LTC6811 stat registers. More...
 
uint8_t LTC6811_pladc ()
 Sends the poll ADC command. More...
 
uint32_t LTC6811_pollAdc ()
 This function will block operation until the ADC has finished it's conversion. More...
 
void LTC6811_clrcell ()
 Clears the LTC6811 cell voltage registers. More...
 
void LTC6811_clraux ()
 Clears the LTC6811 Auxiliary registers. More...
 
void LTC6811_clrstat ()
 Clears the LTC6811 Stat registers. More...
 
void LTC6811_diagn ()
 Starts the Mux Decoder diagnostic self test Running this command will start the Mux Decoder Diagnostic Self Test. More...
 
void LTC6811_cvst (uint8_t MD, uint8_t ST)
 Starts cell voltage self test conversion. More...
 
void LTC6811_axst (uint8_t MD, uint8_t ST)
 Start an Auxiliary Register Self Test Conversion. More...
 
void LTC6811_statst (uint8_t MD, uint8_t ST)
 Start a Status Register Self Test Conversion. More...
 
void LTC6811_adol (uint8_t MD, uint8_t DCP)
 Starts cell voltage overlap conversion. More...
 
void LTC6811_adaxd (uint8_t MD, uint8_t CHG)
 Start an GPIO Redundancy test. More...
 
void LTC6811_adstatd (uint8_t MD, uint8_t CHST)
 Start a Status register redundancy test Conversion. More...
 
int16_t LTC6811_run_cell_adc_st (uint8_t adc_reg, uint8_t total_ic, cell_asic *ic, uint8_t md, bool adcopt)
 Helper function that runs the ADC Self Tests. More...
 
uint16_t LTC6811_run_adc_overlap (uint8_t total_ic, cell_asic *ic)
 Helper Function that runs the ADC Overlap test. More...
 
int16_t LTC6811_run_adc_redundancy_st (uint8_t adc_mode, uint8_t adc_reg, uint8_t total_ic, cell_asic *ic)
 Helper function that runs the ADC Digital Redundancy commands and checks output for errors. More...
 
void LTC6811_adow (uint8_t MD, uint8_t PUP, uint8_t CH, uint8_t DCP)
 Start an open wire Conversion. More...
 
void LTC6811_run_openwire_single (uint8_t total_ic, cell_asic *ic)
 Helper function that runs the data sheet open wire algorithm for single cell detection. More...
 
void LTC6811_run_openwire_multi (uint8_t total_ic, cell_asic *ic)
 Helper function that runs open wire for multiple cell and two consecutive cells detection. More...
 
void LTC6811_set_discharge (int Cell, uint8_t total_ic, cell_asic *ic)
 Helper function to set discharge bit in CFG register. More...
 
void LTC6811_clear_discharge (uint8_t total_ic, cell_asic *ic)
 Clears all of the DCC bits in the configuration registers. More...
 
void LTC6811_wrpwm (uint8_t total_ic, uint8_t pwmReg, cell_asic *ic)
 Write the LTC6811 PWM register. More...
 
int8_t LTC6811_rdpwm (uint8_t total_ic, uint8_t pwmReg, cell_asic *ic)
 Reads pwm registers of a LTC6811 daisy chain. More...
 
void LTC6811_wrsctrl (uint8_t total_ic, uint8_t sctrl_reg, cell_asic *ic)
 Write the LTC6811 Sctrl register. More...
 
int8_t LTC6811_rdsctrl (uint8_t total_ic, uint8_t sctrl_reg, cell_asic *ic)
 Reads sctrl registers of a LTC6811 daisy chain. More...
 
void LTC6811_stsctrl ()
 Start Sctrl data communication This command will start the sctrl pulse communication over the spins. More...
 
void LTC6811_clrsctrl ()
 Clears the LTC6811 Sctrl registers. More...
 
void LTC6811_wrcomm (uint8_t total_ic, cell_asic *ic)
 Writes to the LTC6811 COMM register. More...
 
int8_t LTC6811_rdcomm (uint8_t total_ic, cell_asic *ic)
 Reads comm registers of a LTC6811 daisy chain. More...
 
void LTC6811_stcomm (uint8_t len)
 Issues a stcomm command and clocks data out of the COMM register. More...
 
void LTC6811_check_pec (uint8_t total_ic, uint8_t reg, cell_asic *ic)
 Helper Function that counts overall PEC errors and register/IC PEC errors. More...
 
void LTC6811_reset_crc_count (uint8_t total_ic, cell_asic *ic)
 Helper Function that resets the PEC error counters. More...
 
void LTC6811_init_cfg (uint8_t total_ic, cell_asic *ic)
 Helper Function to initialize the CFGR data structures. More...
 
void LTC6811_set_cfgr (uint8_t nIC, cell_asic *ic, bool refon, bool adcopt, bool gpio[5], bool dcc[12], bool dcto[4], uint16_t uv, uint16_t ov)
 Helper function to set appropriate bits in CFGR register based on bit function. More...
 
void LTC6811_set_cfgr_refon (uint8_t nIC, cell_asic *ic, bool refon)
 Helper function to turn the refon bit HIGH or LOW. More...
 
void LTC6811_set_cfgr_adcopt (uint8_t nIC, cell_asic *ic, bool adcopt)
 Helper function to turn the ADCOPT bit HIGH or LOW. More...
 
void LTC6811_set_cfgr_gpio (uint8_t nIC, cell_asic *ic, bool gpio[5])
 
void LTC6811_set_cfgr_dis (uint8_t nIC, cell_asic *ic, bool dcc[12])
 
void LTC6811_set_cfgr_dcto (uint8_t nIC, cell_asic *ic, bool dcto[4])
 
void LTC6811_set_cfgr_uv (uint8_t nIC, cell_asic *ic, uint16_t uv)
 Helper function to set uv field in CFGRA register. More...
 
void LTC6811_set_cfgr_ov (uint8_t nIC, cell_asic *ic, uint16_t ov)
 Helper function to set ov field in CFGRA register. More...
 

Function Documentation

◆ LTC6811_adax()

void LTC6811_adax ( uint8_t  MD,
uint8_t  CHG 
)

Start a GPIO and Vref2 Conversion.

Returns
void
Parameters
MDADC Conversion Mode
CHGSets which GPIO channels are converted

Definition at line 113 of file LTC6811.cpp.

◆ LTC6811_adaxd()

void LTC6811_adaxd ( uint8_t  MD,
uint8_t  CHG 
)

Start an GPIO Redundancy test.

Returns
void
Parameters
MDADC Conversion Mode
CHGSets which GPIO channels are converted

Definition at line 268 of file LTC6811.cpp.

◆ LTC6811_adcv()

void LTC6811_adcv ( uint8_t  MD,
uint8_t  DCP,
uint8_t  CH 
)

Starts cell voltage conversion.

Returns
void
Parameters
MDADC Conversion Mode
DCPControls if Discharge is permitted during conversion
CHSets which Cell channels are converted

Definition at line 104 of file LTC6811.cpp.

◆ LTC6811_adcvax()

void LTC6811_adcvax ( uint8_t  MD,
uint8_t  DCP 
)

Starts cell voltage and GPIO 1&2 conversion.

Returns
void
Parameters
MDADC Conversion Mode
DCPControls if Discharge is permitted during conversion

Definition at line 129 of file LTC6811.cpp.

◆ LTC6811_adcvsc()

void LTC6811_adcvsc ( uint8_t  MD,
uint8_t  DCP 
)

Starts cell voltage and SOC conversion.

Returns
void
Parameters
MDADC Conversion Mode
DCPControls if Discharge is permitted during conversion

Definition at line 137 of file LTC6811.cpp.

◆ LTC6811_adol()

void LTC6811_adol ( uint8_t  MD,
uint8_t  DCP 
)

Starts cell voltage overlap conversion.

Returns
void
Parameters
MDADC Conversion Mode
DCPDischarge permitted during conversion

Definition at line 260 of file LTC6811.cpp.

◆ LTC6811_adow()

void LTC6811_adow ( uint8_t  MD,
uint8_t  PUP,
uint8_t  CH,
uint8_t  DCP 
)

Start an open wire Conversion.

Returns
void
Parameters
MDADC Mode
PUPDischarge Permit
CHCell selection
DCPDischarge Permit

Definition at line 319 of file LTC6811.cpp.

◆ LTC6811_adstat()

void LTC6811_adstat ( uint8_t  MD,
uint8_t  CHST 
)

Start a Status ADC Conversion.

Returns
void
Parameters
MDADC Conversion Mode
CHSTSets which Stat channels are converted

Definition at line 121 of file LTC6811.cpp.

◆ LTC6811_adstatd()

void LTC6811_adstatd ( uint8_t  MD,
uint8_t  CHST 
)

Start a Status register redundancy test Conversion.

Returns
void
Parameters
MDADC Conversion Mode
CHSTSets which Status channels are converted

Definition at line 276 of file LTC6811.cpp.

◆ LTC6811_axst()

void LTC6811_axst ( uint8_t  MD,
uint8_t  ST 
)

Start an Auxiliary Register Self Test Conversion.

Returns
void
Parameters
MDADC Conversion Mode
STSets if self test 1 or 2 is run

Definition at line 244 of file LTC6811.cpp.

◆ LTC6811_check_pec()

void LTC6811_check_pec ( uint8_t  total_ic,
uint8_t  reg,
cell_asic ic 
)

Helper Function that counts overall PEC errors and register/IC PEC errors.

Returns
void
Parameters
total_icNumber of ICs in the system
regType of register
icA two dimensional array that will store the data

Definition at line 458 of file LTC6811.cpp.

◆ LTC6811_clear_discharge()

void LTC6811_clear_discharge ( uint8_t  total_ic,
cell_asic ic 
)

Clears all of the DCC bits in the configuration registers.

Returns
void
Parameters
total_icNumber of ICs in the daisy chain
icA two dimensional array that will store the data

Definition at line 368 of file LTC6811.cpp.

◆ LTC6811_clraux()

void LTC6811_clraux ( )

Clears the LTC6811 Auxiliary registers.

Returns
void

Definition at line 215 of file LTC6811.cpp.

◆ LTC6811_clrcell()

void LTC6811_clrcell ( )

Clears the LTC6811 cell voltage registers.

Returns
void

Definition at line 206 of file LTC6811.cpp.

◆ LTC6811_clrsctrl()

void LTC6811_clrsctrl ( )

Clears the LTC6811 Sctrl registers.

Returns
void

Definition at line 428 of file LTC6811.cpp.

◆ LTC6811_clrstat()

void LTC6811_clrstat ( )

Clears the LTC6811 Stat registers.

Returns
void

Definition at line 224 of file LTC6811.cpp.

◆ LTC6811_cvst()

void LTC6811_cvst ( uint8_t  MD,
uint8_t  ST 
)

Starts cell voltage self test conversion.

Returns
void
Parameters
MDADC Conversion Mode
STSets if self test 1 or 2 is run

Definition at line 236 of file LTC6811.cpp.

◆ LTC6811_diagn()

void LTC6811_diagn ( )

Starts the Mux Decoder diagnostic self test Running this command will start the Mux Decoder Diagnostic Self Test.

This test takes roughly 1ms to complete. The MUXFAIL bit will be updated. The bit will be set to 1 for a failure and 0 if the test has been passed.

Returns
void

Definition at line 230 of file LTC6811.cpp.

◆ LTC6811_init_cfg()

void LTC6811_init_cfg ( uint8_t  total_ic,
cell_asic ic 
)

Helper Function to initialize the CFGR data structures.

Returns
void
Parameters
total_icNumber of ICs in the system
icA two dimensional array that will store the data

Definition at line 475 of file LTC6811.cpp.

◆ LTC6811_init_reg_limits()

void LTC6811_init_reg_limits ( uint8_t  total_ic,
cell_asic ic 
)

Initialize the Register limits.

Returns
void
Parameters
total_icNumber of ICs in the system
icA two dimensional array that will store the data

Definition at line 66 of file LTC6811.cpp.

◆ LTC6811_pladc()

uint8_t LTC6811_pladc ( )

Sends the poll ADC command.

Returns
uint8_t, 1 byte read back after a pladc command. If the byte is not 0xFF ADC conversion has completed

Definition at line 191 of file LTC6811.cpp.

◆ LTC6811_pollAdc()

uint32_t LTC6811_pollAdc ( )

This function will block operation until the ADC has finished it's conversion.

Returns
uint32_t, the approximate time it took for the ADC function to complete.

Definition at line 197 of file LTC6811.cpp.

◆ LTC6811_rdaux()

int8_t LTC6811_rdaux ( uint8_t  reg,
uint8_t  nIC,
cell_asic ic 
)

Reads and parses the LTC6811 auxiliary registers.

Returns
int8_t, PEC Status 0: No PEC error detected -1: PEC error detected, retry read
Parameters
regControls which GPIO voltage register is read back
total_icThe number of ICs in the daisy chain
icA two dimensional array of the parsed gpio voltage codes

Definition at line 164 of file LTC6811.cpp.

◆ LTC6811_rdcfg()

int8_t LTC6811_rdcfg ( uint8_t  total_ic,
cell_asic ic 
)

Reads configuration registers of a LTC6811.

Returns
int8_t, PEC Status. 0: Data read back has matching PEC -1: Data read back has incorrect PEC
Parameters
total_icNumber of ICs
icA two dimensional array that the function stores the read configuration data

Definition at line 94 of file LTC6811.cpp.

◆ LTC6811_rdcomm()

int8_t LTC6811_rdcomm ( uint8_t  total_ic,
cell_asic ic 
)

Reads comm registers of a LTC6811 daisy chain.

Returns
int8_t, PEC Status. 0: Data read back has matching PEC -1: Data read back has incorrect PEC
Parameters
total_icNumber of ICs in the daisy chain
icTwo dimensional array that the function stores the read comm data.

Definition at line 442 of file LTC6811.cpp.

◆ LTC6811_rdcv()

uint8_t LTC6811_rdcv ( uint8_t  reg,
uint8_t  total_ic,
cell_asic ic 
)

Reads and parses the LTC6811 cell voltage registers.

Returns
uint8_t, PEC Status. 0: No PEC error detected -1: PEC error detected, retry read
Parameters
regControls which cell voltage register is read back.
total_icThe number of ICs in the daisy chain
icArray of the parsed cell codes from lowest to highest.

Definition at line 149 of file LTC6811.cpp.

◆ LTC6811_rdpwm()

int8_t LTC6811_rdpwm ( uint8_t  total_ic,
uint8_t  pwmReg,
cell_asic ic 
)

Reads pwm registers of a LTC6811 daisy chain.

Returns
int8_t, PEC Status. 0: Data read back has matching PEC -1: Data read back has incorrect PEC
Parameters
total_icNumber of ICs
pwmRegSelect register
icA two dimensional array that the function stores the read pwm data

Definition at line 384 of file LTC6811.cpp.

◆ LTC6811_rdsctrl()

int8_t LTC6811_rdsctrl ( uint8_t  total_ic,
uint8_t  sctrl_reg,
cell_asic ic 
)

Reads sctrl registers of a LTC6811 daisy chain.

Returns
int8_t, PEC Status. 0: Data read back has matching PEC -1: Data read back has incorrect PEC
Parameters
total_icNumber of ICs in the daisy chain
sctrl_regSelect register
icA two dimensional array that the function stores the read data

Definition at line 404 of file LTC6811.cpp.

◆ LTC6811_rdstat()

int8_t LTC6811_rdstat ( uint8_t  reg,
uint8_t  total_ic,
cell_asic ic 
)

Reads and parses the LTC6811 stat registers.

Returns
int8_t, PEC Status 0: No PEC error detected -1: PEC error detected, retry read
Parameters
regDetermines which Stat register is read back.
total_icThe number of ICs in the system
icArray of the parsed Stat codes

Definition at line 180 of file LTC6811.cpp.

◆ LTC6811_reset_crc_count()

void LTC6811_reset_crc_count ( uint8_t  total_ic,
cell_asic ic 
)

Helper Function that resets the PEC error counters.

Returns
void
Parameters
total_icNumber of ICs in the system
icA two dimensional array that will store the data

Definition at line 467 of file LTC6811.cpp.

◆ LTC6811_run_adc_overlap()

uint16_t LTC6811_run_adc_overlap ( uint8_t  total_ic,
cell_asic ic 
)

Helper Function that runs the ADC Overlap test.

Returns
uint16_t, error 0: Pass -1: False, Error detected
Parameters
total_icNumber of ICs in the system
icA two dimensional array that will store the data

Definition at line 297 of file LTC6811.cpp.

◆ LTC6811_run_adc_redundancy_st()

int16_t LTC6811_run_adc_redundancy_st ( uint8_t  adc_mode,
uint8_t  adc_reg,
uint8_t  total_ic,
cell_asic ic 
)

Helper function that runs the ADC Digital Redundancy commands and checks output for errors.

Returns
int16_t, error
Parameters
adc_modeADC Mode
adc_regType of register
total_icNumber of ICs in the system
icA two dimensional array that will store the data

Definition at line 307 of file LTC6811.cpp.

◆ LTC6811_run_cell_adc_st()

int16_t LTC6811_run_cell_adc_st ( uint8_t  adc_reg,
uint8_t  total_ic,
cell_asic ic,
uint8_t  md,
bool  adcopt 
)

Helper function that runs the ADC Self Tests.

Returns
int16_t, error Number of errors detected
Parameters
adc_regType of register
total_icNumber of ICs in the system
icA two dimensional array that will store the data
mdADC Mode
adcoptThe adcopt bit in the configuration register

Definition at line 284 of file LTC6811.cpp.

◆ LTC6811_run_openwire_multi()

void LTC6811_run_openwire_multi ( uint8_t  total_ic,
cell_asic ic 
)

Helper function that runs open wire for multiple cell and two consecutive cells detection.

Returns
void
Parameters
total_icNumber of ICs in the system
icA two dimensional array that will store the data

Definition at line 337 of file LTC6811.cpp.

◆ LTC6811_run_openwire_single()

void LTC6811_run_openwire_single ( uint8_t  total_ic,
cell_asic ic 
)

Helper function that runs the data sheet open wire algorithm for single cell detection.

Returns
void
Parameters
total_icNumber of ICs in the system
icA two dimensional array that will store the data

Definition at line 329 of file LTC6811.cpp.

◆ LTC6811_set_cfgr()

void LTC6811_set_cfgr ( uint8_t  nIC,
cell_asic ic,
bool  refon,
bool  adcopt,
bool  gpio[5],
bool  dcc[12],
bool  dcto[4],
uint16_t  uv,
uint16_t  ov 
)

Helper function to set appropriate bits in CFGR register based on bit function.

Returns
void
Parameters
nICCurrent IC
icA two dimensional array that will store the data
refonThe REFON bit
adcoptThe ADCOPT bit
gpioThe GPIO bits
dccThe DCC bits
dctoThe Dcto bits
uvThe UV value
ovThe OV value

Definition at line 483 of file LTC6811.cpp.

◆ LTC6811_set_cfgr_adcopt()

void LTC6811_set_cfgr_adcopt ( uint8_t  nIC,
cell_asic ic,
bool  adcopt 
)

Helper function to turn the ADCOPT bit HIGH or LOW.

Returns
void
Parameters
nICCurrent IC
icA two dimensional array that will store the data
adcoptThe ADCOPT bit

Definition at line 504 of file LTC6811.cpp.

◆ LTC6811_set_cfgr_dcto()

void LTC6811_set_cfgr_dcto ( uint8_t  nIC,
cell_asic ic,
bool  dcto[4] 
)

Definition at line 522 of file LTC6811.cpp.

◆ LTC6811_set_cfgr_dis()

void LTC6811_set_cfgr_dis ( uint8_t  nIC,
cell_asic ic,
bool  dcc[12] 
)

Definition at line 516 of file LTC6811.cpp.

◆ LTC6811_set_cfgr_gpio()

void LTC6811_set_cfgr_gpio ( uint8_t  nIC,
cell_asic ic,
bool  gpio[5] 
)

Definition at line 510 of file LTC6811.cpp.

◆ LTC6811_set_cfgr_ov()

void LTC6811_set_cfgr_ov ( uint8_t  nIC,
cell_asic ic,
uint16_t  ov 
)

Helper function to set ov field in CFGRA register.

Returns
void
Parameters
nICCurrent IC
icA two dimensional array that will store the data
ovThe OV value

Definition at line 534 of file LTC6811.cpp.

◆ LTC6811_set_cfgr_refon()

void LTC6811_set_cfgr_refon ( uint8_t  nIC,
cell_asic ic,
bool  refon 
)

Helper function to turn the refon bit HIGH or LOW.

Returns
void
Parameters
nICCurrent IC
icA two dimensional array that will store the data
refonThe REFON bit

Definition at line 498 of file LTC6811.cpp.

◆ LTC6811_set_cfgr_uv()

void LTC6811_set_cfgr_uv ( uint8_t  nIC,
cell_asic ic,
uint16_t  uv 
)

Helper function to set uv field in CFGRA register.

Returns
void
Parameters
nICCurrent IC
icA two dimensional array that will store the data
uvThe UV value

Definition at line 528 of file LTC6811.cpp.

◆ LTC6811_set_discharge()

void LTC6811_set_discharge ( int  Cell,
uint8_t  total_ic,
cell_asic ic 
)

Helper function to set discharge bit in CFG register.

Returns
void
Parameters
CellThe cell to be discharged
total_icNumber of ICs in the system
icA two dimensional array that will store the data

Definition at line 345 of file LTC6811.cpp.

◆ LTC6811_statst()

void LTC6811_statst ( uint8_t  MD,
uint8_t  ST 
)

Start a Status Register Self Test Conversion.

Returns
void
Parameters
MDADC Conversion Mode
STSets if self test 1 or 2 is run

Definition at line 252 of file LTC6811.cpp.

◆ LTC6811_stcomm()

void LTC6811_stcomm ( uint8_t  len)

Issues a stcomm command and clocks data out of the COMM register.

Returns
void
Parameters
lenLength of data to be transmitted

Definition at line 452 of file LTC6811.cpp.

◆ LTC6811_stsctrl()

void LTC6811_stsctrl ( )

Start Sctrl data communication This command will start the sctrl pulse communication over the spins.

Returns
void

Definition at line 418 of file LTC6811.cpp.

◆ LTC6811_wrcfg()

void LTC6811_wrcfg ( uint8_t  total_ic,
cell_asic ic 
)

Write the LTC6811 configuration register.

Returns
void
Parameters
total_icThe number of ICs being written
icA two dimensional array of the configuration data that will be written

Definition at line 86 of file LTC6811.cpp.

◆ LTC6811_wrcomm()

void LTC6811_wrcomm ( uint8_t  total_ic,
cell_asic ic 
)

Writes to the LTC6811 COMM register.

Returns
void
Parameters
total_icNumber of ICs in the daisy chain
icA two dimensional array of the comm data that will be written

Definition at line 434 of file LTC6811.cpp.

◆ LTC6811_wrpwm()

void LTC6811_wrpwm ( uint8_t  total_ic,
uint8_t  pwmReg,
cell_asic ic 
)

Write the LTC6811 PWM register.

Returns
void
Parameters
total_icNumber of ICs
pwmRegSelect register
icA two dimensional array that the function stores the data in.

Definition at line 374 of file LTC6811.cpp.

◆ LTC6811_wrsctrl()

void LTC6811_wrsctrl ( uint8_t  total_ic,
uint8_t  sctrl_reg,
cell_asic ic 
)

Write the LTC6811 Sctrl register.

Returns
void
Parameters
total_icNumber of ICs in the daisy chain
sctrl_regSelect register
icA two dimensional array of the data that will be written

Definition at line 395 of file LTC6811.cpp.