9. Introduction to the ESP32 

Install the drivers CP2102 for the USB bridge chip

In this lesson, I will show you how to install the driver for the CP210x family of USB to UART bridge chips. This chip is used on many ESP32 development boards to support USB communications.

You can watch the video, or if you are the “reading” type, you can read the text below.

What is the CP210x USB to UART bridge?

Before we start experimenting with the ESP32 dev kit, I wanted to mention one issue that a lot of people come across, and that has to do with the sheer number of different development kits for the ESP32, and the small differences between them.

One of those differences has to do with the chip that is used to implement the USB to UART bridge which enables the USB programmability of the board.

My dev kit contains this chip, so I have to install the driver for the operating system, and it isn’t normally installed by default. So this chip here on my board, which is just stock standard as I’ve said before, requires a driver that typically is not installed by default on Windows or Mac OS computers and therefore has to be installed manually.

The CP2102 USB-UART bridge chip on my ESP32 dev board

Without installing this particular driver, you will not be able to upload a sketch to the board.

How to identify your board’s bridge chip

My particular board uses the CP2102 bridge chip. There’s a good chance that your board uses the same one or at least a bridge from the same CP210x family as these are all popular low-cost USB to UART bridge chips.

To identify the USB to UART bridge chip on your board, first try to read the model number from the package of the chip itself. If at all possible, you will need a strong magnifying glass. In most of my boards, the UART bridge chips have no readable text on them, so I had to investigate further.

Go to esp32.net/usb-uart/, where you will find lists of bridge chips and the dev board on which they are used.

At esp32.net/usb-uart/, you will find information that will help you identify your board’s UART bridge chip.

How do you know if you need to install the bridge driver?

You might be one of the lucky ones. Your ESP32 dev kit may be using a USB bridge chip, which is already supported by your operating system.

To determine that, connect your development kit to your computer via USB.

Then, start up your Arduino IDE, and look under Tools, Port.

If your dev kit is connected to your computer, but its port is not listed under “Port,” you will need to install the USB-UART driver.

Can you see your dev kit port listed there? If not, you will need to install the third-party driver, so continue reading.

Install the USB-UART driver

Using the information available at esp32.net, determine the USB-UART bridge chip that is used in your ESP32 dev kit. I discovered that mine uses CP2102.

Once you have the model number, you need to find the driver that is appropriate for your operating system.

To do this, go to the Silicon Labs website. This link will take you directly to the driver download page. 

The source of the USB-UART bridge drivers for the CP210x chips is Silicon Labs.

This driver is available for a variety of operating systems. Download the one for your operating system and install it.

Most likely, you will need to restart your operating system. If you are not prompted to restart your operating system, be sure to restart the Arduino IDE.

Because of how many different drivers are out there and the differences between their operating systems and the exact installation procedure, I have not documented the driver installation process.

Verify the driver installation

After the driver installation is complete, you should test it.

Start, or restart, your Arduino IDE.

Connect your ESP32 development kit to your computer.

Click on the Tools menu, then click on Port.

Can you see your development kit listed?

My dev kit is listed in the Port menu; the driver installation was successful.

Click on the dev kit port to make it the target for the Arduino IDE.

Let’s try and upload the current sketch. It’s ok that it is empty, we just want to verify that the Upload process works, nothing else.

Click on the Upload button (the IDE will probably ask you to save the sketch first; click Ok to that).

The test upload was successful.

Look at the log messages that appear in the Arduino IDE. You will be able to see the progress of the upload process until it reaches 100%, and the hash of the data is verified. Your board will then reset so that the newly uploaded sketch can start its execution.

And with this, your setup is complete, and you can start your experimentation with your ESP32. In the next lesson, you will learn how to make an LED blink, which is the obligatory first sketch for virtually any electronics platform.


"Introduction to the ESP32" series

Ready for some serious learning?

Enrol to 

ESP32 for Busy People.

This is our comprehensive ESP32 course for Arduino Makers.

It's packed with high-quality video, mini-projects, and everything you need to learn Arduino from the ground up.

Just click on the big red button to learn more.

  • Thank you for describing the USB to UART driver installation process. A sketch will only upload if the two buttons on my ESP 32S board are pressed and released during the early stage of the upload. This is fiddly!

    Is there a way to get round this – perhaps by connecting two or more pins together?

    Thanks in advance

      • Peter

        Many thanks for your timely response.

        I am trying to persuade an ESP32S (with NODE MCU stamped on the underside) to accept simple sketches reliably. Compiling and uploading ‘Blink’ with:

        board – Node32S
        upload speed -115200 baud
        flash frequency – 80 MHz
        port – /dev/cu.SLAB-USBtoUART


        ‘esptool.py v2.6
        Serial port /dev/cu.SLAB_USBtoUART

        A fatal error occurred: Failed to connect to ESP32: Timed out waiting for packet header
        A fatal error occurred: Failed to connect to ESP32: Timed out waiting for packet header’

        Note that the ‘A fatal error…’ message appears twice as above.

        If I press and release the right-hand button (with micro USB connector at the bottom) as the sequence moves into the ‘upload phase’, there is success:

        Hard resetting via RTS pin…’

        I have achieved this level of success after much trial and error as I couldn’t find any reliable and properly formulated guidance in all the usual places.

        The question remains: is there a way to avoid the manual ‘reset’ that seems to be required?

        Looking at the very long Github discussion, I have the sensation of being drowned in a multitude of ‘possibilities of definite may be solutions’.

        If there is a full explanation of the problem and a well-informed workaround, I would be most interested to learn of it.

        Thank you in advance

        Rodney Buckland

        • Hi Rodney,

          The ESP32 is implemented in a variety of devkits, made by a variety of manufacturers.

          When the Arduino IDE tries to upload a new sketch, it will attempt to reset the board so that it boots into the bootloader. The bootloader gives a bit of time to the Arduino IDE to upload a sketch, and if there is no sketch to be uploaded, it will just boot whichever sketch is already in the flash memory.

          However, if the ESP32 devkit’s reset circuit is not working properly, the bootloader will not start as expected, and you will need to press the boot/reset button.

          The link I provided in my previous response contains a lot of information on this.

          If you want to “hack” your board to get the reset to work, you can attach a 100nF ceramic capacitor to the EN and GND pins. I have heard that this works from a lot of makers, as it help to improve the quality of reset signal.

          • Peter

            Many thanks for the clear and concise response.

            Your explanation of the underlying ‘handshake’ when the IDE tries to upload a new sketch makes me confident in trying your ‘add a capacitor’ modification.

            I’ll try it out soon and let you know the result.

            All the best


  • {"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}