From: Bench on 7 Dec 2006 09:22 Hello, i've to play a simple sound out of a driver. I read a while in the DDK and found, that the stream api ( KS.. ) is more complicated, than i thoght ;-(. I've to send simple 'beeps' via the sound card, as there is no buzzer connected. I've to do this in kernelmode, as the beeps have to be generated also within a registered shutdown handler. Would opening sysaudio and sending IOCTL_KS_WRITE_STREAM do the trick? How to set up the buffers for this IOCTL? Or would it be a better way to build an audio filter with an extra device object? Any help would be fine. Thank you, - b
From: Don Burn on 7 Dec 2006 09:27 First this is a poor idea, anything that assumes a user is present (otherwise why are you doiing this) in a kernel mode driver shows a bad desing. If beeps are all you do need and recognizing that you really should not do this, seach the groups for HalMakeBeep. -- Don Burn (MVP, Windows DDK) Windows 2k/XP/2k3 Filesystem and Driver Consulting http://www.windrvr.com Remove StopSpam from the email to reply "Bench" <Bench(a)discussions.microsoft.com> wrote in message news:DBADA52D-D511-4DD5-AD23-238550FE39E8(a)microsoft.com... > Hello, > > i've to play a simple sound out of a driver. > I read a while in the DDK and found, that the stream api ( KS.. ) is more > complicated, than i thoght ;-(. > I've to send simple 'beeps' via the sound card, as there is no buzzer > connected. > I've to do this in kernelmode, as the beeps have to be generated also > within > a registered shutdown handler. > > Would opening sysaudio and sending IOCTL_KS_WRITE_STREAM do the trick? > How to set up the buffers for this IOCTL? > Or would it be a better way to build an audio filter with an extra device > object? > > Any help would be fine. > > Thank you, > - b
From: Bench on 7 Dec 2006 10:10 Hello Don, in this case the shutdown was initiated by a user, which does not see the screen ( as the machine can be fixed in a wall and he is behind the wall, but has different possibilities to interact running transactions ) and he should know, when he's allowed to power off the pc. Consider, your OS is not only used for home desktops. Windows is sometimes put ( OS/2 is still dying ) on self service terminals with other handlings ( so please do not talk about design; within the shutdown handler i also show pictures with informations on why the shutdown occured ( blackout, invalid config, external shutdown event, .. ) and what should be done next...informational text for the people in front of the machine; if there is a rear service diplay connected too, than more fun is produced... ). Until now ( a buzzer was connected ) i beeped via the beep driver. Does HalMakeBeep() really go through the sound card? Thank you, - b "Don Burn" wrote: > First this is a poor idea, anything that assumes a user is present > (otherwise why are you doiing this) in a kernel mode driver shows a bad > desing. If beeps are all you do need and recognizing that you really > should not do this, seach the groups for HalMakeBeep. > > > -- > Don Burn (MVP, Windows DDK) > Windows 2k/XP/2k3 Filesystem and Driver Consulting > http://www.windrvr.com > Remove StopSpam from the email to reply > > > > "Bench" <Bench(a)discussions.microsoft.com> wrote in message > news:DBADA52D-D511-4DD5-AD23-238550FE39E8(a)microsoft.com... > > Hello, > > > > i've to play a simple sound out of a driver. > > I read a while in the DDK and found, that the stream api ( KS.. ) is more > > complicated, than i thoght ;-(. > > I've to send simple 'beeps' via the sound card, as there is no buzzer > > connected. > > I've to do this in kernelmode, as the beeps have to be generated also > > within > > a registered shutdown handler. > > > > Would opening sysaudio and sending IOCTL_KS_WRITE_STREAM do the trick? > > How to set up the buffers for this IOCTL? > > Or would it be a better way to build an audio filter with an extra device > > object? > > > > Any help would be fine. > > > > Thank you, > > - b > > >
From: Don Burn on 7 Dec 2006 10:21 Nope, HalMakeBeep will probably not go through the sound card. I suspect you will have to do KS stuff I would ask this question at http://www.wdmaudiodev.com/. I do know about non-desktop systems and that is why I cautioned you, since I have had the joy of dealing with drivers that knew there was a sound card or video or other such nonsense and watching the results when it was not there. Since this is an essentally embedded environment your design is fine, but without that piece of data my comments are needed. -- Don Burn (MVP, Windows DDK) Windows 2k/XP/2k3 Filesystem and Driver Consulting http://www.windrvr.com Remove StopSpam from the email to reply "Bench" <Bench(a)discussions.microsoft.com> wrote in message news:D5317F22-7F9D-4A15-925D-4AB685E8A9A8(a)microsoft.com... > Hello Don, > > in this case the shutdown was initiated by a user, which does not see the > screen ( as the machine can be fixed in a wall and he is behind the wall, > but has different possibilities to interact running transactions ) and he > should know, when he's allowed to power off the pc. > Consider, your OS is not only used for home desktops. > Windows is sometimes put ( OS/2 is still dying ) on self service > terminals > with other handlings ( so please do not talk about design; within the > shutdown handler i also show pictures with informations on why the > shutdown > occured ( blackout, invalid config, external shutdown event, .. ) and > what > should be done next...informational text for the people in front of the > machine; if there is a rear service diplay connected too, than more fun > is > produced... ). > > Until now ( a buzzer was connected ) i beeped via the beep driver. > Does HalMakeBeep() really go through the sound card? > > Thank you, > - b > > "Don Burn" wrote: > >> First this is a poor idea, anything that assumes a user is present >> (otherwise why are you doiing this) in a kernel mode driver shows a bad >> desing. If beeps are all you do need and recognizing that you really >> should not do this, seach the groups for HalMakeBeep. >> >> >> -- >> Don Burn (MVP, Windows DDK) >> Windows 2k/XP/2k3 Filesystem and Driver Consulting >> http://www.windrvr.com >> Remove StopSpam from the email to reply >> >> >> >> "Bench" <Bench(a)discussions.microsoft.com> wrote in message >> news:DBADA52D-D511-4DD5-AD23-238550FE39E8(a)microsoft.com... >> > Hello, >> > >> > i've to play a simple sound out of a driver. >> > I read a while in the DDK and found, that the stream api ( KS.. ) is >> > more >> > complicated, than i thoght ;-(. >> > I've to send simple 'beeps' via the sound card, as there is no buzzer >> > connected. >> > I've to do this in kernelmode, as the beeps have to be generated also >> > within >> > a registered shutdown handler. >> > >> > Would opening sysaudio and sending IOCTL_KS_WRITE_STREAM do the trick? >> > How to set up the buffers for this IOCTL? >> > Or would it be a better way to build an audio filter with an extra >> > device >> > object? >> > >> > Any help would be fine. >> > >> > Thank you, >> > - b >> >> >>
|
Pages: 1 Prev: EHCI driver causes blue csreen Next: SplPromptUIInUsersSession |