Functions | |
uint16_t | BattBak_unlockBackupSubSystem (uint16_t baseAddress) |
Unlocks any pending backup input pins and RTC_B interrupts to be serviced. More... | |
void | BattBak_enableBackupSupplyToADC (uint16_t baseAddress) |
Enables the backup supply to be measured by the ADC battery monitor input. More... | |
void | BattBak_disableBackupSupplyToADC (uint16_t baseAddress) |
Disables the backup supply input to the ADC module. More... | |
void | BattBak_switchToBackupSupplyManually (uint16_t baseAddress) |
Manually switches to backup supply. More... | |
void | BattBak_disable (uint16_t baseAddress) |
Disables backup battery system. More... | |
void | BattBak_initAndEnableCharger (uint16_t baseAddress, uint8_t chargerEndVoltage, uint8_t chargeCurrent) |
Initializes and enables the backup battery charger. More... | |
void | BattBak_disableCharger (uint16_t baseAddress) |
Disables and resets backup battery charger settings. More... | |
void | BattBak_setBackupRAMData (uint16_t baseAddress, uint8_t backupRAMSelect, uint16_t data) |
Sets data into the selected backup RAM space. More... | |
uint16_t | BattBak_getBackupRAMData (uint16_t baseAddress, uint8_t backupRAMSelect) |
Returns the data from the selected backup RAM space. More... | |
void BattBak_disable | ( | uint16_t | baseAddress | ) |
Disables backup battery system.
This function disables the battery backup system from being used. The battery backup system is re-enabled after a power cycle.
baseAddress | is the base address of the BATTBAK module. |
void BattBak_disableBackupSupplyToADC | ( | uint16_t | baseAddress | ) |
Disables the backup supply input to the ADC module.
This function disables the ability to monitor the backup supply voltage from the ADC battery monitor input.
baseAddress | is the base address of the BATTBAK module. |
void BattBak_disableCharger | ( | uint16_t | baseAddress | ) |
Disables and resets backup battery charger settings.
This function clears all backup battery charger settings and disables it. To re-enable the charger, a call to BattBak_initAndEnableCharger() is required.
baseAddress | is the base address of the BATTBAK module. |
void BattBak_enableBackupSupplyToADC | ( | uint16_t | baseAddress | ) |
Enables the backup supply to be measured by the ADC battery monitor input.
This function enables the backup supply signal to be monitored by the ADC battery supply monitor input, to allow a measurement of the voltage from the backup battery.
baseAddress | is the base address of the BATTBAK module. |
uint16_t BattBak_getBackupRAMData | ( | uint16_t | baseAddress, |
uint8_t | backupRAMSelect | ||
) |
Returns the data from the selected backup RAM space.
This function returns the 16-bit data currently residing in the selected backup RAM space.
baseAddress | is the base address of the BATTBAK module. |
backupRAMSelect | is the backup RAM space to read out from. Valid values are:
|
void BattBak_initAndEnableCharger | ( | uint16_t | baseAddress, |
uint8_t | chargerEndVoltage, | ||
uint8_t | chargeCurrent | ||
) |
Initializes and enables the backup battery charger.
This function initializes the backup battery charger with the selected settings.
baseAddress | is the base address of the BATTBAK module. |
chargerEndVoltage | is the maximum voltage to charge the backup battery to. Valid values are:
|
chargeCurrent | is the maximum current to charge the backup battery at. Valid values are:
|
void BattBak_setBackupRAMData | ( | uint16_t | baseAddress, |
uint8_t | backupRAMSelect, | ||
uint16_t | data | ||
) |
Sets data into the selected backup RAM space.
This function sets the given 16-bit data into the selected backup RAM space.
baseAddress | is the base address of the BATTBAK module. |
backupRAMSelect | is the backup RAM space to set data into. Valid values are:
|
data | is the data to set into the selected backup RAM space. |
void BattBak_switchToBackupSupplyManually | ( | uint16_t | baseAddress | ) |
Manually switches to backup supply.
This function uses software to manually switch to the backup battery supply. Once this bit is set, it will be automatically reset by a POR and the system returns to an automatic switch to backup supply.
baseAddress | is the base address of the BATTBAK module. |
uint16_t BattBak_unlockBackupSubSystem | ( | uint16_t | baseAddress | ) |
Unlocks any pending backup input pins and RTC_B interrupts to be serviced.
This function unlocks the ability to view and service any pending backup input pin interrupts, as well as pending RTC_B interrupts. The backup sub- system can only be unlocked when the backup domain has settled, so this function returns the status of the unlock bit after it has been to be verified by user code. Please note, the backup sub-system should only be unlocked after modifying the RTC_B registers.
baseAddress | is the base address of the BATTBAK module. |