Difference between revisions of "Component: FTDI (FTD2XX) (Third Party)"

From Flowcode Help
Jump to navigationJump to search
Line 16: Line 16:
  
 
==Detailed description==
 
==Detailed description==
 +
 +
  
  
Line 26: Line 28:
  
 
==Examples==
 
==Examples==
 +
 +
  
  
Line 47: Line 51:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
 
| colspan="2" | Handle of the device. 
 
| colspan="2" | Handle of the device. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | RxQueueLength
 
| width="90%" | RxQueueLength
 
|-
 
|-
 
| colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the receive queue. 
 
| colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the receive queue. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | TxQueueLength
 
| width="90%" | TxQueueLength
 
|-
 
|-
 
| colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the transmit queue. 
 
| colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the transmit queue. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | EventStatus
 
| width="90%" | EventStatus
 
|-
 
|-
Line 80: Line 84:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 98: Line 102:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 131: Line 135:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 164: Line 168:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 197: Line 201:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
 
| colspan="2" | Handle of the device. 
 
| colspan="2" | Handle of the device. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | ModemStatus
 
| width="90%" | ModemStatus
 
|-
 
|-
Line 220: Line 224:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 238: Line 242:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | DevCount
 
| width="90%" | DevCount
 
|-
 
|-
Line 256: Line 260:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
 
| colspan="2" | Handle of the device. 
 
| colspan="2" | Handle of the device. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | ReadTimeout
 
| width="90%" | ReadTimeout
 
|-
 
|-
 
| colspan="2" | Read timeout in milliseconds. 
 
| colspan="2" | Read timeout in milliseconds. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | WriteTimeout
 
| width="90%" | WriteTimeout
 
|-
 
|-
Line 284: Line 288:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 312: Line 316:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 365: Line 369:
 
| colspan="2" | Pointer to buffer to store device description as a null-terminated string 
 
| colspan="2" | Pointer to buffer to store device description as a null-terminated string 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | TempHandle
 
| width="90%" | TempHandle
 
|-
 
|-
Line 383: Line 387:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 401: Line 405:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 419: Line 423:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
 
| colspan="2" | Handle of the device. 
 
| colspan="2" | Handle of the device. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Mask
 
| width="90%" | Mask
 
|-
 
|-
Line 442: Line 446:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
 
| colspan="2" | Handle of the device. 
 
| colspan="2" | Handle of the device. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | RxQueueLength
 
| width="90%" | RxQueueLength
 
|-
 
|-
Line 465: Line 469:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 498: Line 502:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 516: Line 520:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 539: Line 543:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 562: Line 566:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 585: Line 589:
 
| colspan="2" | Index of the device to open.  Indices are 0 based. 
 
| colspan="2" | Index of the device to open.  Indices are 0 based. 
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | ft_Handle
 
| width="90%" | ft_Handle
 
|-
 
|-
Line 616: Line 620:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-
Line 634: Line 638:
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:]] -  
+
| width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
 
| width="90%" | Handle
 
| width="90%" | Handle
 
|-
 
|-

Revision as of 14:44, 17 December 2021

Author Matrix Ltd
Version 1.0
Category Third Party


FTDI (FTD2XX) component

Simulation only interface to allow communications with a FTDI USB 232 IC connected to the system. For more details refer to the D2XX_Programmers_Guide from FTDI.

Detailed description

No detailed description exists yet for this component

Examples

No additional examples


Downloadable macro reference

Fc9-comp-macro.png FT_GetStatus
Gets the device status including number of characters in the receive queue, number of characters in the transmit queue, and the current event status.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-s32-icon.png - LONG RxQueueLength
Pointer to a variable of type DWORD which receives the number of characters in the receive queue. 
Fc9-s32-icon.png - LONG TxQueueLength
Pointer to a variable of type DWORD which receives the number of characters in the transmit queue. 
Fc9-s32-icon.png - LONG EventStatus
Pointer to a variable of type DWORD which receives the current state of the event status. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_ClrRts
This function clears the Request To Send (RTS) control signal.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png FT_Write
Write data to the device.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Buffer
Pointer to the buffer that contains the data to be written to the device. 
Fc9-u32-icon.png - ULONG Bytes
Number of bytes to write to the device. 
Fc9-u32-icon.png - ULONG Count
Pointer to a variable of type DWORD which receives the number of bytes written to the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_Read
Read data from the device.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Buffer
Pointer to the buffer that receives the data from the device. 
Fc9-u32-icon.png - ULONG Bytes
Number of bytes to be read from the device. 
Fc9-u32-icon.png - ULONG Count
Pointer to a variable of type DWORD which receives the number of bytes read from the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetFlowControl
This function sets the flow control for the device. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u16-icon.png - UINT FlowControl
Flow setting 0=None, 0x0100=RTS/CTS, 0x0200=DTR/DSR, 0x0400=XON/XOFF 
Fc9-u8-icon.png - BYTE Xon
Character used to signal Xon. Only used if flow control is Xon/Xoff 
Fc9-u8-icon.png - BYTE Xoff
Character used to signal Xoff. Only used if flow control is Xon/Xoff 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_GetModemStatus
Gets the modem status and line status from the device.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-s32-icon.png - LONG ModemStatus
Pointer to a variable of type DWORD which receives the modem status and line status from the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetBreakOn
Sets the BREAK condition for the device.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_CreateDeviceInfoList
This function builds a device information list and returns the number of D2XX devices connected to the system. The list contains information about both unopen and open devices.  
Fc9-s32-icon.png - LONG DevCount
Unsigned long array used to store the number of devices connected 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetTimeouts
This function sets the read and write timeouts for the device. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-s32-icon.png - LONG ReadTimeout
Read timeout in milliseconds. 
Fc9-s32-icon.png - LONG WriteTimeout
Write timeout in milliseconds. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetBitMode
Enables different chip modes. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Mask
Required value for bit mode mask. This sets up which bits are inputs and outputs. A bit value of 0 sets the corresponding pin to an input, a bit value of 1 sets the corresponding pin to an output. 
Fc9-u8-icon.png - BYTE Mode
0=Reset / 1=AsyncBB / 2=MPSSE / 4=SyncBB / 8=MCUHost / 16=FastOpto / 32=CBUS / 64=SyncFIFO 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetRts
This function sets the Request To Send (RTS) control signal. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_GetDeviceInfoDetail
This function returns an entry from the device information list. 
Fc9-u32-icon.png - ULONG Index
Index of the entry in the device info list. 
Fc9-u32-icon.png - ULONG Flags
Pointer to unsigned long to store the flag value. 
Fc9-u32-icon.png - ULONG Type
Pointer to unsigned long to store device type. 
Fc9-u32-icon.png - ULONG ID
Pointer to unsigned long to store device ID. 
Fc9-u32-icon.png - ULONG LocID
Pointer to unsigned long to store the device location ID. 
Fc9-u8-icon.png - BYTE SerNum
Pointer to buffer to store device serial number as a null terminated string 
Fc9-u8-icon.png - BYTE Descript
Pointer to buffer to store device description as a null-terminated string 
Fc9-s32-icon.png - LONG TempHandle
Pointer to a variable of type FT_HANDLE where the handle will be stored 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_Close
Close an open device. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_ClrDtr
This function clears the Data Terminal Ready (DTR) control signal. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_Purge
This function purges receive and transmit buffers in the device. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-s32-icon.png - LONG Mask
Used to determine which buffer to purge, 1=Rx / 2=Tx / 3=Both 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_GetQueueStatus
Gets the number of bytes in the receive queue. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-s32-icon.png - LONG RxQueueLength
Pointer to a variable of type DWORD which receives the number of bytes in the receive queue. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetDataCharacteristics
This function sets the data characteristics for the device.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE WordLength
Number of bits per word - Must be 7 or 8 
Fc9-u8-icon.png - BYTE StopBits
Number of stop bits - Must be 1 or 2 
Fc9-u8-icon.png - BYTE Parity
Parity 0=None / 1=Odd / 2=Even / 3=Mark / 4=Space 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetBreakOff
Resets the BREAK condition for the device.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetDivisor
This function sets the baud rate for the device. It is used to set non-standard baud rates.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u16-icon.png - UINT Divisor
Divisor. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetBaudRate
This function sets the baud rate for the device.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u32-icon.png - ULONG BaudRate
Baud rate. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetDtr
This function sets the Data Terminal Ready (DTR) control signal. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_Open
Open the device and return a handle which will be used for subsequent accesses. 
Fc9-s16-icon.png - INT Device
Index of the device to open. Indices are 0 based. 
Fc9-s32-icon.png - LONG ft_Handle
Pointer to a variable of type FT_HANDLE where the handle will be stored. This handle must be used to access the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png ScanFor232
Scans for a FTDI D2XX device, returnes true if at least one device was found. 
Fc9-bool-icon.png - BOOL Return


Fc9-comp-macro.png FT_ResetDevice
This function sends a reset command to the device.  
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png FT_SetChars
This function sets the special characters for the device. 
Fc9-s32-icon.png - LONG Handle
Handle of the device. 
Fc9-u8-icon.png - BYTE EventCh
Event character. 
Fc9-u8-icon.png - BYTE EventChEn
0 if event character disabled, non-zero otherwise. 
Fc9-u8-icon.png - BYTE ErrorCh
Error character. 
Fc9-u8-icon.png - BYTE ErrorChEn
0 if error character disabled, non-zero otherwise. 
Fc9-u8-icon.png - BYTE Return



Property reference

Fc9-prop-icon.png Properties
Fc9-type-10-icon.png Label
A text label for the component's panel component. 
Fc9-conn-icon.png Connections
Fc9-conn-icon.png Simulations