Difference between revisions of "CSND Shared Memory"

From 3dbrew
Jump to navigation Jump to search
Line 24: Line 24:
  
 
=Type0 Commands=
 
=Type0 Commands=
 +
=Command 0x8=
 +
{| class="wikitable" border="1"
 +
|-
 +
!  Index Byte
 +
!  Description
 +
|-
 +
| 0x2-0x3
 +
| CmdID 0x8
 +
|-
 +
| 0xC-0xF
 +
| Value for the audio sampling frequency?
 +
|}
 +
 +
This sets the audio sampling frequency?
 +
 
=Command 0xE=
 
=Command 0xE=
 
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"

Revision as of 06:56, 21 August 2013

This page describes the structure of the CSND shared memory.

Type0 Command Structure

Index Byte Description
0x0-0x1 Offset in shared-memory for the command to process immediately after this one, when not 0xFFFF.
0x2-0x3 CommandID
0x4-0x7 This is initially zero when this command data is written by the user process, once the CSND module finishes processing the command this is set to 0x1.
0x8-0xB The low 5-bits for this field is the the channel-index. This word is used for command parameters as well.
0xC-0x1F Command parameters

Type0 Commands

Command 0x8

Index Byte Description
0x2-0x3 CmdID 0x8
0xC-0xF Value for the audio sampling frequency?

This sets the audio sampling frequency?

Command 0xE

Index Byte Description
0x2-0x3 CmdID 0xE
0x14-0x17 Physical address for the audio data.
0x1C-0x1F ?

This sets the physical address of the audio data used when playing sound.