34 #if defined(IDAC_COUNT) && (IDAC_COUNT > 0)
52 #if defined(_EFM32_ZERO_FAMILY) || defined(_EFM32_HAPPY_FAMILY)
53 #define ERRATA_FIX_IDAC_E101_EN
81 EFM_ASSERT(IDAC_REF_VALID(idac));
83 tmp = (uint32_t)(init->
prsSel);
116 volatile uint32_t *reg;
118 EFM_ASSERT(IDAC_REF_VALID(idac));
135 EFM_ASSERT(IDAC_REF_VALID(idac));
137 #if defined(ERRATA_FIX_IDAC_E101_EN)
150 idac->
DUTYCONFIG = IDAC_DUTYCONFIG_DUTYCYCLEEN;
156 #if defined ( _IDAC_CAL_MASK )
157 idac->CAL = _IDAC_CAL_RESETVALUE;
174 volatile uint32_t *reg;
176 EFM_ASSERT(IDAC_REF_VALID(idac));
203 #if defined( _IDAC_CURPROG_TUNING_MASK )
208 EFM_ASSERT(IDAC_REF_VALID(idac));
212 #if defined ( _IDAC_CAL_MASK )
218 idac->CAL = (
DEVINFO->IDAC0CAL0 & _DEVINFO_IDAC0CAL0_RANGE0_MASK)
219 >> _DEVINFO_IDAC0CAL0_RANGE0_SHIFT;
222 idac->CAL = (
DEVINFO->IDAC0CAL0 & _DEVINFO_IDAC0CAL0_RANGE1_MASK)
223 >> _DEVINFO_IDAC0CAL0_RANGE1_SHIFT;
226 idac->CAL = (
DEVINFO->IDAC0CAL0 & _DEVINFO_IDAC0CAL0_RANGE2_MASK)
227 >> _DEVINFO_IDAC0CAL0_RANGE2_SHIFT;
230 idac->CAL = (
DEVINFO->IDAC0CAL0 & _DEVINFO_IDAC0CAL0_RANGE3_MASK)
231 >> _DEVINFO_IDAC0CAL0_RANGE3_SHIFT;
236 tmp |= (uint32_t)range;
238 #elif defined( _IDAC_CURPROG_TUNING_MASK )
313 tmp |= (uint32_t)range;
316 #warning "IDAC calibration register definition unknown."
337 EFM_ASSERT(IDAC_REF_VALID(idac));
359 volatile uint32_t *reg;
361 EFM_ASSERT(IDAC_REF_VALID(idac));
Clock management unit (CMU) API.
#define _IDAC_CURPROG_RANGESEL_MASK
#define _DEVINFO_IDAC0CAL0_SOURCERANGE1TUNING_SHIFT
#define _DEVINFO_IDAC0CAL1_SINKRANGE3TUNING_MASK
#define _DEVINFO_IDAC0CAL1_SINKRANGE0TUNING_SHIFT
IDAC_PRSSEL_TypeDef prsSel
Emlib peripheral API "assert" implementation.
#define _DEVINFO_IDAC0CAL0_SOURCERANGE2TUNING_MASK
#define _DEVINFO_IDAC0CAL0_SOURCERANGE3TUNING_MASK
#define _DEVINFO_IDAC0CAL1_SINKRANGE0TUNING_MASK
RAM and peripheral bit-field set and clear API.
Current Digital to Analog Converter (IDAC) peripheral API.
#define _IDAC_CURPROG_TUNING_SHIFT
#define _DEVINFO_IDAC0CAL0_SOURCERANGE2TUNING_SHIFT
#define _DEVINFO_IDAC0CAL1_SINKRANGE2TUNING_MASK
#define IDAC_CURPROG_RANGESEL_RANGE0
#define _IDAC_CTRL_OUTEN_SHIFT
#define _DEVINFO_IDAC0CAL0_SOURCERANGE0TUNING_MASK
#define _IDAC_CURPROG_STEPSEL_MASK
#define _IDAC_CTRL_EN_SHIFT
void IDAC_Enable(IDAC_TypeDef *idac, bool enable)
Enable/disable IDAC.
#define _IDAC_CURPROG_TUNING_MASK
void IDAC_MinimalOutputTransitionMode(IDAC_TypeDef *idac, bool enable)
Enable/disable Minimal Output Transition mode.
#define _IDAC_CTRL_MINOUTTRANS_SHIFT
#define _DEVINFO_IDAC0CAL0_SOURCERANGE1TUNING_MASK
#define IDAC_CTRL_OUTENPRS
void IDAC_RangeSet(IDAC_TypeDef *idac, const IDAC_Range_TypeDef range)
Set the current range of the IDAC output.
#define _DEVINFO_IDAC0CAL1_SINKRANGE2TUNING_SHIFT
#define _IDAC_DUTYCONFIG_RESETVALUE
#define _IDAC_CURPROG_RANGESEL_SHIFT
#define _DEVINFO_IDAC0CAL0_SOURCERANGE0TUNING_SHIFT
void IDAC_Init(IDAC_TypeDef *idac, const IDAC_Init_TypeDef *init)
Initialize IDAC.
#define IDAC_CTRL_CURSINK
IDAC_OutMode_TypeDef outMode
void IDAC_StepSet(IDAC_TypeDef *idac, const uint32_t step)
Set the current step of the IDAC output.
#define _DEVINFO_IDAC0CAL0_SOURCERANGE3TUNING_SHIFT
#define _IDAC_CURPROG_RESETVALUE
#define _IDAC_CTRL_RESETVALUE
#define _DEVINFO_IDAC0CAL1_SINKRANGE1TUNING_SHIFT
void IDAC_Reset(IDAC_TypeDef *idac)
Reset IDAC to same state as after a HW reset.
void IDAC_OutEnable(IDAC_TypeDef *idac, bool enable)
Enable/disable the IDAC OUT pin.
__STATIC_INLINE void BUS_RegBitWrite(volatile uint32_t *addr, unsigned int bit, unsigned int val)
Perform a single-bit write operation on a peripheral register.
#define _IDAC_CURPROG_STEPSEL_SHIFT
#define _DEVINFO_IDAC0CAL1_SINKRANGE3TUNING_SHIFT
#define _DEVINFO_IDAC0CAL1_SINKRANGE1TUNING_MASK