

The Adafruit CP2102N Friend (Manufacturer Part ID: 5335) is a USB-to-UART bridge designed to facilitate seamless communication between a computer and microcontrollers or other serial devices. It features a built-in level shifter, making it compatible with both 3.3V and 5V logic levels. This compact and versatile module is ideal for debugging, programming, and interfacing with microcontrollers, sensors, and other serial devices.








The Adafruit CP2102N Friend is based on the Silicon Labs CP2102N USB-to-UART bridge chip. Below are its key technical details:
| Specification | Details |
|---|---|
| USB Interface | USB 2.0 Full-Speed (12 Mbps) |
| UART Baud Rate | Up to 3 Mbps |
| Voltage Compatibility | 3.3V and 5V (selectable via onboard jumper) |
| Logic Level Shifting | Built-in level shifter for 3.3V and 5V compatibility |
| Operating Temperature | -40°C to +85°C |
| Dimensions | 1.3" x 0.7" (33mm x 18mm) |
| Connector Type | Micro-USB for USB connection, 6-pin header for UART |
| Drivers | Compatible with Windows, macOS, and Linux (drivers available from Adafruit) |
The CP2102N Friend has a 6-pin header for UART communication. Below is the pinout:
| Pin | Name | Description |
|---|---|---|
| 1 | GND | Ground connection |
| 2 | VCC | Power output (3.3V or 5V, depending on jumper setting) |
| 3 | TXD | Transmit data (output from CP2102N to the connected device) |
| 4 | RXD | Receive data (input to CP2102N from the connected device) |
| 5 | RTS | Request to Send (optional, for hardware flow control) |
| 6 | CTS | Clear to Send (optional, for hardware flow control) |
Connect the CP2102N Friend to Your Computer:
Set the Voltage Level:
Connect to Your Device:
TXD to the RX pin of your device.RXD to the TX pin of your device.GND to the ground of your device.RTS and CTS if hardware flow control is required.Open a Serial Terminal:
The CP2102N Friend can be used to communicate with an Arduino UNO via UART. Below is an example Arduino sketch and corresponding Python script for communication:
void setup() {
Serial.begin(9600); // Initialize UART communication at 9600 baud
while (!Serial) {
// Wait for the serial port to connect
}
Serial.println("Hello from Arduino!");
}
void loop() {
if (Serial.available()) {
char received = Serial.read(); // Read incoming data
Serial.print("Received: ");
Serial.println(received); // Echo received data back
}
}
import serial
import time
ser = serial.Serial('COM3', 9600) # Replace 'COM3' with your actual COM port time.sleep(2) # Wait for the connection to stabilize
ser.write(b'Hello from PC!\n') # Send a message to the Arduino
while True: if ser.in_waiting > 0: response = ser.readline().decode('utf-8').strip() print(f"Arduino says: {response}") break
ser.close() # Close the serial connection
Device Not Recognized by Computer:
No Data Transmission:
Incorrect Voltage Level:
Serial Port Not Found:
Q: Can I use the CP2102N Friend with a 1.8V device?
A: No, the CP2102N Friend only supports 3.3V and 5V logic levels. For 1.8V devices, you will need an external level shifter.
Q: Is the CP2102N Friend compatible with macOS?
A: Yes, the CP2102N Friend is compatible with macOS. Ensure you install the appropriate drivers from the Adafruit website.
Q: Can I power my microcontroller using the VCC pin?
A: Yes, but only if your microcontroller's power requirements are within the current limits of the CP2102N Friend. Avoid powering high-current devices directly from the VCC pin.
Q: Does the CP2102N Friend support hardware flow control?
A: Yes, the CP2102N Friend supports hardware flow control via the RTS and CTS pins, but it is optional and not required for most applications.