Comments on: Raspberry Pi Pico: Control a Stepper Motor with MicroPython https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/ Learn ESP8266, ESP32, Arduino, and Raspberry Pi Mon, 09 Feb 2026 11:52:05 +0000 hourly 1 https://wordpress.org/?v=6.8.5 By: Sara Santos https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-1160627 Mon, 09 Feb 2026 11:52:05 +0000 https://randomnerdtutorials.com/?p=146332#comment-1160627 In reply to Ray Spinhirne.

Hi.
I’m sorry, but I’m not sure I understood your previous questions.
Can you reformulate and be a little more specific?
Regards,
Sara

]]>
By: Ray Spinhirne https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-1159385 Sat, 07 Feb 2026 00:04:17 +0000 https://randomnerdtutorials.com/?p=146332#comment-1159385 In reply to Ray Spinhirne.

Are you going to answer my questions about stepper.py

]]>
By: Geoff https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-1086529 Tue, 26 Aug 2025 11:25:08 +0000 https://randomnerdtutorials.com/?p=146332#comment-1086529 In reply to Ronald.

Hi Ronald,
I too want to be able to control the spped of a 28byj48 accurately, I found this:
youtube.com/watch?v=qLuuBtVHIgU
This allows you to control the speed with a potentiometer using an ADC in Micropython. I haven’t tried it yet, I’m hoping for a more elegant way to control multiple stepper motors not just the 28byj48.
Let me know if it works or if you find another way to do it.
Regards,
Geoff.

]]>
By: Ronald https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-1086185 Mon, 25 Aug 2025 20:39:16 +0000 https://randomnerdtutorials.com/?p=146332#comment-1086185 Hi Sara & Rui,
Thnx for this very clear explanation. I was looking for a way to program this stepper motor in MicroPython instead of the Arduino c.
But now: is there a way to control the speed of the motor?
Thanks again and keep up this excellent work

]]>
By: Gerhard https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-1079014 Wed, 06 Aug 2025 08:33:58 +0000 https://randomnerdtutorials.com/?p=146332#comment-1079014 Hello,
thank you for this work!
Why shouldn’t I exceed 360°? I thought a stepper motor ist starting at 0/1 again.

]]>
By: Sara Santos https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-1062289 Sun, 29 Jun 2025 10:42:55 +0000 https://randomnerdtutorials.com/?p=146332#comment-1062289 In reply to bob.

Hi.
Make sure you’ve installed micropython on your board and that the computer is connected to the board.
Also, make sure you have the correct board and interpreter selected at the bottom right corner.~

The machine module is automatically isntalled when you install the Micropython firmware on your boards.

Regards,
Sara

]]>
By: bob https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-1061968 Sat, 28 Jun 2025 15:51:43 +0000 https://randomnerdtutorials.com/?p=146332#comment-1061968 Not working! Where did you get the machine library from?

]]>
By: Ray Spinhirne https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-1021740 Tue, 01 Apr 2025 04:41:04 +0000 https://randomnerdtutorials.com/?p=146332#comment-1021740 Thanks for this code.

I have a question:

In the _step function in stepper.py the current position and state are update after the
gpio pins are set. This seems to me to leave the position and state how they will be after
the next step not after this step. Am I missing something here.

Also have you tested the step_degrees function. I get a zero not defined.

Thanks

]]>
By: Bob https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-993277 Sat, 21 Dec 2024 15:08:30 +0000 https://randomnerdtutorials.com/?p=146332#comment-993277 Just what I was looking for to use in a rotary turn table I’m making for making videos.

Thanks!

Bob

]]>
By: Per https://randomnerdtutorials.com/raspberry-pi-pico-stepper-motor-micropython/#comment-993046 Fri, 20 Dec 2024 14:49:46 +0000 https://randomnerdtutorials.com/?p=146332#comment-993046 Thanks.

]]>