Skip to content

smabo-esp32

Set up smabo-esp32, which controls the actuators and reads the sensors, then print the required parts, wire them and check that everything works.

This page is the guide for the 'smabo-esp32' node on the roadmap below.

This guide assumes you have completed the Base Parts guide.

This page explains how to set up smabo-esp32.

smabo-esp32 is responsible for:

  • Controlling sensors and actuators connected to the ESP32

The following parts are required to implement this feature.

Part Example (Japanese shop) Notes
ESP32-DevKitC link Compatible alternatives OK
Breadboard (SAD101)
link Standard breadboards have 5 holes per row, but this one has 6 — required for the ESP32's width.
Jump wires link -
Battery box (AA ×4, battery-snap compatible) link Battery snap version is recommended for easier handling.
Battery snap (for battery box) link A version with connector pins is recommended — easier to insert into the breadboard and less likely to come loose.
Rechargeable AA batteries × 4 link Rechargeable batteries are recommended.
Battery charger link -
Servo motor driver PCA9685 link Compatible alternatives OK, but only needed if implementing Hand / Neck / Robot Arm features.
Mini breadboard link Choose one with an adhesive backing.
TB6612FNG dual motor driver link Compatible alternatives OK (though a version without pre-soldered pin headers will require soldering yourself).

Only needed if implementing Mobile Robot / Encoder Mobile Robot features.

Print the newly added parts on your 3D printer.

Because slicer software varies by printer model, only key points are noted here rather than step-by-step slicer instructions.

Print the following parts oriented as shown in the images.

  • smabo-hardware/stl/base/bread_board_stopper_bottom_l.stl


    bread_board_stopper_bottom_l


  • smabo-hardware/stl/base/bread_board_stopper_bottom_r.stl


    bread_board_stopper_bottom_r


  • smabo-hardware/stl/base/bread_board_stopper.stl


    bread_board_stopper


  • smabo-hardware/stl/base/mini_bread_board_stand.stl


    mini_bread_board_stand


  • smabo-hardware/stl/base/pca9685_stopper_l.stl


    pca9685_stopper_l


  • smabo-hardware/stl/base/pca9685_stopper_r_bottom.stl


    pca9685_stopper_r_bottom


  • smabo-hardware/stl/base/pca9685_stopper_r_top.stl


    pca9685_stopper_r_top


  • [Optional] smabo-hardware/stl/base/in_base_plate_wire_hole.stl


    in_base_plate_wire_hole

    • This part can be used as an internal divider inside smabo.


      Partition inside base plate

The SAD101 ships with a jumper wire inserted in the middle of the + rail.

In smabo, the + rail is split into two zones:

  • Right side of + rail → 6 V (battery box)
  • Left side of + rail → 3.3 V (ESP32 output)

The left side is 3.3 V so that no signal above 3.3 V reaches the ESP32's signal pins (they are 3.3 V pins).

Breadboard power rails


Therefore, remove the factory-installed jumper wire in the center of the + rail.

Remove jumper wire

Assemble the required parts as shown in the video below.

Note: the video also includes parts printed in previous steps.


For this step we are not yet driving any actuators, so only the battery wiring is needed as preparation for later steps.

In the tables below, "Point A" and "Point B" are directly connected in the circuit.

Point A Point B Notes
Battery box (+) Breadboard + rail (right side) From here on, the right side is the 6 V rail
Battery box (-) Breadboard - rail -
Point A Point B Notes
ESP32 3.3V Breadboard + rail (left side) From here on, the left side is the 3.3 V rail
ESP32 GND Breadboard - rail -

As noted above, the left and right sides of the + rail carry different voltages.

  • Mixing 6 V and 3.3 V on the same rail half will damage the ESP32 and actuators.

Please wire carefully.


The wiring diagram for the ESP32-DevKitC (with the defaults in config.esp32-classic.json) is shown below.

Wiring diagram

The completed robot looks like this.

<Image of the finished robot goes here>

Download and install Thonny for your OS from:

https://thonny.org/


Once installation is complete, launch Thonny.

Connect the ESP32 to your PC via USB, then click the bottom-right button and select 'MicroPython (ESP32)'.

Thonny — select interpreter


Select all Python files inside 'smabo-esp32', right-click and choose 'Upload to /' to flash them to the ESP32.

Thonny — upload source

Next, flash the config file.

From the configs directory, select the JSON file matching your ESP32 model and copy it as 'config.json'.

Copy config file


Fill in the following fields for your environment:

  • wifi/ssid — SSID of the network to connect to
  • wifi/password — password of that network

Config WiFi and IP settings


Once you have filled in the settings, flash config.json to the ESP32 the same way you flashed the source code.

Upload config to ESP32

Follow the startup procedure here.


Setup is complete once all programs start and communication is confirmed.

Next, follow the guide for: