Topic : The ATARI Compendium
Author : Scott Sanders / JAY Software
Version : 1.25 (20/6/2003)
Subject : Documentation
Nodes : 1117
Index Size : 32614
HCP-Version : 6
Compiled on : Atari
@charset : UTF-8
@lang : en
@default :
@help : %About
@options : +g -i -t4 +y +z
@width : 100
View Ref-FileDsp_Reserve() XBIOSSyntaxWORD Dsp_Reserve( xreserve, yreserve )
LONG xreserve, yreserve;
Function Dsp_Reserve() reserves DSP memory for program usage.
Opcode 107 (0x6B)
Availability Available only when bit #3 of the '_SND' cookie is set.
Parameters xreserve and yreserve specify the amount of memory (in DSP words) to reserve for a DSP program in X and Y memory space
respectively. xreserve and yreserve must include all
program/data space so that subroutines do not overwrite your
reserved area.
Binding move.l yreserve,-(sp)
move.l xreserve,-(sp)
move.w #$6B,-(sp)
trap #14
lea 10(sp),sp
Return Value Dsp_Reserve() returns a 0 if the memory was reserved
successfully or -1 if not enough DSP memory was available.
Comments If this call fails you should call Dsp_FlushSubroutines() and then retry it. If it fails a second time, the DSP lacks
enough memory space to run your program.