TM USB-FileSys Driver-free USB embedded file system (Previously USB-Config) Mechanical Specifications Summary USB-FileSys is a low cost USB FAT file system. Its memory area is accessed by a host controller using SPI commands, and, when plugged into a USB port, simultaneously appears on a PC like a file system on a removable disk. For low duty configuration and diagnostic applications, USB-FileSys can use its own on-chip pre-formatted 8kByte flash memory area. For moderate file storage and transfer, USB-FileSys can be interfaced to Microchip 25AA1024 EEPROM for 128kByte storage. Device pinout For large file storage and transfer applications, USB- FileSys can be interfaced to SD cards, and integrated Table 1. Device Pinout Pin circuits with SD card interfaces, of up to 1GBbyte. Name Description DIL SS (Internal and SD options for 28-pin devices only.) 20 1 Vdd Power positive input 9 2 OSC1 Oscillator input USB-FileSys uses the Mass Storage Device (MSD) USB 10 3 OSC2 Oscillator output profile. It works without drivers on PCs running Media Media detect Windows (ME or later), Mac (OS 9 or later) or Linux (4.0 1 Vpp TEAclipper Vpp or later). It is available pre-programmed as a 28-pin DIL RST Device reset (Active low) package and a 20 pin SSOP package. 4 Vpp TEAclipper Vpp 11 5 MISO-M Data input from SPI memory Features 12 6 MOSI-M Data output to SPI memory FAT12 / FAT16 file system, no licensing needed 13 7 SCK-M Clock output to SPI memory 7 8 SSn-H Slave select input from host True MSD plug and play, no drivers required 18 9 MISO-H Data output to host 4 10 SSn-M Slave select output to SPI memory Works with internal flash memory, 25AA1024 22 11 SCK-H Clock input from host external memory (128Kbyte) and SD compatible 3 12 Activity USB Activity Indicator cards and integrated circuits up to 1GB. 21 13 MOSI-H Data input from host Partial support for long file names 24 14 Sleep Sleep control input (Active low) 5 15 PTO Power take-off OK indicator (active low) USB 2.0 compatible 26 16 USB-S USB voltage sense 14 17 Vusb USB supply filter Applications 15 D- USB data - 18 27 PGC TEAclipper PGC Consumer products, e.g. photo frames 16 D+ USB data+ 19 Data logging 28 PGD TEAclipper PGD 8,19 20 Vss Power ground reference File transfer Device configuration & diagnostics Firmware Factory Ltd 3 Plough Yard, Ground Floor London EC2A 3LP, UK sales firmwarefactory.com support firmwarefactory.com Figure 2 Serial Memory Embedded Data Store Product Looks like Flash Drive USB USB-FileSys Host p1 of 10 26-Aug-10 USB-FileSys / USB-Config HW149-8 www.hexwax.comRST Electrical Specifications The 20-pin device has an active low pin in place of the Table 2. Electrical Specifications media detect pin. This should normally be biased high Operating voltage Vdd, 28-pin device 2.7V 5.5V with a 22k resistor. Operating voltage Vdd, 20-pin device 1.8V 5.5V Typical/max supply current, Vdd = 5.0 10mA / 21mA D+, D- Typical/max Sleep current, Vdd = 5.0 0.1A / 2A Operating Temperature -40C to +85C USB data I/O. Refer to the USB Connectors section for Maximum SPI clock rate 1MHz details of their connections. USB Voltage Sense Basic Operation This input should be high when the device is plugged To the host microcontroller (host), USB-FileSys looks into a USB host. Refer to figure 5 for a typical method like a file system accessed with SPI commands. To the of deriving this input from the USB supply input. PC, it looks like a flash drive. USB Activity Indication The use of the MSD USB profile means that no driver Output that can either be used for connecting to an installation is required. It is plug-and-play compatible activity indication LED, or for generating an interrupt with PCs running Windows (ME or later), Mac (OS 9 or when an USB write event occurs. later) or Linux (4.0 or later). If configured as an activity indicator, it is high for Pin Functions approximately 100ms when USB status is changing, or a USB command is being processed other than Test The pin functions are shown in table 1. Pins marked n.c. Unit Ready. (Test Unit Ready is ignored because will be configured as inputs and, in order to minimize operating systems send it approximately once per power consumption, should not be left floating. second to verify the drive is still available.) The pin functions are described in detail below. If configured as an interrupt, it can be set to output high Vss, Vdd, Vusb when the PC is executing a write to any sector, or a write to the root directory entries. The primary purpose Vss is the power supply ground reference. Vdd should of these functions is to allow the host to capture the date be connected to a regulated supply, most usually the and time information when the PC closes a file. USB power when available and a battery when USB power is not available. Vusb should be connected, via a PTO 470nF capacitor, to Vss. See for example C8 in figure 4. The Power Take-Off output is low when power may be OSC1, OSC2 drawn by the application circuit from the USB supply. USB-FileSys device is configured to request up to OSC1 and OSC2 should be connected to a 12MHz 100mA, allowing the device to operate from unpowered parallel cut crystal circuit with 22pF capacitors or a hubs. It may be reconfigured to request up to 500mA 12MHz resonator with 0.25% total tolerance. using the Set Configuration command. If this is done the device will work from PCs and powered hubs only. Vpp, PGC, PCD If PTO is high, the device should draw no more than TEAclipper programming pins. Refer to the TEAclipper 100A. In no event should an external power source Programming section for details. Note that the Vpp pin inject power into the USB Vdd line. may be subject to voltages as high as 13V during programming. On the 28-pin device, PGC and PGD will Sleep be configured as outputs in normal use and should be left floating when not being used for programming. The Sleep input is be regularly polled. If it is low, the device and its slave memory enter a low-power sleep Media Detect state. When sleep goes high, the device will resume normal operation within 70ms. The Media detect input pin should be pulled low with a 33K resistor if 25AA1024 memory used. If the SCK-M SCK-M, MISO-M, MOSI-M, SSn-M pin is biased low indicating that internal memory is used, the Media detect pin is ignored. If SD or 25AA1024 memory is used, these pins are the SPI serial interface to the memory. 4k7 pull-up resistors The Media detect input pin should be high during normal are required on all these lines. operation with SD memory. If SD memory removable, Media detect should be taken low when it is removed. If If internal memory is used, SCK-M should be biased low. the device is connected to a PC, a soft detach and re- SCK-H, MISO-H, MOSI-H, SSn-H attach will be performed on media removal. The SD memory must be physically removed so that a power-up In SPI communications with the embedded host, USB- reset is performed when it is re-inserted. FileSys acts as an SPI slave device. USB-FileSys is selected by transitioning SSn from high to low. At that In order to allow USB-FileSys to be programmed in- time, SCLK should be low (CPOL=0). On the rising circuit, it must be possible to configure the application edge of SCLK, one bit of data is read on MOSI circuit so that this input appears to be pulled high via a (CPHA=0). On the falling edge of SCLK, the data on 22k resistor, or pulled low with a 33k resistor. p2 of 10 26-Aug-10 USB-FileSys / USB-Config HW149-8 www.hexwax.com