Does mcd work in 6.4.1?

I’m trying to use mcd to check for a USB stick being inserted. So I’m opening on /dev/mcd/MOUNT rule and then doing a simple read. And the read stays blocked forever even though I’m inserting and removing the USB drive.

I’m also running mcd verbosely and it does not seem to send any output to sloginfo. So I’m stuck.

I’d appreciate it if someone can help me out.

I’m confused about what the /dev/mcd/MOUNT is about, but let’s say your device is mounted like this:

/dev/mcd/mcd0

You should be able to open /dev/mcd as a directory and scan.

MOUNT is the rule that I open from /dev/mcd and start to read from. The issue is I don’t know when the USB key is going to be mounted, so I’m looking for QNX to let me know through the mcd interface. I got around the issue so far by just polling for /fs/usb0 (it’s mount location) and waiting for it to be accessible. But using the /dev/mcd is the “right” way, and I’d like to implement using it.