Choosing the right Device Class for your application

Visit  home page for more
USB related articles.


USB Mass Storage Device Class (MSD)
[Or] The "Flash Drive, MP3 Player, External USB Hard Drive, Digital Camera" Class


Article Related Resources
Microchip MSD Class Implementation
Microchip MSD Class Source Code
Atmel MSD
MSD @ www.usb.org
Mass Storage Overview 1.2
Mass Storage Bulk Only 1.0
Mass Storage Control/Bulk/Interrupt (CBI) Specification 1.1  
Mass Storage UFI Command Specification 1.0
Mass Storage Bootability Specification 1.0
Lockable Mass Storage Specification 1.0 and Adopters Agreement (.zip format, size 288 KB)
  - Lockable Mass Storage IP Disclosure

MSD @ www.lvr.com

MSD on Linux


Source Code Files

Free code for Microchip USB device


To understand more about the Device classes read the parent article.
1. USB Mass Storage Device (MSD) Class - Introduction

After HID Class MSD (Mass Storage Device) Class is the most celebrated device class out of all the USB Device Classes. Unlike HID class it is really not used for many different kinds of applications. It's sole purpose of existance is to connect a device to the PC as if the device is a Disk Drive. Thus the name Mass Storage Device Class

Most popular examples of devices based on Mass Storage Device Class are: 

* external magnetic hard drives
* external optical drives, including CD and DVD reader and writer drives
* portable flash memory devices
* adapters bridging between standard flash memory cards and a USB connection
* digital cameras
* various digital audio players & portable media players
* Card readers
* Portable Gaming systems (Nokia N-GAGE/Sony PSP)
* personal data assistants and handheld computers
* some newer mobile phones, like Sony Ericsson K800 and K510, Nokia N73, Nokia E61 

Two books that covers MSD to the core are USB Complete and USB Mass Storage .

2. Benefits of using MSD device in your application

Mass Storage Devices are almost supported by all existing operating systems. For Windows 95, the MSD device used to come with it's own Windows 95 driver, as Microsoft did not produce any Generice USB MSD driver by then. Similar case with Windows 98 too. Almost all  versions of Microsoft Windows starting from Windows 98 SE, and all most all Linux variants, latest MaxOS versions give good support to Mass Storage Device Class. What it means to you as an USB device developer is, you don't have put effort on developing OS specific device drivers. These device drivers are already available for your use.  The only catch is when you design and develop a Mass Storage Device hardware/firmware you are essentially developing a device that will be viewed by the host computer as a Disk Drive. And that is what you need to remember.  

Windows Mobile supports accessing of the most USB mass storage devices formatted with FAT on devices with USB Host. Also note that there is no native support for Mass Storage Devices in Windows NT.


3. How to interact with any MSD device on Windows

The USB mass storage specification does not require any particular file system to be used on MSD devices. Instead, it provides a simple interface to read and write sectors of data—much like the low-level interface used to access any hard drive—using the "SCSI transparent command set." Operating systems may treat the USB drive like a hard drive, and can format it with any file system they like.

But if you want to provide additional File System support then, MSD device need to implement a File Syetem on top of the firmware. Some standard file systems are NTFS, FAT, FAT32 etc..

Once you are have your MSD firmware stack ready, and your device is viewed as MSD device by the OS, and you can access the MSD device from your application like access any other file system. You can create files, directories, format the drive and do all sorts of things that you can do with a file system.
4. How to Initialize any MSD device on Linux

The following articles will provide better understanding on MSD on Linux.
These articles explain how Mass Storage Devices can be initialized in Linux, what are Linux commands need to use called etc...

Shop for USB Devices

Books and Gadgets

Site Resources

External Resources

Privacy Policy

Contact Us



Copyright 2006, www.comvcon.com