[wdmaudiodev] Re: MSVAD simple example plays wav file continuously under debugger

  • From: "Jan M" <jan_m@xxxxxxxxxxxxxxxx>
  • To: <wdmaudiodev@xxxxxxxxxxxxx>
  • Date: Mon, 18 Jan 2010 21:51:54 -0000

Hi Tim,

----- Original Message ----- From: "Tim Roberts" <timr@xxxxxxxxx>
To: <wdmaudiodev@xxxxxxxxxxxxx>
Sent: Monday, January 18, 2010 9:10 PM
Subject: [wdmaudiodev] Re: MSVAD simple example plays wav file continuously under debugger

Is MSVAD the output device in this case?


If so, how do you know it's repeating? Are you spewing any debug information to the debugger?

Yes. It repeats calls to CSaveData::WriteData() with calls to CSaveData::FileWrite() when the buffer is full. Under the debugger the output file (normally 41k bytes) grows to hundreds of K.

If you send a sound to the normal audio output device and then break in
the debugger, you will hear the last bufferful repeated forever.  This
is just the way sound cards work.  They have to be told to stop playing,
and while you're in the debugger, it can't process interrupts to know
that playing should stop.  It's quite normal.  As soon as you step or
run in the  debugger, it will start handling interrupts again and move
on to the next sample.

MSVAD simply writes audio output to a file. The driver does not send anything to a sound card.
I believe it simulates hardware interrupts with timers.

The debugger is not stopping at a breakpoint, just outputting trace messages:

MSVAD: [CMiniportWaveCyclic::NewStream]
MSVAD: [CMiniportWaveCyclicMSVAD::ValidateFormat]
MSVAD: CMiniportWaveCyclicMSVAD::ValidatePcm
MSVAD: [CSaveData::InitializeWorkItems]
MSVAD: [CMiniportWaveCyclicStreamMSVAD::Init]
MSVAD: SaveData 8A45FF7C
MSVAD: [CSaveData::SetDataFormat]
MSVAD: [CSaveData::Initialize]
MSVAD: [CMiniportWaveCyclicStreamMSVAD::AllocateBuffer]
MSVAD: [CMiniportWaveCyclicStreamMSVAD::SetFormat]
MSVAD: [CSaveData::SetDataFormat]
MSVAD: New Format: 64000
MSVAD: [CMiniportWaveCyclicStreamMSVAD::SetNotificationFreq]
MSVAD: [CMiniportWaveCyclicStreamMSVAD::SetFormat]
MSVAD: [CSaveData::SetDataFormat]
MSVAD: New Format: 11025
MSVAD: [CMiniportWaveCyclicStreamMSVAD::SetNotificationFreq]
MSVAD: [CMiniportWaveCyclicStreamMSVAD::SetState]
MSVAD: [CMiniportWaveCyclicStreamMSVAD::SetState]
MSVAD: [CSaveData::WriteData ulByteCount=440]
MSVAD: [CSaveData::WriteData ulByteCount=440]
MSVAD: [CSaveData::WriteData ulByteCount=440]
MSVAD: [CMiniportWaveCyclicStreamMSVAD::SetState]
MSVAD: [CSaveData::WriteData ulByteCount=444]
MSVAD: [CSaveData::WriteData ulByteCount=440]
. repeated 35 times
MSVAD: [CSaveData::SaveFrame]

The CSaveData::WriteData and CSaveData::SaveFrame repeat ad nauseam.

(cannot step this as XP is free build).

That's not true at all.  You can step and breakpoint all you want, in
either the checked or free build.

I can step the driver (MSVAD) - not the free build OS. If you can tell me how to step the free build nt module (other than the disassembly, i.e. with C/C++ source code) I would be grateful.

Is there any way to stop nt (or whatever) repeating the file.

There's just not enough information here.  Can you describe the scenario
in a little more detail?

Hope the forgoing helps.




WDMAUDIODEV addresses:
Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
Unsubscribe:  mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx


Other related posts: