Skip to the content
2 layers90 × 78.5 mmOnstep, the printed circuit board in 3D

Converting a manual Skywatcher EQ4 equatorial mount into a fully computerized GoTo mount using OnStepX firmware on an ESP32 microcontroller.

Size
90 × 78.5 mm
Copper layers
2
Thickness
1.6 mm
Parts
13
Nets
49
Pads
92
Tracks, vias
202, 0
Routed
Yes
KiCad
KiCad 9.0 (file 20241229)
Created
10 Sep 2026
Updated
14 Sep 2026

Overview

Onstep is an open-source printed circuit board by Cosmiccirkit01, from the Cosmiccirkit01/OnStepX-Eq4 repository on GitHub, published under the GPL-3.0 licence. It is a 2-layer board of 90 × 78.5 mm with 13 parts on 49 nets, routed with 202 tracks and 0 vias.

It is built around the EEUFC1H101. Its parts include 2 ICs and 2 connectors. It belongs with the ESP32 boards of this library.

Main components

1

README

README.md

EQ4 to GoTo Mount Conversion using OnStepX

Converting a manual Skywatcher EQ4 equatorial mount into a fully computerized GoTo mount using OnStepX firmware on an ESP32 microcontroller.

Stock EQ4 mount

Overview

OnStepX is an open-source, computerized GoTo controller for telescope mounts, built around stepper motors. It supports both Equatorial and Alt/Az mounts and runs on a range of microcontrollers (ESP32, STM32 Blue Pill/Black Pill, Fysetc boards, Teensy, etc.).

This project documents converting a stock EQ4 equatorial mount into a GoTo mount using an ESP32, custom-built stepper driver electronics, and a 3D-printed mount for the electronics. It covers everything from flashing the firmware to designing a custom PCB to machining brackets for motors that the mount was never designed to hold.

Note: This is a personal build log, not an official OnStepX guide. Some steps (such as pin assignments and gear ratios) are specific to this hardware combination and may need to be adapted for other mounts or driver boards.

Table of Contents

Bill of Materials

ComponentNotesLink
Digital MultimeterFor voltage/continuity checksLink
Breadboard (840 tie points)For initial circuit testingLink
ESP32 (ESP-WROOM-32)Main microcontrollerLink
NEMA17 Stepper Motor200 steps/rev, one per axisLink
DRV8825 Motor DriverOne per axis (see driver comparison)Link
Electrolytic Capacitor (100µF, 50V)Protects driver from voltage spikesLink
Jumper Cables (M2M)Breadboard wiringLink
Power Source: 12V, 2A (or 12V, 5A)2A is sufficient for testing; upgrade to 5A if needed2A · 5A
Active BuzzerStatus indicationLink
Step-Down Buck ConverterSteps 12V down to 5V for the driver FLT pinLink
4-Pin Aviation ConnectorsDetachable motor/power connectionsLink
L-shaped brackets (NEMA17)Mounting motors to the axesLink
GT2 Pulleys (60T & 12T)5:1 gear ratio60T · 12T
GT2 Timing BeltClosed-loop, 180mmLink

Step 1: Flashing OnStepX Firmware to the ESP32

  1. Download the OnStepX firmware from the official GitHub repository — use the main branch for the latest configuration. Latest version for this build: 10.28.

    OnStepX GitHub repository Credits: hjd1964

  2. Unzip the downloaded file (it extracts as OnStepX-main) and rename the folder to OnStepX.

  3. Open the folder — it should contain the following files:

    OnStepX folder contents

  4. Open the OnStepX.ino file. This launches Arduino IDE along with the Config.h and Extended.config.h files alongside it.

    Arduino IDE with OnStepX project open

    If you don't have Arduino IDE installed, download it from the official website.

  5. Install the ESP32 USB driver. The ESP32 dev board uses a CP210x USB-to-UART chip, which needs an external driver on most systems. Follow this driver installation guide if needed.

  6. Add the ESP32 board package to Arduino IDE:

    • Go to File

      Arduino IDE File menu

    • Go to Preferences

      Preferences menu

    • In the Preferences window, paste the following URL into Additional Boards Manager URLs, then click OK:

      text
      https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json

      Preferences window

  7. Select the board and port. Click the board/port dropdown and choose "Select other board and port".

    Select board and port

    Select your ESP32 variant and the COM port it's connected to (in this build: ESP32 Dev Module on COM7).

    Select port COM7

  8. Click Upload.

    Upload button

  9. Verify the flash succeeded: open the Serial Monitor, type #GVP:, and press Enter. A response of Onstep confirms the firmware flashed correctly.

Step 2: Connecting the ESP32 to the OnStep Controller App

  1. Once flashed, the ESP32 broadcasts its own Wi-Fi access point named OnStepX. Connect to it — the password is password.

  2. Install OnStep Controller2 from the Play Store and open it.

  3. When prompted "Would you like to create a new one now?", tap Yes.

    OnStep Controller2 app start screen

  4. On the connection screen, enter the IP address 192.168.0.1 and tap Accept.

    Entering the connection IP

  5. Wait a few seconds for the app to connect to the mount.

    Connected to the mount

  6. Tap the three-dot menu (top right) → Observing Sites, and enter your local Latitude, Longitude, and UTC Offset. Tap Upload, then return to the main menu.

    Observing Sites menu

  7. From the main menu, go to Initialize/Park. This is where most mount actions (park, unpark, home, goto) happen.

    Initialize/Park screen

    Important: Tap Set Date/Time before unparking. If this step is skipped, the mount won't accept any further commands.

Alternatively, the Triton GoTo App is worth trying — it includes a built-in planetarium view and has a more intuitive setup flow than the stock OnStep app.

Step 3: Choosing a Motor Driver and Setting Vref

A4988 vs. DRV8825

A NEMA17 stepper motor takes 200 full steps per revolution (1.8° per step). Microstepping divides each full step into smaller increments for finer resolution:

DriverMax microstepsDegrees per microstepSteps per revolution
A4988161.8° / 16 = 0.1125°3,200
DRV8825321.8° / 32 = 0.05625°6,400

Finer steps mean smoother, more precise tracking — important for accurately locating objects in the sky. This build started with an A4988 for initial testing, then upgraded to the DRV8825 for higher resolution (and for a second reason covered in Step 5).

Setting the reference voltage (Vref)

Vref limits the current the driver delivers to the motor, protecting both the driver and the motor from damage.

DRV8825 Vref potentiometer

Vref is set using the small potentiometer on the driver board (turn carefully with a small screwdriver — it's easy to damage).

Formula:

text
Vref = Imax / 2

For the NEMA17 motor used here, Imax = 1.2A per phase:

text
Vref = 1.2 / 2 = 0.6V

For a safety margin, this build used 10% less:

text
Vref = 0.5V

To measure and set it: power the driver with +5V (connect GND to GND, and FLT to +5V — the pinout may differ slightly by board, but this method works regardless). With the multimeter's red probe on the potentiometer and black probe on GND, adjust until the reading matches your target Vref.

If you run into trouble, this YouTube tutorial walks through the process on an A4988 — the same steps apply to the DRV8825. The main difference is that the DRV8825 has a FLT pin where the A4988 has VDD. See the DRV8825 connection notes for reference.

Datasheets: DRV8825 · A4988

Step 4: Breadboard Testing

  1. Identify motor coil pairs. On this motor, Red/Blue was Coil 1 and Green/Black was Coil 2 — verify yours with a multimeter or the tutorial linked above, since wire colors vary by motor.

  2. Find your ESP32 pinmap. Inside the OnStepX folder, go to:

    text
    OnStepX > src > pinmaps

    Pinmaps folder

    Select the file matching your MCU — this build used Pins.MaxESP3.h.

    ESP32 pinmap file open

    Scroll to the AXIS1 / AXIS2 definitions and wire accordingly. Optional buzzer/LED status pins can also be added here.

  3. Wire the power stage. Connect the 100µF electrolytic capacitor as shown in the wiring video above. VMOT connects to +12V, and FLT connects to +5V — ideally from a step-down buck converter rather than the ESP32's own 5V rail.

    Power connection diagram

    This build used a 12V, 2A supply.

  4. Test one axis at a time. Wire and test Axis 1 (RA) first. Power on, connect the ESP32 via USB, open the OnStep app, and go to Guide/Focus to manually jog the motor and confirm it moves correctly in both directions.

    Guide/Focus screen

    Once Axis 1 works, repeat the same wiring and test process for Axis 2 (Dec).

  5. Run both axes together on the breadboard before moving to a permanent circuit.

    Breadboard circuit with both axes wired

    If motors behave erratically, check that the capacitor is installed and that the power supply is adequate. And if problems still persist there may be a fault with wiring itself.

Step 5: Designing a Custom PCB

The first PCB used for this build had an internal short at the 12V input hole, which cascaded into shorts across nearby resistors and capacitors — making the board unusable.

Initial PCB with internal short

What is a short? A short circuit is an unintended low-resistance connection between two points (+12V and GND). This allows excessive current to flow, which can overheat and damage the circuit. A multimeter's continuity mode (which beeps when it detects a connection) is a fast way to check for shorts before powering anything on.

Since the original board was unrepairable, a custom PCB was designed from scratch in KiCad.

  1. Schematic — includes the ESP32, A4988/DRV8825, and buck converter. Footprints for the ESP32 and driver were available online; the buck converter's footprint was custom-made by measuring the physical board.

    KiCad schematic

  2. PCB layout — routed after the schematic was finalized.

    KiCad PCB layout

  3. 3D preview — used to sanity-check the layout before fabrication.

    KiCad 3D PCB view

  4. Generate Gerber files: File > Fabrication Outputs > Gerbers (.gbr). Run DRC first to catch errors, then Plot, then Save.

    Gerber export screen

  5. Fabrication and assembly:

    Fabricated PCB underside

    This is a single-sided PCB — the underside shows the routed copper tracks. Three connections that couldn't be routed on one layer were completed with single-strand jumper wire.

    Fabricated PCB, populated, topside

    Populated components: ESP32, DRV8825, step-down buck converter, active buzzer, and the 100µF electrolytic capacitor. Motor and power connectors are separate.

  6. Enclosure: a custom case was 3D-printed to house the finished board.

    3D-printed case, finished electronics

Motor driver connections to the NEMA17 use the motor's original connectors, soldered to 1-meter aviation connectors — long enough to avoid tension or interference around the mount.

Step 6: Firmware Configuration

This is the step that matches the firmware's electrical and mechanical parameters to your specific hardware — arguably as important as the wiring itself.

  1. Go to the OnStep Configuration Generator.

    Configuration generator homepage Credits: Khalid Baheyeldin

  2. Download the enhanced spreadsheet it links to.

    Configuration spreadsheet

    This spreadsheet calculates the correct settings for your driver and gearing. Key fields:

    FieldWhat it meansValue used in this build
    Stepper StepsFull steps per motor revolution (check your motor's datasheet)200 (NEMA17)
    AXIS1/2_DRIVER_MICROSTEPSMaximum microsteps your driver supports32 (DRV8825)
    GR2 RatioNumber of teeth on the mount's worm wheel144 (EQ4)
    GR1 RatioPulley gear ratio (large pulley teeth ÷ small pulley teeth)5 (60T / 12T)
  3. Checking if your gear ratio is sufficient:

    text
    Steps per degree = (Stepper Steps × Microsteps × GR1 × GR2) / 360

    With a DRV8825 (32 microsteps) and GR1 = 5:

    text
    (200 × 32 × 5 × 144) / 360 = 12,800 steps/degree

    With an A4988 (16 microsteps), a higher GR1 (≥10) is needed to hit a comparable resolution:

    text
    (200 × 16 × 10 × 144) / 360 = 12,800 steps/degree

    Higher steps-per-degree means finer, more precise tracking resolution. Choose your driver's microstep setting and GR1 ratio together based on the resolution you need.

  4. Fill in only the fields relevant to your hardware in the spreadsheet, leaving the rest at default, then return to the generator site and click Generate. This produces a Config.h file — copy it into your OnStepX folder (where the .ino file lives), replacing the existing Config.h when prompted.

Step 7: Setting Up the Web Server Plugin

OnStepX supports an optional web-based control interface via a plugin.

  1. Download the plugin from the OnStepX-Plugins repository.

    OnStepX-Plugins repository Credits: hjd1964

    This build uses tag v1.0a specifically — the main branch had errors at the time of writing.

  2. Extract the download and copy the website folder into:

    text
    OnStepX > src > plugins
  3. Open Plugins.config.h and add:

    cpp
    #define PLUGIN1 website
    #include "website/Website.h"
  4. In Config.h, just below the PINMAPS section under SERIAL PORT COMMAND CHANNELS, add:

    cpp
    #define SERIAL_RADIO WIFI_ACCESS_POINT
  5. In Extended.config.h, near the end of the file, add:

    cpp
    #define SERIAL_IP_MODE WIFI_ACCESS_POINT
    #define WEB_SERVER on
  6. Save both files and reflash the ESP32. Connect to its Wi-Fi network, then open a browser to 192.168.0.1 to reach the OnStepX web interface.

Web interface screens:

Web server — Controller tab

Web server — status page

Web server — align and goto controls

Opening the Network tab prompts for a password — again, it's password by default.

Web server — network password prompt

Step 8: Servicing the Mount and Fitting Motor Brackets

This build is based on a stock EQ4 mount.

Before adding any electronics, the mount was fully disassembled and inspected:

  • Checked all parts for wear.
  • Cleaned old grease buildup off the worm wheel and worm shaft.
  • Re-greased the gears for smooth movement.
  • Reassembled and adjusted the worm shaft tension screws until it turned with even, moderate resistance (neither too loose nor too tight).
  • Verified smooth manual movement before adding any motorized components.

Fitting motor brackets

Some mounts — like the Explore Scientific EXOS2 with a OnStep kit — have screw holes purpose-built for motor brackets:

EXOS2 mount with factory bracket mounting Credits: Phobos Astronomy

The EQ4 used in this build has no such mounting points, so brackets couldn't be bolted on directly. The workaround:

  1. A solid steel angle was custom-made at a local weld shop, sized to bear the motor's weight.
  2. The angle was ground to fit the Dec axis, then drilled to match the screw pattern (washers recommended if hole alignment isn't perfect).
  3. The modified steel angle was welded to the motor bracket. This was repeated for both the RA and Dec axes.

Belt and pulley fitment

Per the Configuration step, this build uses a 5:1 gear ratio: a 60-tooth GT2 pulley on the worm shaft and a 12-tooth GT2 pulley on the motor. See the OnStep Drive Design wiki for guidance on choosing pulleys and belts for your own ratio.

An open-loop belt was tried first (cut to length and joined with super glue) since the correct closed-loop length wasn't known in advance — this didn't hold up, but it confirmed the needed belt length. A 180mm closed-loop GT2 belt was ordered afterward.

Bracket and pulleys stacked together

The belt ended up 4mm too long for the pulley spacing; a 4mm spacer plate was added between the steel angle and the bracket to compensate.

The bracket holes were also enlarged into oblong slots, allowing the motor to slide and adjust belt tension:

Bracket with enlarged oblong holes

Final assembled Dec axis:

Finished Dec axis assembly

The same process was repeated for the RA axis.

Safety Notes

  • This build involves mains-adjacent DC power (12V @ up to 5A) and exposed PCB traces. Always double-check polarity and use a multimeter in continuity mode before powering on a new circuit for the first time.
  • Set Vref before connecting a motor — an incorrectly set or unset Vref can damage the driver or motor.
  • Never hot-plug motor connectors while the driver is powered.
  • Handle the worm shaft and gear tension carefully — over-tightening can strip the wheel or bind the axis motor.

Credits

Additional Photos & Videos

More photos and testing videos (breadboard testing, PCB assembly, and mount tracking tests) are available here:

📁 **Google Drive — Photos & Videos

Status / Next Steps

Both axes are wired, mechanically mounted, and configured. Remaining work / not yet documented here:

  • End-to-end GoTo accuracy testing (polar alignment + star-based accuracy check).
  • Final photos and video of the fully assembled mount in operation.

Hardware used in this build: EQ4 mount · ESP32 · DRV8825 · NEMA17 steppers · Custom KiCad PCB · OnStepX 10.24

Note

This project uses v10.24 of OnStepX. All the changes mentioned above are present in files provided.

Parts

13
QtyValueFootprintReferences
4MountingHoleMountingHole:MountingHole_2.7mmH1, H2, H3, H4
2EEUFC1H101EEUFC1H101:CAPPRD500W60D1000H1250100UF,50V1, 100UF,50V2
2Pololu_Breakout_A4988Module:Pololu_Breakout-16_15.2x20.3mmAXIS1, AXIS2
2Screw_Terminal_01x04TerminalBlock:TerminalBlock_Xinya_XY308-2.54-4P_1x04_P2.54mm_HorizontalJ1, J2
1DEVKIT_V1_ESP32-WROOM-32DEVKIT_V1_ESP32-WROOM-32:MODULE_DEVKIT_V1_ESP32-WROOM-32U1
1MP2307 BUCKMP2307:MP2307 Buck ConverterU2
1Screw_Terminal_01x02TerminalBlock:TerminalBlock_Xinya_XY308-2.54-2P_1x02_P2.54mm_HorizontalINPUT1

Similar boards

  • 2 layers40 × 20 mmUsb uart, the printed circuit board in 3D

    Usb uart

    earthtojake/text-to-cad

    Design physical products with AI

    13 parts26kMIT
  • 2 layers35 × 29 mmMagSpoofTC, the printed circuit board in 3D

    MagSpoofTC

    samyk/magspoof

    A portable device that can spoof/emulate any magnetic stripe, credit card or hotel card "wirelessly", even on standard magstripe (non-NFC/RFID) readers.

    13 parts4.2k
  • 2 layers20.6 × 23.6 mmAO-03 signal amplifier, the printed circuit board in 3D

    AO-03 signal amplifier

    fossasia/pslab-scripts

    Pocket Science Lab - Scripts for Sensor Experiments

    13 parts1.6kApache-2.0
  • 2 layers47 × 35.6 mmMX7-C-35PL C11, the printed circuit board in 3D

    MX7-C-35PL C11

    rusefi/rusefi

    rusefi - GPL internal combustion engine control unit

    13 parts1.2k
  • 2 layers95 × 95 mmCube batteryboard, the printed circuit board in 3D

    Cube batteryboard

    willem-pennings/balancing-cube

    A cube that balances itself in a corner or edge using reaction wheels

    13 parts1.1kGPL-3.0
  • 2 layers15.2 × 20.3 mmPt100stick, the printed circuit board in 3D

    Pt100stick

    VoronDesign/Voron-Hardware

    Cool Hardware designed by the Voron Design group

    13 parts1.1kGPL-3.0
  • 2 layers53.9 × 23.2 mmBuffer, the printed circuit board in 3D

    Buffer

    hoglet67/RGBtoHDMI

    Bare-metal Raspberry Pi project that provides pixel-perfect sampling of Retro Computer RGB/YUV video and conversion to HDMI

    13 parts1kGPL-3.0

Questions

How big is the Onstep PCB?

It measures 90 × 78.5 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Onstep use?

13 parts, built around the EEUFC1H101. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the Onstep KiCad files?

From the Cosmiccirkit01/OnStepX-Eq4 repository on GitHub, at the commit this page was made from: the board is KICAD/Layout/onstep.kicad_pcb and its schematic KICAD/Schematic/onstep.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Onstep design in my own project?

Its repository publishes it under the GPL-3.0 licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).