Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
app_util.h File Reference
Go to the source code of this file.
Data Structures | |
struct | uint8_array_t |
Byte array type. More... | |
Typedefs | |
typedef uint8_t | uint16_le_t [2] |
type for holding an encoded (i.e. | |
typedef uint8_t | uint32_le_t [4] |
Type for holding an encoded (i.e. | |
Enumerations | |
enum | { UNIT_0_625_MS = 625, UNIT_1_25_MS = 1250, UNIT_10_MS = 10000 } |
Functions | |
static __INLINE uint64_t | value_rescale (uint32_t value, uint32_t old_unit_reversal, uint16_t new_unit_reversal) |
Function for changing the value unit. | |
static __INLINE uint8_t | uint16_encode (uint16_t value, uint8_t *p_encoded_data) |
Function for encoding a uint16 value. | |
static __INLINE uint8_t | uint24_encode (uint32_t value, uint8_t *p_encoded_data) |
Function for encoding a three-byte value. | |
static __INLINE uint8_t | uint32_encode (uint32_t value, uint8_t *p_encoded_data) |
Function for encoding a uint32 value. | |
static __INLINE uint8_t | uint48_encode (uint64_t value, uint8_t *p_encoded_data) |
Function for encoding a uint48 value. | |
static __INLINE uint16_t | uint16_decode (const uint8_t *p_encoded_data) |
Function for decoding a uint16 value. | |
static __INLINE uint16_t | uint16_big_decode (const uint8_t *p_encoded_data) |
Function for decoding a uint16 value in big-endian format. | |
static __INLINE uint32_t | uint24_decode (const uint8_t *p_encoded_data) |
Function for decoding a three-byte value. | |
static __INLINE uint32_t | uint32_decode (const uint8_t *p_encoded_data) |
Function for decoding a uint32 value. | |
static __INLINE uint32_t | uint32_big_decode (const uint8_t *p_encoded_data) |
Function for decoding a uint32 value in big-endian format. | |
static __INLINE uint8_t | uint32_big_encode (uint32_t value, uint8_t *p_encoded_data) |
Function for encoding a uint32 value in big-endian format. | |
static __INLINE uint64_t | uint48_decode (const uint8_t *p_encoded_data) |
Function for decoding a uint48 value. | |
static __INLINE uint8_t | battery_level_in_percent (const uint16_t mvolts) |
Function for converting the input voltage (in milli volts) into percentage of 3.0 Volts. | |
static __INLINE bool | is_word_aligned (void const *p) |
Function for checking if a pointer value is aligned to a 4 byte boundary. | |
static __INLINE bool | is_address_from_stack (void *ptr) |
Function for checking if provided address is located in stack space. |
Detailed Description
Definition in file app_util.h.
Generated on Wed Jul 13 2022 07:07:19 by
