P&E Microcomputer Systems, Inc.
P.O. Box 2044, Woburn, MA 01888, USA
TEL: (617) 353-9206 FAX: (617) 353-9205 http://www.pemicro.com
USB HCS08/HCS12 Multilink Rev. C
Technical Summary
Supporting Freescale RS08/HCS08/HC(S)12(X) Families
Document # PE3374, Version 1.02
1. Introduction
2. Usage of the HCS08/HCS12 Multilink Interface
3. Driver Installation on Windows XP/2000
4. Computers running Windows 95, 98, ME, and NT
5. Using a USB Hub
6. Connecting to the target
7. Startup Reset Sequence
8. Interface Libraries
9. Firmware Updates
1.0 Introduction
P&E’s USB HCS08/HCS12 MULTILINK Interface provides access to the Background Debug Mode (BDM)
on Freescale RS08, HCS08, HC12 and HCS12 microcontrollers. It is the hardware interface between a USB
port on a Windows 2000 or XP machine and the standard 6-pin “Berg” debug connector on the target. By
using the USB HCS08/HCS12 MULTILINK, the user can take advantage of the background debug mode to
halt normal processor execution and use a PC to control the processor. The user can then directly control the
target’s execution, read/write registers and memory values, debug code on the processor, and program
internal or external FLASH memory devices.
The pin-outs of the connector as specified by Freescale are:
2.0 Usage of the USB HCS08/HCS12 Multilink Interface
The USB HCS08/HCS12 MULTILINK can communicate with an RS08, HCS08, HC12, or HCS12 processor
whose bus frequency is up to 35 MHz. P&E’s softw are packages will automatically detect the proper
communications rate to establish a connection with the target. For HC12/HCS12 devices, the BDM
communications speed may be set (instead of being auto-detected) by setting the value of the
IO_DELAY_CNT variable. The proper IO_DELAY_CNT may be calculated by the equation:
IO_DELAY_CNT = (120000000 / Fbus) – 1
Fbus is the bus frequency in hertz. The RS08 and HCS08 frequency is always detected automatically.
The Multilink interface will work w ith targets whose pr ocessor power supply is in the range of 1.6V to 5.25V.
The Multilink interface derives its power from the USB port and as such draws less than 1mA from the
target.
The USB HCS08/HCS12 Multilink has a female type B USB connector. Use a Type A to Type B USB
extension cable to connect the interface to the PC.
The USB HCS08/HCS12 Multilink is a high power USB device. If a USB HUB is used, it must be a self-
powered hub (i.e. with a power supply). By default, the USB protocol used is 2.0.
There are two LEDs, which protrude through the housing of the USB HCS08/HCS12 Multilink interface.
The Blue LED indicates that the Multilink interface is powered and running. The Yellow LED indicates that
target power has been detected.
The 6-pin ribbon cable, which allows connection to the target debug connector, is fixed within the Multilink
housing. PIN 1 is denoted by the red stripe running down the ribbon cable.
3.0 Driver Installation on Windows XP/2000
Before connecting the USB HCS08/HCS12 Multilink to the PC, the appropriate drivers need to be installed
on the PC. The drivers are automatically installed when installing any of P&E’s RS08/HCS08/HC12/HCS12
development packages built after January 1, 2005. A copy of the driver installation program may also be
downloaded from the “Downloads” section of P&E’s “Support Center” located at http://www.pemicro.com.
When the cable is plugged in, the operating system should indicate that it has found a driver for the attached
“USB Multilink 2.0”. Follow the instructions in the “Found New Hardw are Wiz ard” dialog for having
Windows automatically install the driver.
If you connected the Multilink interface prior to installing the drivers, Windows will not have been able to
find the appropriate driver and may have disabled the device. If you unplug and then plug in the device,
Windows will automatically disable it even if you have installed the drivers. To force Window s to attempt to
load the driver again, perform the following steps while the USB HCS08/HCS12 Multilink interface is
plugged into the computer:
1.) Open the Control Panel (Start Button->Settings->Control Panel)
2.) Double Click the “System” Icon
3.) Select the “Hardware” tab
4.) Click the “Device Manager” Button
5.) The “USB-ML-12 Rev. C” device will be shown with an exclamation mark next to it. Double
click this device.
6.) Click the “Reinstall Driver…” button and follow the dialog instructions for having Windows
automatically install the driver.
If you have purchased one of P&E’s software development packages prior to January 1, 2005, contact P&E
to obtain the latest version which supports the USB HCS08/HCS12 Multilink Rev. C interface (support for
the cable is separate from the Windows USB drivers). If you are using third-party software, make sure you
have a version which supports the USB HCS08/HCS12 Multilink Rev. C interface.
4.0 Computers running Windows 98, ME
The USB HCS08/HCS12 Multilink is supported under Windows 98 and Windows Millenium Edition
(ME). The driver installation is similar to that of Windows XP/2000.
5.0 Computers running Windows 95, NT
Windows NT and Windows 95 do not have support for USB, and therefore the USB Multilink is not
supported under these operating systems. For these operating systems, P&E produces the BDM Multilink,
which connects the parallel port on the PC to the 6-pin debug connector on the target. For more information,
visit http://www.pemicro.com.
6.0 Using a USB Hub
The USB HCS08/HCS12 Multilink is classified as a high power USB device, which is powered from the USB
bus. A high power device requires that if a USB hub is used, it must be a self-powered hub. This means that it
has a separate power supply from which it derives its operating pow er (as opposed to deriving its power from
the PC). It must be able to supply 500mA per port (a high power USB device may derive up to 500mA from
the port). P&E has made a powered hub available as an accessory, which has been tested with the USB
HCS08/HCS12 Multilink. Details may be found at http://www.pemicro.com.
7.0 Connecting to the target
The following is the proper connection sequence to connect the PC to the target system via the USB
HCS08/HCS12 Multilink interface:
1) Make sure the target power is OFF and the USB HCS08/HCS12 Multilink is not connected to either
the target or the PC
2) Connect the Multilink to the target via its ribbon cable. Make sure that the ribbon cable is plugged
into the target with the proper orientation. PIN 1 is denoted by the red stripe running down the
ribbon cable.
3) Connect the Multilink to the PC via a USB extension cable. The Blue LED on the Multilink should
become lit.
4) Turn the target power on. The Yellow LED on the Multilink should become lit.
Before disconnecting the setup, turn the target power off.
7.0 Startup Reset Sequence
In order to use the Background Debug Mode of the microcontroller, it is initialized into debug mode via a
reset sequence.
This is accomplished by P&E’s software via the following reset sequence:
RST 5msec
BKGD 10msec 20msec
a) Initially the BKGD (pin-1) and Reset (pin-4) are pulled low.
b) After 5 milliseconds, the RESET (pin-4) goes high.
c) After 10 milliseconds, the BKGD (pin-1) goes high.
d) Wait for 20 milliseconds, followed by activities on BKGD (pin-1).
8.0 Interface Libraries
One of the products P&E produces is a set of interface libraries which allows the user to directly control the
USB HCS08/HCS12 Multilink from any Windows Development Environment which can interact w ith a
DLL. The interface libraries come with examples for controlling the Multilink interface from Microsoft
Visual C as well as Borland Delphi. Details of the libraries for the RS08 may be found at P&E's RS08
Product Page. Details of the libraries for the HCS08 may be found at P&E's HCS08 Product Page. Details of
the libraries for the HC12 and HCS12 may be found at P&E's HC(S)12 Product Page.
9.0 Firmware Updates
The latest version of the firmware for the Multilink interface is included in P&E softw are development kits.
When the debugger or programmer is run, if it detects that the Multilink interface firmware needs to be
updated, it will ask the user’s permission to do this. If granted, the update happens automatically.
Alternately, the latest version of the firmware may be downloaded from the “Firmw are Updates” section of
the “Support Center” located at http://www.pemicro.com.