⚙️

Servo

Tap where you want it; the timing is yours to tune

Page 45 of 45 MCP / API open OTA updates

Page 45 drives a servo from the GPIO 16 LEDC hardware channel: the current angle in large digits with the live pulse width in microseconds and duty cycle, a slider that rescales with the configured travel, then the parameter panel and ±5 / ±1 trim buttons.

Configuration is live rather than hard-coded: pulse limits (500–2500 us by default), travel (up to 360°), analog or digital servo, continuous-rotation mode and PWM frequency are all adjustable. Six presets are built in, values persist to NVS across reboots, and can also be saved to `/servo.cfg` on the SD card to carry between devices.

Screen

On-screen interface

A recreation of this page on the 2.41-inch AMOLED display (600 × 450). Actual interaction and layout follow the latest firmware.

Servo GPIO16 · 50 Hz
Angle120° · 1833 us · 9.2 % duty
0° — 120° — 180°
Type / modedigital servo · analog drive
Frequency50 Hz · 16-bit
Step11.1 us/°
Storagesaved to NVS · persists
Tap to jump · dragging will not page
Screen · Page 45
May differ from the actual interface; the screen of the real device is the final reference.
Highlights

Key capabilities

🎚

Tap to jump

Tap anywhere on the track to position, or drag the handle.

🧮

Live maths

Pulse width, duty and step size in us/degree update as you edit.

💾

Saved config

NVS keeps it across reboots, or store it on the SD card.

🔁

Continuous mode

In continuous rotation the slider becomes speed and direction.

Specifications

Technical specs

Signal pinGPIO 16 (LEDC channel 1, 16-bit)
PWM50 Hz by default, 20 ms period, configurable
Pulse500–2500 us by default, mapped to 0–180°
ModesAnalog / digital / continuous rotation
StorageNVS (persists) + SD card `/servo.cfg`
Use Cases

Typical scenarios

Pan mount

Pair with the laser ranger for a sweeping distance head.

Valve or flap

Acts as a small winch in continuous-rotation mode.

Commands

Related commands

page 45  Open servo control
servo <angle>  Move to a given angle
servo cfg  Show or change pulse range, travel, frequency and mode
servo save | load  Persist to NVS / read back from NVS
servo sd | sdload  Save to `/servo.cfg` on SD / load it back

Read the full API & command reference →

⚠ Boundaries & notes
  • ★ The servo needs its own 5V supply sharing only ground; running it from 3V3 browns out the board and reboots it.
  • Set the pulse range for each new servo model, or it may drive into a mechanical stop and strip its gears.
  • Dragging the slider owns the horizontal gesture, so swiping on this page will not change page — by design.

Other feature pages