|
|
(5 intermediate revisions by the same user not shown) |
Line 17: |
Line 17: |
| ==Component Source Code== | | ==Component Source Code== |
| | | |
− | Please click here to download the component source project: [https://www.flowcode.co.uk/wikicopy/componentsource/FC_Comp_Source_ftd2xx_232.fcsx FC_Comp_Source_ftd2xx_232.fcsx] | + | Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_ftd2xx_232.fcsx FC_Comp_Source_ftd2xx_232.fcsx] |
| | | |
| Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_ftd2xx_232.fcsx FC_Comp_Source_ftd2xx_232.fcsx] | | Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_ftd2xx_232.fcsx FC_Comp_Source_ftd2xx_232.fcsx] |
| | | |
| ==Detailed description== | | ==Detailed description== |
| + | |
| + | |
| + | |
| + | |
| | | |
| | | |
Line 46: |
Line 50: |
| | | |
| ==Examples== | | ==Examples== |
| + | |
| + | |
| + | |
| + | |
| | | |
| | | |
Line 71: |
Line 79: |
| | | |
| | | |
− | ==Macro reference==
| |
| | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetStatus'''
| |
− | |-
| |
− | | colspan="2" | Gets the device status including number of characters in the receive queue, number of characters in the transmit queue, and the current event status.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | RxQueueLength
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the receive queue.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | TxQueueLength
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the transmit queue.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | EventStatus
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the current state of the event status.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
| | | |
| | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ClrRts'''
| |
− | |-
| |
− | | colspan="2" | This function clears the Request To Send (RTS) control signal.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
| | | |
| | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Write'''
| |
− | |-
| |
− | | colspan="2" | Write data to the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Buffer
| |
− | |-
| |
− | | colspan="2" | Pointer to the buffer that contains the data to be written to the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Bytes
| |
− | |-
| |
− | | colspan="2" | Number of bytes to write to the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Count
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of bytes written to the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
| | | |
| | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Read'''
| |
− | |-
| |
− | | colspan="2" | Read data from the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Buffer
| |
− | |-
| |
− | | colspan="2" | Pointer to the buffer that receives the data from the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Bytes
| |
− | |-
| |
− | | colspan="2" | Number of bytes to be read from the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Count
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of bytes read from the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
| | | |
| | | |
| + | |
| + | ==Macro reference== |
| + | |
| + | ===FT_Close=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetFlowControl''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Close''' |
| |- | | |- |
− | | colspan="2" | This function sets the flow control for the device. | + | | colspan="2" | Close an open device. |
| |- | | |- |
| |- | | |- |
Line 202: |
Line 104: |
| |- | | |- |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| |
− | | width="90%" | FlowControl
| |
− | |-
| |
− | | colspan="2" | Flow setting 0=None, 0x0100=RTS/CTS, 0x0200=DTR/DSR, 0x0400=XON/XOFF
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Xon
| |
− | |-
| |
− | | colspan="2" | Character used to signal Xon. Only used if flow control is Xon/Xoff
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Xoff
| |
− | |-
| |
− | | colspan="2" | Character used to signal Xoff. Only used if flow control is Xon/Xoff
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 223: |
Line 110: |
| | | |
| | | |
| + | ===FT_ClrDtr=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetModemStatus''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ClrDtr''' |
| |- | | |- |
− | | colspan="2" | Gets the modem status and line status from the device. | + | | colspan="2" | This function clears the Data Terminal Ready (DTR) control signal. |
| |- | | |- |
| |- | | |- |
Line 235: |
Line 123: |
| |- | | |- |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | ModemStatus
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the modem status and line status from the device.
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 246: |
Line 129: |
| | | |
| | | |
| + | ===FT_ClrRts=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBreakOn''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ClrRts''' |
| |- | | |- |
− | | colspan="2" | Sets the BREAK condition for the device. | + | | colspan="2" | This function clears the Request To Send (RTS) control signal. |
| |- | | |- |
| |- | | |- |
Line 259: |
Line 143: |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
| |- | | |- |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| | width="90%" style="border-top: 2px solid #000;" | ''Return'' | | | width="90%" style="border-top: 2px solid #000;" | ''Return'' |
| |} | | |} |
| | | |
| | | |
| + | ===FT_CreateDeviceInfoList=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 282: |
Line 167: |
| | | |
| | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| + | ===FT_GetDeviceInfoDetail=== |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetTimeouts'''
| |
− | |-
| |
− | | colspan="2" | This function sets the read and write timeouts for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | ReadTimeout
| |
− | |-
| |
− | | colspan="2" | Read timeout in milliseconds.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | WriteTimeout
| |
− | |-
| |
− | | colspan="2" | Write timeout in milliseconds.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBitMode'''
| |
− | |-
| |
− | | colspan="2" | Enables different chip modes.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Mask
| |
− | |-
| |
− | | colspan="2" | 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.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Mode
| |
− | |-
| |
− | | colspan="2" | 0=Reset / 1=AsyncBB / 2=MPSSE / 4=SyncBB / 8=MCUHost / 16=FastOpto / 32=CBUS / 64=SyncFIFO
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetRts'''
| |
− | |-
| |
− | | colspan="2" | This function sets the Request To Send (RTS) control signal.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 409: |
Line 221: |
| | | |
| | | |
| + | ===FT_GetModemStatus=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Close''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetModemStatus''' |
| |- | | |- |
− | | colspan="2" | Close an open device. | + | | colspan="2" | Gets the modem status and line status from the device. |
| |- | | |- |
| |- | | |- |
Line 421: |
Line 234: |
| |- | | |- |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− |
| |
− |
| |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ClrDtr'''
| |
− | |-
| |
− | | colspan="2" | This function clears the Data Terminal Ready (DTR) control signal.
| |
− | |-
| |
| |- | | |- |
| | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG | | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG |
− | | width="90%" | Handle | + | | width="90%" | ModemStatus |
| |- | | |- |
− | | colspan="2" | Handle of the device. | + | | colspan="2" | Pointer to a variable of type DWORD which receives the modem status and line status from the device. |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Purge'''
| |
− | |-
| |
− | | colspan="2" | This function purges receive and transmit buffers in the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Mask
| |
− | |-
| |
− | | colspan="2" | Used to determine which buffer to purge, 1=Rx / 2=Tx / 3=Both
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 468: |
Line 245: |
| | | |
| | | |
| + | ===FT_GetQueueStatus=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 491: |
Line 269: |
| | | |
| | | |
| + | ===FT_GetStatus=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetDataCharacteristics''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetStatus''' |
| |- | | |- |
− | | colspan="2" | This function sets the data characteristics for the device. | + | | colspan="2" | Gets the device status including number of characters in the receive queue, number of characters in the transmit queue, and the current event status. |
| |- | | |- |
| |- | | |- |
Line 503: |
Line 282: |
| |- | | |- |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | WordLength
| |
− | |-
| |
− | | colspan="2" | Number of bits per word - Must be 7 or 8
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | StopBits
| |
− | |-
| |
− | | colspan="2" | Number of stop bits - Must be 1 or 2
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Parity
| |
− | |-
| |
− | | colspan="2" | Parity 0=None / 1=Odd / 2=Even / 3=Mark / 4=Space
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− |
| |
− |
| |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBreakOff'''
| |
− | |-
| |
− | | colspan="2" | Resets the BREAK condition for the device.
| |
− | |-
| |
| |- | | |- |
| | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG | | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG |
− | | width="90%" | Handle | + | | width="90%" | RxQueueLength |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetDivisor'''
| |
− | |-
| |
− | | colspan="2" | This function sets the baud rate for the device. It is used to set non-standard baud rates.
| |
| |- | | |- |
| + | | colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the receive queue. |
| |- | | |- |
| | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG | | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG |
− | | width="90%" | Handle | + | | width="90%" | TxQueueLength |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| |
− | | width="90%" | Divisor
| |
− | |-
| |
− | | colspan="2" | Divisor.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBaudRate'''
| |
− | |-
| |
− | | colspan="2" | This function sets the baud rate for the device.
| |
| |- | | |- |
| + | | colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the transmit queue. |
| |- | | |- |
| | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG | | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG |
− | | width="90%" | Handle | + | | width="90%" | EventStatus |
| |- | | |- |
− | | colspan="2" | Handle of the device. | + | | colspan="2" | Pointer to a variable of type DWORD which receives the current state of the event status. |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | BaudRate
| |
− | |-
| |
− | | colspan="2" | Baud rate.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetDtr'''
| |
− | |-
| |
− | | colspan="2" | This function sets the Data Terminal Ready (DTR) control signal.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 606: |
Line 303: |
| | | |
| | | |
| + | ===FT_Open=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 629: |
Line 327: |
| | | |
| | | |
| + | ===FT_Purge=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''ScanFor232''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Purge''' |
| |- | | |- |
− | | colspan="2" | Scans for a FTDI D2XX device, returnes true if at least one device was found.
| + | | colspan="2" | This function purges receive and transmit buffers in the device. |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-bool-icon.png]] - BOOL
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ResetDevice'''
| |
− | |-
| |
− | | colspan="2" | This function sends a reset command to the device. | |
| |- | | |- |
| |- | | |- |
Line 654: |
Line 340: |
| |- | | |- |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− |
| |
− |
| |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetChars'''
| |
− | |-
| |
− | | colspan="2" | This function sets the special characters for the device.
| |
− | |-
| |
| |- | | |- |
| | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG | | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG |
− | | width="90%" | Handle | + | | width="90%" | Mask |
| |- | | |- |
− | | colspan="2" | Handle of the device. | + | | colspan="2" | Used to determine which buffer to purge, 1=Rx / 2=Tx / 3=Both |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | EventCh
| |
− | |-
| |
− | | colspan="2" | Event character.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | EventChEn
| |
− | |-
| |
− | | colspan="2" | 0 if event character disabled, non-zero otherwise.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | ErrorCh
| |
− | |-
| |
− | | colspan="2" | Error character.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | ErrorChEn
| |
− | |-
| |
− | | colspan="2" | 0 if error character disabled, non-zero otherwise.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | | |
− | | |
− | ==Property reference==
| |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-type-10-icon.png]]
| |
− | | width="90%" | Label
| |
− | |-
| |
− | | colspan="2" | A text label for the component's panel component.
| |
− | |}==Macro reference==
| |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetStatus'''
| |
− | |-
| |
− | | colspan="2" | Gets the device status including number of characters in the receive queue, number of characters in the transmit queue, and the current event status.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | RxQueueLength
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the receive queue.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | TxQueueLength
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the transmit queue.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | EventStatus
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the current state of the event status.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ClrRts'''
| |
− | |-
| |
− | | colspan="2" | This function clears the Request To Send (RTS) control signal.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Write'''
| |
− | |-
| |
− | | colspan="2" | Write data to the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Buffer
| |
− | |-
| |
− | | colspan="2" | Pointer to the buffer that contains the data to be written to the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Bytes
| |
− | |-
| |
− | | colspan="2" | Number of bytes to write to the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Count
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of bytes written to the device.
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 798: |
Line 351: |
| | | |
| | | |
| + | ===FT_Read=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 831: |
Line 385: |
| | | |
| | | |
| + | ===FT_ResetDevice=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetFlowControl''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ResetDevice''' |
| |- | | |- |
− | | colspan="2" | This function sets the flow control for the device. | + | | colspan="2" | This function sends a reset command to the device. |
| |- | | |- |
| |- | | |- |
Line 843: |
Line 398: |
| |- | | |- |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| |
− | | width="90%" | FlowControl
| |
− | |-
| |
− | | colspan="2" | Flow setting 0=None, 0x0100=RTS/CTS, 0x0200=DTR/DSR, 0x0400=XON/XOFF
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Xon
| |
− | |-
| |
− | | colspan="2" | Character used to signal Xon. Only used if flow control is Xon/Xoff
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Xoff
| |
− | |-
| |
− | | colspan="2" | Character used to signal Xoff. Only used if flow control is Xon/Xoff
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 864: |
Line 404: |
| | | |
| | | |
| + | ===FT_SetBaudRate=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetModemStatus''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBaudRate''' |
| |- | | |- |
− | | colspan="2" | Gets the modem status and line status from the device. | + | | colspan="2" | This function sets the baud rate for the device. |
| |- | | |- |
| |- | | |- |
Line 877: |
Line 418: |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
| |- | | |- |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG | + | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG |
− | | width="90%" | ModemStatus | + | | width="90%" | BaudRate |
| |- | | |- |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the modem status and line status from the device. | + | | colspan="2" | Baud rate. |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBreakOn'''
| |
− | |-
| |
− | | colspan="2" | Sets the BREAK condition for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_CreateDeviceInfoList'''
| |
− | |-
| |
− | | colspan="2" | 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.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | DevCount
| |
− | |-
| |
− | | colspan="2" | Unsigned long array used to store the number of devices connected
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetTimeouts'''
| |
− | |-
| |
− | | colspan="2" | This function sets the read and write timeouts for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | ReadTimeout
| |
− | |-
| |
− | | colspan="2" | Read timeout in milliseconds.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | WriteTimeout
| |
− | |-
| |
− | | colspan="2" | Write timeout in milliseconds.
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 951: |
Line 428: |
| | | |
| | | |
| + | ===FT_SetBitMode=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 979: |
Line 457: |
| | | |
| | | |
| + | ===FT_SetBreakOff=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetRts''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBreakOff''' |
| |- | | |- |
− | | colspan="2" | This function sets the Request To Send (RTS) control signal. | + | | colspan="2" | Resets the BREAK condition for the device. |
| |- | | |- |
| |- | | |- |
Line 997: |
Line 476: |
| | | |
| | | |
| + | ===FT_SetBreakOn=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetDeviceInfoDetail''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBreakOn''' |
| |- | | |- |
− | | colspan="2" | This function returns an entry from the device information list. | + | | colspan="2" | Sets the BREAK condition for the device. |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Index
| |
− | |-
| |
− | | colspan="2" | Index of the entry in the device info list.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Flags
| |
− | |-
| |
− | | colspan="2" | Pointer to unsigned long to store the flag value.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Type
| |
− | |-
| |
− | | colspan="2" | Pointer to unsigned long to store device type.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | ID
| |
− | |-
| |
− | | colspan="2" | Pointer to unsigned long to store device ID.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | LocID
| |
− | |-
| |
− | | colspan="2" | Pointer to unsigned long to store the device location ID.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | SerNum
| |
− | |-
| |
− | | colspan="2" | Pointer to buffer to store device serial number as a null terminated string
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Descript
| |
− | |-
| |
− | | colspan="2" | Pointer to buffer to store device description as a null-terminated string
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | TempHandle
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type FT_HANDLE where the handle will be stored
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Close'''
| |
− | |-
| |
− | | colspan="2" | Close an open device.
| |
| |- | | |- |
| |- | | |- |
Line 1,068: |
Line 495: |
| | | |
| | | |
| + | ===FT_SetChars=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ClrDtr''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetChars''' |
| |- | | |- |
− | | colspan="2" | This function clears the Data Terminal Ready (DTR) control signal. | + | | colspan="2" | This function sets the special characters for the device. |
| |- | | |- |
| |- | | |- |
Line 1,081: |
Line 509: |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
| |- | | |- |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | + | | width="90%" | EventCh |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
| |- | | |- |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | + | | colspan="2" | Event character. |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Purge'''
| |
| |- | | |- |
− | | colspan="2" | This function purges receive and transmit buffers in the device. | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
| + | | width="90%" | EventChEn |
| |- | | |- |
| + | | colspan="2" | 0 if event character disabled, non-zero otherwise. |
| |- | | |- |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | Handle | + | | width="90%" | ErrorCh |
| |- | | |- |
− | | colspan="2" | Handle of the device. | + | | colspan="2" | Error character. |
| |- | | |- |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | Mask | + | | width="90%" | ErrorChEn |
| |- | | |- |
− | | colspan="2" | Used to determine which buffer to purge, 1=Rx / 2=Tx / 3=Both | + | | colspan="2" | 0 if error character disabled, non-zero otherwise. |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetQueueStatus'''
| |
− | |-
| |
− | | colspan="2" | Gets the number of bytes in the receive queue.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | RxQueueLength
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of bytes in the receive queue.
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 1,132: |
Line 534: |
| | | |
| | | |
| + | ===FT_SetDataCharacteristics=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 1,165: |
Line 568: |
| | | |
| | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| + | ===FT_SetDivisor=== |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBreakOff'''
| |
− | |-
| |
− | | colspan="2" | Resets the BREAK condition for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 1,206: |
Line 592: |
| | | |
| | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| + | ===FT_SetDtr=== |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBaudRate'''
| |
− | |-
| |
− | | colspan="2" | This function sets the baud rate for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | BaudRate
| |
− | |-
| |
− | | colspan="2" | Baud rate.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 1,247: |
Line 611: |
| | | |
| | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| + | ===FT_SetFlowControl=== |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Open'''
| |
− | |-
| |
− | | colspan="2" | Open the device and return a handle which will be used for subsequent accesses.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
| |
− | | width="90%" | Device
| |
− | |-
| |
− | | colspan="2" | Index of the device to open. Indices are 0 based.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | ft_Handle
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type FT_HANDLE where the handle will be stored. This handle must be used to access the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''ScanFor232'''
| |
− | |-
| |
− | | colspan="2" | Scans for a FTDI D2XX device, returnes true if at least one device was found.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-bool-icon.png]] - BOOL
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ResetDevice'''
| |
− | |-
| |
− | | colspan="2" | This function sends a reset command to the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetChars'''
| |
− | |-
| |
− | | colspan="2" | This function sets the special characters for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | EventCh
| |
− | |-
| |
− | | colspan="2" | Event character.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | EventChEn
| |
− | |-
| |
− | | colspan="2" | 0 if event character disabled, non-zero otherwise.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | ErrorCh
| |
− | |-
| |
− | | colspan="2" | Error character.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | ErrorChEn
| |
− | |-
| |
− | | colspan="2" | 0 if error character disabled, non-zero otherwise.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | | |
− | | |
− | ==Property reference==
| |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-type-10-icon.png]]
| |
− | | width="90%" | Label
| |
− | |-
| |
− | | colspan="2" | A text label for the component's panel component.
| |
− | |}==Macro reference==
| |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetStatus'''
| |
− | |-
| |
− | | colspan="2" | Gets the device status including number of characters in the receive queue, number of characters in the transmit queue, and the current event status.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | RxQueueLength
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the receive queue.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | TxQueueLength
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of characters in the transmit queue.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | EventStatus
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the current state of the event status.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ClrRts'''
| |
− | |-
| |
− | | colspan="2" | This function clears the Request To Send (RTS) control signal.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Write'''
| |
− | |-
| |
− | | colspan="2" | Write data to the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Buffer
| |
− | |-
| |
− | | colspan="2" | Pointer to the buffer that contains the data to be written to the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Bytes
| |
− | |-
| |
− | | colspan="2" | Number of bytes to write to the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Count
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of bytes written to the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Read'''
| |
− | |-
| |
− | | colspan="2" | Read data from the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Buffer
| |
− | |-
| |
− | | colspan="2" | Pointer to the buffer that receives the data from the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Bytes
| |
− | |-
| |
− | | colspan="2" | Number of bytes to be read from the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Count
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of bytes read from the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 1,505: |
Line 645: |
| | | |
| | | |
| + | ===FT_SetRts=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetModemStatus''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetRts''' |
| |- | | |- |
− | | colspan="2" | Gets the modem status and line status from the device. | + | | colspan="2" | This function sets the Request To Send (RTS) control signal. |
| |- | | |- |
| |- | | |- |
Line 1,517: |
Line 658: |
| |- | | |- |
| | colspan="2" | Handle of the device. | | | colspan="2" | Handle of the device. |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | ModemStatus
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the modem status and line status from the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− |
| |
− |
| |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBreakOn'''
| |
− | |-
| |
− | | colspan="2" | Sets the BREAK condition for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− |
| |
− |
| |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_CreateDeviceInfoList'''
| |
− | |-
| |
− | | colspan="2" | 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.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | DevCount
| |
− | |-
| |
− | | colspan="2" | Unsigned long array used to store the number of devices connected
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 1,564: |
Line 664: |
| | | |
| | | |
| + | ===FT_SetTimeouts=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 1,592: |
Line 693: |
| | | |
| | | |
| + | ===FT_Write=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
| | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBitMode''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Write''' |
| |- | | |- |
− | | colspan="2" | Enables different chip modes. | + | | colspan="2" | Write data to the device. |
| |- | | |- |
| |- | | |- |
Line 1,606: |
Line 708: |
| |- | | |- |
| | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | Mask | + | | width="90%" | Buffer |
− | |-
| |
− | | colspan="2" | 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.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Mode
| |
− | |-
| |
− | | colspan="2" | 0=Reset / 1=AsyncBB / 2=MPSSE / 4=SyncBB / 8=MCUHost / 16=FastOpto / 32=CBUS / 64=SyncFIFO
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetRts'''
| |
− | |-
| |
− | | colspan="2" | This function sets the Request To Send (RTS) control signal.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetDeviceInfoDetail'''
| |
− | |-
| |
− | | colspan="2" | This function returns an entry from the device information list.
| |
| |- | | |- |
| + | | colspan="2" | Pointer to the buffer that contains the data to be written to the device. |
| |- | | |- |
| | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG | | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG |
− | | width="90%" | Index | + | | width="90%" | Bytes |
| |- | | |- |
− | | colspan="2" | Index of the entry in the device info list. | + | | colspan="2" | Number of bytes to write to the device. |
| |- | | |- |
| | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG | | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG |
− | | width="90%" | Flags | + | | width="90%" | Count |
| |- | | |- |
− | | colspan="2" | Pointer to unsigned long to store the flag value.
| + | | colspan="2" | Pointer to a variable of type DWORD which receives the number of bytes written to the device. |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | Type
| |
− | |-
| |
− | | colspan="2" | Pointer to unsigned long to store device type.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | ID
| |
− | |-
| |
− | | colspan="2" | Pointer to unsigned long to store device ID.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | LocID
| |
− | |-
| |
− | | colspan="2" | Pointer to unsigned long to store the device location ID.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | SerNum
| |
− | |-
| |
− | | colspan="2" | Pointer to buffer to store device serial number as a null terminated string
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Descript
| |
− | |-
| |
− | | colspan="2" | Pointer to buffer to store device description as a null-terminated string
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | TempHandle
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type FT_HANDLE where the handle will be stored
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Close'''
| |
− | |-
| |
− | | colspan="2" | Close an open device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ClrDtr'''
| |
− | |-
| |
− | | colspan="2" | This function clears the Data Terminal Ready (DTR) control signal.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Purge'''
| |
− | |-
| |
− | | colspan="2" | This function purges receive and transmit buffers in the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Mask
| |
− | |-
| |
− | | colspan="2" | Used to determine which buffer to purge, 1=Rx / 2=Tx / 3=Both
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_GetQueueStatus'''
| |
− | |-
| |
− | | colspan="2" | Gets the number of bytes in the receive queue.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | RxQueueLength
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type DWORD which receives the number of bytes in the receive queue. | |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetDataCharacteristics'''
| |
− | |-
| |
− | | colspan="2" | This function sets the data characteristics for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | WordLength
| |
− | |-
| |
− | | colspan="2" | Number of bits per word - Must be 7 or 8
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | StopBits
| |
− | |-
| |
− | | colspan="2" | Number of stop bits - Must be 1 or 2
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | Parity
| |
− | |-
| |
− | | colspan="2" | Parity 0=None / 1=Odd / 2=Even / 3=Mark / 4=Space
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBreakOff'''
| |
− | |-
| |
− | | colspan="2" | Resets the BREAK condition for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetDivisor'''
| |
− | |-
| |
− | | colspan="2" | This function sets the baud rate for the device. It is used to set non-standard baud rates.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| |
− | | width="90%" | Divisor
| |
− | |-
| |
− | | colspan="2" | Divisor.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetBaudRate'''
| |
− | |-
| |
− | | colspan="2" | This function sets the baud rate for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| |
− | | width="90%" | BaudRate
| |
− | |-
| |
− | | colspan="2" | Baud rate.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetDtr'''
| |
− | |-
| |
− | | colspan="2" | This function sets the Data Terminal Ready (DTR) control signal.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− | | |
− | | |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_Open'''
| |
− | |-
| |
− | | colspan="2" | Open the device and return a handle which will be used for subsequent accesses.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
| |
− | | width="90%" | Device
| |
− | |-
| |
− | | colspan="2" | Index of the device to open. Indices are 0 based.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | ft_Handle
| |
− | |-
| |
− | | colspan="2" | Pointer to a variable of type FT_HANDLE where the handle will be stored. This handle must be used to access the device.
| |
| |- | | |- |
| | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
Line 1,911: |
Line 727: |
| | | |
| | | |
| + | ===ScanFor232=== |
| {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
| |- | | |- |
Line 1,922: |
Line 739: |
| | width="90%" style="border-top: 2px solid #000;" | ''Return'' | | | width="90%" style="border-top: 2px solid #000;" | ''Return'' |
| |} | | |} |
− |
| |
− |
| |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_ResetDevice'''
| |
− | |-
| |
− | | colspan="2" | This function sends a reset command to the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− |
| |
− |
| |
− | {| class="wikitable" style="width:60%; background-color:#FFFFFF;"
| |
− | |-
| |
− | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| |
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''FT_SetChars'''
| |
− | |-
| |
− | | colspan="2" | This function sets the special characters for the device.
| |
− | |-
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-s32-icon.png]] - LONG
| |
− | | width="90%" | Handle
| |
− | |-
| |
− | | colspan="2" | Handle of the device.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | EventCh
| |
− | |-
| |
− | | colspan="2" | Event character.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | EventChEn
| |
− | |-
| |
− | | colspan="2" | 0 if event character disabled, non-zero otherwise.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | ErrorCh
| |
− | |-
| |
− | | colspan="2" | Error character.
| |
− | |-
| |
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" | ErrorChEn
| |
− | |-
| |
− | | colspan="2" | 0 if error character disabled, non-zero otherwise.
| |
− | |-
| |
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| |
− | | width="90%" style="border-top: 2px solid #000;" | ''Return''
| |
− | |}
| |
− |
| |
− |
| |
| | | |
| | | |