Tutorial – Adding GPIO to a Radiobuttonshow

Greg Reynolds from the Canadian Air and Space Museum in Ottawa has provided a tutorial on how add GPIO based buttons to a Radiobuttonshow. He provides much useful information which is not immediately obvious from the manual including the directory structure of Pi Presents. He takes you through editing gpio.cfg and a copy of the pp_radiobuttonshow_1p3 example profile to show how to set up the control path between a button click and a video playing.

The tutorial is applicable to Version 1.3 (gapless). Version 1.2 (next) has detailed differences but the genral principles are the same.

The tutorial is a pdf document which can be found here

Advertisements

4 Responses to Tutorial – Adding GPIO to a Radiobuttonshow

  1. Fernando Har says:

    Hello Ken,

    Thank you for the great software! I am using this for an Expo in Hong Kong for elderly health care support.

    I am using Pi3, Jessie, gapless version. In my profile, my “start show” is a “radiobuttonShow”. In the radiobuttonshow’s control tab I defined the mapping in which GPIO plays my tracks. (Total three tracks). Each go my tracks are “mediashow”, and each mediashow contains images. Everything goes well, I can start pipresent with my profile, and pressing GPIO buttons jumps to different tracks.

    However, I am having problem trying to make another GPIO button that performs “pp-up” or “pp-down” for moving between images when my mediashow is playing. Is that a limitation to the software or I have misconfigured my profile? Many thanks.

    Fernando Har

    • KenT says:

      Hi
      Its a limitation of a radiobuttonshow.
      In all other types of show input events are passed down to the lowest level subshow.
      However in a radiobuttonshow the above means that during the running of a show track it is not possible to interrupt it and run an alternative track, which is the primary feature of a radiobuttonshow. So in a radiobuttonshow subshows will have no controls.

      You can have one or the other but not both.
      You can change the behaviour in pp_radiobuttonshow to give control to subshows by commenting and uncommenting the lines in

      def handle_input_event(self,symbol):

      around line 136. If you do this you will lose the ability to interrupt the show to select another track during a show.

      I think I need to make the alternatives an option in the profile in the next release.

  2. Thank you for this tutorial. I am trying to use this to set up buttons to change images not videos but I don’t know what syntax to use under Controls. For video he used “play” what do you use for an image? I’ve tried several guesses and when I run Validate I get “error – incorrect number of fields in control”.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s