APEX & Raspberry Pi Game

This is a proof of concept for a multiplayer game in Oracle APEX. Players log into an APEX application and choose a team (Blue/Red). Then the game presents each player with a page and a randomly chosen math problem. The page however is “locked” by a modal page telling the player that the game is paused.

The button the the Raspberry Pi controls the game state: Stopped, Ready, Running. When the game is stopped or ready, the player’s screens are blocked with the modal window.

A breadboard with a LED and two buttons is connected to the Raspberry Pi (the blue button doesn’t do anything).

The red button cycles through the games states. When the game is in Running state, the modal window goes away, and the players can answer the math question. When the button is pressed again, the game goes into Stopped state, and the modal window pops up, preventing the players from answering more questions.

In addition, the LED also shows the game state: Off- game stopped, Blinking – ready, On – running.

The interaction between the Raspberry Pi and APEX is done through Node.js utilizing Node4ORDS and socket.io.

This video shows me cycling through the three game states. There are four players connected: Red team on phones, Blue team on separate browsers.
At first the game is Stopped (LED off, modal window up), the first button press puts the game in Ready state (LED blinks, modal window up). The second button press puts the game in running state (LED on, modal window disappears). The final button press puts the game back int Stopped state (LED off, modal window up).

[youtube https://www.youtube.com/watch?v=v7ze56dbotQ&w=560&h=315]

2 thoughts on “APEX & Raspberry Pi Game

  • March 1, 2016 at 3:48 pm

    it would be interesting to get a good tutorial about this project in order to practise wey well

  • March 1, 2016 at 4:55 pm

    I’m working on it. I’ve just been too busy to post more. Please stay tuned. 🙂

Comments are closed.