Skip to content

Commit

Permalink
drivers: spi: RPi Pico PIO SPI code size and byte order.
Browse files Browse the repository at this point in the history
Use minimized PIO code for 3-wire operation.

Input and output buffers are conventionally stored in bus byte order.
For 16 and 32 bit transfers, this is effectively big-endian, so
txbuf and rxbuf need to be read as such.  Those pointers also need
to be declared uint8_t * instead of void *.
In addition, tx_count and rx_count are based on dts, and refer to
whole transfers (8, 16, or 32 bits), not bytes.

Added rpi_pico.overlay to samples/sensor/magn_polling to demonstrate
32-bit word size, and updated the README.rst to make it independent
of the specific sensor.

Clean up compliance check failures.
Fix typos.
Synchronize 3-wire TX and RX cycles.
Simplify state machine synchronization
Minimize SPI bus delay time in 3-wire mode
Move clock delay to PIO code and remove k_sleep

Signed-off-by: Steve Boylan <[email protected]>
  • Loading branch information
ThreeEights authored and nashif committed Nov 16, 2024
1 parent 782f0b2 commit d0aced3
Show file tree
Hide file tree
Showing 3 changed files with 134 additions and 149 deletions.
Loading

0 comments on commit d0aced3

Please sign in to comment.