Separating CS from lpspi #131
-
Currently,
Can I create an Many thanks. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
It sounds like the The BSP lets us write this, but we have to ignore the For full transparency: I've never personally tested the "drive chip select with a GPIO" approach. Additionally, there's an LPSPI command queue, and writes block until there's space in the queue. Writes can return early before data is actually sent out. Keep this in mind when changing GPIO states in software. (I don't think there's a |
Beta Was this translation helpful? Give feedback.
It sounds like the
Lpspi::without_pins()
constructor would help. This gives us the driver handle, but it doesn't configure any pins. The caller is responsible for setting up the pins. There's more information here.The BSP lets us write this, but we have to ignore the
board
APIs. e985b7f shows how to rewrite theblocking_spi_loopback.rs
example to create an LPSPI4 driver without the four required pins.For full transparency: I've never personally tested the "drive chip select with a GPIO" approach. Additionally, there's an LPSPI command queue, and writes block until there's space in the queue. Writes can return early before data is actually sent out. Keep this in mind when changing GPIO …