SDIO Interrupt mode - OSAEvent error

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

SDIO Interrupt mode - OSAEvent error

Jump to solution
1,074 Views
PIHL
Contributor II

Hello,
I am having an issue with SDIO communication. I am using interrupt mode with 4 data lines and high speed.
My program tries to interface with SDIO device and the commands are working properly.
Unfortunately sometimes the communication fails - it always happend at the exact same moment of running the program.

I use functions:
SDMMC_OSAEventClear
SDIF_TransferNonBlocking
SDMMC_OSAEventWait

The last one is getting Error event from the SDIO bus. Evant value 14 (1110 in binary), meaning I get SDMMC_OSA_EVENT_TRANSFER_CMD_FAIL, SDMMC_OSA_EVENT_TRANSFER_DATA_SUCCESS and SDMMC_OSA_EVENT_TRANSFER_DATA_FAIL.

What may cause such a behaviour? The command used is 53, with argument 603979780, reading register. This command is happening diretly after writing data using block mode.

Thanks,
Piotr

Labels (1)
Tags (2)
0 Kudos
1 Solution
977 Views
PIHL
Contributor II

Hello,

I found out that the issue was in the code that I implemented myself. Long story short - in bulk data transfer I was calculating data size incorrectly.

View solution in original post

0 Kudos
3 Replies
978 Views
PIHL
Contributor II

Hello,

I found out that the issue was in the code that I implemented myself. Long story short - in bulk data transfer I was calculating data size incorrectly.

0 Kudos
1,067 Views
Abernathy
Contributor I

The ESP32 SDIO Card peripherals (Host, Slave) shares two sets of pins as below table. The first set is usually occupied by SPI0 bus which is responsible for the SPI flash holding the code to run. This means SDIO slave driver can only runs on the second set of pins while SDIO host is not using it.

jcpenneykiosk login

0 Kudos
1,069 Views
frank_m
Senior Contributor III

> This command is happening diretly after writing data using block mode.

A write will take some time on a MMC device, like with internal Flash. Basically, these are similar technologies.

I didn't work with OSA yet, but you might need to check the status, or wait.

0 Kudos