[General Questions and Answers] SetoK:
OK, I don't have the answer. But since no one is responding I'll try to give a few ideas that might help.

First, I have a hp6315 and an apache. Under settings, they both have a utility to enable/disable AGC. The ipaq's utility is labeled "ipaq audio" if you disable agc, you can then configure the microphone gain. This gain is stored in the registry. I think searching for gain or audio will find it. The apache doesn't have this. searching for audio, gain, wav, volume in the apache registry doesn't find anything that looks like microphone gain. I guess this is a "value added" thing from hp. But you could try searching anyway.

Then there's the mixer API. This is the way that user level apps are meant to control the audio. Works great on the desktop. Use mixerGetNumDevs() to find out how many devices you can control. On the h6315 mixerGetNumDevs returns 0. I haven't tried the apache, but I can remember a few years ago reading that many (most?) devices return 0. Oh well, hopefully you'll have better luck. However, there are two mixers that are implemented on the pocketPC the question is how to access them.

see this link for info on the mixers

http://blogs.msdn.com/medmedia/archive/2007/01/12/what-do-you-mean-by-mixer.aspx

Here's a link that shows the relationship between the mixer api and the other mixers, wavedev2 mixer, and software mixer.

http://msdn2.microsoft.com/en-us/library/ms923709.aspx

You'll notice that the the mixer api interacts with the mixer in the device driver not the software mixer in the WaveAPI.dll. You'll so notice that this section on audio drivers has pages for MDD/PDD drivers and Unified Audio Model (UAM) drivers. Platform Builder for WinCE 5.0 comes with a sample for each of these model drivers. Both models handle WAV_IOControl Messages. There are two types of messages, IOCTL_MIX_MESSAGE for the mixer, and IOCTL_WAV_MESSAGE for the rest of the driver. It looks like these IOCTL_MIX_MESSAGE are the way the mixer API controls the mixer. In the MDD/PPD sample they can be used to set WPDMX_MIC_VOL and WPDMX_LINEIN_VOL. In the UAM driver it's AC97_MIC_VOL and AC97_LINEIN_VOL. Perhaps sending the right IOCTL will solve the problem.

This blog entry

http://blogs.msdn.com/medmedia/archive/2007/01/03/windows-ce-audio-driver-samples.aspx

seems to say that a wavedev2 sample is available now. Also, while the WinCE 5.0 page above only metions two models the corresponding wince 6.0 also talks about wavedev2. I suspect if you got the current version of platform builder for WinCE 6.0 (trial version is free) you would have get the sample code for wavedev2, which is likely to be the best documentation of how this works. Amazingly, the drivers aren't that hard to read.

Both of the functions waveInMessage() and waveInSetProperty() are available to user apps. Hopefully both should be able to change the microphone gain if you can set the parameters properly. While most of these things are about windows CE, I think most (or all) apply to windows mobile 5.

Windows mobile 5, likely uses wavedev2 devices not MDD/PDD or UAM drivers.

Another interesting page about wavedev2 audio is here:

http://blogs.msdn.com/medmedia/archive/2007/01/04/the-wavedev2-gainclass-implementation.aspx

If your able to succeed or even learn more, be sure to post it back here.

I said a lot so I probably got something wrong. Anyone, please feel free to correct anything.