It might be a lot less complicated to just increase the osc speed from 4MHz and clock the SPI faster. Running at 32MHz with SPICLK=8MHz it takes <2us to send out a byte... hardly worth the bother. At the speed you're running now it takes longer than that just to branch to an interrupt.though the my next step is to have this trigger as interrupt to control the latch while performing another routine
I'd also ditch the PAUSE in the Send_Data routine.
Bookmarks