Gpio button

From Box Of Stops Online Help
Jump to: navigation, search

One special feature of the Raspberry Pi is its GPIO, or General Purpose Input/Output connector. This is the strip of pins that runs along one side of the Pi, which acts as a connector to a number of physical inputs or outputs.

This ability to wire up custom physical inputs, switches or buttons, is part of the reason Box Of Stops was written for the Raspberry Pi. Perfect for a bit of DIY organ building.

Setting up a Gpio input

There is a section on Customizing the Raspberry Pi on the main website. Adding buttons to the Pi is an important part of many hobby projects, so please browse the wealth of information available on this topic, maybe starting here.

Once you have wired up a Gpio button, this can be used to control Box Of Stops in exactly the same way as any other Trigger.

In Configuration mode, if you click the Plus.png icon to add a trigger to a Stop, Coupler or Combination in the usual way, then the screen will wait for you to press the new input button. Assuming everything has been wired up correctly, the screen will then confirm which button you pressed.

Plugging in a breakout board

The other possibility is dedicated Gpio board like the Status Board from The Pi Hut. This comes pre-wired with sockets for buttons, and LEDs to indicate which controls are active.

Sharing Gpio inputs with another application on the Pi

By default Box Of Stops will assume it is the only application running on the Raspberry Pi that needs to access the Gpio inputs, and take input from all 17 of them.

To share the inputs with another application, please look in the Application properties for Box Of Stops. The pi.input.pins property can be used to define which pins Box Of Stops should open - more details in the application.properties.default file.