Solaris Software
Loading...
Searching...
No Matches
types.h
Go to the documentation of this file.
1/**
2 * @file types.h
3 * @brief Portable integer types and SPI/storage configuration types for SPP.
4 *
5 * Provides width-exact integer typedefs derived from <stdint.h> and <stdbool.h>
6 * so that SPP code is independent of compiler-specific type widths. Also
7 * defines configuration structs shared between the HAL interface and port
8 * implementations.
9 *
10 * Naming conventions used in this file:
11 * - Portable base types: spp_<sign><width>_t (lowercase snake)
12 * - Config struct types: SPP_<Name>_t (uppercase prefix, CamelCase)
13 * - Enum / constant values: K_SPP_*
14 */
15
16#ifndef SPP_TYPES_H
17#define SPP_TYPES_H
18
19#include <stdint.h>
20#include <stdbool.h>
21#include <stddef.h>
22
23/* ----------------------------------------------------------------
24 * Portable integer aliases
25 * ---------------------------------------------------------------- */
26
27typedef uint8_t spp_uint8_t; /**< Unsigned 8-bit integer. */
28typedef int8_t spp_int8_t; /**< Signed 8-bit integer. */
29typedef uint16_t spp_uint16_t; /**< Unsigned 16-bit integer. */
30typedef int16_t spp_int16_t; /**< Signed 16-bit integer. */
31typedef uint32_t spp_uint32_t; /**< Unsigned 32-bit integer. */
32typedef int32_t spp_int32_t; /**< Signed 32-bit integer. */
33typedef uint64_t spp_uint64_t; /**< Unsigned 64-bit integer. */
34typedef int64_t spp_int64_t; /**< Signed 64-bit integer. */
35typedef float spp_float32_t; /**< Single-precision float. */
36typedef bool spp_bool_t; /**< Boolean type. */
37
38
39#endif /* SPP_TYPES_H */
uint16_t spp_uint16_t
Definition types.h:29
uint32_t spp_uint32_t
Definition types.h:31
int8_t spp_int8_t
Definition types.h:28
uint8_t spp_uint8_t
Definition types.h:27
int32_t spp_int32_t
Definition types.h:32
bool spp_bool_t
Definition types.h:36
int64_t spp_int64_t
Definition types.h:34
uint64_t spp_uint64_t
Definition types.h:33
float spp_float32_t
Definition types.h:35
int16_t spp_int16_t
Definition types.h:30