Online Development Notebook > Index > U421 USB Interface > U421 Capabilities

U421 Capabilities

Digital I⁄O Interface

The U421 can be programmed to be a simple digital i⁄o interface for the PC (Win⁄Linux) or Mac (OSX) . There are two 8-bit ports, thus sixteen i⁄o lines. There are two commands that set port A and port B i⁄o directions. The individual lines of the port can be set to inputs or outputs on a per line basis, but the command to set the direction operates on an entire port.

The ports can be read with two distinct port read commands. The state of the lines that are set as inputs are returned with the read command. The state of any line that is not set as an input is undetermined and should be ignored.

The ports, when set as outputs, can be written to on a byte-wide basis with two distinct port write commands. Individual line states may be changed with a set of commands that mask the port state and affect only user-specified lines.

A set of commands allow for a byte write to one port, while strobing a user-selected line from another port. The strobe can be either negative-going or positive-going.

LCD Interface

The U421 is a convenient way to interface a standard Hitachi-type of intelligent LCD controller to USB. The commands that support communication to the LCD module are the "standard" LCD commands. Standard commands include writing characters to the display, and controlling the display.

SPI Master

The U421 is an interface to SPI devices. The firmware on the U401 provides generic access to read and write SPI devices. The SPI clock rate can be adjusted to 62.5 kHz, 500 kHz, 1 MHz, or 2 MHz. Because additional pins are available as generic i⁄o, the U421 can use these lines as slave select lines and address multiple SPI devices.

SPI Slave

The U421 can be operated as a SPI slave device. A microcontroller circuit external to the device can transfer data via SPI into the U421. The data can then be read from the PC (Win⁄Linux) or Mac (OSX) with an application. The external processor could be, for example, a PIC that performs data collection and filtering from an analog sensor, and transfers readings to the PC (Win⁄Linux) or Mac (OSX) via the U421.

Stepper Motor Control

The U421 can be operated as a two channel stepper motor controller. The U401 can interface to various types of stepper motor driver circuits. The stepper sequence can be "Wave", "Full", or "Half" with control over direction, speed, and step count.

1-Wire Interface

The U421 can interface with 1-wire devices (temperature sensors, i⁄o ports, etc) either on each individual U421 device pin, or on a bus of multiple 1-wire devices.

Hardware:  U401 USB Interface    U421 USB Interface   U451 USB Interface

Programming:  USBm DLL Programming    Download Files

Application Notes:  U4x1 Application Notes    Misc Applications and Information    FAQ

While every effort has been made to make sure that the information posted on this site is correct, the author can not be held liable for any damages whatsoever for losses as a result of the application of this information. Use this information at your own risk.

USBmicro can design your custom and semi-custom USB product. Email about USB design can be directed to " Robert " at

Copyright © USBmicro, L.L.C., 2002-2010

Previous  |  Next ]     [ Up  |  First  |  Last ]     (Article 13 of 126)

This page is created with TreePad