Removable Media in MSD class

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

Removable Media in MSD class

509 Views
OldNick
Contributor IV

Hi,

Using the Mass Storage Class driver, but want to keep Windoze off my back until the SD card is inserted and MFS has got out of the way.

From Jan Axelson's books, I think the best way to do this is at the SCSI layer.

Has anybody persuaded MQX3.8.1 USB device stack to issue UNIT ATTENTION conditions on media insertion/removal?

Or is there another way to do this?

I cannot find this in any Tower examples.

Thanks in advance.

0 Kudos
2 Replies

419 Views
KJFPE
Contributor III

Hi Nick

Just in case this is useful have a look for BSP_SDCARD_GPIO_DETECT and there is an example in mqx x.x \mfs\examples\sdcard, should be possible to use an interrupt if required

0 Kudos

419 Views
OldNick
Contributor IV

Kevin,

Thanks for this – the nearest I have got to working example code is in AN4406

But that simply holds the USB task off until a semaphore is released by the insertion of the card.

I am looking for a hook into the MSD class driver.

Best Regards

0 Kudos