Skip to content

Repository files navigation

winder

Docs | YouTube | TikTok | Instagram | X

BLDC motor winding machine

Winding the wire for a BLDC motor is a time-consuming and labor-intensive process. This winding machine automates this tedious tasks.

Motors

This machine uses four motors to perform the winding operation: Motor name

  • M0: Move M1 unit (closed loop control)
  • M1: Rotate the stator (closed loop control)
  • M2: Wind the wire (closed loop control)
  • M3: Adjust the wire tension (closed loop torque control using voltage)

code: Aotenjo One

Master Controller

All motors are controlled by Aotenjo Master, a master controller board based on the STM32G431CBU6 microcontroller. It communicates with the host computer via USB and controls the motors via CAN bus.

Master Diagram

code: Aotenjo Master

Installation

You can set up the environment with either conda or uv. Both install the same pinned dependency versions.

Option A — conda

Prerequisite: Miniconda.

  1. Clone the Winder repository and enter it:
    git clone https://github.com/aotenjo-xyz/winder.git
    cd winder
  2. Create a new conda environment and install the required dependencies:
    conda env create -f environment.yml
  3. Activate the conda environment:
    conda activate winding
    export PYTHONPATH=$PWD
  4. Create a settings.yml file based on settings-example.yml and update the settings as needed:
    cp settings-example.yml settings.yml

Option B — uv

Prerequisite: install uv.

  1. Clone the Winder repository and enter it:
    git clone https://github.com/aotenjo-xyz/winder.git
    cd winder
  2. Create the virtual environment and install all dependencies (uv installs Python 3.12 automatically if needed):
    uv sync
  3. Create a settings.yml file based on settings-example.yml and update the settings as needed:
    cp settings-example.yml settings.yml

That's it — no need to set PYTHONPATH. Run any command inside the environment with uv run, e.g. uv run python scripts/main.py -s or uv run pytest.

Hardware

  • M0: BE4108 75T gimbal motor (built with this machine)
  • M1: BE4108 75T gimbal motor (built with this machine)
  • M2: BE4108 75T gimbal motor (built with this machine)
  • M3: BE4108 60T gimbal motor (built with this machine)

Result

BE4108 75T gimbal motor

Result

This motor was initially a drone motor.

Drone motor vs DIY gimbal motor

Simulation with Godot

Quickstart

Simulation with Godot

See simulation/README.md for details.

About

BLDC motor winding machine

Topics

Resources

Stars

200 stars

Watchers

15 watching

Forks

Releases

Packages

Contributors

Languages