Hi,
We are using imx8m mini evk board.
SD card auto mounting is working fine.
But we want user space code detect to detect sd card insertion and removal.
Ubuntu i have tried netlink(libnl) suite https://www.infradead.org/~tgr/libnl/doc/core.html but not able to find proper apis.
Please help us solve the issue.
Thanks & Regards,
Vasu
I can suggest to grep /var/log/messages for messages related to SD card.
I mean something like this:
[ 542.576330] mmc1: card 59b4 removed
and this:
[ 570.761873] mmc1: new high speed SDHC card at address 59b4
Hi @b36401,
We want to detect user space c/c++ code.
Do you have any suggestion detecting in user space c/c++ code ?
Thanks & Regards,
Vasu
Another way (that may be more useful for C code) is to check if /dev/mmcblk1 appears.
I mean that the code may periodically check /dev/mmcblk1 filesystem entry for existing.