uint32_t shiftIn( uint32_t ulDataPin, uint32_t ulClockPin, uint32_t ulBitOrder );
uint32_t shiftIn( uint32_t ulDataPin, uint32_t ulClockPin, uint32_t ulBitOrder );
Reads data of a byte by bits on the assigned pin. Every bit of data is read from the data pin. You can select to combine the read 8-bit data into a byte from MSB or LSB. Every clock cycle (meaning the clock goes through a complete high voltage and low voltage) reads a bit of data; every bit of data is read when the clock signal is at high voltage.
|
Parameters |
Description |
|
uint32_t ulDataPin |
[IN] Data input pin, for reading every bit of data |
|
uint32_t ulClockPin |
[IN] Clock pin. Periodically switches between high voltage and low voltage when dataPin outputs data |
|
uint32_t ulBitOrder |
[IN] Data input order. Can be MSBFIRST (MSB first) or LSBFIRST (LSB first) |
Data read (one byte)
wiring_shift.h