USB to SPI

Go To Last Post
7 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Does anyone have any experience using USB to SPI? I know USB to serial is commonplace but I have an application that needs a high speed SPI master, and going to serial and then to SPI would be too slow. The FT2232 is alleged to have an SPI mode on one channel, and I found a Cypress PSOC application note. I could use an AT90USBxxx, but I'm on a tight schedule and prefer not to have to develop the code from scratch. I heard rumors of a PIC solution, but I don't want to go there :?

So I thought I'd ask here and see if anyone has already done it.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

There is around an ISP programmer that uses the bitbanged (??) SPI of the FTDI chip (FT232RL??). Not really sure how it all works, someone in eastern Europe was selling the kit.

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

There are several interesting projects that do soft-USB. Some of them report to do SPI. They use ATTiny45 up to ATMega168s and beyond. This page has a list of applications: http://www.obdev.at/products/avr...

This one might be useful in: http://www.headfuzz.co.uk/?q=USB...
Or this one? http://www.xs4all.nl/~dicks/avr/...

Not sure they fit the bill, but worth a shot :-)

David

Dr. David Harris OpenLCB Development Team openlcb.org

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'm actually in the same boat really. Hope i'm not hijacking but i am using an AVR (new XMega 4A) to talk to an SD Card. Now, i also want to be able to plug the laptop into it and have the SD card show up as a Mass Storage Device but i dont want to go through the uC (though i could use a DMA i guess)

I dont need to be able to use the SD card with the uC when the Laptop is plugged in so a simple stand alone SD Card Reader chip would be fine.

Any input?

I'm planning on soldering a Micro SD card to the PCB and still want to be able to access/modify the data using a PC of some sorts

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You can get USB-based SPI and I2C host adapter called Aardvark from Total Phase. Works for me.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

userial is a USB to I2C/SPI/GPIO adapter. It is based on an AT90USB647, but is easily ported to AT90USB162 or similar. It uses Dean Camera's LUFA library, enumerates as an virtual COM port (CDC class; no driver installation required) and you control the I2C/SPI/GPIO ports using a simple ASCII Based protocol.

It is not high speed, but it might give you enough help to jump-start your software.

Thomas

pycrc -- a free CRC calculator and C source code generator

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Dean Camera Rules. Thanks, tpircher, for the suggestion of Dean's LUFA library, and thanks, Dean, for providing it. I used a USB key and my total code and debugging took less than one hour.