EVK525 AT90USBxxx Dual role demonstration with file system

License

Use of this program is subject to Atmel's End User License Agreement.

Please read file lic_page for copyright notice.

Description

This embedded application source code illustrates how to implement a dual role application with the AT90USBxxx controller.

As the AT90USBxxx implements a device/host usb controller, the embedded application can operates in one of the following usb operating modes:

The application contains 3 Logical Units (LUN) :

Revision

V2.0.3
USB Device:

USB Host:

SD/MMC driver:

NandFlash driver:

New ushell (MAJOR update)

V2.0.2
USB Stack:

DataFlash driver:

MMC/SD driver:

NandFlash driver :

New watchdog driver to control the specific sequence timing

FileSystem:

V2.0.1
USB Stack :

V2.0.0 and before

First use

Please, don't use the package "evk525_dms_host_ms_filesystem_hub-1_0_0" because this one include a major bug on NandFlash driver. Please read the EVK525 User Hardware Guide before connecting the EVK525 to STK525, and before using this program.

About the source code

This source code is usable with the following compilers:

Support for other compilers may required modifications or attention for:

About the sample application

By default the demonstration is preconfigured for dual role USB application. It means that the code generated allows to operate as a device or a host depending on the USB ID pin:

appli_pc.gif

appli_host.gif

Using the USB device mode

Connect the STK525&EVK525 to a PC host system with a miniB (STK525 side) to plugA (PC host) cable

Using the USB host mode

About the HUB support

The optional hub support included in this demonstration allows to connect up to two USB MSD to the STK525. The AT90USB1287 as an OTG device does not fully support usb hubs. This demonstration implements many firmware tricks in order to support a hub with USB mass storage devices. The hub support firmware included within this demonstration is suitable only for bulk only peripherals. Support for other usb device interfaces with either interrupt or isochronous transfer mode will not work.

Using the shell terminal

Connected to a serial terminal emulator the Usheel command line interpreter allows to:

For more information about File System module see File System

Architecture

As illustrated in the figure bellow, the application entry point is located is the main.c file. The main function first performs the initialization of a scheduler module and then runs it in an infinite loop. The scheduler is a simple infinite loop calling all its tasks defined in the conf_scheduler.h file. No real time schedule is performed, when a task ends, the scheduler calls the next task defined in the configuration file (conf_scheduler.h).

The sample dual role application is based on several different tasks:

arch_full.gif

Generated on Wed Sep 23 09:17:02 2009 for ATMEL by  doxygen 1.5.3