WiFi 'tethered' Arduino robot

From Richmond Maker Labs
Revision as of 10:37, 22 December 2022 by IanM (talk | contribs) (Connecting to an Arduino over WiFi as-if it was plugged in via USB.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Back in 2021 I was working on an Arduino based robot. These are my notes on how to 'tether' the robot via an existing WiFi network to permit Arduino program upload, and serial terminal monitoring and control, from a Windows PC as-if I had a USB lead plugged into the Arduino.

Materials required:

  • Arduino, on robot - the Arduino must use the standard serial bootloader not the USB bootloader used on Leonardo etc.
  • ESP8266 module - e.g. Wemos D1 Mini, or ESP01
  • Quad MOSFET Level Converter, e.g. https://www.sparkfun.com/products/12009
  • Miniature latching DPDT switch
  • DuPont jumper wires, to suit headers on robot
  • Strip of 0.1" pitch header pins
  • Small bore heatshrink sleeving

The level converter is needed if the Arduino is 5V. The DPDT switch is needed if you want to retain the capability to program the Arduino via USB The header pins are needed if you want to make the level converter or ESP8266 module pluggable.


If nothing is connected to an Arduino's USB port, you can connect a serial interface to its RX and TX pins and program it over this interface. /RESET needs to be pulsed low immediately before programming to enter the bootloader.


The hookup is: 5V Arduino <=> Level Converter <=> Switch <=> ESP8266 module

Cut two jumper wires in the middle and solder all the cut ends to the switch so it can disconnect both wires. Optionally solder a link across both NO contacts so that when the switch is open, the ESP8266 RX and TX pins are looped together.

Make Y (or daisychain) wires for power and ground, e.g. by cutting two DuPont jumpers and splicing three cut ends together, insulating it with heatshink. Make one red, and one black Y wire.

Populate the level converter and ESP8266 module with header pins.

Connect everything together:

Wiring - one wire per row
Arduino pin Level Converter pin Switch pin ESP8266 pin Notes
5V HV - 5V Y wire
3.3V LV
Gnd Gnd - Gnd Y wire
RX (0) HV0 Data to Arduino
LV0 NC0 "
TX (1) HV1 Data from Arduino
LV1 NC1 "
NO0-NO1 Esp-Link Loopback
Reset HV3 Triggers bootloader
LV3 - GPIO* "
  • Which ESP8266 GPIO to use for Reset depends on your module. It cant be RX, TX or used for the ESP8266 SPI Flash program memory.