2008-02-29 04:08 AM
2011-05-17 12:50 AM
Hi all,
i use the SSP0 for more than one Device on the bus. So, i have to toggle Port-Pins for the Device-Specific Chip Select. What Register must i check that i know that the last transmition to the device is ready and i can set the Chip Select to ''1''? Bit ''0'' in the SSP0_SR doesn't work correctley...when it indicates a empty FIFO, the data is still clocked out (for SCLK < 1MHz) Thanks, Michael2011-05-17 12:50 AM
Remember that SPI interfaces are always bi-directional, even if you ignore the input side while sending. the best way to test for an inactive SPI bus is to read in the data after every corresponding byte clocked out. Ignore the actual data read but keep a count. After the last data byte is read in, you are guaranteed that the bus is no longer generating a data clock.