Author Topic: FTDI Linux Bitbang  (Read 10784 times)

Brownout

  • Member
  • ***
  • Posts: 14
FTDI Linux Bitbang
« on: February 01, 2015, 11:20:54 pm »
I have been working with FTDI FT4232 USB products for both UART and Bitbang functionality.  Here is my previous thread: http://janaxelson.com/forum/index.php?topic=1169.msg5663#msg5663  But now I'm migrating to Linux and I'm not exactly sure how to proceed.  I'm confused by some of the things I've read, like how supplied Linux drivers are only good for serial and not Bitbang.  I'm not sure if D2XX drivers work in Linux.  Although FTDI website shows a Linux download, I've read they don't work reliably.  Also, there is a 3rd party driver which is claimed to work (libftdi), but I can't use the programs I've written because it uses a different API.  And so, my question is: is anyone using FTDI bitbang with Linux?  Could you please share your experience with me?  I'm running Fedora 20 and using FT4232 mini module.

Brownout

  • Member
  • ***
  • Posts: 14
Re: FTDI Linux Bitbang
« Reply #1 on: February 01, 2015, 11:22:32 pm »
Also, I'd be interested in other easy ways to get USB to general purpose I/0.

Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 3033
    • Lakeview Research
Re: FTDI Linux Bitbang
« Reply #2 on: February 02, 2015, 06:21:58 pm »
I've been impressed with Phidgets:

http://www.phidgets.com/

They use the HID driver. If you don't want to buy the Phidgets hardware, you can use the HID driver with just about any device controller. I have Linux HID code here, also libusb code (another option):

http://janaxelson.com/beagleboard.htm

Brownout

  • Member
  • ***
  • Posts: 14
Re: FTDI Linux Bitbang
« Reply #3 on: February 03, 2015, 12:19:23 pm »
Thanks Jan.  Great article about using HID, and I definitely want to try this with a PIC 18F4550 (for example)  I've heard of people doing this, but have never read such a detailed article about how to achieve it.  This is on my list of things to do.  However, at this time, the D2xx library is working correctly on my Linux machine.  The only trick is to disable the core ftdi_sio driver before running the D2xx program.  You can't run one while the other is running.

Although installing libftdi didn't work, using the library supplied by FTDI was easier than I thought.  I was hesitant only because everything I've done with Linux has turned out to be days long, arduous, nail-biting, hair-pulling experiences.  This time, not so much.

Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 3033
    • Lakeview Research
Re: FTDI Linux Bitbang
« Reply #4 on: February 03, 2015, 12:42:09 pm »
Glad you got it working!