Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
systems:moonlight [2021/05/30 15:05] – ↷ Page moved from emulators:moonlight to systems:moonlight igno2ksystems:moonlight [2026/03/12 15:45] (current) – Reorg paragraphs to get 43 instructions earlier lbrpdx
Line 1: Line 1:
-===== Moonlight =====+<WRAP group> 
 +<WRAP round box twothirds column> 
 +{{ https://raw.githubusercontent.com/fabricecaruso/es-theme-carbon/master/art/logos/moonlight.svg?nolink&400 }}
  
-[[https://moonlight-stream.org|Moonlight]] is an open source implementation of NVIDIAs GameStream protocol that lets you stream games from a PC with a NVIDIA graphics card to your Batocera box. It's a game streaming software similar to [[https://en.wikipedia.org/wiki/Steam_Link|Steam Link]], a piece of hardware that was discontinued in 2018 and that now lives as an Android/iPhone app.+====== Moonlight Embedded ======
  
-Batocera uses [[https://github.com/irtimmer/moonlight-embedded|Moonlight Embedded]] which also works on embedded ARM devices like the Raspberry Pi.+[[https://moonlight-stream.org|Moonlight]] is an open source game streaming host that lets you stream games from a PC with an supported GPU to your Batocera box. It's a game streaming software similar to [[https://en.wikipedia.org/wiki/Steam_Link|Steam Link]], a piece of hardware that was discontinued in 2018 and that now lives as an Android/iPhone app.
  
-<WRAP important> +Up to Batocera 42, we used [[https://github.com/irtimmer/moonlight-embedded|Moonlight Embedded]] which also works on x86_64 & embedded ARM devices like the Raspberry Pi. 
-At the moment Moonlight streaming in Batocera is non-functional because of changes in NVIDIAs GameStream protocol. A fixed version of Moonlight is on it's way an will be added to Batocera when it gets released.+ 
 +Starting with Batocera 43, we switched to [[https://github.com/moonlight-stream/moonlight-qt|Moonlight-QT]]. 
 + 
 +<WRAP center round important> 
 +The Moonlight protocol changes regularly, and you need to have a client version compatible with the Sushine Streaming Server [[https://app.lizardbyte.dev/Sunshine/?lng=en#Download]].
 </WRAP> </WRAP>
  
-<WRAP info>+<WRAP center round info>
 Moonlight is designed to stream games and applications from your PC accessible via LAN or VPN. It will not work with Cloud-streaming services like [[https://www.nvidia.com/de-de/geforce-now/|GeForce Now]]. Moonlight is designed to stream games and applications from your PC accessible via LAN or VPN. It will not work with Cloud-streaming services like [[https://www.nvidia.com/de-de/geforce-now/|GeForce Now]].
 </WRAP> </WRAP>
 +
 +This system scrapes metadata for the "moonlight" group and loads the ''moonlight'' set from the currently selected theme, if available.
 +</WRAP>
 +
 +<WRAP third column>
 +{{ https://raw.githubusercontent.com/fabricecaruso/es-theme-carbon/master/art/consoles/moonlight.png?nolink&350 |}}
 +</WRAP>
 +</WRAP>
 +
 +==== Quick reference ====
 +
 +  * **Emulator:** [[#moonlight|moonlight]]
 +  * **Folder:** ''/userdata/roms/moonlight''
 +  * **Accepted ROM formats:** ''.moonlight''
  
 ==== Prerequisites ==== ==== Prerequisites ====
Line 17: Line 37:
 These are the PC side prerequisites to enable Moonlight to fetch and stream your games: These are the PC side prerequisites to enable Moonlight to fetch and stream your games:
  
-  * NVIDIA GeForce GTX/RTX 600+ series GPU +  * AMD: VCE 1.0 or higher, see [[https://github.com/obsproject/obs-amd-encoder/wiki/Hardware-Support]] 
-  * NVIDIA GeForce Experience (GFE) 2.1.or higher installed (Windows Desktop Only) +  * Intel: VAAPI-compatible, see [[https://www.intel.com/content/www/us/en/developer/articles/technical/linuxmedia-vaapi.html]] 
-  * 720p or higher display (or headless display dongle) connected to the GeForce GPU.+  * Nvidia: NVENC enabled cards, see [[https://developer.nvidia.com/video-encode-and-decode-gpu-support-matrix-new]] 
 +  * AMD: Ryzen 3 or Intel: Core i3 or higher 
 +  * 4GB or more 
 +  * See [[https://docs.lizardbyte.dev/projects/sunshine/en/latest/about/overview.html#system-requirements]] for further details.
  
-If you are facing any issue, please take a look at the first topics inside [[https://github.com/moonlight-stream/moonlight-docs/wiki/Setup-Guide|Setup Guide]] at Moonlight wiki. They are focused on the installation at the PC site of this setup.+It is recommended you get acquainted with the Sunshine User manual for the best experience - [[https://docs.lizardbyte.dev/projects/sunshine/en/latest/]]
  
-==== Initial Pairing====+If you are facing any issue, also take a look at the first topics inside [[https://github.com/moonlight-stream/moonlight-docs/wiki/Setup-Guide|Setup Guide]] at Moonlight wiki. They are focused on the installation at the PC site of this setup. 
 + 
 + 
 +==== Install Sunshine on the PC side ==== 
 + 
 +You need to install the Sunshine server on your gaming PC. This is the PC that will render the game assets and do all the heavy lifting. It will also compress the resulting video of the game played into a low-latency H.264 or HEVC video stream that will be sent to the Batocera Moonlight client. The Batocera Moonlight client only displays this content on the screen, and intercepts the controller actions to send them back to the Sunshine server. 
 + 
 +  - Download the Sunshine server corresponding to your gaming PC (they have Windows versions, both installer and portable, but also Linux packages for popular desktop Linux distributions, as well as Flatpak and Appimage versions). 
 +  - Launch Sunshine. Once the server is launched, you will see a message asking you to connect to a local URL to finish the configuration. Typically a URL like https://localhost:47990 -- don't forget to enable a security extension on your web browser if requested. 
 +  - choose a username (by default ''sunshine'') and a password. This will be required to login into the UI. 
 + 
 +==== Instructions for Batocera v43 and later ==== 
 +=== Onto your Batocera machine: enable moonlight-qt and configure from the UI === 
 + 
 +Moonlight requires a bit of manual configuration. In order to do that, you need to [[:access_the_batocera_via_ssh|connect to your Batocera with SSH.]] 
 + 
 +First, create a file ''Moonlight.moonlight'' in the ''moonlight'' rom directory. 
 + 
 +<code> 
 +# touch /userdata/roms/moonlight/Moonlight.moonlight 
 +</code> 
 + 
 +Reload your games in ES (from the UI: "Game Settings" -> "Update Gamelists") and then you can start "Moonlight" from the Moonlight system. 
 + 
 +On first launch, the Moonlight client will search for the Sunshine server(s) available on your network and present them. When a new server is found, it will present you with a code to enter in the Sunshine server to pair them together: 
 + 
 +{{ :systems:moonlight-qt.png?600 |}} 
 + 
 +==== Instructions for Batocera up to v42: initial pairing ==== 
 +=== Onto your Batocera machine: initial pairing ===
  
 Moonlight requires a bit of manual configuration. In order to do that, you need to [[:access_the_batocera_via_ssh|connect to your Batocera with SSH.]] Moonlight requires a bit of manual configuration. In order to do that, you need to [[:access_the_batocera_via_ssh|connect to your Batocera with SSH.]]
  
-First, make sure your PC is up and running and on the same local network as your Batocera.+First, make sure your PC with Sunshine is up and running and on the same local network as your Batocera machine.
  
 On Batocera box run: On Batocera box run:
Line 39: Line 91:
 </code>  </code> 
  
-This command correctly discovered my PC running NVIDIA GeForce Experience with its IP address 10.0.0.72, but tells me I need to pair with it. Let'do it:+This command correctly discovered my PC running Sunshine with its IP address 10.0.0.72, but tells me I need to pair with it. 
 +If you don't get an IP address, check you're on the same LAN or VLAN as the streaming server or you have inter-VLAN routing enabled. 
 +Although WAN connections are possible, it is not recommended. 
 + 
 +Now let'pair with it:
  
 <code> <code>
Line 47: Line 103:
 </code> </code>
      
-The PIN ''1234'' is an example, you'll get a different PIN in your setup. You have to enter this PIN in the GeForce Experience pop-up window of your PC running where it asks a PIN to connect a "SHIELD" device.+The PIN ''1234'' is an example, you'll get a different PIN in your setup. You have to enter this PIN in the Sunshine Server PIN menu option of your server PC, once you are logged into the Sunshine configuration webpage.
      
 Once the PIN is entered on you PC you should see ''Succesfully paired'' on your Batocera terminal. Once the PIN is entered on you PC you should see ''Succesfully paired'' on your Batocera terminal.
  
 You can check that the connection is successful by typing ''moonlight list'' again in your Batocera terminal, you should now see the list of games installed on your PC. You can check that the connection is successful by typing ''moonlight list'' again in your Batocera terminal, you should now see the list of games installed on your PC.
-    
  
-==== Moonlight initial configuration ====+=== Moonlight initial configuration ===
  
 We now need to build the list of games we want to reference. In order to do so, enter the command: We now need to build the list of games we want to reference. In order to do so, enter the command:
Line 73: Line 128:
  
 It also generated a list with all games available in ''/userdata/system/configs/moonlight/gamelist.txt'' It also generated a list with all games available in ''/userdata/system/configs/moonlight/gamelist.txt''
 +
 +You can also relaunch a new game scraping with the command ''batocera-moonlight scrape''.
  
  
 ==== Moonlight Configuration ==== ==== Moonlight Configuration ====
  
-The configuration directory for Moonlight is ''/userdata/system/configs/moonlight/''. The main configuration file there is ''moonlight.conf''Depending on your hardware configuration, you might want to tune the resolution, framerate or bitrate of the game streams.+Depending on your hardware configuration, you might want to tune the resolution, framerate or bitrate of the game streams. These and other Moonlight settings can be configured within Batocera from v34 by going to Advanced System Options. If you would like to enter alternate options not available through Advanced System Options you can save a file named "moonlight.conf" in the Moonlight configuration directory located at ''/userdata/system/configs/moonlight/''. An example of a moonlight.conf file can be found [[https://github.com/moonlight-stream/moonlight-embedded/blob/master/moonlight.conf|here]]. If a moonlight.conf file is present then settings set in Advanced System Options will not be applied.
  
-You can also relaunch a new game scraping with the command ''batocera-moonlight scrape''.+If you use an **Odroid Go Advance**, make sure you set the Preferred AV Decoder to "SDL" in Advance System Settings or add the line ''platform = sdl'' in the ''moonlight.conf'' configuration file, otherwise you'll have a screen rotated by 90 degrees.
  
 ==== Moonlight Shortcuts ==== ==== Moonlight Shortcuts ====
Line 106: Line 163:
 it can be safely ignored. It just means that Batocera couldn't get some data from theGamesDB, so there will be some metadata missing in your ''gamelist.xml''. Your games are still likely to be listed, though. it can be safely ignored. It just means that Batocera couldn't get some data from theGamesDB, so there will be some metadata missing in your ''gamelist.xml''. Your games are still likely to be listed, though.
        
 +==== Further troubleshooting ====
  
 +For further troubleshooting, refer to the [[:support|generic support pages]].
  
  • systems/moonlight.1622387103.txt.gz
  • Last modified: 5 years ago
  • by igno2k