home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Club Amiga de Montreal - CAM
/
CAM_CD_1.iso
/
files
/
623a.lha
/
TurboDEX
/
ExampleSources
/
PlaySample.dex
< prev
next >
Wrap
Text File
|
1992-03-22
|
527b
|
29 lines
' play a beeeeeeep for 1 second '
PROC main()
VOID sample({sampledata},8,508)
VOID Delay(50)
VOID nosample()
CHIPSTRUCT sampledata
CHAR 0,49,90,117,127,117,90,49,0,-49,-90,-117,-127,-117,-90,-49
ENDCHIPSTRUCT
ENDPROC
PROC sample( adr, size, rate)
' n.b. size of sample is in words , adr must be chipmem !
LOCAL adr:LONG, size:INT, rate:INT
DMACON := 15
AUD0LCH := adr
AUD0LEN := size
AUD0PER := rate
AUD0VOL := 64
ADKCON := 255
DMACON := $8201
ENDPROC
PROC nosample()
DMACON := 1
ENDPROC