FT232H
The sixth generation of fixed-function D2xx devices. This is essentially half of an FT2232H with some improvements.
The base device is FT232H. However, just like FT2232H, it also has two USB-PD variants:
- FT233HP: two USB-PD ports
- FT232HP: one USB-PD port (actually identical to FT233HP with the extra port unbonded)
Both USB-PD variants are the same silicon (which is distinct from the "base" FT232H silicon).
Features:
- is a high-speed USB 2.0 peripherial
- integrated D+ pullup resistor
- single-channel D2xx device
- can be configured to one of several supported modes:
- FT232R-like UART mode (default)
- FT245R-like FIFO mode (selected in EEPROM)
- FT2232H-like synchronous FIFO mode (dynamically selected variant of FIFO mode)
- FT2232D-like CPU FIFO mode (selected in EEPROM)
- FT2xxB-like async bitbang mode (dynamically selected)
- FT2232C-like sync bitbang mode (dynamically selected)
- FT232R-like CBUS bitbang mode (dynamically selected, but has to be pre-configured in EEPROM)
- FT2232C-like MPSSE mode (dynamically selected)
- FT2232C-like fast opto-isolated serial mode (selected in EEPROM)
- new FT1248 mode (selected in EEPROM)
- 1kiB IN FIFO and 1kiB out FIFO
- 120MHz internal base clock, generated from 12MHz crystal or external oscillator
- internal 5V to 3.3V
- internal 5V/3.3V to 1.8V LDO
- 1.8V VCORE power supply for internal logic from internal LDO
- 3.3V VCCIO power supply for business-end IO
- 3.3V VPHY power supply for USB PHY
- 3.3V separate AGND and VPLL power supply for PHY PLL
- internal power-on reset circuit
- required external support circuitry:
- precision resistor for PHY current reference
- decoupling capacitor for internal LDO
- 12MHz crystal or oscillator
- optionally, a 93LC56 (128×16-bit) or 93LC66 (256×16-bit) EEPROM
For USB-PD devices, the USB-PD function is described on the USB-PD page.
The full list of devices is:
| device | USB-PD ports | default VID:PID | bcdDevice | package |
|---|---|---|---|---|
| FT232HL | - | 0403:6014 | 0x0900 | 48-pin LQFP |
| FT232HQ | - | 0403:6014 | 0x0900 | 48-pin QFN |
| FT233HPQ | 2 | 0403:6044 | 0x3200 | 64-pin QFN |
| FT232HPQ | 1 | 0403:6045 | 0x3300 | 56-pin QFN |
Pinout — base device
| LQFP48 and QFN48 | category | function |
|---|---|---|
| 1 | clock | XCSI |
| 2 | clock | XCSO |
| 3 | power | VPHY |
| 4 | power | AGND |
| 5 | reference | REF |
| 6 | USB | DM |
| 7 | USB | DP |
| 8 | power | VPLL |
| 9 | power | AGND |
| 10 | power | GND |
| 11 | power | GND |
| 12 | power | VCCIO |
| 13 | IO-DBUS | ADBUS0 |
| 14 | IO-DBUS | ADBUS1 |
| 15 | IO-DBUS | ADBUS2 |
| 16 | IO-DBUS | ADBUS3 |
| 17 | IO-DBUS | ADBUS4 |
| 18 | IO-DBUS | ADBUS5 |
| 19 | IO-DBUS | ADBUS6 |
| 20 | IO-DBUS | ADBUS7 |
| 21 | IO-CBUS | ACBUS0 |
| 22 | power | GND |
| 23 | power | GND |
| 24 | power | VCCIO |
| 25 | IO-CBUS | ACBUS1 |
| 26 | IO-CBUS | ACBUS2 |
| 27 | IO-CBUS | ACBUS3 |
| 28 | IO-CBUS | ACBUS4 |
| 29 | IO-CBUS | ACBUS5 |
| 30 | IO-CBUS | ACBUS6 |
| 31 | IO-CBUS | ACBUS7 |
| 32 | IO-CBUS | ACBUS8 |
| 33 | IO-CBUS | ACBUS9 |
| 34 | control | RESET# |
| 35 | power | GND |
| 36 | power | GND |
| 37 | power | VCCA |
| 38 | power | VCCCORE |
| 39 | power | VCCD |
| 40 | power | VREGIN |
| 41 | power | AGND |
| 42 | control | TEST |
| 43 | EEPROM | EEDATA |
| 44 | EEPROM | EECLK |
| 45 | EEPROM | EECS |
| 46 | power | VCCIO |
| 47 | power | GND |
| 48 | power | GND |
Pinout — USB-PD devices
| QFN64 | QFN56 | category | function |
|---|---|---|---|
| 1 | 1 | EEPROM | EECS |
| 2 | 2 | EEPROM | EECLK |
| 3 | 3 | EEPROM | EEDATA |
| 4 | 4 | control | TEST |
| 5 | 5 | power | VCCIO |
| 6 | 6 | control | RESET# |
| 7 | 7 | IO-PD | GPIO0 |
| 8 | 8 | IO-PD | GPIO1 |
| 9 | 9 | IO-PD | GPIO2 |
| 10 | 10 | IO-PD | GPIO3 |
| 11 | - | IO-PD | GPIO4 |
| 12 | - | IO-PD | GPIO5 |
| 13 | 11 | power | VCORE |
| 14 | 12 | power | GND |
| 15 | 13 | power | VCCIO |
| 16 | - | IO-PD | GPIO6 |
| 17 | - | IO-PD | GPIO7 |
| 18 | 14 | power | VCCIO |
| 19 | 15 | clock | OSCI |
| 20 | 16 | clock | OSCO |
| 21 | 17 | power | GND |
| 22 | 18 | power | VREGIN |
| 23 | 19 | power | VREGOUT |
| 24 | 20 | power | FSOURCE |
| 25 | 21 | power | VPP |
| 26 | 22 | power | VCORE |
| 27 | - | NC | - |
| 28 | 23 | IO-DBUS | ADBUS0 |
| 29 | 24 | IO-DBUS | ADBUS1 |
| 30 | 25 | IO-DBUS | ADBUS2 |
| 31 | 26 | IO-DBUS | ADBUS3 |
| 32 | 27 | IO-DBUS | ADBUS4 |
| 33 | 28 | power | VCCIO |
| 34 | 29 | IO-DBUS | ADBUS5 |
| 35 | 30 | IO-DBUS | ADBUS6 |
| 36 | 31 | IO-DBUS | ADBUS7 |
| 37 | 32 | IO-CBUS | ACBUS0 |
| 38 | 33 | IO-CBUS | ACBUS1 |
| 39 | 34 | IO-CBUS | ACBUS2 |
| 40 | 35 | IO-CBUS | ACBUS3 |
| 41 | 36 | power | VCORE |
| 42 | 37 | IO-CBUS | ACBUS4 |
| 43 | 38 | IO-CBUS | ACBUS5 |
| 44 | 39 | IO-CBUS | ACBUS6 |
| 45 | 40 | power | VCCIO |
| 46 | 41 | power | GND |
| 47 | 42 | IO-CBUS | ACBUS7 |
| 48 | 43 | IO-CBUS | ACBUS8 |
| 49 | 44 | IO-CBUS | ACBUS9 |
| 50 | 45 | NC? | - |
| 51 | 46 | power | VCORE |
| 52 | 47 | power | VCC_USB |
| 53 | 48 | USB | DM |
| 54 | 49 | USB | DP |
| 55 | 50 | reference | REF |
| 56 | 51 | power | VCC_PD |
| 57 | 52 | PD | PD1_CC2 |
| 58 | 53 | PD | PD1_SVBUS |
| 59 | 54 | PD | PD1_VCONN |
| 60 | 55 | PD | PD1_CC1 |
| 61 | - | PD | PD2_CC1 |
| 62 | - | PD | PD2_SVBUS |
| 63 | - | PD | PD2_CC2 |
| 64 | 56 | power | VCORE |
Pin functions per mode
| pin | UART | FIFO | sync FIFO | CPU FIFO | bitbang | MPSSE | opto-isolated | FT1248 |
|---|---|---|---|---|---|---|---|---|
| ADBUS0 | TXD | D0 | D0 | D0 | D0 | TCK/SK | FSDI | CIOPIO0 |
| ADBUS1 | RXD | D1 | D1 | D1 | D1 | TDI/DO | FSCLK | CIOPIO1 |
| ADBUS2 | RTS# | D2 | D2 | D2 | D2 | TDO/DI | FSDO | CIOPIO2 |
| ADBUS3 | CTS# | D3 | D3 | D3 | D3 | TMS/CS | FSCTS | CIOPIO3 |
| ADBUS4 | DTR# | D4 | D4 | D4 | D4 | GPIOL0 | - | CIOPIO4 |
| ADBUS5 | DSR# | D5 | D5 | D5 | D5 | GPIOL1 | - | CIOPIO5 |
| ADBUS6 | DCD# | D6 | D6 | D6 | D6 | GPIOL2 | - | CIOPIO6 |
| ADBUS7 | RI# | D7 | D7 | D7 | D7 | GPIOL3 | - | CIOPIO7 |
| ACBUS0 | [CBUS0] | RXF# | RXF# | CS# | [CBUS0] | GPIOH0 | [CBUS0] | SCLK |
| ACBUS1 | [CBUS1] | TXE# | TXE# | A0 | WR# | GPIOH1 | [CBUS1] | CS# |
| ACBUS2 | [CBUS2] | RD# | RD# | RD# | RD# | GPIOH2 | [CBUS2] | CIPO |
| ACBUS3 | [CBUS3] | WR | WR | WR# | [CBUS3] | GPIOH3 | [CBUS3] | [CBUS3] |
| ACBUS4 | [CBUS4] | SIWU# | SIWU# | SIWU# | SIWU# | GPIOH4 | SIWU# | [CBUS4] |
| ACBUS5 | [CBUS5] | [CBUS5] | CLKOUT | [CBUS5] | [CBUS5] | GPIOH5 | [CBUS5] | [CBUS5] |
| ACBUS6 | [CBUS6] | [CBUS6] | OE# | [CBUS6] | [CBUS6] | GPIOH6 | [CBUS6] | [CBUS6] |
| ACBUS7 | PWRSAV# | PWRSAV# | PWRSAV# | PWRSAV# | PWRSAV# | GPIOH7 | PWRSAV# | PWRSAV# |
| ACBUS8 | [CBUS8] | [CBUS8] | [CBUS8] | [CBUS8] | [CBUS8] | [CBUS8] | [CBUS8] | [CBUS8] |
| ACBUS9 | [CBUS9] | [CBUS9] | [CBUS9] | [CBUS9] | [CBUS9] | [CBUS9] | [CBUS9] | [CBUS9] |
Note: the function of the pins labeled with square brackets is determined by the configuration in EEPROM when the relevant mode is active.
CBUS pins
The device has 10 CBUS pins. They can be configured through the EEPROM to do the following functions:
| EEPROM value | valid on pins | function |
|---|---|---|
0x0 | all | tristate |
0x1 | all but CBUS7 | UART TXLED# |
0x2 | all but CBUS7 | UART RXLED# |
0x3 | all but CBUS7 | UART TXRXLED# |
0x4 | all but CBUS7 | PWREN# |
0x5 | all but CBUS7 | SLEEP# |
0x6 | all but CBUS7 | const-0 output |
0x7 | CBUS[05689] | const-1 output |
0x8 | CBUS[5689] | I/O (for CBUS bitbang mode) |
0x9 | all but CBUS7 | UART TXDEN |
0xa | CBUS[05689] | CLK30 |
0xb | CBUS[05689] | CLK15 |
0xc | CBUS[05689] | CLK7.5 |
TODO: valid pin set far from certain.
Note that the EEPROM-configured CBUS pin function may be overriden by whatever mode is currently active.
EEPROM data format
The device will accept 128-word and 256-word EEPROMs. In case of 256-word EEPROMs, only first half is covered by the checksum. The other half can still be used to store user data.
Note that 64-word EEPROMs are not supported for unknown reasons. This may be related to the funny fixed word at address 0x45. Since this is in the same address range as the FT232R uses for factory-programmed data, it is somewhat likely that it is an accidental bit of leftover FT232R circuitry.
The EEPROM format is:
- word 0x00:
- bits 0-3: mode
- 0: UART
- 1: 245-style FIFO
- 2: CPUFIFO
- 4: opto-isolated
- 8: FT1248
- bit 4: enable bind to VCP driver
- 0: low
- bit 9: FT1248 bit order
- 0: MSB first
- 1: LSB first
- bit 10: FT1248 flow control enable
- TODO: the polarity of this bit is not clear, it might be a disable
- bit 15: enable PWRSAV# function on ACBUS7
- bits 0-3: mode
- word 0x01: idVendor (USB VID)
- word 0x02: idProduct (USB PID)
- word 0x03: bcdDevice (see table)
- word 0x04: USB config (goes straight to configuration descriptor)
- bits 0-7: bmAttributes
- bit 5: remote wakeup enabled
- bit 6: self-powered
- bit 7: always set to 1
- bits 8-15: bMaxPower (max power in units of 2mA)
- bits 0-7: bmAttributes
- word 0x05: device control
- bit 2: IO pulldown in suspend
- bit 3: serial number enabled
- word 0x06:
- bits 0-1: ADBUS drive strength
- 0: 4mA
- 1: 8mA
- 2: 12mA
- 3: 16mA
- bit 2: ADBUS slow slew rate
- bit 3: ADBUS schmitt trigger
- bits 4-5: ACBUS drive strength
- bit 6: ACBUS slow slew rate
- bit 7: ACBUS schmitt trigger
- bits 0-1: ADBUS drive strength
- word 0x07: manufacturer string pointer
- word 0x08: product description string pointer
- word 0x09: serial number string pointer
- word 0x0a: always 0
- word 0x0b: always 0
- word 0x0c:
- bits 0-3: CBUS0 function (see table above)
- bits 4-7: CBUS1 function
- bits 8-11: CBUS2 function
- bits 12-15: CBUS3 function
- word 0x0d:
- bits 0-3: CBUS4 function
- bits 4-7: CBUS5 function
- bits 8-11: CBUS6 function
- bits 12-15: CBUS7 function (lol has to be 0?)
- word 0x0e:
- bits 0-3: CBUS8 function
- bits 4-7: CBUS9 function
- word 0x0f: EEPROM type
- 0x56: 93LC56 (128-word)
- 0x66: 93LC66 (256-word)
- words 0x10..0x40: user area
- word 0x2e: set to 0x302 by default (concidentally or not, this corresponds to a header of an empty string descriptor)
- words 0x40..0x50: reserved area for unclear reason (stuff copied over from FT232R?)
- word 0x45: always set to 0x48
- words 0x50..0x7f: string / user area
- word 0x7f: checksum
String pointers are formatted as follows:
- bits 0-7: pointer to descriptor within EEPROM (counted in bytes); note that FTDI tools will only store string descriptors in the area starting at word 0x50, ensuring the high bit is always set
- bits 8-15: total length of descriptor in bytes
TODO: figure out wtf it is with the always-set high bit
The string descriptors are stored in ROM with the descriptor header included, as follows:
- word 0: header
- bits 0-7: total length of descriptor in bytes (includes header)
- bits 8-15: descriptor type (always 3 — string)
- words 1 and up: string in UTF-16
The checksum can be computed as follows:
#![allow(unused)] fn main() { fn checksum(eeprom: &[u16]) -> u16 { let mut res: u16 = 0xaaaa; for pos in 0..0x7f { // checksum word is NOT included — we're calculating it res ^= eeprom[pos]; res = res.rotate_left(1); } res } }