User Tools

Site Tools


sound_20and_20envelope_20in_20assembler

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

sound_20and_20envelope_20in_20assembler [2018/03/31 13:19]
127.0.0.1 external edit
sound_20and_20envelope_20in_20assembler [2018/04/13 10:47] (current)
richardrussell
Line 1: Line 1:
 =====SOUND and ENVELOPE in assembler===== =====SOUND and ENVELOPE in assembler=====
  
-//by Richard Russell, March 2010//\\ \\ //BBC BASIC for Windows// provides no direct means for an assembly language program to access the **SOUND** or **ENVELOPE** statements. It can be achieved using the technique described in [[/​Calling%20BASIC%20from%20assembler%20code|Calling BASIC from assembler code]] but an alternative approach is to use the code listed below. This makes available three subroutines:​ **Sound**, **Envelope** and **Qstatus**,​ the last of which allows you to discover the amount of space available in a sound queue (similar to what can be achieved using **ADVAL**).\\ \\  The parameters and returned values are documented within the code:\\ +//by Richard Russell, March 2010//\\ \\ //BBC BASIC for Windows// provides no direct means for an assembly language program to access the **SOUND** or **ENVELOPE** statements. It can be achieved using the technique described in [[/​Calling%20BASIC%20from%20assembler%20code|Calling BASIC from assembler code]] but an alternative approach is to use the code listed below. This makes available three subroutines:​ **Sound**, **Envelope** and **Qstatus**,​ the last of which allows you to discover the amount of space available in a sound queue (similar to what can be achieved using **ADVAL**).\\ \\  The parameters and returned values are documented within the code: 
 + 
 +<code bb4w>  ​
         DEF PROCassemble         DEF PROCassemble
         LOCAL L%, P%, code%, pass%         LOCAL L%, P%, code%, pass%
Line 96: Line 98:
         NEXT pass%         NEXT pass%
         ENDPROC         ENDPROC
 +</​code>​
sound_20and_20envelope_20in_20assembler.txt · Last modified: 2018/04/13 10:47 by richardrussell