Example code for FLEXSPI_TransferNonBlocking usage

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Example code for FLEXSPI_TransferNonBlocking usage

2,269 次查看
ebodek
Contributor II

Hello,

I didn't find any example code for using FLEXSPI_TransferNonBlocking

SDK examples all use FLEXSPI_TransferBlocking.

 

Can someone point me to relevant example code for i.MXRT1050?

Thank you.

标签 (1)
0 项奖励
回复
5 回复数

1,468 次查看
ColinLam
Contributor II

Me too.

how to drive norflash for fatFS in RTOS environment?

0 项奖励
回复

1,442 次查看
ColinLam
Contributor II

Hi, Some questions.

1, 

void FLEXSPI_TransferCreateHandle(FLEXSPI_Type *base,
                                  flexspi_handle_t *handle,
                                  flexspi_transfer_callback_t callback,
                                  void *userData)
how to write the callback function?
0 项奖励
回复

2,239 次查看
danielchen
NXP TechSupport
NXP TechSupport

Hi

please refer to below code snippet.

-Initialize
FLEXSPI_Enable(((FLEXSPI_Type *)FLEXSPI_BASE), true);
FLEXSPI_GetDefaultConfig(&config);
FLEXSPI_Init(((FLEXSPI_Type *)FLEXSPI_BASE), &config);

 

flexspi_handle_t rc_handle;
flexspi_handle_t tr_handle;

FLEXSPI_TransferCreateHandle(((FLEXSPI_Type *)FLEXSPI_BASE), &tr_handle, NULL, 0
/*flexspi_transfer_callback_t callback,
void *userData*/);

FLEXSPI_TransferCreateHandle(((FLEXSPI_Type *)FLEXSPI_BASE), &rc_handle, NULL, 0
/*flexspi_transfer_callback_t callback,
void *userData*/);

-Read QSPI.
status = FLEXSPI_TransferNonBlocking(((FLEXSPI_Type *)FLEXSPI_BASE), &rc_handle, &rc_data);

while((status = FLEXSPI_TransferGetCount (((FLEXSPI_Type *)FLEXSPI_BASE), &rc_handle, &count )) == kStatus_FLEXSPI_Busy);

 

 

Regards

Daniel

0 项奖励
回复

2,143 次查看
arunmuthuganesh
Contributor I
Hi Daniel,

Can you please share the code snippet for QSPI write in NonBlocking transfer mode ?
 
Thanks in Advance,
Arun Muthuganesh
0 项奖励
回复

2,064 次查看
senthil_kumarn
Contributor I

dear daniel

 

please share the code snippet for QSPI write in NonBlocking transfer mode

0 项奖励
回复