BrainStem USB Interface Information
Last Modified: 2008-01-29
find:

basket

Acroname Robotics PDF webpage version BrainStem USB Interface Information PDF

Related
Products

Product image for BrainStem Moto 1.0 Module
BrainStem Moto 1.0 Module
Product image for Brainstem GP 1.0 Module
Brainstem GP 1.0 Module
Product image for USB-Serial Interface Conn V2.0
USB-Serial Interface Conn V2.0
Product image for USB Serial Int Assembly V2.0
USB Serial Int Assembly V2.0
Product image for CMUCam2+
CMUCam2+
Product image for Nubotics Wheel Commander
Nubotics Wheel Commander

Contents

Overview

The BrainStem USB Interface offers a USB-based connection to any standard RS-232 serial device.  This is accomplished in two layers.  The first layer manages the direct USB driver layer to connect to the Bridge chip used on the USB Interface board.  The second layer sits on top of the base layer and it provides a psueudo serial interface to you operating system layer.  This allows you to use standard serial calls on your computer and things get negotiated across USB to the TTL level signals that form the other end of this interface connector.  These signals conform to the Acroname Serial Interface Standard so they work with all BrainStem modules, the CMUCam2+, Wheel Commander, and any other conforming device. 

Host and Peripheral USB

USB is based on a tree topology with each root node being a USB host and each branch of the tree being a peripheral.  Common peripherals are handhelds, phones, iPods, and BrainStems.  Unfortunately, a host and peripheral are not the same and you cannot readily connect a handheld or iPod that uses USB to the BrainStem as they are both peripherals.  You need a host like a PC to negotiate the traffic on the bus so a iPod powered robot is not currently an easy proposition. 

Windows USB Serial Adapter Information

Note

These instructions are for XP.  The following set of instructions seems to work with Windows 2000 as well, but we primarily work with XP. 

Instructions are also available for Mac OS X.  

The Windows interface is quite easy to set up.  That being said, we still see people that are challenged by this configuration.  The basic steps for this interface are as follows:

Start without plugging in the USB device.  It won't break anything if you do (you probably did first, before reading these instructions) but it is easier if you don't.  Install the drivers found in the Acroname Download Center .  This driver is found under the category "Drivers" and the target "Win32". 

Be certain you get the proper driver where the part number on the back of your USB interface connector matches the driver file name.  These drivers are pretty straightforward.  It will seem like it installs twice as there are two layers and each needs to be installed. 

Next, you can plug in the interface connector and you should get some sort of happy sound and indication from the device manager that the device is recoginized and ready to use.  There are two things to check out at this point.  One is whether the little yellow light is lit on the connector.  This indicates that the connector is getting reliable power.  The second is to open your device manager to check that the hardware has been recoginized by Windows.  This is under your Control Panel's System Icon.  The System Properties show a tab named "Hardware".  Click on this and then click the "Device Manager" button.  You will get a screen that looks like this:

What you should see in the Device Manager for Windows.

Make sure this device is present and doesn't show a yellow icon with a question mark which would indicate that there is a problem with the drivers or the connection. 

Now, the device is ready to use if you have gotten this far.  For the BrainStem or other devices, will need to figure out what the device ("COM" port in Windows speak) name is.  This can be done by getting the properties by right-clicking on the entry shown above in the device manager.  This will give you a property panel and you will want the "Port Settings" tab.  Click the Advanced Button and you can then change or learn what COM port you are using:

Preference panes for changing USB device information on Windows.
Digging deeper into the USB port configuration in Windows.

Be sure you configure your device to use the shown COM port or change the COM port to the one you need to use for your device.  Generally, it is safest to use an unused COM port below COM5, although if you know what you are doing, any COM port will work. 

Configuring Brainstem Applications in Windows

The final step is only relevant for BrainStem users.  You will want to make a file for each of our standard applications (like Console, Moto, and GP).  These files are all documented in the reference (just type ".config" in the find box on any website page including this one).  Each file is a plain text file and the case (capitalization) of the file name is just as important as the extension.  If either is wrong, the file will not work.  For instance, the console uses a file named "console.config".  This file must be placed in the aBinary directory.  If you downloaded the GP and Console applications into separate folders (we recommend you place them on top of one another in the same folder), you must make sure you have the file in the same aBinary directory as the executable you are trying to run (like GP.exe). 

Note

Windows by default messes this up frequently as it tries to "help" you by obscuring (hiding) the actual extension of the filenames.  This means you may look at the file in the explorer window and see a name of "console.config" but the actual filename might be "console.config.txt".  This is the case by default if you create the file in Notepad and haven't disabled the hiding of extensions (under folder options) in explorer.  We are driven crazy by this and explicitly disable this "feature" in Windows on any machine we get near.  To be certain, right-click on the file and view it's properties as shown in the following figure:

Screenshot of making sure Windows did not append a txt file extension.
Making sure Windows did not append a txt file extension.

The file contents are a couple of lines of text that again must be typed with the proper case to work.  Here is an example console.config file that specifies COM4 as the port for the Console application to use:

portname = COM4

Spaces don't matter in the config files and you can comment out a line with the "#" character so this same file could written:

# console.config (without a hidden .txt extension) # this file is for the console serial configuration # set the portname for the USB interface connector portname = COM4

Configuring Brainstem Applications in MacOS X

The configuration procedure for the USB to serial devices has previously been covered in the article MacOS USB Tips .  The following procedure outlines the necessary steps to get the USB Serial Interface Connector to work with your system. 

Install the drivers found in the Acroname Download Center .  This driver is found under the category "Drivers" and the target "All".  Select the "MacOS X USB/Serial Drivers" download option.  Untar the downloaded file and double click it to expand the download into a Disk Image.  Follow the instructions in the installer and view the README.txt file if necessary. 

Follow the instructions at MacOS USB Tips .  The major difference will be the name of the USB device.  Here is an example console.config file for the S19-USB-SERIAL-INT adapter. 

# Example of a Console.config file for S19-USB-SERIAL-INT portname = tty.SLAB_USBtoUART

Linux USB to Serial Adapter Information

The USB Serial Interface Connector has been tested sucessfully on a Fedora Core 3 install with a 2.6 kernel.  A Brainstem's heartbeat was observed using Minicom without having to install any additional drivers or do any modifications of the system to get things to work. 

Tip

You can check the kernel build and operating system version of your machine by typing the following into a shell.  Supported kernel versions for the S19-USB-SERIAL-INT are now 2.4 and 2.6. 

user$ uname -a

You can check to see if the device has been inserted by looking at the system message buffer.  This is one of many methods that can be used to find out what and where devices may exist at. 

user$ dmesg | grep "USB"

If the system can identify the S19-USB-SERIAL-INT, it will say something like "CP2101 converter now attached to ttyUSB0".  The attached location may be different from machine to machine. 

Other Linux based systems are NOT supported directly by Acroname due to variety of kernels, OS versions, hardware, and religions. 

Conclusion

In general, you will need to load the drivers, set a known COM port, and create a 1-line text file with the proper name, extension, and contents.  That should be all you need to use the BrainStem modules with the USB Interface.  Once this work is done, you likely will not need to do it again as long as you use the modules on the same machine.  There are more notes on downloading the software in the Windows Downloading Tips

Revision History:

  • 2007-11-07: Added a comment so users are sure they get the correct driver for the part number of the USB adapter they are using.

BrainStem
Resources

 

Related Links:

Acroname Serial Interface Standard

Tips on interfacing the BrainStem to a MacOS X USB hub

BrainStem - Hardware

voice: 720-564-0373, email: sales@acroname.com, address: 4822 Sterling Dr., Boulder CO, 80301-2350, privacy
© Copyright 1994-2008 Acroname, Inc., Boulder, Colorado. All rights reserved.