Retroarch: kiosk mode

Created on 13 Jun 2016  路  42Comments  路  Source: libretro/RetroArch

Some folks on the forum have been asking about adding a "kiosk mode" to XMB. Basically, just hide everything except for the playlists so that people can't monkey with settings, etc.


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

enhancement

Most helpful comment

It's been a year since there last was any activity on this issue and I believe it's time to take up the discussion again. One of the reasons I've started taking an interest in a kiosk mode (or "kids mode", if you like) is that I became a father myself this summer. In time, I see myself introducing my kids to some of the classics from my youth, but I also clearly see how that places different requirements on the software compared to when I use it myself.

My current personal setup for RetroArch is a dedicated mini-ITX system. I did it this way since I want to have a "locked" setup that isn't in constant flux (new hardware, drivers, OS updates, etc.). In part because I want something that "just works" and in part because I, as many of you know, have spent some time on ensuring that the system has really low input lag. Any change to a system can affect the input lag, so that's a good reason for locking everything down once it works as intended.

Being able to lock everything down and harden the system makes it possible to build something that works more like a "real" product, such as the NES Mini Classic or SNES Mini Classic or any other console for that matter. You simply cannot mess up a NES Classic Mini using just the controller and there's something nice and desireable about that. I really think it's an ability that RetroArch should have as well. I'm fully aware of that you can write protect RetroArch's configuration/directories at the OS level, but that's really more of a hack which instead leaves you with a bunch of unnecessary UI clutter.

So, with the above in mind, I've spent some time looking at RetroArch's UI. There's already the possibility of disabling tabs and some menu options, but more needs to be done to really finish this work. I've also suggested a couple of options that could help streamline and improve UI navigation for less tech-savvy users.

Main menu (RetroArch tab)

Option to enable/disable further (non-essential) items:

  • Load Core
  • Load Content
  • Information
  • Configurations

Out of the above, the "Configurations" option seems the most important to disable for a kiosk mode. The benefit of being able to disable the others is to reduce UI clutter. For a fully configured system using playlists, these options add little to no value.

Playlists

  • Option for disabling the ability to rename a playlist item (in the same way there's an option to disable removal of a playlist item).
  • Option to launch playlist item immediately, i.e. without first showing the "Run/Rename/Remove/Information" menu for the playlist item and then selecting "Run". When closing the content, RetroArch would then also return directly to the playlist and not to the "Run/Rename/Remove/Information" menu.

The last item above is obviously not essential. However, this is another option that would reduce UI clutter and "clean up" the experience. It's not for everyone, but it's definitely something that makes sense for those of us that aim for the cleanest possible presentation for non-tech-savvy users.

Quick menu

  • Options for enabling/disabling almost all of the Quick Menu items, i.e.:

    • Take Screenshot

    • Save/load state controls (State Slot, Save State, Load State, Undo Load State, Undo Save State). A single option to enable/disable all of these.

    • Options

    • Controls

    • Cheats

    • Shaders

    • Save Core Overrides

    • Save Game Overrides

    • Information

  • Only the following items are always active:

    • Resume

    • Restart

    • Close Content

  • Option for preventing user from pressing back when in the Quick Menu, going back to the main menu. This can be confusing for new users and especially younger kids who might get lost in the user interface.

For a kiosk mode, several of the Quick Menu items obviously have to be possible to disable. Others, such as "Take Screenshot", "Save State", etc. don't have to be possible to disable, but if we put in the work to make it possible to disable the configuration related items, we might as well put in options for all the non-essential items. Again, it gives the user the option of both protecting the configuration and creating a really sleek setup.

The Kiosk Mode setting

Finally, I believe that it should be possible to control these options individually as well as enable an umbrella setting called "Kiosk Mode". Kiosk Mode would only disable the configuration related menu items. If the user wants to disable additional items, this would have to be done manually.

I think it should be possible to disable Kiosk Mode right from the RetroArch tab, i.e. without editing retroarch.cfg manually. I also think the same should be true if you've disabled the Settings tab and you want to re-enable it. The way this could be solved is:

  1. When enabling Kiosk Mode or disabling the Settings tab: Ask the user to input a password. This can be optional, i.e. the user can input a blank password.
  2. Under the RetroArch tab, there will now be one of these two items:

    • Disable Kiosk Mode

    • Enable Settings Tab

When selecting one of the items in step 2 above, the user will be prompted for the password (unless a blank one was given in step 1).

I believe it should be okay to store the password as plain text in retroarch.cfg. Obviously, it would also still be possible to disable Kiosk Mode/enable the Settings tab via retroarch.cfg if you forget the password.

This may sound like a lot of changes, but I believe they would go a long way in establishing RetroArch as the go-to choice for creating a user-friendly and console-like experience. As far as I know, RetroArch would be pretty unique in this. I hope we can have an open discussion regarding these suggestions and what the best way of implementing them would be. Although I've looked at and made minor changes to RetroArch's source code before, I'm not currently qualified to judge the feasibility of this proposal. I would like to help implementing it, but I can't promise anything. I'm not kidding you when I say that taking care of two 3 months old babies is basically full time work from the minute I get home from my other full time work. :-P What I'm saying is that I'll do what I can, but if I were to attempt to implement all of this on my own it would probably take a looooong time.

All 42 comments

OK, can look into this.

We have to unhardcode this:

{
  XMB_SYSTEM_TAB_MAIN = 0,
  XMB_SYSTEM_TAB_SETTINGS,
  XMB_SYSTEM_TAB_HISTORY,
  XMB_SYSTEM_TAB_ADD
};

"kiosk mode" It is perfect for protecting configurations from curious and newbies or kids :-) , I like the idea

Could be done similar to the password protection in USB Loader GX on the Wii. Locks you out from settings.

I for one am not bothered by having the top-level menus accessible, however, placing them _after_ the ADD symbol seems to me like a logical idea. I'd want to go straight for the game especially if the setting to automatically activate/detect core is on.

Of course, hiding the TLMs is then, the sensible idea not to corrupt the whole system... So, to keep on with the spirit of this thread, I came up with some ideas for the Kiosk:

  1. Gamepad / keyboard invisible key combination to access the hidden menus.
  2. On pressing a particular combination (example: L1+L2+R1+R2) a box is displayed showing a sequence of keys to be pressed prior access to hidden menus.
  3. Even better would be as idea#2 but no sequence is displayed, instead, only a timer waiting for a pre-configured sequence of key presses that will make available the menus.

http://libretro.com/forums/showthread.php?t=6058&p=41105&viewfull=1#post41105

Personally, I would prefer just a cfg switch. kiosk_mode_enable = "true"/"false"

Agreed but you would still need to implement some sort of activation to gain access to the settings, should you need to tinker with them.

To me, whoever knows RA enough to enable the kiosk mode should know retroarch.cfg. So I'd say just like @hizzlekizzle

I've plumbed a basic form of hiding tabs by swapping the enum for a few variables in the driver data.

You can find the options in the various Settings->Menu->Hide Tab toggles.

I've put some more work into this feature: https://github.com/gitghostcoder/RetroArch

@gitghostcoder Thank you for this new feature.

Fixed with this commit.

GUI
Setting Tab > Menu > Hide XXX Tab

Retroarch.cfg

xmb_hide_main = "false"
xmb_hide_settings = "false"
xmb_hide_images = "false"
xmb_hide_music = "false"
xmb_hide_video = "false"
xmb_hide_history = "false"
xmb_hide_import = "false"

Perfect, thanks guys.

Yes! Thanks :-)

Updated commit.

I can't seem to get this feature working in the 9/11/2016 nightly RetroArch build. Hiding everything except "Main Menu" and "Import" seems to work. I have tried putting:

xmb_hide_main = "true"
xmb_hide_import = "true"

into retroarch.cfg (in addition to the other settings above) but still have those two menus and my sole test playlist showing up. Any ideas?

@cheetoninja There are currently no options named xmb_hide_main or xmb_hide_import in the code, so that would be why it doesn't work. I don't see either of those implemented in any way. I see options for showing settings/images/music/video/history (of which only settings/images/history actually show up in the menu), but that's it. So if it was there before, I guess it got removed.

I also don't understand why this is (seemingly arbitrarily) an XMB-only feature, I would think all menu drivers would benefit from having these options.

It's been a year since there last was any activity on this issue and I believe it's time to take up the discussion again. One of the reasons I've started taking an interest in a kiosk mode (or "kids mode", if you like) is that I became a father myself this summer. In time, I see myself introducing my kids to some of the classics from my youth, but I also clearly see how that places different requirements on the software compared to when I use it myself.

My current personal setup for RetroArch is a dedicated mini-ITX system. I did it this way since I want to have a "locked" setup that isn't in constant flux (new hardware, drivers, OS updates, etc.). In part because I want something that "just works" and in part because I, as many of you know, have spent some time on ensuring that the system has really low input lag. Any change to a system can affect the input lag, so that's a good reason for locking everything down once it works as intended.

Being able to lock everything down and harden the system makes it possible to build something that works more like a "real" product, such as the NES Mini Classic or SNES Mini Classic or any other console for that matter. You simply cannot mess up a NES Classic Mini using just the controller and there's something nice and desireable about that. I really think it's an ability that RetroArch should have as well. I'm fully aware of that you can write protect RetroArch's configuration/directories at the OS level, but that's really more of a hack which instead leaves you with a bunch of unnecessary UI clutter.

So, with the above in mind, I've spent some time looking at RetroArch's UI. There's already the possibility of disabling tabs and some menu options, but more needs to be done to really finish this work. I've also suggested a couple of options that could help streamline and improve UI navigation for less tech-savvy users.

Main menu (RetroArch tab)

Option to enable/disable further (non-essential) items:

  • Load Core
  • Load Content
  • Information
  • Configurations

Out of the above, the "Configurations" option seems the most important to disable for a kiosk mode. The benefit of being able to disable the others is to reduce UI clutter. For a fully configured system using playlists, these options add little to no value.

Playlists

  • Option for disabling the ability to rename a playlist item (in the same way there's an option to disable removal of a playlist item).
  • Option to launch playlist item immediately, i.e. without first showing the "Run/Rename/Remove/Information" menu for the playlist item and then selecting "Run". When closing the content, RetroArch would then also return directly to the playlist and not to the "Run/Rename/Remove/Information" menu.

The last item above is obviously not essential. However, this is another option that would reduce UI clutter and "clean up" the experience. It's not for everyone, but it's definitely something that makes sense for those of us that aim for the cleanest possible presentation for non-tech-savvy users.

Quick menu

  • Options for enabling/disabling almost all of the Quick Menu items, i.e.:

    • Take Screenshot

    • Save/load state controls (State Slot, Save State, Load State, Undo Load State, Undo Save State). A single option to enable/disable all of these.

    • Options

    • Controls

    • Cheats

    • Shaders

    • Save Core Overrides

    • Save Game Overrides

    • Information

  • Only the following items are always active:

    • Resume

    • Restart

    • Close Content

  • Option for preventing user from pressing back when in the Quick Menu, going back to the main menu. This can be confusing for new users and especially younger kids who might get lost in the user interface.

For a kiosk mode, several of the Quick Menu items obviously have to be possible to disable. Others, such as "Take Screenshot", "Save State", etc. don't have to be possible to disable, but if we put in the work to make it possible to disable the configuration related items, we might as well put in options for all the non-essential items. Again, it gives the user the option of both protecting the configuration and creating a really sleek setup.

The Kiosk Mode setting

Finally, I believe that it should be possible to control these options individually as well as enable an umbrella setting called "Kiosk Mode". Kiosk Mode would only disable the configuration related menu items. If the user wants to disable additional items, this would have to be done manually.

I think it should be possible to disable Kiosk Mode right from the RetroArch tab, i.e. without editing retroarch.cfg manually. I also think the same should be true if you've disabled the Settings tab and you want to re-enable it. The way this could be solved is:

  1. When enabling Kiosk Mode or disabling the Settings tab: Ask the user to input a password. This can be optional, i.e. the user can input a blank password.
  2. Under the RetroArch tab, there will now be one of these two items:

    • Disable Kiosk Mode

    • Enable Settings Tab

When selecting one of the items in step 2 above, the user will be prompted for the password (unless a blank one was given in step 1).

I believe it should be okay to store the password as plain text in retroarch.cfg. Obviously, it would also still be possible to disable Kiosk Mode/enable the Settings tab via retroarch.cfg if you forget the password.

This may sound like a lot of changes, but I believe they would go a long way in establishing RetroArch as the go-to choice for creating a user-friendly and console-like experience. As far as I know, RetroArch would be pretty unique in this. I hope we can have an open discussion regarding these suggestions and what the best way of implementing them would be. Although I've looked at and made minor changes to RetroArch's source code before, I'm not currently qualified to judge the feasibility of this proposal. I would like to help implementing it, but I can't promise anything. I'm not kidding you when I say that taking care of two 3 months old babies is basically full time work from the minute I get home from my other full time work. :-P What I'm saying is that I'll do what I can, but if I were to attempt to implement all of this on my own it would probably take a looooong time.

After having discussed this with hunterk on the forums (link) I've put together a more formal proposal of what needs to be done in order to achieve what I outlined above. I'm prepared to spend some of my pretty non-existent spare time to make this happen, but it will take a while. I've divided the work into stages, though, and there are no dependencies between these stages. It would obviously be nice if others are willing to help as well.

RetroArch Kiosk Mode v3.pdf

This proposal is geared towards implementing this in the XMB menu driver. I'm not really familiar with the other menu drivers. My focus would be on XMB primarily. Will that be a problem, i.e. disparity between the menu drivers?

What do you think? @hizzlekizzle @twinaphex @Kivutar

@Brunnis
That all looks fine to me, and the implementation plan looks pretty unobtrusive. Disparity between the menu drivers shouldn't be a problem in this case, I don't think, as I'm pretty sure the existing hide/show settings are XMB-only already...?

Anyway, thumbs-up from me. We'll see how @twinaphex and @Kivutar feel about it.

I was able to set up a working development environment and take a quick look at the menu related source code over the past week. Given some time, this shouldn't be too complicated to implement, I think.

I've made a few small changes to the implementation specification for work packages 7 and 8:

I plan on making the password option for the settings tab and kiosk mode visible as separate items in the GUI. If no password is supplied, the behavior will be the same as today, i.e. there will be no option to enable the settings tab or disable kiosk mode from the GUI. These options only appear under the Main Menu tab if a password has been supplied. Doing it this way has the benefit of not making the "Enable Settings Tab" item appear under the Main Menu tab when existing users update their RetroArch installation.

RetroArch Kiosk Mode v4.pdf

EDIT: On this subject, I noticed Lakka (2.1 RC5) has the "Quit RetroArch" item under the Main Menu tab. When selected, RetroArch just seems to restart. Is this really the correct and expected behavior, @Kivutar ?

Sacrificed an hour's worth of sleep last night. I'm coming to grips with how the menu has been implemented:

enable_settings_tab

@Brunnis All Lakka does is run RetroArch. So yeah Esc/Quit in the menu will just relaunch it.

@parkerlreed No, Lakka has all sorts of specific menu stuff going on. For example, it adds Reboot/Shutdown options under the Main Menu tab that's not there in the regular build. So, the question remains: why is Quit RetroArch still there when it, seemingly, is so easy to remove?

@Brunnis yes it is the expected behavior. When RA crashes (or quit) the systemd unit relaunches it.

@Kivutar I should rephrase the question: What purpose does the "Quit RetroArch" option have in Lakka? From a user experience point of view it's not really a good idea to present the user with an option that seemingly does nothing except flash the screen.

Also, do you have any comments on the proposed kiosk mode implementation?

It restarts RetroArch which can be useful if something's gone horribly wrong or just generally broken.

Ideally, this menu entry should not exist. I use it for a few cases:

  • Quit RA when something is broken
  • Cleanly quit RA when I launch it manually from command line
  • Force the saving of the sram and retroarch.cfg to the hard drive (at that time, we didn't have a menu entry to explicitly save)

I just opened a pull request for Stage 1 (see RetroArch Kiosk Mode v4.pdf), i.e. the ability to restore the Settings tab visibility directly from XMB.

After having looked into implementing Stage 2 (option for launching a playlist item without first showing the "run menu") and Stage 3 (option for disabling the ability to back out of Quick Menu to Main Menu), I've come to the conclusion that I can't really come up with good solutions without too large changes or ugly hacks. The way the menu is designed, making such changes does not appear trivial. Maybe someone with more knowledge of the code could come up with something, but given the limited time I currently have at my disposal, I've chosen to skip it. These were just small UI simplifications anyway, so nothing that has any actual bearing on Kiosk Mode.

The rest of the stages should be fairly straight forward to implement, although still pretty time consuming given the large amount of places where changes are needed for each new setting.

@Brunnis yeah, definitely understandable. I've only added one thing to the menu and was surprised at how many places I needed to touch just to have it show up and work.

Opened pull request for Stage 4: Option for controlling the ability to rename a playlist entry.

The next stage involves creating some new settings to be able to better control what appears under the Main Menu tab.

Opened pull request for Stage 5: New settings for showing/hiding Main Menu tab options.

Here's an example of the kind of clean look that can now be accomplished (if the pull request is approved):

image

Opened pull request for Stage 6: New settings for showing/hiding Quick Menu options.

Here's an example of the kind of clean look that can now be accomplished (if the pull request is approved):

image

With step 6 merged, users now have the ability to customize the XMB to prevent access to RetroArch's configuration/settings. In addition, it's also possible to disable other menu options which, for any number of reasons, might not be desired on a particular setup. These include options such as the save/load state controls, "Take Screenshot", "Information", etc.

The only thing that remains is to create the umbrella setting "Enable Kiosk Mode", which will be a convenient way of flicking one switch to ensure that the configuration is secured. I'll try to get this done over the coming week.

With the pull request referenced above (waiting to be merged), I've now finally implemented a new "Enable Kiosk Mode" setting under Settings -> User Interfaces! While there's nothing stopping anyone from implementing this fully in the other menu drivers, I've focused on XMB for this first attempt since I'm really short on time (I actually forced this to get it done in a reasonable amount of time, causing some grumblings from my significant other...). Anyway, it should be pretty easy to add this into the other menu drivers now that the plumbing is in place.

Hope you like it!

Brunnis, that is amazing work. I had to create an account on here to show appreciation. How do i go about pulling these changes into the latest image 2.1 ?

@Thinman123 Glad to hear you like it! I'm not sure how to do that in Lakka. Maybe you'd be better off tou wait for Kivutar to release an update (if he hasn't already).

I'm going to release 2.1-rc6 too. I will test it with the latest RA, and if there are no regressions, I will include it.

We have a Kiosk mode! Feel free to create new issues for feature requests specifically for it. Thanks a lot.

Why does kiosk mode not disable "Reset Core Association"?
How do I disable that so kids can't reset the emulator that works for a particular game?

I鈥檓 guessing that menu option was added after kiosk mode and the person adding it forgot to make it hideen when kiosk mode is enabled.

That鈥檚 one of the issues with kiosk mode, i.e. making sure any new settings that are added also adhere to the kiosk mode setting when applicable.

Was this page helpful?
0 / 5 - 0 ratings