Welcome to Laser Pointer Forums - discuss green laser pointers, blue laser pointers, and all types of lasers



Source code for stepper motors

boraicho

New member
Joined
Oct 13, 2013
Messages
28
Points
3
Hi friends.
I would like build laser with stepper motor. I have everything except program for processor. I know to programming, but i don't know how i have to write program for stepper for different patterns. I use PIC18F46K22 this is not important, i know to modify whatever source code for my needs.
So i please , can someone share some codes for steppers with me? Arduino also, i can't find anything. i use unipolar stepper motors with 5 wires. Thanks
 



hakzaw1

Well-known member
Joined
Apr 2, 2009
Messages
9,853
Points
113
wow
that brings back memories... Steppers are not a cool As I had hoped. For a short cut- seek and buy a very cheap Chnia PJ. (used <$70) they have two steppers which accounts for the terrible quality of the output.
Steppers can be used for beam turners. Sending beams to mirror balls and bounce mirrors etc.
I had a BUNCH saved before I learned of the stepper's limitations .. I recycle them now. I even bought a stepper controller kit== never put it together.
While alike IMHO they are not the same as Galvo Scanners-(from $80 to $800)

Your Coding skillz will be very helpful to you. But your 'talents' may be wasted on steppers...

you will find these interesting.. 'Laser Beam Projector Rail Style'
I wanted to make the poor man's version with of course all steppers...
I have seen a bunch of these 'Rails' at SELEM events.

Being used to PJs inside enclosures and the dangers if not.... these 'open' projectors surprised & they
are 'old school' now.. and they take much time setting them up to be safe. First one I saw was being worked on and I asked the dumbest question--where is the top/cover for this PJ?? duh!
Once you begin this project- a thread w/ lots of PICS on your work would be welcomed.
It will encourage others to try and some will see it is not easy.. and will not try. win win!!
lase safe!!!

hak
see link''\

http://www.lasershs.com/LitePipe_laser_entertainment_projector.htm

btw $$$
one arm and TWO legs--da aint cheap!!!
 

BobDiaz

Active member
Joined
Mar 4, 2014
Messages
139
Points
28
I'm not sure if I can find the code I wrote a while back, but steppers are driven in different ways. Assume a Uni-polar Stepper with 4 coils, A, B, C, and D. The letter indicates which coil is turned on.

Single Phase or Wave Drive:
A
B
C
D
(repeat over and over for clockwise and reverse for counter clock wise)

Dual Phase or Full Step Drive:
AB
BC
CD
DA
(repeat over and over for clockwise and reverse for counter clock wise)

Half Step:
A
AB
B
BC
C
CD
D
DA
(repeat over and over for clockwise and reverse for counter clock wise)
 

boraicho

New member
Joined
Oct 13, 2013
Messages
28
Points
3
Thanks guys for comments.
As you can see I have some lasers, also i have one with stepper motor, but i want build one purple with my own program. I am already tried something write, but i am not finished it. 4 years ago. And now, it is only for me pleasure. When i have a some little time, so i want to try something coding.
LASERS:
https://photos.app.goo.gl/luGYBeq0I3LofRWx2

P4182350.JPG
 
Last edited:

boraicho

New member
Joined
Oct 13, 2013
Messages
28
Points
3
Hi, i already have 405nm 125mw laser with stepper motors, but MCU is not my, i am bought it. everythink others is my. But offer still pays.
If someone has some codes on patterns with stepper motor, i will be glad to see it. Thanks.



 




Top