CY4611B

CY4611B Datasheet


CY4611B FX2LP USB to ATA/CF Reference Design Notes

Part Datasheet
CY4611B CY4611B CY4611B (pdf)
PDF Datasheet Preview
CY4611B FX2LP USB to ATA/CF Reference Design Notes

Introduction

Cypress has two USB High Speed Mass Storage solutions. The AT2LP is a low-power fixed-function Mass Storage solution for ATA devices. The CY4611B is a flexible bridge solution that enables additional features to be added to a USB bridge device. The Cypress EZ-USB FX2LP Mass Storage reference design connects the EZ-USB FX2LP to the following device types:
• IDE devices Hard disk drives
• Compact Flash & micro drives
• ATAPI devices

ZIP drives CD-ROM/R/RW drives DVD-ROM/RAM/RW drives

Reference Design Contents
• FX2LP Mass Storage Reference Design PCBA
• Reference Design Schematic in both PDF and OrCAD source files
• Reference Design BOM
• Firmware source and object code
• Reference Design Notes this document
• UDMA White Paper
• Driver INF and .SYS files
• Operating Instructions
• Manufacturing tools
• Release Notes
• Errata

Background Information

You should be familiar with the USB Mass Storage Class specification and general operation of Cypress’ EZ-USB FX2LP to get the most from this document. For more information please refer to these specifications or Cypress’s EZ-USB FX2LP Technical Reference Manual.

Mass Storage Class Specification

The USB Mass Storage Class specification contains two subclasses, the CBI Command, Bulk, Interrupt , and the newer Bulk Only Transport. This reference design complies with the Bulk Only subclass of the USB Mass Storage Specification. The Bulk Only
subclass is supported by the Windows XP, 2000 and ME drivers as well as MacOS 9 and X. Cypress provides custom drivers for Windows and Macintosh operating systems to add support for security and SMART monitoring. The latest driver versions are available on the Cypress website.

Firmware Overview

Note CBW, CSW, dataTransferLength, and “Persistent Stall” are defined in the “USB Mass Storage Class, Bulk Only Transport” document referenced below.

The firmware for the device is a straightforward implementation of a USB Bulk Only Mass Storage Device. After reset, it waits for a CBW packet, checks it and then executes the data phase of the command if any . Once the data phase is complete, the firmware sends a CSW packet to the host. SETUP commands are handled in an ISR. A timer ISR is used to poll VBUS and GPIOs. The only commands that the firmware generates on its own are SCSI Identify Device to get the device name and ATA Identify Device to get the device serial number .

The CY4611B firmware supports both high speed 480Mbps and full speed 12Mbps hosts.

Firmware Details

Refer to the flowchart on the following page for more details.

There are three main sections in the firmware
• Initialization
• Command CBW processing
• ISRs

The initialization code sets up the hardware, reads the EEPROM configuration and detects the attached drives. Initialization routines include resetATAPIDevice, ATAInit, initUSB, TD_Init, detectSCSIvsATA, and ATAPIIdDevice. When the initialization code is complete, the hardware is set up, drives are fully enumerated, GPIF is loaded and the firmware is ready to accept CBW commands.

The CBW processing takes place in the TD_Poll loop. This loop also polls the sleep flag to determine

Cypress Semiconductor Corporation
• 3901 North First Street
• San Jose
• CA 95134
• 408-943-2600 7/11/05

EZ-USB FX2LP USB to ATA Reference Design Notes
if it is time for USB suspend. The final function of the main loop is to poll for new removable CF devices.

The ISRs have two main functions. They handle SETUP command processing and background polling for events like VBUS removal, GPIO changes and ATA_ENABLE changes.

Main This routine calls the TD_Init and ATAInit routines and then starts the master while 1 loop. The while 1 loop polls the sleep flag and calls TD_Poll, the main command processing routine.

ATAInit On a hard reset, TD_init is called, which initializes the hardware using initUSB . The resetATAPIDevice routine is called to reset the drive. After the drive has been reset the drive discovery algorithm, detectSCSIvsATA , is called once for the master device and again for the slave device.
detectSCSIvsATA The detectSCSIvsATA routine determines whether the attached device is IDE or ATAPI by reading the byte count registers. The scsi flag is set to 1 to indicate an ATAPI device, scsi is set to 0 on an IDE device. This routine sets the bDevicePresent flag when a drive is successfully detected.

ATAPIIdDevice This routine is called to collect information from the drive into internal data structures. This information includes the max PIO or UDMA speed supported and the serial number of the drive. If the device supports PIO-3, PIO-4 or UDMA, this routine will program the drive to run at the new speed.

Hardware Reset of FX2

Initialize Hardware [TD_Init, initUSB]

USB Reset or ATA_ENABLE -> disable
in any state

Initalize ATA Device Detect ATAPI vs IDE [resetATAPIDevice]

Wait for CBW [TD_Poll ]

Send CSW [sendUSBS ]

LUN changed?

Change GPIF waveforms
More datasheets: 74LVQ373SCX | 74LVQ373QSCX | 74LVQ373SJ | 74LVQ373SJX | 74LVQ373SC | 74LVQ373QSC | HFBR-0310 | TP11SH9AKE | 7111S1615A02LF | 96ND1TB-ST-SG5K


Notice: we do not provide any warranties that information, datasheets, application notes, circuit diagrams, or software stored on this website are up-to-date or error free. The archived CY4611B Datasheet file may be downloaded here without warranties.

Datasheet ID: CY4611B 507798