阅读:1436回复:1
User-mode application for USB flash disk
Post subject: User-mode application for USB flash disk
-------------------------------------------------------------------------------- I had completed the firmware of the flash disk and now I want develop a user-mode application to write some special command to the USB device to do some certain work. I use SetupDiGetClassDevs(..) function with GUID=a5dcbf10-6530-11d2-901f-00c04fb951ed(Interface class for USB devices) and check the PID and VID to indicate the device. The problem is that I can CreateFile successfully and WriteFile or ReadFile failed. I had comfirmed the pipe and they have no wrong. Why I can't read/write data from/to the USB flash disk via my application? (Somewhere, I had read an article and it said that the mass storge device has already opened by windows and other read/write access will be denied. But I notice that I can use CreateFile(..) function to open it and it returns TRUE, but I also notice that I change the PIPE in the device path name to "PIPE09", the CreateFile function still return TRUE.why?) I only want to make an application to access my USB flash disk device and do something I want to do, how should I do? That is to say, how to develop a flash disk tool? (My develop environment is VC + DDK.) |
|
|
沙发#
发布于:2005-01-04 15:35
http://www.driverdevelop.com/forum/html_84397.html?1104824119
|
|
|