Hardware Abstraction Layer (HAL)

General Description

HAL specific return codes definitions for all drivers.

HAL drivers are generally built on top of a lower level driver. In this case the errors returned from the HAL could be one of the values below or a value from that lower level driver. See the device specific documentation for details about the other error codes.

API Reference

 ADC HAL Results
 ADC specific return codes.
 
 Clock HAL Results
 Clock specific return codes.
 
 Comparator HAL Results
 Comparator specific return codes.
 
 CRC HAL Results
 CRC specific return codes.
 
 DAC HAL Results
 DAC specific return codes.
 
 DMA HAL Results
 DMA specific return codes.
 
 EZI2C HAL Results
 EZI2C specific return codes.
 
 Flash HAL Results
 Flash specific return codes.
 
 HWMGR HAL Results
 HWMGR specific return codes.
 
 I2C HAL Results
 I2C specific return codes.
 
 I2S HAL Results
 I2S specific return codes.
 
 Interconnect HAL Results
 Interconnect specific return codes.
 
 LPTimer HAL Results
 LPTimer specific return codes.
 
 Opamp HAL Results
 Opamp specific return codes.
 
 PDM/PCM HAL Results
 PDM/PCM specific return codes.
 
 PWM HAL Results
 PWM specific return codes.
 
 QSPI HAL Results
 QSPI specific return codes.
 
 RTC HAL Results
 RTC specific return codes.
 
 SDHC HAL Results
 SDHC specific return codes.
 
 SDIO HAL Results
 SDIO specific return codes.
 
 SPI HAL Results
 SPI specific return codes.
 
 SYSPM HAL Results
 SYSPM specific return codes.
 
 Timer HAL Results
 Timer specific return codes.
 
 TRNG HAL Results
 TRNG specific return codes.
 
 UART HAL Results
 UART specific return codes.
 
 USB Device HAL Results
 USB Device specific return codes.
 
 WDT HAL Results
 WDT specific return codes.
 

Enumerations

enum  cyhal_rslt_module_chip {
  CYHAL_RSLT_MODULE_HWMGR = (0x01 << 8),
  CYHAL_RSLT_MODULE_ADC = (0x02 << 8),
  CYHAL_RSLT_MODULE_CLOCK = (0x03 << 8),
  CYHAL_RSLT_MODULE_COMP = (0x04 << 8),
  CYHAL_RSLT_MODULE_CRC = (0x05 << 8),
  CYHAL_RSLT_MODULE_DAC = (0x06 << 8),
  CYHAL_RSLT_MODULE_DMA = (0x07 << 8),
  CYHAL_RSLT_MODULE_EZI2C = (0x08 << 8),
  CYHAL_RSLT_MODULE_FLASH = (0x09 << 8),
  CYHAL_RSLT_MODULE_GPIO = (0x0A << 8),
  CYHAL_RSLT_MODULE_I2C = (0x0B << 8),
  CYHAL_RSLT_MODULE_I2S = (0x0C << 8),
  CYHAL_RSLT_MODULE_INTERCONNECT = (0x0D << 8),
  CYHAL_RSLT_MODULE_OPAMP = (0x0E << 8),
  CYHAL_RSLT_MODULE_PDMPCM = (0x0F << 8),
  CYHAL_RSLT_MODULE_PWM = (0x10 << 8),
  CYHAL_RSLT_MODULE_QSPI = (0x11 << 8),
  CYHAL_RSLT_MODULE_QUADDEC = (0x12 << 8),
  CYHAL_RSLT_MODULE_RTC = (0x13 << 8),
  CYHAL_RSLT_MODULE_SDHC = (0x14 << 8),
  CYHAL_RSLT_MODULE_SDIO = (0x15 << 8),
  CYHAL_RSLT_MODULE_SPI = (0x16 << 8),
  CYHAL_RSLT_MODULE_SYSPM = (0x17 << 8),
  CYHAL_RSLT_MODULE_SYSTEM = (0x18 << 8),
  CYHAL_RSLT_MODULE_TIMER = (0x19 << 8),
  CYHAL_RSLT_MODULE_TRNG = (0x1A << 8),
  CYHAL_RSLT_MODULE_UART = (0x1B << 8),
  CYHAL_RSLT_MODULE_USB = (0x1C << 8),
  CYHAL_RSLT_MODULE_WDT = (0x1D << 8)
}
 Enum to specify module IDs for cy_rslt_t values returned from the HAL. More...
 
enum  cyhal_signal_digital_out_t {
  CYHAL_SIGNAL_DMA_COMPLETE,
  CYHAL_SIGNAL_PWM_OUT,
  CYHAL_SIGNAL_PWM_OUT_INV,
  CYHAL_SIGNAL_PWM_OVERFLOW,
  CYHAL_SIGNAL_PWM_UNDERFLOW,
  CYHAL_SIGNAL_PWM_COMPARE,
  CYHAL_SIGNAL_TIMER_OVERFLOW,
  CYHAL_SIGNAL_TIMER_UNDERFLOW,
  CYHAL_SIGNAL_TIMER_CAPTURE,
  CYHAL_SIGNAL_QUADDEC_TC
}
 Enum to specify all of the digital output signals supported by different hardware peripherals. More...
 

Enumeration Type Documentation

◆ cyhal_rslt_module_chip

Enum to specify module IDs for cy_rslt_t values returned from the HAL.

Enumerator
CYHAL_RSLT_MODULE_HWMGR 

An error occurred in hardware management module.

CYHAL_RSLT_MODULE_ADC 

An error occurred in ADC module.

CYHAL_RSLT_MODULE_CLOCK 

An error occurred in Clock module.

CYHAL_RSLT_MODULE_COMP 

An error occurred in comparator module.

CYHAL_RSLT_MODULE_CRC 

An error occurred in crypto CRC module.

CYHAL_RSLT_MODULE_DAC 

An error occurred in DAC module.

CYHAL_RSLT_MODULE_DMA 

An error occurred in DMA module.

CYHAL_RSLT_MODULE_EZI2C 

An error occurred in EZI2C module.

CYHAL_RSLT_MODULE_FLASH 

An error occurred in flash module.

CYHAL_RSLT_MODULE_GPIO 

An error occurred in GPIO module.

CYHAL_RSLT_MODULE_I2C 

An error occurred in I2C module.

CYHAL_RSLT_MODULE_I2S 

An error occurred in I2S module.

CYHAL_RSLT_MODULE_INTERCONNECT 

An error occurred in Interconnect module.

CYHAL_RSLT_MODULE_OPAMP 

An error occurred in OpAmp module.

CYHAL_RSLT_MODULE_PDMPCM 

An error occurred in PDM/PCM module.

CYHAL_RSLT_MODULE_PWM 

An error occurred in PWM module.

CYHAL_RSLT_MODULE_QSPI 

An error occurred in QSPI module.

CYHAL_RSLT_MODULE_QUADDEC 

An error occurred in Quadrature Decoder module.

CYHAL_RSLT_MODULE_RTC 

An error occurred in RTC module.

CYHAL_RSLT_MODULE_SDHC 

An error occurred in SDHC module.

CYHAL_RSLT_MODULE_SDIO 

An error occurred in SDIO module.

CYHAL_RSLT_MODULE_SPI 

An error occurred in SPI module.

CYHAL_RSLT_MODULE_SYSPM 

An error occurred in SysPM module.

CYHAL_RSLT_MODULE_SYSTEM 

An error occurred in System module.

CYHAL_RSLT_MODULE_TIMER 

An error occurred in Timer module.

CYHAL_RSLT_MODULE_TRNG 

An error occurred in RNG module.

CYHAL_RSLT_MODULE_UART 

An error occurred in UART module.

CYHAL_RSLT_MODULE_USB 

An error occurred in USB module.

CYHAL_RSLT_MODULE_WDT 

An error occurred in WDT module.

◆ cyhal_signal_digital_out_t

Enum to specify all of the digital output signals supported by different hardware peripherals.

These can be used as inputs to other peripherals if the selected device has internal routing resources.

Enumerator
CYHAL_SIGNAL_DMA_COMPLETE 

DMA complete signal.

CYHAL_SIGNAL_PWM_OUT 

PWM output signal.

CYHAL_SIGNAL_PWM_OUT_INV 

PWM output signal inverted.

CYHAL_SIGNAL_PWM_OVERFLOW 

PWM overflow signal.

CYHAL_SIGNAL_PWM_UNDERFLOW 

PWM underflow signal.

CYHAL_SIGNAL_PWM_COMPARE 

PWM period match signal.

CYHAL_SIGNAL_TIMER_OVERFLOW 

Timer overflow signal.

CYHAL_SIGNAL_TIMER_UNDERFLOW 

Timer underflow signal.

CYHAL_SIGNAL_TIMER_CAPTURE 

Timer capture match signal.

CYHAL_SIGNAL_QUADDEC_TC 

Quadrature Decoder terminal count signal. High on index event, or when counter reaches min/max value.