Skip to main content

CF12-6_Servo Web Interface Control

1. ESP32 Download Tool​

Generally, you need to install the Arduino IDE and related dependency libraries first, then compile and upload the program, in order to control CF series servos. Using the ESP32 download tool provided here, you can flash the matching servo control program to the driver board without installing the Arduino IDE or related dependency libraries.

Click to download the ESP32 Download Tool Dedicated to CF Series Servos. After extracting it, double-click to open "flash_download_tool_3.9.5.exe". Two windows will appear: one is a black terminal window showing the tool's status, and the other is the main UI where you perform the operations.

In the "DOWNLOAD TOOL MODE" interface, select ChipType as ESP32 and WorkMode as Factory (this uses binary files with auto‑adapted relative paths; no manual input is required). Click OK to confirm.

Download tool usage step 1

Keep the LockSettings checkbox selected (this supports flashing up to 8 boards simultaneously). Connect the driver board to your computer via USB, click the COM option, and select the newly detected COM port. BAUD sets the flashing speed, up to 921600 (higher speed means faster flashing).

Download tool usage step 2

After confirming the settings, click START to begin flashing. When the interface shows FINISH, the flashing is successful.

Download tool usage step 3

Download tool usage step 4

After flashing is complete, disconnect the USB connection between the driver board and the computer, connect the servo, and supply power to the driver board to begin controlling the CF series servo.

2. Web Usage Tutorial​

The following tutorial uses the Bus Servo Driver Board as an example to explain how to control servos on the Web. If you need to use bus servos in a project, you can refer to the example programs and the Bus Servo Driver Circuit Schematic for secondary development.

2.1 Connecting Servos and Power​

Taking the CF12-6 Servo as an example, after connecting the servo to the driver board, you need to supply 4V - 8.4V to it through the 5.5 × 2.1 mm DC interface on the servo driver board (7.4 V power supply is recommended). This power interface directly supplies power to the servo.

warning

The Servo Driver with ESP32 has a maximum current rating of 5 A. If you are using a large number of servos, power them in separate groups to prevent the board from being damaged by excessive current.

2.2 Connecting to the Board's Wi‑Fi Hotspot​

  1. After power‑up, the board automatically creates a Wi‑Fi hotspot with the default SSID ESP32_DEV and password 12345678.
  2. Use your phone or computer to connect to this Wi‑Fi. Since this network does not provide Internet access, some devices may automatically switch to other saved Wi‑Fi networks. If this happens, reconnect to the ESP32_DEV network; after a successful reconnection, the connection should remain stable.
  3. It is recommended to use Google Chrome. Enter 192.168.4.1 in the address bar to access the Web control interface.

Servo Driver with ESP32-Web control interface

2.3 Servo Scanning​

  1. The driver board automatically scans for servos when powered on. If the servo is connected after the driver board is powered on, click Start Searching on the interface to rescan.
  2. Our servos have a default ID of 1. When connecting multiple servos to the board, you must change their IDs to avoid conflicts; otherwise, they may not be detected. When changing a servo ID, it is recommended to connect only the single servo that needs its ID changed.
  3. The driver board scans servos with IDs 0 - 20 by default at startup. If you use a servo with an ID greater than 20, you need to modify the MAX_ID value in the source code ServoDriverCF.ino file (the maximum valid value is 253), and reflash the program for it to take effect.
  4. After scanning, the interface displays all currently connected servo IDs, allowing you to perform subsequent operations.

2.4 Core Function Operations​

The buttons on the web interface and their functions are described below. All operations apply to the currently selected Active ID (the currently selected servo ID):

CategoryButton NameDescription
ID ManagementID Select+/-Switch the currently selected Active ID
ID to Set+/-Adjust the new servo ID value to be assigned
Set New IDChange the servo with the current Active ID to the new ID set by ID to Set. The change persists after power‑off.
Position ControlMiddleMove the servo to the middle position (position range 0‑4095; middle is 2047)
Set Middle PositionSet the servo's current position as the new middle position (2047), customizing the servo's zero reference
Motion ControlPosition+Rotate the servo clockwise. In servo mode, it stops once it reaches position 4095
Position-Rotate the servo counterclockwise. In servo mode, it stops once it reaches position 0
Current+/-Set the servo current, in units of 6.5mA; the rated current of this servo is 900mA
Speed+/-Set the servo rotation speed. This servo reaches a maximum of about 7718 steps/second (50 steps/second ≈ 0.732RPM)
StopStop servo motion (useful when the servo does not stop on its own after secondary development)
Torque ControlReleaseDisable torque lock; the servo can be rotated manually
TorqueEnable torque lock; the servo will hold its position with force
Operating Mode SwitchingSet Servo ModeSwitch to servo mode, supporting 360° absolute angle control. The mode persists after power‑off
Set Motor ModeSwitch to motor mode, supporting continuous rotation with relative angle control within 30000 steps/±7 turns. The rotation count does not persist after power‑off, but the mode does
Serial DebuggingStart Serial ForwardingSerial forwarding mode: control the servo directly via the Type‑C interface and receive feedback for debugging. The serial baud rate is 115200
ESP‑NOW Communication ModeNormalNormal mode; does not send or receive ESP‑NOW messages
LeaderMaster mode: sends the Active ID servo's ID, position, and speed information to followers via ESP‑NOW. See ESP‑NOW Communication Configuration
FollowerFollower mode: receives ESP‑NOW commands from the leader and follows the leader's servo movements
Lighting ControlRainbowON/OFFEnable/disable the RGB LED rainbow effect