Connecting devices on stage using Google Nearby (V5.x.x)

If you have multiple devices on stage running OpenSongApp you can now connect them using Google Nearby which is built into the app.   This allows you to have one device act as a host that controls multiple other devices.  You can change songs, sections and transmit songs stored on the host to clients (who can view and even copy them to their library).  

The host and client devices can be in the same or different modes to each other.  E.g. a host could be the device connected to the projector and the clients are the on stage devices.  Alternatively, the band leader could be the host sending the song and sections from their stage mode to a client device running presentation mode that is connected to a projector and other client devices running performance mode on stage.


Here is a short video demonstration courtesy of Jeremiah, which is based on a slightly older version of the app, but the features are shown nicely with the host device in this case running Presentation mode and four client devices running Performance mode.

In order to make connections, you will need to allow Location permissions (this is part of the Bluetooth permission that is used to find other nearby devices).  Google Nearby will use a combination of Bluetooth, Bluetooth LE and WiFi to make connections.  Devices don't need to have WiFi or Bluetooth turned on and they do not need to be connected to a WiFi router, or be on the same network - Google Nearby will make its own connection!

Open the options menu and select the 'Connect devices' setting.  If permission has not already been given for locations permissions (for Bluetooth), you will need to grant permission and open the menu again.

You will then see the connections options.  By default the app will use your device nickname (often from Bluetooth), however, you can change your device name by clicking on the name in the Connect Devices menu.

Host

At least one device must be set to be the host (controlling device).  

If you only want to accept new clients when on this menu (i.e. not receive requests during a performance), you can switch on the option to only listen for connections when this page is visible.

Hosts will continuously broadcast a service while the app is open.

Client

Once the host has started broadcasting/advertising, the client devices are now ready to make connections.  

Receiving / Keeping host songs

Host

The host device always broadcasts the following information:

The host does not need to switch on the additional settings show below .


Client

The client device by default will listen for the above information and try to load the song using the folder and filename received.   If the client doesn't have the song, they will see the error message that the song doesn't exist on their device.  Client devices have the following options, depending on what they want to do:

Changing the host/client

Once a connection has been established, the host can easily be changed.  Simply switch the 'Act as host' switch on on the desired device.  Multiple devices can act as hosts if required, but only devices that are acting as clients will receive song information.

Close the connection

To close the connection, select the 'Off' option in the connections menu.