-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheyes2.bs2
More file actions
64 lines (51 loc) · 1.05 KB
/
Copy patheyes2.bs2
File metadata and controls
64 lines (51 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
'{$STAMP BS2}
'{$PBASIC 2.5}
l CON 15
r CON 14
i VAR WORD
j VAR WORD
lp VAR WORD
rp VAR WORD
d VAR WORD
s VAR WORD
s = 1
d = 17
li = 0
ri = 0
'i=0:j=100:s=1:lp=850:rp=650:d=17: GOSUB Nav
'i=0:j=100:s=1:lp=850:rp=650:d=17:li=0:ri=0: GOSUB NavRamp
i=0:j=100:s=1:lp=850:rp=650: GOSUB Nav
Nav:
FOR i TO j STEP s
PULSOUT l, lp
PULSOUT r, rp
PAUSE d
NEXT
RETURN
NavRamp:
FOR i TO j STEP s
PULSOUT l, lp+li
PULSOUT r, rp+ri
PAUSE d
NEXT
RETURN
StartTune:
'left DATA WORD 1175, WORD 1175, WORD 1175, WORD 1175, WORD 1175, WORD 1568, WORD 1568
middle DATA WORD 1480, WORD 1480, WORD 1480, WORD 1480, WORD 1480, WORD 0, WORD 1976
right DATA WORD 2637, WORD 2637, WORD 2637, WORD 2093, WORD 2637, WORD 3136, WORD 3136
durations DATA 16, 8, 8, 16, 8, 4, 4
wholenote VAR WORD
wholenote = 2000
'note1 VAR WORD
note2 VAR WORD
note3 VAR WORD
duration VAR BYTE
FOR i=0 TO 7*2 STEP 2
'READ left+i, WORD note1
READ middle+i, WORD note2
READ right+i, WORD note3
READ durations+(i/2), duration
FREQOUT 1, wholenote/duration, note2, note3
PAUSE 2
NEXT
RETURN