|
META TOPICPARENT |
name="Scilab" |
Implementing the Arduino toolbox
The program structure |
|
Sanp: Where "S" identifies for the stepper motor device, "a" stands for "attach" n is the GPIO pin and p is the pulse (N1 .. N4 or the stepping motor driver module) . The command also programs the GPIO pins as output. Sa21 will therefore attach GPIO pin 2 to the first stepping motor driver input (N1 on the driver card). |
|
< < | Sm: moves the stepping motor by 1 step |
> > | Smfs: m: moves the stepping motor by 1 step. The parameters f and s stand for f: forward of b: backward and s is the stepping mode which can be single phase, double phase or half step. The direction and the stepping mode can be selected in the xcos block:
In the screen dump above half step mode in forward direction is selected. |
|
Sc: Clears all coil signals to low
Reading analog values |
|
META FILEATTACHMENT |
attachment="xcosEncoder.png" attr="" comment="" date="1549551382" name="xcosEncoder.png" path="xcosEncoder.png" size="32649" user="UliRaich" version="1" |
META FILEATTACHMENT |
attachment="encoderResult.png" attr="" comment="" date="1549551382" name="encoderResult.png" path="encoderResult.png" size="15252" user="UliRaich" version="1" |
META FILEATTACHMENT |
attachment="arduino-linux_1.6-src-6feb.tar.gz" attr="" comment="" date="1549551606" name="arduino-linux_1.6-src-6feb.tar.gz" path="arduino-linux_1.6-src-6feb.tar.gz" size="2722718" user="UliRaich" version="1" |
|
|
> > |
META FILEATTACHMENT |
attachment="steppingModes.png" attr="" comment="" date="1549639668" name="steppingModes.png" path="steppingModes.png" size="25119" user="UliRaich" version="1" |
|