Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Synchronizing to SPI frames on PIC32

Status
Not open for further replies.

Borisw37

Newbie level 4
Joined
Dec 16, 2013
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
65
I have a master device that spits out 256 byte SPI messages (with some delay in between messages). The SS pin is pulled low at start of transmission and goes high at the end.
The slave needs to acquire the entire message but also be able to discard a message if let's the slave processor was busy and missed some data.
The SPI peripheral is setup with an interrupt but how do I go about telling if its start of the frame or not..? The values in the data can be 0-255 so I can't really have a "START" or "END" byte set to a particular value.
Do I setup a time out, if full message not received in X time, discard message?
Do I need to add an additional pin that let's say will stay high only during the 1st byte of the data?

Any thoughts on this topic will be useful.

I'm using PIC32 as a slave.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top