diff options
Diffstat (limited to 'fullmonty')
-rw-r--r-- | fullmonty/digital_io/cylon1.bas | 10 | ||||
-rw-r--r-- | fullmonty/digital_io/cylon2.bas | 22 |
2 files changed, 32 insertions, 0 deletions
diff --git a/fullmonty/digital_io/cylon1.bas b/fullmonty/digital_io/cylon1.bas new file mode 100644 index 0000000..c768590 --- /dev/null +++ b/fullmonty/digital_io/cylon1.bas @@ -0,0 +1,10 @@ +10 FOR F=0 TO 7 +20 OUT 0,2^F +30 GOSUB 100 +40 NEXT F +50 FOR F=7 TO 0 STEP -1 +60 OUT 0,2^F +70 GOSUB 100 +80 NEXT F +90 GOTO 10 +100 FOR X = 1 TO 150 : NEXT X : RETURN diff --git a/fullmonty/digital_io/cylon2.bas b/fullmonty/digital_io/cylon2.bas new file mode 100644 index 0000000..a5d5b7c --- /dev/null +++ b/fullmonty/digital_io/cylon2.bas @@ -0,0 +1,22 @@ +1 REM cylon demo program using RC2014 digital IO board +2 REM buttons may be pressed to alter speed + +5 DL=150 +6 DN=150 +10 FOR F=0 TO 7 +20 OUT 0,2^F +30 GOSUB 1000 +40 NEXT F +50 FOR F=7 TO 0 STEP -1 +60 OUT 0,2^F +70 GOSUB 1000 +80 NEXT F +90 GOTO 10 + +1000 X=0 +1010 BU=INP(0) +1020 IF BU <> 0 THEN DN = BU*5 +1030 IF DN <> DL THEN DL=DN : PRINT DN : RETURN +1040 IF X > DL THEN RETURN +1050 X=X+1 +1060 GOTO 1010 |