Enumerated Types¶
-
group
group_csdidac_enums
Describes the enumeration types defined by the CSDIDAC.
These enumerations can be used for checking CSDIDAC functions’ return status, for defining a CSDIDAC LSB and polarity, and for choosing IDAC for an operation and defining its states. For detailed information about enumerations, see each enumeration description.
Enums
-
enum
cy_en_csdidac_status_t
¶ cy_en_csdidac_status_t: CSDIDAC return enumeration type.
Values:
-
enumerator
CY_CSDIDAC_SUCCESS
¶ The operation executed successfully.
-
enumerator
CY_CSDIDAC_BAD_PARAM
¶ An input parameter is invalid.
The user checks whether all the input parameters are valid.
-
enumerator
CY_CSDIDAC_HW_BUSY
¶ The CSD HW block is busy, i.e.
any of current channel (A or B) is enabled.
-
enumerator
CY_CSDIDAC_HW_LOCKED
¶ The CSD HW block is acquired and locked by other middleware or application.
The CSDIDAC middleware waits for the CSD HW block release to acquire it for use.
-
enumerator
CY_CSDIDAC_HW_FAILURE
¶ A CSD HW block failure.
The possible reasons:
No peripheral clock assigned to the CSD HW block.
Peripheral clock assigned to the CSD HW block is disabled.
The CSD HW clock frequency is less than 100 kHz.
The configuration CSD HW block registers are corrupted.
The CSD HW block is damaged.
-
enumerator
CY_CSDIDAC_BAD_CONFIGURATION
¶ The CSDIDAC configuration structure initialization issue.
The possible reasons:
The base pointer is initialized with NULL.
The csdCxtPtr pointer is initialized with NULL.
The configA or configB fields are not enumerators of the cy_en_csdidac_channel_config_t type.
The ptrPinA (ptrPinB) field is initialized with NULL when configA (configB) is initialized with CY_CSDIDAC_GPIO.
The configA and configB fields are initialized with CY_CSDIDAC_DISABLED simultaneously.
The configA and configB fields are initialized with CY_CSDIDAC_JOIN simultaneously.
The configA (configB) field is initialized with CY_CSDIDAC_JOIN when configB (configA) is initialized with CY_CSDIDAC_DISABLED.
-
enumerator
-
enum
cy_en_csdidac_lsb_t
¶ cy_en_csdidac_lsb_t: The CSDIDAC output current LSB enumeration type.
The user can choose LSB when the Cy_CSDIDAC_OutputEnableExt() function is called and can check which LSB was chosen by the Cy_CSDIDAC_OutputEnable() function in the cy_stc_csdidac_context_t structure.
Values:
-
enumerator
CY_CSDIDAC_LSB_37_IDX
¶ Index for 37.5 nA LSB.
-
enumerator
CY_CSDIDAC_LSB_75_IDX
¶ Index for 75.0 nA LSB.
-
enumerator
CY_CSDIDAC_LSB_300_IDX
¶ Index for 0.3 uA LSB.
-
enumerator
CY_CSDIDAC_LSB_600_IDX
¶ Index for 0.6 uA LSB.
-
enumerator
CY_CSDIDAC_LSB_2400_IDX
¶ Index for 2.4 uA LSB.
-
enumerator
CY_CSDIDAC_LSB_4800_IDX
¶ Index for 4.8 uA LSB.
-
enumerator
-
enum
cy_en_csdidac_polarity_t
¶ cy_en_csdidac_polarity_t: The CSDIDAC polarity enumeration type.
The user can choose the polarity when the Cy_CSDIDAC_OutputEnableExt() function is called and can check which polarity was chosen by the Cy_CSDIDAC_OutputEnable() function in the cy_stc_csdidac_context_t structure.
Values:
-
enumerator
CY_CSDIDAC_SOURCE
¶ Source polarity.
-
enumerator
CY_CSDIDAC_SINK
¶ Sink polarity.
-
enumerator
-
enum
cy_en_csdidac_state_t
¶ cy_en_csdidac_state_t: The CSDIDAC channel enabling enumeration type.
The user can check which channel (A or B or both) is currently enabled in the cy_stc_csdidac_context_t structure.
Values:
-
enumerator
CY_CSDIDAC_DISABLE
¶ The channel is disabled.
-
enumerator
CY_CSDIDAC_ENABLE
¶ The channel is enabled.
-
enumerator
-
enum
cy_en_csdidac_choice_t
¶ cy_en_csdidac_choice_t: The CSDIDAC choosing enumeration type.
The user can choose channel A or B to operate with the Cy_CSDIDAC_OutputEnableExt(), Cy_CSDIDAC_OutputDisable(), or Cy_CSDIDAC_OutputEnable() functions.
Values:
-
enumerator
CY_CSDIDAC_A
¶ The IDAC A is chosen for an operation.
-
enumerator
CY_CSDIDAC_B
¶ The IDAC B is chosen for an operation.
-
enumerator
CY_CSDIDAC_AB
¶ Both IDACs are chosen for an operation.
-
enumerator
-
enum
cy_en_csdidac_channel_config_t
¶ cy_en_csdidac_channel_config_t: The CSDIDAC channel configuration defines either disabled or enabled with specific routing.
Values:
-
enumerator
CY_CSDIDAC_DISABLED
¶ The IDAC channel is disabled.
-
enumerator
CY_CSDIDAC_GPIO
¶ The IDAC channel is enabled and routed to a pin.
-
enumerator
CY_CSDIDAC_AMUX
¶ The IDAC channel is enabled and routed to a corresponding analog bus.
-
enumerator
CY_CSDIDAC_JOIN
¶ The IDAC channel is enabled and routed to the other IDAC channel.
-
enumerator
-
enum