Assigned access has some issues. one of which is the lack of printing support. It appears you have found others. The fact that the application is running above the lock screen and not fully logged into the account means there is limited access to some items. I recommend traying Shell Launcher to launch the application as the shell rather than using assigned access.
Volume control in kiosk mode

I'm setting up a medical device based on Windows 10 Enterprise LTSC, version 1809, OS build 17763.107
It's set in Kiosk mode, so that when Windows starts it automatically launches a custom win32 software.
Now, in this software we would like to control the audio volume, the programmer tried a couple of different approaches, but none of them seems to work.
I noticed that even if I try to regulate the volume with the buttons on the physical keyboard (which in normal use wouldn't be connected to the machine) it doesn't change. I can ear the sounds, but I'm unable to control the volume
When I run explorer.exe, and the shell pops up, the volume starts to work, both with physical buttons and inside the sw.
So it seems to me that without the default shell Windows 10 is unable to control the volume.
How can I solve this?
Windows 10
-
Sean Liming 4,141 Reputation points • MVP
2020-12-30T17:32:13.157+00:00 When you say KIOSK mode, do you mean you are using Shell Launcher or Assigned Access?
5 answers
Sort by: Most helpful
-
Sean Liming 4,141 Reputation points • MVP
2020-12-29T17:22:04.017+00:00 Below is a PowerShell script I found and used to set the audio volume without the volume interface. Maybe this might provide some ideas:
Add-Type -TypeDefinition @' using System.Runtime.InteropServices; [Guid("5CDF2C82-841E-4546-9722-0CF74078229A"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)] interface IAudioEndpointVolume { // f(), g(), ... are unused COM method slots. Define these if you care int f(); int g(); int h(); int i(); int SetMasterVolumeLevelScalar(float fLevel, System.Guid pguidEventContext); int j(); int GetMasterVolumeLevelScalar(out float pfLevel); int k(); int l(); int m(); int n(); int SetMute([MarshalAs(UnmanagedType.Bool)] bool bMute, System.Guid pguidEventContext); int GetMute(out bool pbMute); } [Guid("D666063F-1587-4E43-81F1-B948E807363F"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)] interface IMMDevice { int Activate(ref System.Guid id, int clsCtx, int activationParams, out IAudioEndpointVolume aev); } [Guid("A95664D2-9614-4F35-A746-DE8DB63617E6"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)] interface IMMDeviceEnumerator { int f(); // Unused int GetDefaultAudioEndpoint(int dataFlow, int role, out IMMDevice endpoint); } [ComImport, Guid("BCDE0395-E52F-467C-8E3D-C4579291692E")] class MMDeviceEnumeratorComObject { } public class Audio { static IAudioEndpointVolume Vol() { var enumerator = new MMDeviceEnumeratorComObject() as IMMDeviceEnumerator; IMMDevice dev = null; Marshal.ThrowExceptionForHR(enumerator.GetDefaultAudioEndpoint(/*eRender*/ 0, /*eMultimedia*/ 1, out dev)); IAudioEndpointVolume epv = null; var epvid = typeof(IAudioEndpointVolume).GUID; Marshal.ThrowExceptionForHR(dev.Activate(ref epvid, /*CLSCTX_ALL*/ 23, 0, out epv)); return epv; } public static float Volume { get {float v = -1; Marshal.ThrowExceptionForHR(Vol().GetMasterVolumeLevelScalar(out v)); return v;} set {Marshal.ThrowExceptionForHR(Vol().SetMasterVolumeLevelScalar(value, System.Guid.Empty));} } public static bool Mute { get { bool mute; Marshal.ThrowExceptionForHR(Vol().GetMute(out mute)); return mute; } set { Marshal.ThrowExceptionForHR(Vol().SetMute(value, System.Guid.Empty)); } } } '@ [audio]::Volume = 0.5
0 No commentsAliceYang-MSFT 2,071 Reputation points2020-12-30T09:02:25.557+00:00 Hi,
Thank you for the detailed information you provided and solutions you attempted.
I think we need do more to narrow down the root cause.
- Switch out of the kiosk mode and run the custom win32 app on the device to check volume control function
- If works, we can say kiosk mode is the culprit. But I tested on my Windows 10 Enterprise, version 2004. I can control volume in Kiosk mode with physical keyboard, so I suppose kiosk mode isn’t the reason why volume control fails.
- If fails, something might be wrong with the device or the custom win32 app.
- Run another app on the device and check whether volume control works
- If works, the custom win32 app needs to be changed to enable volume control
- If fails, the device might doesn’t support volume control. We can contact the manufacturer for assistance.
Please note that Kiosk mode only supports specific apps. It might be difficult to let your custom app work fine in this mode.
If the Answer is helpful, please click "Accept Answer" and upvote it. Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
-
Cosma Tassinari 1 Reputation point
2020-12-30T13:10:57.48+00:00 As I already said in my question:
When I run explorer.exe, and the shell pops up, the volume starts to work, both with physical buttons and inside the sw.
If it can be of any use, I deployed the kiosk mode via a provisioning profile that I made, very basic, with automatic access, tablet mode enabled, branding neutral set to 32.
Sean Liming 4,141 Reputation points • MVP2020-12-30T17:32:49.273+00:00 When you say KIOSK mode, do you mean you are using Shell Launcher to launch the application or Assigned Access?
Cosma Tassinari 1 Reputation point2020-12-30T17:34:07.18+00:00 Assigned access
AliceYang-MSFT 2,071 Reputation points2021-01-04T09:08:26.137+00:00 Hi,
If you configure the kiosk using a provisioning package, you must apply the provisioning package after the device completes the out-of-box experience (OOBE).
Have you let the device complete the OOBE before you apply the provisioning profile?
Cosma Tassinari 1 Reputation point2021-01-04T09:46:47.52+00:00 I complete OOBE for administrator user before installing the provisioning profile.
Then I install the provisioning which creates the local user needed for the assigned access.
Then I reboot and the system directly enters in the assigned access without completing OOBE for the local user.
Volume control doesn't work.Anyway, the first time I exit assigned access, launching the shell from the local user, OOBE starts and I can complete it (and with the shell I can control volume, both via software and via keyboard buttons), but still, when I reboot the machine and I get back into my application, I don't have any chance to control the volume
Sign in to comment
AliceYang-MSFT 2,071 Reputation points2021-01-05T09:43:23.613+00:00 Hi,
It seems that there is something wrong between the custom software and kiosk mode.
I'm not sure whether it could solve the problem. But if the programmer could create a hotkey to control volume in the software, it might be possible to control the volume through keyboard when the software runs on the machine. After the volume is OK, disconnect the keyboard from the machine.
Sorry again that I couldn't provide a solution for this issue. You may want to contact Microsoft Support for business for help.
Please note: Information posted in the given link is hosted by a third party. Microsoft does not guarantee the accuracy and effectiveness of information.
----------
If the Answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.0 No commentsCosma Tassinari 1 Reputation point2021-01-06T07:47:44.243+00:00 Thank you for trying to help, but again, it's not the software, because when in kiosk mode, neither the physical volume keys on the keyboard work...
0 No comments
Hi,
we are finding the same issue in our env.
We set an .exe application to run on kiosk mode ( so we are using WPF application kiosk mode ) so "eshell.exe" replace the "explorer.exe" process and in this way the physical button on the monitor and on the keyboard doesn't work anymore and we can't regulate the audio anymore.
Did you find any solution or do you have any tips ?
Thanks a lot
Unfortunately no.
The only very basic workaround that I found and that can somehow work in my environment is to set the volume to 100% for all users, before applying the provisioning profile that activates the kiosk mode. Rather crude, but better than nothing
Hi,
i don't know if is it the correct solution and if it can work even for your application but i replace on the regkey
the shell value from "eshell.exe" to "customshellhost.exe" "emulating" the "Shell Launcher v2" actions as i found on https://learn.microsoft.com/it-it/windows/configuration/kiosk-shelllauncher.
I know that should be a "no sense" change but ... this change "enabled" the physical button on the monitor and on the keyboard and i can now regulate the volume.
Let me know if this solution works even for your kiosk
Ciao
Sign in to comment