Dear all,
I am currently working on connecting a self build sensor with the HTC Desire
running Android with hostmode enabled. I am using a FTDI Chip and libftdi for
the task.
Since it might be possible that I have multiple FTDI Devices connected, I
cannot use the ftdi_usb_open API. Instead i'm using ftdi_usb_find_all
afterwards ftdi_usb_open_dev. Then I read the eeprom(ftdi_read_eeprom_getsize &
ftdi_eeprom_decode), to determine weather this is the sensor I'm looking for.
I have two problems with this:
1. I have arbitrary problems with reading the eeprom. Mostly it works the first
time after a reboot, but on the second time I get a error on reading the
eeprom. It also happens, that it does not work at all after a reboot or it even
works multiple times in a row without the need to reboot. Does anybody have an
Idea what I am doing wrong with this? Is there another way how to distinguish
between multiple FTDI devices?
2. When I try to set the baudrate for the sensor with ftdi_set_baudrate after I
did the ftdi_usb_open_dev I get an error. After some research I found out, that
ftdi_usb_open_dev already sets the baudrate to something like 9600, I need
115200 though. After looking through the API I did not find a different way to
do this. Is there any way I can connect to a usb_device and set the baudrate
manually? Are there any other ways to discover all connected FTDI devices and
connect with a specific one not using the ftdi_usb_open_dev API?
Your help would be greatly appreciated.
Thank you.
Tim Schneider
--
libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx
|