Nanjing QinHeng Electronics CH340



These are cheap USB UARTs available is various configurations.

These devices are becoming popular, so much so that fake ch340 chips exist. The fakes have the ch340 USB identity and can be found in RS485 adatpers (see below).

As well as being found on general purpose serial interfaces they are often found on Arduino clones and ESP8266 bridges.


    CH340G              CH340T              CH340R
    +------+            +------+            +------+
GND 1     16 VCC   CKO  1     20 NOS#  NC   1     20 NOS#
TXD 2     15 R232  ACT# 2     19 VCC   ACT# 2     19 VCC
RXD 3     14 RTS#  TXD  3     18 R232  TXD  3     18 R232
V3  4     13 DTR#  RXD  4     17 NC    RXD  4     17 IR#
VD+ 5     12 DCD#  V3   5     16 RTS#  V3   5     16 RTS#
VD- 6     11 RI#   VD+  6     15 DTR#  VD+  6     15 DTR#
XI  7     10 DSR#  VD-  7     14 DCD#  VD-  7     14 DCD#
XO  8      9 CTS#  GND  8     13 RI#   GND  8     13 RI#
    +------+       XI   9     12 DSR#  XI   9     12 DSR#
                   XO   10    11 CTS#  XO   10    11 CTS#
                        +------+            +------+


ESP8266 bridge

ID 1a86:7523 QinHeng Electronics HL-340 USB-Serial adapter
udev /dev/ttyCH340
    RUN+="/bin/ln -sf %k /dev/ttyCH340"
udev by-id

Pickle Microchip PIC ICSP


Pickle ICSP supports RS232 for programming boards such as the Velleman K8048 kit.

Velleman K8048 Configuration

The K8048 kit has an RS232 interface which is used in a bit-bang mode of operation. USB UARTS are not ideal for this purpose but can operate, albeit slowly.

The .pickle configuration for the CH340 is this.


The SLEEP value affects both the speed of programming and the reliability of operation.



Top: ch340g Bottom: fake

Cheap RS485 adapters exist using both this chip and a fake version of this chip.

The real chip is a CH340G with 16 pins and the fake chip has 24 pins in an unmarked package. The top 20 pins of the fake match those of a genuine CH340R or CH340T device which is only available in 20-pin packages.

The RS485 I/O stage varies slightly between the real and fake adapters and is constructed like this for the CH340G device.


This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.More information about cookies