Returns the status of a given bit into a bitarray (0 or !0)
u8 cpct_getBit (void* array, u16 index);
(2B DE) array | Pointer to the first byte of the array |
(2B HL) index | Position of the bit in the array to be retrieved |
u8 | Status of the selected bit: false (0) when the bit value is 0, true (> 0) when the bit value is 1. Take into account that >0 means any value different than 0, and not necessarily 1. |
Returns 0 or >0 depending on the value of the bit at the given position (index) in the specified array. It will assume that the array elements have a size of 8 bits and also that the given position is not bigger than the number of bits in the array (size of the array multiplied by 8).
AF, BC, DE, HL
42 bytes (8 bytes bitWeights table, 33 bytes code)
Case | Cycles | microSecs (us) ------------------------------- Any | 191 | 47.75 -------------------------------