ReactOS 0.4.16-dev-197-g92996da
sb16.h File Reference
#include <portcls.h>
#include <stdunk.h>
Include dependency graph for sb16.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define MAX_DMA_BUFFER_SIZE   65536
 
#define MPU401_OUTPUT_READY   0x40
 
#define MPU401_INPUT_READY   0x80
 
#define MPU401_RESET   0xff
 
#define MPU401_UART_MODE   0x3f
 

Typedefs

typedef IWaveMiniportSB16 * PWAVEMINIPORTSB16
 
typedef IAdapterSB16 * PADAPTERSB16
 

Enumerations

enum  DspRegister {
  DspRegCMSD0 = 0x00 , DspRegCMSR0 = 0x01 , DspRegCMSD1 = 0x02 , DspRegCMSR1 = 0x03 ,
  DspRegMixerReg = 0x04 , DspRegMixerData = 0x05 , DspRegReset = 0x06 , DspRegFMD0 = 0x08 ,
  DspRegFMR0 = 0x09 , DspRegRead = 0x0a , DspRegWrite = 0x0c , DspRegDataAvailable = 0x0e ,
  DspRegAck8 = 0x0e , DspRegAck16 = 0x0f
}
 
enum  DspCommand {
  DspWriteWaveProgrammedIo = 0x10 , DspWriteWave = 0x14 , DspWriteWaveAuto = 0x1c , DspReadWave = 0x24 ,
  DspReadWaveAuto = 0x2C , DspWriteHighSpeedWave = 0x90 , DspReadHighSpeedWave = 0x98 , DspSetSampleRate = 0x40 ,
  DspSetBlockSize = 0x48 , DspEnableOutput = 0xd1 , DspDisableOutput = 0xd3 , DspOutputStatus = 0xd8 ,
  DspPauseDma = 0xd0 , DspContinueDma = 0xd4 , DspHaltAutoDma = 0xda , DspInverter = 0xe0 ,
  DspGetVersion = 0xe1 , DspGenerateInterrupt = 0xf2 , DspSetDacRate = 0x41 , DspSetAdcRate = 0x42 ,
  DspStartDac16 = 0xb6 , DspStartAdc16 = 0xbe , DspStartDac8 = 0xc6 , DspStartAdc8 = 0xc3 ,
  DspPauseDma16 = 0xd5 , DspContinueDma16 = 0xd6 , DspHaltAutoDma16 = 0xd9
}
 
enum  DspMixerRegister {
  DspMixMasterVolumeLeft = 0x00 , DspMixMasterVolumeRight = 0x01 , DspMixVoiceVolumeLeft = 0x02 , DspMixVoiceVolumeRight = 0x03 ,
  DspMixIrqConfig = 0x80 , DspMixDmaConfig = 0x81
}
 

Functions

 DEFINE_GUID (IID_IWaveMiniportSB16, 0xbe23b2d7, 0xa760, 0x43ab, 0xb7, 0x6e, 0xbc, 0x3e, 0x93, 0xe6, 0xff, 0x54)
 
 DECLARE_INTERFACE_ (IWaveMiniportSB16, IUnknown)
 
 DEFINE_GUID (IID_IAdapterSB16, 0xfba9052c, 0x0544, 0x4bc4, 0x97, 0x3f, 0x70, 0xb7, 0x06, 0x46, 0x81, 0xe5)
 
 DECLARE_INTERFACE_ (IAdapterSB16, IUnknown)
 

Macro Definition Documentation

◆ MAX_DMA_BUFFER_SIZE

#define MAX_DMA_BUFFER_SIZE   65536

Definition at line 18 of file sb16.h.

◆ MPU401_INPUT_READY

#define MPU401_INPUT_READY   0x80

Definition at line 85 of file sb16.h.

◆ MPU401_OUTPUT_READY

#define MPU401_OUTPUT_READY   0x40

Definition at line 84 of file sb16.h.

◆ MPU401_RESET

#define MPU401_RESET   0xff

Definition at line 87 of file sb16.h.

◆ MPU401_UART_MODE

#define MPU401_UART_MODE   0x3f

Definition at line 88 of file sb16.h.

Typedef Documentation

◆ PADAPTERSB16

typedef IAdapterSB16* PADAPTERSB16

Definition at line 139 of file sb16.h.

◆ PWAVEMINIPORTSB16

typedef IWaveMiniportSB16* PWAVEMINIPORTSB16

Definition at line 101 of file sb16.h.

Enumeration Type Documentation

◆ DspCommand

Enumerator
DspWriteWaveProgrammedIo 
DspWriteWave 
DspWriteWaveAuto 
DspReadWave 
DspReadWaveAuto 
DspWriteHighSpeedWave 
DspReadHighSpeedWave 
DspSetSampleRate 
DspSetBlockSize 
DspEnableOutput 
DspDisableOutput 
DspOutputStatus 
DspPauseDma 
DspContinueDma 
DspHaltAutoDma 
DspInverter 
DspGetVersion 
DspGenerateInterrupt 
DspSetDacRate 
DspSetAdcRate 
DspStartDac16 
DspStartAdc16 
DspStartDac8 
DspStartAdc8 
DspPauseDma16 
DspContinueDma16 
DspHaltAutoDma16 

Definition at line 39 of file sb16.h.

40{
42 DspWriteWave = 0x14,
43 DspWriteWaveAuto = 0x1c,
44 DspReadWave = 0x24,
45 DspReadWaveAuto = 0x2C,
48 DspSetSampleRate = 0x40,
49 DspSetBlockSize = 0x48,
50 DspEnableOutput = 0xd1,
51 DspDisableOutput = 0xd3,
52 DspOutputStatus = 0xd8,
53 DspPauseDma = 0xd0,
54 DspContinueDma = 0xd4,
55 DspHaltAutoDma = 0xda,
56 DspInverter = 0xe0,
57 DspGetVersion = 0xe1,
59
60 /* SB16 only */
61 DspSetDacRate = 0x41,
62 DspSetAdcRate = 0x42,
63 DspStartDac16 = 0xb6,
64 DspStartAdc16 = 0xbe,
65 DspStartDac8 = 0xc6,
66 DspStartAdc8 = 0xc3,
67 DspPauseDma16 = 0xd5,
68 DspContinueDma16 = 0xd6,
69 DspHaltAutoDma16 = 0xd9
70};
@ DspSetSampleRate
Definition: sb16.h:48
@ DspReadWave
Definition: sb16.h:44
@ DspSetBlockSize
Definition: sb16.h:49
@ DspWriteWaveProgrammedIo
Definition: sb16.h:41
@ DspSetDacRate
Definition: sb16.h:61
@ DspWriteWave
Definition: sb16.h:42
@ DspStartDac16
Definition: sb16.h:63
@ DspContinueDma
Definition: sb16.h:54
@ DspStartAdc16
Definition: sb16.h:64
@ DspInverter
Definition: sb16.h:56
@ DspPauseDma
Definition: sb16.h:53
@ DspStartAdc8
Definition: sb16.h:66
@ DspWriteWaveAuto
Definition: sb16.h:43
@ DspWriteHighSpeedWave
Definition: sb16.h:46
@ DspHaltAutoDma16
Definition: sb16.h:69
@ DspContinueDma16
Definition: sb16.h:68
@ DspGenerateInterrupt
Definition: sb16.h:58
@ DspStartDac8
Definition: sb16.h:65
@ DspDisableOutput
Definition: sb16.h:51
@ DspOutputStatus
Definition: sb16.h:52
@ DspReadWaveAuto
Definition: sb16.h:45
@ DspReadHighSpeedWave
Definition: sb16.h:47
@ DspPauseDma16
Definition: sb16.h:67
@ DspGetVersion
Definition: sb16.h:57
@ DspHaltAutoDma
Definition: sb16.h:55
@ DspSetAdcRate
Definition: sb16.h:62
@ DspEnableOutput
Definition: sb16.h:50

◆ DspMixerRegister

Enumerator
DspMixMasterVolumeLeft 
DspMixMasterVolumeRight 
DspMixVoiceVolumeLeft 
DspMixVoiceVolumeRight 
DspMixIrqConfig 
DspMixDmaConfig 

Definition at line 72 of file sb16.h.

73{
78 /* ... */
79 DspMixIrqConfig = 0x80,
80 DspMixDmaConfig = 0x81
81};
@ DspMixVoiceVolumeRight
Definition: sb16.h:77
@ DspMixIrqConfig
Definition: sb16.h:79
@ DspMixMasterVolumeRight
Definition: sb16.h:75
@ DspMixMasterVolumeLeft
Definition: sb16.h:74
@ DspMixDmaConfig
Definition: sb16.h:80
@ DspMixVoiceVolumeLeft
Definition: sb16.h:76

◆ DspRegister

Enumerator
DspRegCMSD0 
DspRegCMSR0 
DspRegCMSD1 
DspRegCMSR1 
DspRegMixerReg 
DspRegMixerData 
DspRegReset 
DspRegFMD0 
DspRegFMR0 
DspRegRead 
DspRegWrite 
DspRegDataAvailable 
DspRegAck8 
DspRegAck16 

Definition at line 20 of file sb16.h.

21{
22 DspRegCMSD0 = 0x00,
23 DspRegCMSR0 = 0x01,
24 DspRegCMSD1 = 0x02,
25 DspRegCMSR1 = 0x03,
26 DspRegMixerReg = 0x04,
27 DspRegMixerData = 0x05,
28 DspRegReset = 0x06,
29 DspRegFMD0 = 0x08,
30 DspRegFMR0 = 0x09,
31 DspRegRead = 0x0a,
32 DspRegWrite = 0x0c,
34
35 DspRegAck8 = 0x0e,
36 DspRegAck16 = 0x0f
37};
@ DspRegMixerData
Definition: sb16.h:27
@ DspRegCMSD0
Definition: sb16.h:22
@ DspRegCMSD1
Definition: sb16.h:24
@ DspRegRead
Definition: sb16.h:31
@ DspRegFMD0
Definition: sb16.h:29
@ DspRegReset
Definition: sb16.h:28
@ DspRegFMR0
Definition: sb16.h:30
@ DspRegAck8
Definition: sb16.h:35
@ DspRegCMSR0
Definition: sb16.h:23
@ DspRegDataAvailable
Definition: sb16.h:33
@ DspRegAck16
Definition: sb16.h:36
@ DspRegWrite
Definition: sb16.h:32
@ DspRegMixerReg
Definition: sb16.h:26
@ DspRegCMSR1
Definition: sb16.h:25

Function Documentation

◆ DECLARE_INTERFACE_() [1/2]

DECLARE_INTERFACE_ ( IAdapterSB16  ,
IUnknown   
)

Definition at line 107 of file sb16.h.

108{
110
114
115 STDMETHOD_(PINTERRUPTSYNC, GetInterruptSync)( THIS ) PURE;
116
118 IN PWAVEMINIPORTSB16 Miniport) PURE;
119
121
123 IN BYTE Value) PURE;
124
125 STDMETHOD_(NTSTATUS, Reset)( THIS ) PURE;
126
127 STDMETHOD_(void, SetMixerValue)( THIS_
128 IN BYTE Index,
129 IN BYTE Value) PURE;
130
131 STDMETHOD_(BYTE, GetMixerValue)( THIS_
132 IN BYTE Index) PURE;
133
134 STDMETHOD_(void, ResetMixer)( THIS ) PURE;
135
136 /* TODO - Save/load settings */
137};
unsigned char BOOLEAN
LONG NTSTATUS
Definition: precomp.h:26
#define PURE
Definition: basetyps.h:64
#define THIS_
Definition: basetyps.h:65
#define THIS
Definition: basetyps.h:66
#define STDMETHOD_(t, m)
Definition: basetyps.h:63
SetWaveMiniport(IN PWAVEMINIPORTSB16 Miniport)
Definition: adapter.cpp:118
#define DEFINE_ABSTRACT_UNKNOWN()
Definition: ksiface.h:5
IInterruptSync * PINTERRUPTSYNC
Definition: portcls.h:888
IResourceList * PRESOURCELIST
Definition: portcls.h:442
_In_ BOOLEAN Read
Definition: strmini.h:479
#define IN
Definition: typedefs.h:39
static BOOL Write(PBYTE Address, PBYTE Data, SIZE_T Size)
Definition: vmhorizon.c:15
_In_ WDFCOLLECTION _In_ ULONG Index
_In_ PDEVICE_OBJECT DeviceObject
Definition: wdfdevice.h:2055
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING _Out_opt_ PUSHORT _Inout_opt_ PUNICODE_STRING Value
Definition: wdfregistry.h:413
_Must_inspect_result_ _In_ WDFIORESREQLIST _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFIORESLIST * ResourceList
Definition: wdfresource.h:309
IWaveMiniportSB16 * PWAVEMINIPORTSB16
Definition: sb16.h:101
unsigned char BYTE
Definition: xxhash.c:193

◆ DECLARE_INTERFACE_() [2/2]

DECLARE_INTERFACE_ ( IWaveMiniportSB16  ,
IUnknown   
)

Definition at line 93 of file sb16.h.

94{
96
97 STDMETHOD_(void, RestoreSampleRate)( THIS ) PURE;
98 STDMETHOD_(void, ServiceWaveISR)( THIS ) PURE;
99};

◆ DEFINE_GUID() [1/2]

DEFINE_GUID ( IID_IAdapterSB16  ,
0xfba9052c  ,
0x0544  ,
0x4bc4  ,
0x97  ,
0x3f  ,
0x70  ,
0xb7  ,
0x06  ,
0x46  ,
0x81  ,
0xe5   
)

◆ DEFINE_GUID() [2/2]

DEFINE_GUID ( IID_IWaveMiniportSB16  ,
0xbe23b2d7  ,
0xa760  ,
0x43ab  ,
0xb7  ,
0x6e  ,
0xbc  ,
0x3e  ,
0x93  ,
0xe6  ,
0xff  ,
0x54   
)