![]() |
![]() |
|
MSPM0G1X0X_G3X0X Driver Library
1.10.01.05
|
|
Modules | |
| DL_VREF_CTL1_READY | |
| DL_VREF_SH | |
| DL_VREF_HOLD | |
Data Structures | |
| struct | DL_VREF_ClockConfig |
| Configuration struct for DL_VREF_setClockConfig. More... | |
| struct | DL_VREF_Config |
| Configuration struct for DL_VREF_Config. More... | |
Enumerations | |
| enum | DL_VREF_CLOCK { DL_VREF_CLOCK_LFCLK = VREF_CLKSEL_LFCLK_SEL_MASK, DL_VREF_CLOCK_MFCLK = VREF_CLKSEL_MFCLK_SEL_MASK, DL_VREF_CLOCK_BUSCLK = VREF_CLKSEL_BUSCLK_SEL_MASK } |
| enum | DL_VREF_CLOCK_DIVIDE { DL_VREF_CLOCK_DIVIDE_1 = 0, DL_VREF_CLOCK_DIVIDE_2 = 1, DL_VREF_CLOCK_DIVIDE_4 = 3, DL_VREF_CLOCK_DIVIDE_6 = 5, DL_VREF_CLOCK_DIVIDE_8 = 7 } |
| enum | DL_VREF_ENABLE { DL_VREF_ENABLE_DISABLE = VREF_CTL0_ENABLE_DISABLE, DL_VREF_ENABLE_ENABLE = VREF_CTL0_ENABLE_ENABLE } |
| enum | DL_VREF_BUFCONFIG { DL_VREF_BUFCONFIG_OUTPUT_2_5V = VREF_CTL0_BUFCONFIG_OUTPUT2P5V, DL_VREF_BUFCONFIG_OUTPUT_1_4V = VREF_CTL0_BUFCONFIG_OUTPUT1P4V } |
| enum | DL_VREF_SHMODE { DL_VREF_SHMODE_DISABLE = VREF_CTL0_SHMODE_DISABLE, DL_VREF_SHMODE_ENABLE = VREF_CTL0_SHMODE_ENABLE } |
Functions | |
| __STATIC_INLINE void | DL_VREF_enablePower (VREF_Regs *vref) |
| Enables power on VREF module. More... | |
| __STATIC_INLINE void | DL_VREF_disablePower (VREF_Regs *vref) |
| Disable power on VREF module. More... | |
| __STATIC_INLINE void | DL_VREF_enableInternalRef (VREF_Regs *vref) |
| Enables Internal VREF. More... | |
| __STATIC_INLINE void | DL_VREF_disableInternalRef (VREF_Regs *vref) |
| Disables Internal VREF, allows for External VREF. More... | |
| __STATIC_INLINE bool | DL_VREF_isEnabled (VREF_Regs *vref) |
| Checks if the internal VREF is enabled. More... | |
| void | DL_VREF_setClockConfig (VREF_Regs *vref, DL_VREF_ClockConfig *config) |
| Set the clock select and clock divide fields in VREF. More... | |
| void | DL_VREF_getClockConfig (VREF_Regs *vref, DL_VREF_ClockConfig *config) |
| Copy the clock select and clock divide fields in VREF to config. More... | |
| __STATIC_INLINE void | DL_VREF_reset (VREF_Regs *vref) |
| Resets the VREF module. More... | |
| __STATIC_INLINE bool | DL_VREF_isReset (VREF_Regs *vref) |
| Returns if VREF peripheral was reset. More... | |
| __STATIC_INLINE uint32_t | DL_VREF_getStatus (VREF_Regs *vref) |
| Returns VREF register status. More... | |
| void | DL_VREF_configReference (VREF_Regs *vref, DL_VREF_Config *config) |
| Configure VREF enable, control registers. More... | |
The Voltage Reference Driver Library allows full configuration of the MSPM0 VREF module. The VREF module contains a configurable voltage reference buffer which allows users to supply a stable internal reference to on-board analog peripherals. It also supports bringing in an external reference for applications where higher accuracy is required.
| enum DL_VREF_CLOCK |
| enum DL_VREF_CLOCK_DIVIDE |
| enum DL_VREF_ENABLE |
| enum DL_VREF_BUFCONFIG |
| enum DL_VREF_SHMODE |
| __STATIC_INLINE void DL_VREF_enablePower | ( | VREF_Regs * | vref | ) |
Enables power on VREF module.
| vref | Pointer to the register overlay for the peripheral |
| __STATIC_INLINE void DL_VREF_disablePower | ( | VREF_Regs * | vref | ) |
Disable power on VREF module.
| vref | Pointer to the register overlay for the peripheral |
| __STATIC_INLINE void DL_VREF_enableInternalRef | ( | VREF_Regs * | vref | ) |
Enables Internal VREF.
This function only enables the internal VREF but doesn't configure all settings. It's recommended to use DL_VREF_configReference to configure and enable VREF with all parameters.
| vref | Pointer to the register overlay for the peripheral |
| __STATIC_INLINE void DL_VREF_disableInternalRef | ( | VREF_Regs * | vref | ) |
Disables Internal VREF, allows for External VREF.
The internal VREF must be disabled when using external VREF input.
| vref | Pointer to the register overlay for the peripheral |
| __STATIC_INLINE bool DL_VREF_isEnabled | ( | VREF_Regs * | vref | ) |
Checks if the internal VREF is enabled.
| vref | Pointer to the register overlay for the peripheral |
| true | The internal VREF is enabled |
| false | The internal VREF is disabled, external VREF can be used |
References DL_VREF_getClockConfig(), and DL_VREF_setClockConfig().
| void DL_VREF_setClockConfig | ( | VREF_Regs * | vref, |
| DL_VREF_ClockConfig * | config | ||
| ) |
Set the clock select and clock divide fields in VREF.
| vref | Pointer to the register overlay for the peripheral |
| config | Pointer to the configuration structure |
Referenced by DL_VREF_isEnabled().
| void DL_VREF_getClockConfig | ( | VREF_Regs * | vref, |
| DL_VREF_ClockConfig * | config | ||
| ) |
Copy the clock select and clock divide fields in VREF to config.
| vref | Pointer to the register overlay for the peripheral |
| config | Pointer to the configuration structure |
Referenced by DL_VREF_isEnabled().
| __STATIC_INLINE void DL_VREF_reset | ( | VREF_Regs * | vref | ) |
Resets the VREF module.
| vref | Pointer to the register overlay for the peripheral |
| __STATIC_INLINE bool DL_VREF_isReset | ( | VREF_Regs * | vref | ) |
Returns if VREF peripheral was reset.
| vref | Pointer to the register overlay for the VREF peripheral |
| __STATIC_INLINE uint32_t DL_VREF_getStatus | ( | VREF_Regs * | vref | ) |
Returns VREF register status.
| vref | Pointer to the register overlay for the VREF peripheral |
References DL_VREF_configReference().
| void DL_VREF_configReference | ( | VREF_Regs * | vref, |
| DL_VREF_Config * | config | ||
| ) |
Configure VREF enable, control registers.
| vref | Pointer to the register overlay for the VREF peripheral |
| config | Pointer to DL_VREF_Config structure to configure the peripheral |
Referenced by DL_VREF_getStatus().