Andrey Ovcharov

Professional Software Engineer and hobbyist Hardware enthusiast

Andrey Ovcharov

CH340G programmer for ESP8266/ESP32

Buy the CH340G programmer for ESP8266/ESP32 online

I have updated the device with the USB Type C connector and more popular pinout for the header. You can read about it following the link Updated version of CH340G based ESP programmer.

Slightly tired of big and long-running projects both at work and at home I decided to make a small spin-off project to help me working with ESP8266/ESP32 devices. Is there any reason to make it when there are a lot of cheap USB-Serial converters in the market? I don’t think so. My only reason to make it is to have cool addition allowing ESP8266s to be programmed automatically without “flash”/”reset” buttons but simple circuit with two transistors. Most of the USB to Serial converters simply do not have this circuitry on board. And, of course, I wanted to have some fun.

The device is built around cheap and popular CH340G chip. The only addition to standard schematics from the datasheet is two BC847 transistors for automatic programming.

Schematic of the CH340G programmer

Components are soldered on a dual-layer PCB. I did not need to make it as small as possible, so the components are distributed very sparsely. And since I already have a bunch of regular 12MHz quartz oscillators I used one of them instead of buying SMD one.

PCB layout of the CH340G programmer

The PCBs were ordered at JLCPCB and arrived in about two weeks after ordering. The minimal batch of 5 boards is more than enough for this project. Quality, as always, is very good.

PCB for the programmer
PCB for the programmer

With this project for the first time, I have tried a hot air gun. Technology is simply - put some mechanical solder paste on the board, place components and heat them with the hot air. The flux and solder will melt and put everything in place. It worked quite well for me although I’ve put too much of soldering paste and had to remove excess with the iron. Next time I am going to order special stencil together with the board for easy application.

The completed device started to work from the first attempt without any problems. Both ESP8266 and ESP32 boards were successfully programmed with the speed of 921600 baud.

Complete CH340G programmer
Complete CH340G programmer

The projects files are available in my GitHub repo