PDA

View Full Version : Teensy USB options 1. Mass storage device, 2. USB pass through?



jc179
01-02-2014, 08:17 PM
Hi

I've been directed here as a possible option for a few projects im working on. I am interested in using the Teensy as a USB mass storage device, I have some picky hardware that only works with certain devices (Eg VID/ PID / Model # / SN etc). I would like to [experiment] with Teensy and see if I can have it behave as that device. From doing a little research it seems possible to change the VID and PID on the teensy to match what's needed, but is there any option to add additional USB parameters that could be picked up by the host system? I.e. advertise certain capabilities?

One other question is, is there anyway to have Teensy act as a USB pass through device (in terms of I/O and supporting a USB connection besides the built in one)? Lets say I have a joystick I want to connect to my PC, but I want to put Teensy inbetween the computer and joystick to modify the data stream?


Thanks,

Jonathan

PaulStoffregen
01-03-2014, 02:09 AM
I've been directed here as a possible option for a few projects im working on. I am interested in using the Teensy as a USB mass storage device,


Teensy 2.0 and Teensy++ 2.0 support mass storage, but Teensy 3.0 and 3.1 do not (yet). Be sure to get a 2.0 board for this.



I have some picky hardware that only works with certain devices (Eg VID/ PID / Model # / SN etc). I would like to [experiment] with Teensy and see if I can have it behave as that device. From doing a little research it seems possible to change the VID and PID on the teensy to match what's needed, but is there any option to add additional USB parameters that could be picked up by the host system? I.e. advertise certain capabilities?


Yes, you can change all this stuff. But to do so, you'll need to edit the USB code. It's not do-able from in Arduino.

After installing Teensyduino (which you can do before buying anything), look in hardware/teensy/cores/usb_disk for the code.



One other question is, is there anyway to have Teensy act as a USB pass through device (in terms of I/O and supporting a USB connection besides the built in one)? Lets say I have a joystick I want to connect to my PC, but I want to put Teensy inbetween the computer and joystick to modify the data stream?


No. Teensy is a USB device only. This would need 2 ports, one with host mode.

To learn more about "device", "host" and other USB terminology, please read chapter 4 of the USB spec.

http://www.pjrc.com/teensy/beta/usb20.pdf

jc179
01-09-2014, 04:59 PM
Hi Paul

thanks very much for the detailed reply. So to sum it up the Teensy only supports being a USB device, but not acting as a USB Host.

Thanks,

Jonathan

Rob
01-13-2014, 11:10 PM
You could add a USB Host Shield.

Shield
http://www.circuitsathome.com/products-page/arduino-shields/usb-host-shield-for-arduino-pro-mini/

Library
http://www.pjrc.com/teensy/td_libs_USBHostShield.html

jc179
01-17-2014, 04:04 PM
Hey

that's cool! thanks, will look into that.

Cheers

Jonathan

Mevon
03-26-2014, 08:20 PM
Hi everyone,

Please follow this thread, maybe I can get somewhere where I can find a solution with the Teensy 3/3.1 and Freescale USB Stack + Processor Expert inside Eclipse.

http://forum.pjrc.com/threads/25367-...d-(Teensy-3-1)

Thank you,
Mevon

(Sorry for spamming)