Complete CH340 Circuit Diagram Guide for USB to Serial Conversion

For reliable USB-to-serial conversion in embedded projects, use the CH340G with these key components: a 12 MHz crystal paired with two 22 pF capacitors, a 0.1 µF decoupling capacitor near the IC’s VCC pin, and a 1 kΩ pull-up resistor on the DTR/RI pin if hardware flow control is needed. The schematic must include a USB Type-B connector with proper termination–VBUS (5V), D+, D-, and GND–and a 3.3V or 5V voltage regulator if the target microcontroller operates at a different logic level.
Connect the IC’s TXD and RXD pins directly to the UART interface of your microcontroller, but ensure voltage compatibility. For 3.3V systems, add a bi-directional logic level converter or use a voltage divider (two resistors, e.g., 1.5 kΩ and 3.3 kΩ) on the RXD line if the IC defaults to 5V logic. Omit external pull-up resistors on TXD/RXD unless the datasheet specifies otherwise–internal pull-ups are often sufficient.
Power stability is critical: place the decoupling capacitor within 2 mm of the IC’s power pin. If the design includes an LED indicator, use a 470 Ω resistor in series with a 3 mm red LED on the TXD or RXD line to monitor data activity. For prototypes, a male header on the UART lines simplifies debugging with a logic analyzer or serial terminal.
Avoid capacitive loads on D+ and D- lines–keep traces short and direct. If the PCB layout includes ground planes, ensure the USB shield is tied to ground only at one point near the connector to prevent ground loops. For troubleshooting, verify the IC’s driver enumerates in Device Manager (Windows) or lsusb (Linux) as a serial device before proceeding with firmware uploads.
USB-to-Serial Converter Layout: Hands-On Implementation
Use a 12MHz crystal oscillator with two 20pF loading capacitors for stable timing–this avoids data corruption at baud rates above 115200. Position the crystal within 5mm of the IC’s XIN/XOUT pins; longer traces introduce parasitic capacitance that skews frequency.
Route the TXD and RXD traces as differential pairs with 10mil width and 6mil spacing to minimize crosstalk. Add a 1kΩ pull-up resistor on TXD if the host device lacks built-in termination–this prevents floating lines during power-up transients.
Decoupling and Power Delivery
- Place a 0.1µF ceramic capacitor directly between VCC and GND, no farther than 2mm from the IC’s power pin.
- Follow with a 10µF electrolytic capacitor at the USB connector’s VBUS pin to suppress voltage sags during enumeration.
- Avoid ferrite beads on VCC; they introduce inductance that violates USB in-rush current limits.
Connect the DTR pin through a 0.1µF capacitor to the reset line of an attached microcontroller. This creates a clean edge-triggered pulse without steady-state current draw, unlike resistor-based solutions.
Error Prevention Checklist

- Verify USB connector shell is tied to system ground but isolated from chassis–floating shells cause sporadic disconnects.
- Test signal integrity by probing TXD/RXD with an oscilloscope at 921600 baud; rise times should stay under 20ns.
- Skip the 3.3V LDO if the board runs on 5V exclusively–unloaded linear regulators induce noise on VCC.
Add a 500mA PTC fuse in series with VBUS if powering external loads. USB ports typically deliver 500mA, yet many implementations ignore this and risk port damage during short circuits.
For self-powered designs, tie the IC’s internal regulator enable pin high via a 10kΩ resistor; grounding it mistakenly drains the attached battery through the V3 pin instead of VBUS.
Label every pin on the silkscreen with its function and voltage level. Ambiguous markings lead to accidental shorts–most debug time is wasted deciphering pinouts rather than fixing actual issues.
Locating Critical Elements in USB-Serial Interface Blueprints
Start by pinpointing the USB connector–typically a Type-A port with four leads: VBUS (5V), D-, D+, and GND. VBUS powers the converter, while D± differential pairs carry the serial data. Verify the presence of a decoupling capacitor (0.1µF ceramic) directly between VBUS and GND to suppress noise. Omission here introduces instability during high-speed transfers.
Trace the data lines to the converter IC–usually a 16-pin TSSOP package with labeled RXD/TXD and VCC/GND pads. The RXD/TXD pins connect to the target microcontroller’s UART interface via 220–470Ω resistors to limit current spikes. Near these resistors, a 12MHz crystal oscillator with two 22pF load capacitors ensures precise clocking; deviations here cause baud rate mismatches.
Power Regulation and Signal Conditioning
Check for a 3.3V LDO regulator (e.g., AMS1117) if the IC lacks internal regulation. Input capacitors (1–10µF) stabilize the regulator, while output capacitors (1–4.7µF tantalum) prevent voltage droop. Series ferrite beads on VBUS and critical traces (like TX/RX) filter RF interference–absent these, signal integrity degrades in noisy environments.
Identify the onboard LED indicators (if present): a power LED tied to VBUS via a 1kΩ resistor, and a TX/RX activity LED driven by the IC’s internal transistors. These LEDs attach to the signal lines through 470Ω resistors. Missing resistors or incorrect values risk damaging the IC’s output stages, leading to silent failures during operation.
Step-by-Step Wiring for a USB-to-TTL Serial Converter
Begin by connecting the VCC pin to a stable 5V power source–ensure your microcontroller or development board tolerates this voltage without requiring a regulator. If your target device operates at 3.3V, insert a low-dropout regulator (LDO) like the AMS1117-3.3 between the power supply and the converter’s VCC line to prevent damage. Verify the input voltage range of your device before proceeding.
Solder the TXD (transmit) pin of the adapter to the RXD (receive) pin of your microcontroller, and the RXD pin to the TXD pin of the microcontroller. Cross-wiring is mandatory; failure to do so will result in no data transmission. For noise-sensitive applications, add a 100nF ceramic capacitor between VCC and GND near the converter’s power pins to stabilize the supply.
| Adapter Pin | Microcontroller Pin | Notes |
|---|---|---|
| TXD | RXD | Mandatory cross-connection |
| RXD | TXD | Mandatory cross-connection |
| VCC | Power Input | 5V or regulated 3.3V |
| GND | Ground | Common reference required |
For devices with hardware flow control, connect RTS and CTS pins if supported. Most low-cost boards omit these, but if present, wire RTS to the microcontroller’s CTS and CTS to RTS. Skip this step for basic UART communication. Test continuity with a multimeter before powering the circuit–shorts between signal pins will corrupt data.
Ground (GND) must be shared between the adapter and the target device to establish a common reference. Omitting this connection will prevent communication entirely. If your setup includes multiple power domains, use an isolated converter or optocouplers to avoid ground loops, especially in industrial environments.
After wiring, install the appropriate drivers for your operating system. On Windows, download the official driver package from the manufacturer’s website–third-party sources may bundle malware. Linux systems typically recognize the adapter natively (check with lsusb). Open a serial terminal (e.g., PuTTY, screen) at 9600 baud (or your device’s specified rate) to verify data transmission. If no output appears, swap TX and RX pins before assuming a hardware fault.
Common Pinout Configurations for USB-to-Serial Converters in DIY Electronics
For most USB-to-TTL adapters based on this chipset, connect the VCC pin to either 3.3V or 5V, depending on your microcontroller’s logic level. A 3.3V supply is ideal for ESP8266, ESP32, or STM32, while 5V suits Arduino Uno and Mega. Always verify your board’s tolerance–some 3.3V devices may be damaged by 5V signals.
Ground (GND) must be shared between the converter and the target device. Floating grounds can cause erratic behavior or communication failures. For noisy environments, consider adding a 0.1µF ceramic capacitor between VCC and GND near the converter’s pins to stabilize power.
The TXD (transmit) pin of the converter connects to the RXD (receive) pin of the microcontroller. Conversely, RXD on the converter links to TXD on the device. Swapping these will result in no data transmission. For debugging, a logic analyzer or oscilloscope helps confirm signal integrity.
Hardware flow control pins (RTS and CTS) are optional for basic UART communication but necessary for high-speed data transfer. If unused, leave them unconnected unless your firmware explicitly requires them (e.g., some bootloaders or legacy protocols). Pull-up or pull-down resistors (10kΩ) can prevent floating states if needed.
- RTS → CTS: Connect converter’s RTS to microcontroller’s CTS.
- CTS → RTS: Connect converter’s CTS to microcontroller’s RTS.
For auto-reset functionality (common in Arduino-compatible boards), connect DTR or RTS to the reset pin of the microcontroller via a 0.1µF capacitor. This ensures the device resets before program uploads. Omitting this may require manual reset during flashing.
Power consumption varies by model: most variants draw ~50mA at 5V under load. For battery-operated projects, disable the converter when idle or use a low-dropout regulator to extend runtime. Some clones include a 3V3OUT pin–verify its current capability (typically
Baud rate settings depend on the target firmware. Common values include:
- 9600 (default for many sensors).
- 57600 (Arduino IDE default for some boards).
- 115200 (ESP8266/ESP32 default).
- 1.5Mbps (Raspberry Pi Pico).
Mismatched rates cause garbled data. Adjust using serial terminal software (e.g., PuTTY, PlatformIO, or Arduino Serial Monitor).
Package variants dictate pin spacing and form factor. SOP-16 (narrow) is hand-solder friendly, while QFN-28 (leadless) requires hot-air rework. Solder bridges between pins (especially VCC and adjacent lines) are a common failure point–inspect under magnification after assembly.