Is the code snippet below anything like what you are trying to work with?
Code:
let dirsB = %00001111 ; make pins output
main: for b3 = 0 to 99 ; start a for...next loop
gosub lstep ; call left step sub-procedure
next b3 ; next loop
for b3 = 0 to 99 ; start a for...next loop
gosub rstep ; call right step sub-procedure
next b3 ; next loop
goto main ; repeat
lstep: let b1 = b1 + 1 ; add 1 to variable b1
gosub stepit ; do the step
return
rstep: let b1 = b1 - 1 ; subtract 1 from variable b1
gosub stepit ; do the step
return
stepit: let b1 = b1 & %00000011 ; mask lower two bits of b1
lookup b1,(%1010,%1001,%0101,%0110),b2 ; lookup code into b2
let pinsB = b2 ; output b2 onto control lines
return
This code, a version of BASIC, was copied from
this site, which turned up in a
Google search using your title for this thread as a search string.
So, what makes you think you are qualified to write code for the PICAXE microprocessor? Did you design and build the hardware interface motor-driver that the PICAXE controls? Do you know how the output bits must be sequenced to make the motor turn clock-wise and counter clock-wise? Can you explain the difference in operation between a bi-polar and a uni-polar stepper? What waveforms will be applied to the stepper motor coils (windings)? How will the current in those coils be controlled?
What does "a certain place" mean? How is the motor started spinning, and what determines the direction of rotation? How will you determine when to press a button so the motor will stop in a certain place?
What is the purpose of your project? What is the stepper motor supposed to DO (if anything)?