How to realize QSPI 24bit communication
Posted: Sun Aug 05, 2012 9:12 pm
I am a chinese user,how to realize the MOD5282's 24bit communication?
thank you.
thank you.
A community of NetBurner users gathering to discuss NetBurner hardware, software, design and projects
https://forum.embeddedethernet.com/
Code: Select all
BYTE TXBuffer[4];
OS_Sem QSPI_SEM;
OSSemInit( &QSPI_SEM, 0 );
UCOS_ENTER_CRITICAL();
TXBuffer[0] = data[0];
TXBuffer[1] = data[1];
TXBuffer[2] = data[2];
// if you've set the hardware chip enable pin via QSPIInit ignore the pin_.CE lines
pin_.CE = 0; // set the hardware Chip Enable pin low
QSPIStart(TXBuffer, NULL, 3, &QSPI_SEM_);
OSSemPend( &QSPI_SEM_, 0 ); // Wait for QSPI to complete
pin_.CE = 1; // set the hardware Chip Enable pin high
UCOS_EXIT_CRITICAL();