The lag bytes feature is merely an optimization, completely functionally
equivalent to you manually discarding a number of leading bytes from the
response. The optimization works by simply discarding those bytes on the
IOIO side, so that they don't have to be sent to the client (Android/PC)
and discarded there.
The IOIO is a SPI master, so it should be immune to any timing-related
problems (since it is driving the clock).
Seems like there's something else going on. Ideally, if you have access to
a logic analyzer, you can probe the SPI lines and figure out what's wrong.
Otherwise, just try to really simplify your program to zero in on the
problem. What sort of incorrect data are you getting? Are you running at
high frequencies (multiple MHz)? If so, are you confident about your signal
integrity?

On Tue, Apr 14, 2015 at 8:26 PM, <[email protected]> wrote:

> Hi All,
>
> I am trying to implement a fairly high bandwidth SPI data connection and I
> am a bit unclear on the "lag bytes" mentioned in the wiki.  My device
> typically has 0 lag bytes, but if I assume 0 lag bytes, the data I read
> back is incorrect.  Is there a fixed number of lag bytes inherent to the
> IOIO-OTG that I need to account for?  I'm not seeing any padding (none of
> the data is 0xFF, so I am assuming that there are no lag bytes, as I would
> expect from my device, but the fact that the data appears to be wrong makes
> me think otherwise.  But I may have other issues I have yet to figure out.
> I would like to clear up the bit about lag bytes though. Should I account
> for any on the ioio side of things? Any advice would be appreciated.
>
> Thanks,
> Mark.
>
>  --
> You received this message because you are subscribed to the Google Groups
> "ioio-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/ioio-users.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"ioio-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/ioio-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to