ssp bitstream
Page last updated 14 Jan 2013, by
0
replies
.
SPI device (p11, p12, p13); . . . // Configure TX data port device.format(8, 0); // SPI 8 bit mode 0 device.frequency(2000000); // SPI bit rate LPC_SSP0->CR0 |= 0x0010; // Switch to TI mode . . . while (i < len) { while ((LPC_SSP0->SR & 0x0002) == 0x0002) { LPC_SSP0->DR = xmt_msg[i]; i++; } } while ((LPC_SSP0->SR & 0x0001) == 0x0000); for (i=0; i<20; i++); // Allow extra time to clock out the last few bits
Please log in to post comments.