These are advanced functions for trimming the offset and slope of the opamps.
More...
These are advanced functions for trimming the offset and slope of the opamps.
Most users do not need to call these functions and can use the factory trimmed values.
◆ Cy_CTB_OpampSetOffset()
Overrides the CTB opamp offset factory trim.
The trim is a six-bit value and the MSB is a direction bit.
Bit 5 | Bits 4:0 | Note |
0 | 00000 | Negative trim direction - minimum setting |
0 | 11111 | Negative trim direction - maximum setting |
1 | 00000 | Positive trim direction - minimum setting |
1 | 11111 | Positive trim direction - maximum setting |
- Parameters
-
- Function Usage
uint8_t trim;
for (trim = 0u; trim <= 0x3F; trim++)
{
}
◆ Cy_CTB_OpampGetOffset()
Returns the current CTB opamp offset trim value.
- Parameters
-
- Returns
- Offset trim value
- Function Usage
◆ Cy_CTB_OpampSetSlope()
Overrides the CTB opamp slope factory trim.
The offset of the opamp will vary across the temperature. This trim compensates for the slope of the offset across temperature. This compensation uses a bias current from the Analog Reference block. To disable it, set the trim to 0.
The trim is a six-bit value and the MSB is a direction bit.
Bit 5 | Bits 4:0 | Note |
0 | 00000 | Negative trim direction - minimum setting |
0 | 11111 | Negative trim direction - maximum setting |
1 | 00000 | Positive trim direction - minimum setting |
1 | 11111 | Positive trim direction - maximum setting |
- Parameters
-
- Function Usage
uint8_t trim;
for (trim = 0u; trim <= 0x3F; trim++)
{
}
◆ Cy_CTB_OpampGetSlope()
Returns the CTB opamp slope trim value.
- Parameters
-
- Returns
- Slope trim value
- Function Usage
◆ Cy_CTB_DSAB_SetSource()
Overrides the Deep Sleep Amplifier Bias current bias sources from factory trim settings.
If the default (CY_CTB_SRSS_ZTC_DSAB_PTAT) DSAB setting is changed then a periodic re-trim of CTB(m) offset must be performed.
- Parameters
-
- Function Usage
◆ Cy_CTB_DSAB_GetSource()
Returns the Deep Sleep Amplifier Bias current bias source.
- Parameters
-
base | The pointer to structure-describing registers. |
- Returns
- biasSource cy_en_ctb_dsab_bias_source_t
- Function Usage
◆ Cy_CTB_DSAB_SetCurrent()
void Cy_CTB_DSAB_SetCurrent |
( |
CTBM_Type * |
base, |
|
|
uint32_t |
biasCurrent |
|
) |
| |
Overrides the Deep Sleep Amplifier Bias current value from factory trim settings.
Periodic re-trim of CTB(m) offset must be performed if these settings are overridden.
- Parameters
-
base | The pointer to structure-describing registers. |
biasCurrent | The bias current value. |
- Function Usage
◆ Cy_CTB_DSAB_GetCurrent()
uint32_t Cy_CTB_DSAB_GetCurrent |
( |
const CTBM_Type * |
base | ) |
|
Returns the Deep Sleep Amplifier Bias current value.
- Parameters
-
base | The pointer to structure-describing registers. |
- Returns
- The bias current value.
- Function Usage