FAQ: I heard there is some issue with hardware SPI? And full-duplex SPI?
-
The Omega2 does not support full-duplex SPI transmissions. This is due to a hardware bug in the underlying MT7688 SoC used in the Omega2.
On the bright side, half-duplex SPI transmissions will work. We've done some work to improve the speed and stability of half-duplex transmissions, read more about it here.
When working with SPI on the Omega, we recommend:
- Using the python-spidev module
- Writing C code that directly uses the Linux spidev interface
- General information can be found here: https://www.kernel.org/doc/Documentation/spi/spidev
- And here is a good example of how it can be used: http://linux-sunxi.org/SPIdev#In_the_user_space
A few additional notes:
- The
spi-tool
utility and thepyOnionSpi
module are deprecated and should not be used
-
Half Duplex SPI Transactions
If you're looking to do a half-duplex SPI transaction (where Chip-Select is held active between blocks), check out the
xfer3
function in thepython-spidev
module.Details:
If you absolutely need full-duplex SPI
The Omega2 family does not support full-duplex transactions on the hardware SPI bus, but you can make a software (bit-bang) instance of an SPI bus that will support full-duplex.
More info on software-based SPI buses in this FAQ post.