Herunterladen Inhalt Inhalt Diese Seite drucken

Verwendung Des Ay-Players Unter Kc-Basic - Kleincomputer M066 KLANG Handbuch

Inhaltsverzeichnis

Werbung

M066 – KLANG
Beispiel
WORK:
EQU
PLAYER: EQU
;CAOS VORBLOCK-----------------------------------------------------
ORG
PLAYER-#80
DEFM
DEFM
DEFS
DEFB
DEFW
DEFS
ORG
PLAYER
;!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
INCLUDE "AYPLAY.INC"
;!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
ORG
PLAYER+#0500
DEFB
DEFM
;------------------------------------------------------------------
START:
;...HIER ANWENDERPROGRAMM
;LD
HL,SONG
;LD
(WORK),HL
;CALL PLAYER
;...
;CALL PLAYER+6
;...
;LD
HL,SCHUSS
;LD
(WORK),HL
;CALL PLAYER+3
;...
RET
;------------------------------------------------------------------
SCHUSS: DEFB #00,#00,#00,#00,#00,#00,#14,#EF,#00,#10,#00,#00,#1F,#01
;------------------------------------------------------------------
SONG:
INCLUDEBINARY "SONG.STC"
ENDE:
Listing 8: Beispiel für die Verwendung der Include-Datei für den AY-Player

5.3.2.2 Verwendung des AY-Players unter KC-BASIC

Das Abspielen von einfachen Tönen und Geräuschen ist ziemlich einfach
und unkritisch. Das kann mit wenigen OUT-Anweisungen erfolgen. Für das
Abspielen
kompletter
Maschinenkodeprogramm aus BASIC heraus aufgerufen wird.
#0080
;ANFANG ARBEITSZELLEN (BIS WORK+#47)
#0300
;PLAYER (AM DATEIANFANG)
'TEST
'
'KCC'
5,0
3
PLAYER,ENDE,START
105,0
;AY-PLAYER-ENGINE (LÄNGE ENGINE CA. #4FF)
#7F,#7F
'TEST',1
Musik
;NAME FÜR LOAD, 8 STELLEN
;3=MIT AUTOSTART
;WEGEN PLAYER-LÄNGE!
;PROLOG
;MENÜEINTRAG
;ANFANGSADRESSE SONG
;ÜBERGEBEN
;SONG ABSPIELEN
;SONG STOPPEN
;GERÄUSCH LADEN
;UND ABSPIELEN
;HIER WIRD DER SONG EINGEBUNDEN
ist
ein
Player
41
nötig,
der
als
41

Werbung

Inhaltsverzeichnis
loading

Inhaltsverzeichnis