x

Dependents:   20180621_FT813

Fork of BurstSPI by Erik -

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers BurstSPI_LPC_1549.cpp Source File

BurstSPI_LPC_1549.cpp

00001 #if defined(TARGET_LPC1549)
00002 #include "BurstSPI.h"
00003 
00004 void BurstSPI::fastWrite(int data) {
00005     while (!(_spi.spi->STAT & (1 << 1)));
00006 
00007     _spi.spi->TXDAT = (data & 0xffff);
00008     // end of transfer and receive ignore flag
00009     _spi.spi->TXCTL |= ((1 << 20) | (1 << 22));
00010 }
00011 
00012 void BurstSPI::clearRX( void ) {
00013     //We already set receive ignore flag, so this function is never run.
00014 }
00015 
00016 #endif