home *** CD-ROM | disk | FTP | other *** search
/ 64'er / 64ER_CD.iso / 90xx / 9011a.d64 / minisynthi (.txt) < prev    next >
Commodore BASIC  |  1995-03-30  |  2KB  |  43 lines

  1. 0 REM   (W) BY JOMO WALLA
  2. 10 SD=54272:FORI=0TO24:POKESD+I,0:NEXT:DIMHI%(1000):DIMLO%(1000):DIMTD%(1000,1)
  3. 20 DIMTH%(256):DIMTL%(256):ZE=161
  4. 30 TB$="ZSXDCVGBHNJMQ2W3ER5T6Y7UI9O0P@-*\^"
  5. 40 FOR I=1 TO LEN(TB$)
  6. 50 FR=63508/2^(1/12)^(94-35-I)
  7. 60 HI%=FR/256:LO%=FR-256*HI%
  8. 70 TA%=ASC(MID$(TB$,I,1))
  9. 80 TH%(TA%)=HI%:TL%(TA%)=LO%:NEXTI:I=0
  10. 100 PRINT"[147]MENU:":PRINT"1.TON EINSTELLEN":PRINT"2.LIED AUFNEHMEN"
  11. 110 PRINT"3.LIED SPIELEN":PRINT"4.LIED SPEICHERN":PRINT"5.LIED LADEN"
  12. 180 GETG$:G=VAL(G$):IFG<1ORG>5THEN180
  13. 190 ON G GOSUB 1000,2000,3000,4000,5000
  14. 200 GOTO 100
  15. 1000 INPUT"[147]LAUTSTAERKE(0-15)";LS
  16. 1010 INPUT"WELLENFORM(16/32/64/128)";WF
  17. 1020 INPUT"ATTACK(0-15)";A:INPUT"DECAY(0-15)";D:INPUT"SUSTAIN(0-15)";S
  18. 1030 INPUT"RELEASE(0-15)";R:IF WF=64 THEN INPUT"PULSBREITE(0-65535)";PB
  19. 1040 INPUT"FILTERMODUS(0/1/2/4)";FM:IF FM=0 THEN FF=0:FZ=0:GOTO1100
  20. 1050 INPUT"FILTERFREQUENZ(0-2047)";FF
  21. 1060 INPUT"FILTERRESONANZ(0-15)";FZ
  22. 1100 POKESD+24,16*FM+LS:POKESD+5,16*A+D:POKESD+6,16*S+R:POKESD+23,16*FZ+SGN(FM)
  23. 1110 POKESD+21,FF-INT(FF/8)*8:POKESD+22,INT(FF/8):POKESD+2,PB-INT(PB/256)*256
  24. 1120 POKESD+3,INT(PB/256):RETURN
  25. 2000 GETG$:IFG$=""THEN2000
  26. 2010 TP=PEEK(203):FORI=1TO1000:POKEZE,0:POKEZE+1,0:HI%(I)=TH%(G):LO%(I)=TL%(G)
  27. 2030 POKESD,LO%(I):POKESD+1,HI%(I):POKE SD+4,WF+1
  28. 2035 IFPEEK(203)=TPTHEN2035
  29. 2040 TD%(I,0)=PEEK(ZE+1)+256*PEEK(ZE):POKESD+4,WF:POKE198,0:WAIT203,64,255
  30. 2050 G=PEEK(60289+PEEK(203))
  31. 2060 POKE198,0:TP=PEEK(203):TD%(I,1)=PEEK(ZE+1)+256*PEEK(ZE):IFG=95THENRETURN
  32. 2070 NEXTI:RETURN
  33. 3000 FORJ=1TOI:POKEZE+1,0:POKEZE,0:POKESD,LO%(J):POKESD+1,HI%(J)
  34. 3020 POKESD+4,WF+1:IF PEEK(ZE+1)+256*PEEK(ZE)<TD%(J,0)THEN3020
  35. 3040 POKESD+4,WF:IF PEEK(ZE+1)+256*PEEK(ZE)<TD%(J,1)THEN3040
  36. 3050 NEXT J:RETURN
  37. 4000 INPUT"NAME";N$:N$=N$+",S,W":OPEN1,8,2,N$:A$=CHR$(13):PRINT#1,LS,A$,WF
  38. 4010 PRINT#1,PB,A$,A,A$,D,A$,S,A$,R,A$,FM,A$,FF,A$,FZ,A$,I:FORJ=1TOI
  39. 4020 PRINT#1,LO%(J),A$,HI%(J),A$,TD%(J,0),A$,TD%(J,1):NEXTJ:CLOSE1:RETURN
  40. 5000 INPUT"NAME";N$:N$=N$+",S,R":OPEN1,8,2,N$:INPUT#1,LS,WF,PB,A,D,S,R,FM,FF,FZ
  41. 5010 INPUT#1,I:GOSUB1100
  42. 5020 FORJ=1TOI:INPUT#1,LO%(J),HI%(J),TD%(J,0),TD%(J,1):NEXTJ:CLOSE1:RETURN
  43.