Code from the current Forward<T> implementation calls non-blocking SPI traits in embedded_hal-0.2.7, potentially returning nb::Error::WouldBlock and then getting caught in an infinite recursion.
Note: I haven't tested it extremely thoroughly but at least reading and writing seem to work. Looking at the implementation in embedded_hal-0.2.7, their transfer function essentially calls the non-blocking .send() and .read() functions until successful, accomplishing essentially what the previous version of this code was trying to do.
Code from the current
Forward<T>
implementation calls non-blocking SPI traits inembedded_hal-0.2.7
, potentially returningnb::Error::WouldBlock
and then getting caught in an infinite recursion.Note: I haven't tested it extremely thoroughly but at least reading and writing seem to work. Looking at the implementation in
embedded_hal-0.2.7
, their transfer function essentially calls the non-blocking.send()
and.read()
functions until successful, accomplishing essentially what the previous version of this code was trying to do.Fixes #27