> SoundSup/s 0.10 , 12-Nov-1992 v0.10 JGH: Initial version  (@ Intercept OSWORD 7 SOUND call to adjust parameters to make 2& more compatible with BBC series. <: F< chn>=&2000 claimed to stop non-sound commands going to P( sound system (eg SOUND -257 MIDI). Z d? pitch<&0400 reduced to pitch &00xx to allow programs that n> use eg SOUND chn,vol,ASCMID$(S$,... and depend on b8-b15 x being ignored.  . To do: chn &xx0x queue without flushing. : : ver$="0.10" date$="12 Nov 1992"  : : :  mcode% &8000, L% -1 sp=13:link=14:pc=15  opt%=0 1 P%=0:O%=mcode% [OPT opt%*3+4 EQUD 0:\ Start EQUD Initialise EQUD Finalise "EQUD 0:\ Service ,EQUD TitleStr 6EQUD HelpStr @EQUD 0:\ command table JEQUD 0:\ SWI chunk number TEQUD 0:\ SWI chunk handler ^EQUD 0:\ SWI decoding table hEQUD 0:\ SWI decoding code r: | .TitleStr EQUS "SoundSupport":EQUB 0  ALIGN  .HelpStr JEQUS "SoundSupport"+9+ver$+" ("+date$+") "+169+" J.G.Harston":EQUB 0  ALIGN : .Initialise stmfd (sp)!,{link} #mov r0,#7 ; OswordVec adr r1,MyOsword ldr r2,[r12] +swi "OS_Claim" ; Hook into OS_Word : 1mov r0,#0 ; Read number of channels mov r1,#0 mov r2,#0 &mov r3,#0 0mov r4,#0 :swi "Sound_Configure" D1cmp r0,#8 ; If less than 8 channels N,movlt r0,#8 ; set to 8 channels Xswilt "Sound_Configure" b: l,mov r0,#127 ; Ensure full volume vswi "Sound_Volume" : ldmfd (sp)!,{pc} : :  .Finalise stmfd (sp)!,{link} #mov r0,#7 ; OswordVec adr r1,MyOsword ldr r2,[r12] )swi "OS_Release" ; Release OS_Word ldmfd (sp)!,{pc} : :  .MyOsword  cmp r0,#7 'movnes pc,link ; Not , pass on  : *.ldrb r0,[r1,#1] ; Get channel high byte 4'cmp r0,#&20 ; channel>=&2000 >movcs r0,#7 H/ldmcsfd (sp)!,{pc} ; Claim to prevent sound R: \,ldrb r0,[r1,#5] ; Get pitch high byte fcmp r0,#&04 p6movcc r0,#0 ; If pitch<&0400 force to &00xx zstrccb r0,[r1,#5] : -ldrb r0,[r1,#0] ; Get channel low byte *and r0,r0,#&10 ; Mask Flush nybble -cmp r0,#&00 ; Is No-Flush selected #movne r0,#7 ; Restore R0 .movnes pc,link ; Not No-Flush, pass on : /\ Needs to wait for current sound to finish : #mov r0,#7 ; Restore R0  movs pc,link ; Pass on : ] ("SAVE SoundSupp "+~mcode%+" "+~O% *SetType SoundSupp Module *Stamp SoundSupp