StepperMotorControl_PICO

February 18, 2025 ยท View on GitHub

Website Donate

Stepper_Motor_Control_PICO

Overview

  • Title: Stepper Motor Control PICO
  • Description:

A Raspberry pi Pico SDK C++ library to drive stepper motors controllers. The components supported are some of the most widely used by the electronic hobbyist community. This is a partial port of my 'rpiMotorLib' a python raspberry pi library. Not all components supported yet.

  • URL to 'rpiMotorLib': URL LINK

  • Toolchain

    1. Raspberry pi PICO RP2040
    2. SDK C++, compiler G++ for arm-none-eabi
    3. CMAKE , VScode

Supported Components

Note: the help file links below are to the aforementioned raspberry pi python port. The theory of operation, hardware setup and much of the software API is the same. There is an example file for each motor in examples folder. To build the one you want, edit the CMakeLists.txt file add_executable(${PROJECT_NAME} section, comment in one example file path and one only. Code is commented for Doxygen API generation. Code for an optional push button to ground is included in the example files, this push button can be used as a stop on motor movement.

Stepper motors

Motor testedMotor controllerexample fileHelp File URL
Unipolar 28BYJ-48ULN2003 driver moduleBYJ_48Link
Bipolar NemaTB6612FNG Dual Driver CarrierTB6612FNG_NEMALink
Bipolar NemaL298N H-Bridge controller moduleL298N_NEMALink
Bipolar NemaMX1508 Motor controller moduleMX1508_NEMALink
Bipolar NemaA4988 Motor controller moduleA4988_NEMALink
Bipolar NemaDRV8825 Motor controller moduleDRV8825_NEMALink
Bipolar NemaLV8729Motor controller moduleLV8729_NEMALink
Bipolar NemaA3967 Easy DriverA3967_NEMALink

Output

If verbose output is enabled. Data reports and any errors are sent to console at 38400 baud via USB.

 op