OS
v7.3.3
Documentation
|
General purpose Function-like Macros. More...
Macros | |
#define | qFLM_BitsSet(dst, xBits) |
Uses the bitwise OR operator to set bits into dst. | |
#define | qFLM_BitsClear(dst, xBits) |
Uses the bitwise AND operator to clear bits into dst. | |
#define | qFLM_BitSet(dst, xBit, xType) |
Uses the bitwise OR operator to set a single bit into dst. | |
#define | qFLM_BitClear(dst, xBit, xType) |
Uses the bitwise AND operator to clear a single bit into dst. | |
#define | qFLM_BitRead(dst, xBit) |
Uses the bitwise AND operator to read the value of a single bit from dst. | |
#define | qFLM_BitToggle(dst, xBit) |
Uses the bitwise XOR operator to toggle the value of a single bit from dst. | |
#define | qFLM_BitWrite(dst, xBit, xVal) |
Write the bVal in a single bit of the dst variable. | |
#define | qFLM_BitMakeByte(b7, b6, b5, b4, b3, b2, b1, b0) |
Build a byte value from independent bits. | |
#define | qFLM_ByteHighNibble(dst) |
Read the high-nibble from dst. | |
#define | qFLM_ByteLowNibble(dst) |
Read the low-nibble from dst. | |
#define | qFLM_ByteMergeNibbles(H, L) |
Merges two nibbles to form one byte. | |
#define | qFLM_WordHighByte(dst) |
Read the high-byte from dst assuming it as a Word. | |
#define | qFLM_WordLowByte(dst) |
Read the low-byte from dst assuming it as a Word. | |
#define | qFLM_WordMergeBytes(H, L) |
Merges two bytes to form one Word. | |
#define | qFLM_DWordHighWord(dst) |
Read the high-word from dst assuming it as a DWord. | |
#define | qFLM_DWordLowWord(dst) |
Read the low-word from dst assuming it as a DWord. | |
#define | qFLM_DWordMergeWords(H, L) |
Merges two words to form one DWord. | |
#define | qFLM_Clip(X, Min, Max) |
Ensures that X is between the limits set by Min and Max. | |
#define | qFLM_ClipUpper(X, Max) |
Ensures that X is bellow the limits set by Max. | |
#define | qFLM_ClipLower(X, Min) |
Ensures that X is above the value set by Min. | |
#define | qFLM_IsBetween(X, Low, High) |
Check if the value of X is within the limits defined by Low and High. | |
#define | qFLM_Min(a, b) |
Calculates the minimum of a and b. | |
#define | qFLM_Max(a, b) |
Calculates the maximum of a and b. | |
#define | qFLM_ArraySize(x) |
Returns the number of elements in an array x. | |
General purpose Function-like Macros.
#define qFLM_ArraySize | ( | x | ) |
Returns the number of elements in an array x.
[in] | x | The input array |
#define qFLM_BitClear | ( | dst, | |
xBit, | |||
xType ) |
Uses the bitwise AND operator to clear a single bit into dst.
[in] | dst | The variable where the operation will be applied |
[in] | xBit | The bit-index |
[in] | xType | Data-type |
#define qFLM_BitMakeByte | ( | b7, | |
b6, | |||
b5, | |||
b4, | |||
b3, | |||
b2, | |||
b1, | |||
b0 ) |
Build a byte value from independent bits.
[in] | b7...b0 |
#define qFLM_BitRead | ( | dst, | |
xBit ) |
Uses the bitwise AND operator to read the value of a single bit from dst.
[in] | dst | The variable where the operation will be applied |
[in] | xBit | The bit-index |
#define qFLM_BitsClear | ( | dst, | |
xBits ) |
Uses the bitwise AND operator to clear bits into dst.
[in] | dst | The variable where the operation will be applied |
[in] | xBits | Indicates which bits are to be cleared |
#define qFLM_BitSet | ( | dst, | |
xBit, | |||
xType ) |
Uses the bitwise OR operator to set a single bit into dst.
[in] | dst | The variable where the operation will be applied |
[in] | xBit | The bit-index |
[in] | xType | Data-type |
#define qFLM_BitsSet | ( | dst, | |
xBits ) |
Uses the bitwise OR operator to set bits into dst.
[in] | dst | The variable where the operation will be applied |
[in] | xBits | Indicates which bits are to be set |
#define qFLM_BitToggle | ( | dst, | |
xBit ) |
Uses the bitwise XOR operator to toggle the value of a single bit from dst.
[in] | dst | The variable where the operation will be applied |
[in] | xBit | The bit-index |
#define qFLM_BitWrite | ( | dst, | |
xBit, | |||
xVal ) |
Write the bVal in a single bit of the dst variable.
[in] | dst | The variable where the operation will be applied |
[in] | xBit | The bit-index |
[in] | xVal | The boolean value to write |
#define qFLM_ByteHighNibble | ( | dst | ) |
Read the high-nibble from dst.
[in] | dst | The variable where the operation will be applied |
#define qFLM_ByteLowNibble | ( | dst | ) |
Read the low-nibble from dst.
[in] | dst | The variable where the operation will be applied |
#define qFLM_ByteMergeNibbles | ( | H, | |
L ) |
Merges two nibbles to form one byte.
[in] | H | The high nibble |
[in] | L | The low nibble |
#define qFLM_Clip | ( | X, | |
Min, | |||
Max ) |
Ensures that X is between the limits set by Min and Max.
[in] | X | The value to clamp |
[in] | Min | The minimum value allowed. |
[in] | Max | The maximum value allowed. |
#define qFLM_ClipLower | ( | X, | |
Min ) |
Ensures that X is above the value set by Min.
[in] | X | The value to clamp |
[in] | Min | The minimum value allowed. |
#define qFLM_ClipUpper | ( | X, | |
Max ) |
Ensures that X is bellow the limits set by Max.
[in] | X | The value to clamp |
[in] | Max | The maximum value allowed. |
#define qFLM_DWordHighWord | ( | dst | ) |
Read the high-word from dst assuming it as a DWord.
[in] | dst | The variable where the operation will be applied |
#define qFLM_DWordLowWord | ( | dst | ) |
Read the low-word from dst assuming it as a DWord.
[in] | dst | The variable where the operation will be applied |
#define qFLM_DWordMergeWords | ( | H, | |
L ) |
Merges two words to form one DWord.
[in] | H | The high word |
[in] | L | The low word |
#define qFLM_IsBetween | ( | X, | |
Low, | |||
High ) |
Check if the value of X is within the limits defined by Low and High.
[in] | X | The value to check |
[in] | Low | The minimum value allowed. |
[in] | High | The maximum value allowed. |
#define qFLM_Max | ( | a, | |
b ) |
Calculates the maximum of a and b.
[in] | a | A numeric value |
[in] | b | A numeric value |
#define qFLM_Min | ( | a, | |
b ) |
Calculates the minimum of a and b.
[in] | a | A numeric value |
[in] | b | A numeric value |
#define qFLM_WordHighByte | ( | dst | ) |
Read the high-byte from dst assuming it as a Word.
[in] | dst | The variable where the operation will be applied |
#define qFLM_WordLowByte | ( | dst | ) |
Read the low-byte from dst assuming it as a Word.
[in] | dst | The variable where the operation will be applied |
#define qFLM_WordMergeBytes | ( | H, | |
L ) |
Merges two bytes to form one Word.
[in] | H | The high byte |
[in] | L | The low byte |