{ PropForth test program for stepper on Pins 8, 9, 10, 11 and stepper 2 on Pins 12, 13, 14, 15 5 Wire 5Volt 200ma stepper driven by ULN2803 This will test rotation CW and CCW. There are short and long tests November 26, 2012 2:02am Taiwan Time Author - G. Herzog Second version -- Revised from original due to some wrong details. Apply to PropForth v5.03 } fl \ required to load... maybe... called 'fast load' \ Establish Pins as outputs : OUTPUT1 8 9 10 11 pinout pinout pinout pinout 8 9 10 11 pinlo pinlo pinlo pinlo ; : OUTPUT2 12 13 14 15 pinout pinout pinout pinout 12 13 14 15 pinlo pinlo pinlo pinlo ; \ 30 step turn loop -- direction unknown 5ms between steps and 15ms high pulse : TURN1 30 0 do 5 delms 8 pinhi 15 delms 8 pinlo 5 delms 9 pinhi 15 delms 9 pinlo 5 delms 10 pinhi 15 delms 10 pinlo 5 delms 11 pinhi 15 delms 11 pinlo loop ; : TURN2 30 0 do 5 delms 12 pinhi 15 delms 12 pinlo 5 delms 13 pinhi 15 delms 13 pinlo 5 delms 14 pinhi 15 delms 14 pinlo 5 delms 15 pinhi 15 delms 15 pinlo loop ; : TURN3 30 0 do 5 delms 11 pinhi 15 delms 11 pinlo 5 delms 10 pinhi 15 delms 10 pinlo 5 delms 9 pinhi 15 delms 9 pinlo 5 delms 8 pinhi 15 delms 8 pinlo loop ; : TURN4 30 0 do 5 delms 15 pinhi 15 delms 15 pinlo 5 delms 14 pinhi 15 delms 14 pinlo 5 delms 13 pinhi 15 delms 13 pinlo 5 delms 12 pinhi 15 delms 12 pinlo loop ; \ A complete task word TRIAL1 and TRIAL2 and TRIAL3 and TRIAL4 : TRIAL1 OUTPUT1 TURN1 88 . ; : T1 10 0 do TRIAL1 sc loop ; : TRIAL2 OUTPUT2 TURN2 99 . ; : T2 10 0 do TRIAL2 sc loop ; : TRIAL3 OUTPUT1 TURN3 66 . ; : T1 10 0 do TRIAL1 sc loop ; : TRIAL4 OUTPUT2 TURN4 77 . ; : T2 10 0 do TRIAL2 sc loop ; \ Check wiring harnes with 8x led bank : ALLOUT 8 9 10 11 12 13 14 15 pinout pinout pinout pinout pinout pinout pinout pinout ; : ALLHI 8 9 10 11 12 13 14 15 pinhi pinhi pinhi pinhi pinhi pinhi pinhi pinhi ; : ALLLO 8 9 10 11 12 13 14 15 pinlo pinlo pinlo pinlo pinlo pinlo pinlo pinlo ; : TL1 5 0 do TRIAL1 loop ; : TL2 5 0 do TRIAL2 loop ; : TL3 5 0 do TRIAL3 loop ; : TL4 5 0 do TRIAL4 loop ;