Recent

Author Topic: TFTDI Component  (Read 4831 times)

six1

  • Full Member
  • ***
  • Posts: 117
TFTDI Component
« on: May 27, 2016, 09:21:45 am »
Hi,
for my need, i made a FTDI (FTDI Chips able to work with D2xxUnit) Component.
Direct communication, without a virtual com port!
Librarys must be installed first!
WIN (ftd2xx.dll) --> Program Folder or Windows System
LINUX (libftd2xx.so.1.3.6) --> /usr/lib/(libftd2xx.so

With Linux, it is important, to unload driver in system per default! Otherwise you can't access FT-Chip    .
You have to make a Rule in /etc/udev/rules.d  like 98-ftdi.rules
Insert following for Standard Device Descriptions of FTDI into Rule file:
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", ATTRS{product}=="FT232R USB UART", RUN+="/bin/sh -c 'echo $kernel > /sys/bus/usb/drivers/ftdi_sio/unbind'"

Because of the Device Description can be changed with FT_PROG ("FT232R USB UART"), you maybe have to insert different lines!

If you have your own, specific DeviceDescription, just fill in at Component/DeviceDescrition an set Component to active.
Events for connected/disconnected are fired...

If you have standard DeviceDescription  ("FT232R USB UART") and your Hardware behind FTDI Chip is able to answer requests with a string, you can check also Device is online:
Fill in ConectSendString. This will be send to your Device (behind FTDI)
Fill in ConnectReplyString. ( If pos(ConnectReplyString,  Device Answer String) > 0 then Device.active := true)


Not all possible functions are implemented by now. There is BitBanging also possible. (Spare pins on FT232rl i.e)
The FDeviceInfo Structure gives you an overview of Device...

Receive and connecting is done by threading.


Maybe, you find it usefull.



Best, Michael

Download FTDI.zip
« Last Edit: May 27, 2016, 12:16:47 pm by six1 »

 

TinyPortal © 2005-2018