|
| #define | CFN_HAL_MAKE_TYPE(a, b, c, d) |
| |
| #define | CFN_HAL_PERIPHERAL_PREFIX 'A' |
| | Prefix for all HAL-level peripheral types. Reserving 'A' for the base HAL layer to avoid collisions with other layers.
|
| |
| #define | CFN_HAL_PERIPHERAL_TYPE(a, b, c) CFN_HAL_MAKE_TYPE(CFN_HAL_PERIPHERAL_PREFIX, a, b, c) |
| | Helper macro to create a HAL-level peripheral FourCC. Packs the HAL prefix and 3 characters into a 32-bit integer.
|
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_UNKNOWN 0 |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_ADC CFN_HAL_PERIPHERAL_TYPE('A', 'D', 'C') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_CAN CFN_HAL_PERIPHERAL_TYPE('C', 'A', 'N') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_CLOCK CFN_HAL_PERIPHERAL_TYPE('C', 'L', 'K') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_DAC CFN_HAL_PERIPHERAL_TYPE('D', 'A', 'C') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_DMA CFN_HAL_PERIPHERAL_TYPE('D', 'M', 'A') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_GPIO CFN_HAL_PERIPHERAL_TYPE('G', 'P', 'O') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_I2C CFN_HAL_PERIPHERAL_TYPE('I', '2', 'C') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_PWM CFN_HAL_PERIPHERAL_TYPE('P', 'W', 'M') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_RTC CFN_HAL_PERIPHERAL_TYPE('R', 'T', 'C') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_SPI CFN_HAL_PERIPHERAL_TYPE('S', 'P', 'I') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_TIMER CFN_HAL_PERIPHERAL_TYPE('T', 'I', 'M') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_UART CFN_HAL_PERIPHERAL_TYPE('U', 'R', 'T') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_WDT CFN_HAL_PERIPHERAL_TYPE('W', 'D', 'T') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_IRQ CFN_HAL_PERIPHERAL_TYPE('I', 'R', 'Q') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_NVM CFN_HAL_PERIPHERAL_TYPE('N', 'V', 'M') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_I2S CFN_HAL_PERIPHERAL_TYPE('I', '2', 'S') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_QSPI CFN_HAL_PERIPHERAL_TYPE('Q', 'S', 'P') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_CRYPTO CFN_HAL_PERIPHERAL_TYPE('C', 'R', 'Y') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_SDIO CFN_HAL_PERIPHERAL_TYPE('S', 'D', 'I') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_USB CFN_HAL_PERIPHERAL_TYPE('U', 'S', 'B') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_ETH CFN_HAL_PERIPHERAL_TYPE('E', 'T', 'H') |
| |
| #define | CFN_HAL_PERIPHERAL_TYPE_COMP CFN_HAL_PERIPHERAL_TYPE('C', 'M', 'P') |
| |
Common type definitions and enums for the HAL.
Copyright (c) 2026 Hisham Moussa Daou https://www.whileone.me
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.