spi_write16_blocking() function
Write to an SPI device Write \p len halfwords from \p src to SPI. Discard any data received back. Blocks until all data is transferred. No timeout, as SPI hardware always transfers at a known data rate.
Arguments
spi
SPI instance specifier, either
spi0
or
spi1
src
Buffer of data to write
Return value
Number of halfwords written/read
Notes
SPI should be initialised with 16 data_bits using spi_set_format first, otherwise this function will only write 8 data_bits.