6/22/2012

How to make mass-storage recognized as CD-ROM drive.

Many customer asked how to make their mass-storage device recognized as CD-ROM drive.

It can be done by setting the value of device type for the response of "INQUIRY" request from Host.



Set the value in vget_desc() function in hsu_al_ms.c file like following



static void vget_desc
(
msfd_appctx_t ctx,
juint8_t vlun,
/* out parameters that need to be filled in by the function */
juint32_t* dev_type,
juint8_t* version,
char** vendor,
char** product,
char** prod_rev
)
{

//Sample implementation


*dev_type = SCSI_DEVICE_CDROM // the value is 0x05

*vendor = "Customer company name";
*product = "customer product name ";
*prod_rev = inquiry_data_prod_rev;

No comments:

Post a Comment