RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login
    Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

    Tell another device what game is playing

    Scheduled Pinned Locked Moved Help and Support
    retropie 4.7.1emulationstatonscriptingaddons
    3 Posts 3 Posters 906 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • N
      nohitter151
      last edited by

      I'm wondering what options exist, if any, to tell another device on my home network what game is being played on my retropie. I see that emulationstation supports scripting, and I assume that I could go about doing what I want that way, but I'm wondering whether someone has already done the leg work to accomplish this.

      For my particular use case I would like to publish info on what is currently happening on my Retropie (eg. game is playing, screensaver running, etc.) to home assistant which is running on a server in my home network. I would also like to be able to pull the artwork from the currently playing game to display in Home Assistant.

      I appreciate any insights you have to help me accomplish this.

      BuZzB 1 Reply Last reply Reply Quote 0
      • BuZzB
        BuZz administrators @nohitter151
        last edited by BuZz

        @nohitter151 See https://retropie.org.uk/docs/Runcommand/#runcommand-scripts

        Could add a script which sends some data elsewhere on launch.

        Also what is being run is logged in /dev/shm/runcommand.info on launch. In the format

        SYSTEM
        EMULATOR
        ROM
        COMMAND
        

        To help us help you - please make sure you read the sticky topics before posting - https://retropie.org.uk/forum/topic/3/read-this-first

        1 Reply Last reply Reply Quote 0
        • LolonoisL
          Lolonois
          last edited by

          @nohitter151 There is also a different way. ES has script callouts for some events: https://retropie.org.uk/docs/EmulationStation/#scripting

          Put your scripts in your favorite language in the respective folder. Make them executable (chmod a+x <script>) and you should be ready to go. With the values of %rom_path% %rom_name% (first and second parameter inputted to your script you can locate the respective entry in the gamelist.xml which leads you to the artwork.

          PS: Welcome to this forum :)

          1 Reply Last reply Reply Quote 0
          • First post
            Last post

          Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

          Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.