JMRanger
2010-03-03 23:01:01 UTC
I'm trying to generate sound as early as possible during the CE boot process.
To do so, I wrote a dummy driver that calls PlaySound during either its
DllEntry() or Init() call. My idea was to priorize audio drivers in the load
order, and load that dummy one afterward.
Code is simply
playRes = PlaySound(TEXT("\\Windows\\sound1.wav"), NULL, SND_ASYNC);
Apparently, this isn't a good idea. The call to PlaySound works (i.e. sound
is played), but PlaySond' return value is FALSE. In addition, the debug
console adds:
Exception 'Raised Exception' (-1): Thread-Id=01500002(pth=87f7da38),
Proc-Id=00400002(pprc=82631308) 'NK.EXE', VM-active=00400002(pprc=82631308)
'NK.EXE'
PC=c0033c34(k.coredll.dll+0x00013c34) RA=800a64c8(kernel.dll+0x000064c8)
SP=d02ae3a0, BVA=00000000
Trying to catch that with __try/__except changes nothing.
It seems to be specific to DllEntry/Init: placing the call in Open() works
fine - but too late for my purpose (unless there's a way to trigger that call
early that I'm unaware of ?)
Ideas ?
This is on CE 6.0 R3.
Thanks.
To do so, I wrote a dummy driver that calls PlaySound during either its
DllEntry() or Init() call. My idea was to priorize audio drivers in the load
order, and load that dummy one afterward.
Code is simply
playRes = PlaySound(TEXT("\\Windows\\sound1.wav"), NULL, SND_ASYNC);
Apparently, this isn't a good idea. The call to PlaySound works (i.e. sound
is played), but PlaySond' return value is FALSE. In addition, the debug
console adds:
Exception 'Raised Exception' (-1): Thread-Id=01500002(pth=87f7da38),
Proc-Id=00400002(pprc=82631308) 'NK.EXE', VM-active=00400002(pprc=82631308)
'NK.EXE'
PC=c0033c34(k.coredll.dll+0x00013c34) RA=800a64c8(kernel.dll+0x000064c8)
SP=d02ae3a0, BVA=00000000
Trying to catch that with __try/__except changes nothing.
It seems to be specific to DllEntry/Init: placing the call in Open() works
fine - but too late for my purpose (unless there's a way to trigger that call
early that I'm unaware of ?)
Ideas ?
This is on CE 6.0 R3.
Thanks.