top of page

LEGO MINDSTORMS Robot Inventor

Slot Machine

This slot machine model has 3 wheels, each with 4 different positions. Each wheel has a white "7", a colored "fruit" (cherry, lemon, or grapes), and two black blanks. Try your luck by pulling the lever to spin the wheels and see if you can get a winning combination.


You start with 15 credits, each spin costs 5 credits, and various combinations pay back different amounts (see the payback chart below). This program displays the number of credits you have left before each spin, then shows a green light and waits for you to pull the lever to spin the wheels. After the wheels stop, your payback is computed and animated as a series of "coin" pixels on the display. Your new credit count is displayed and then the game repeats.


If you run out of money and don't have at least 5 credits for another spin, a red light is shown and the lever is locked. Press the left arrow button on the hub to reset to 15 credits and play again.


Like a real slot machine, the odds are worked out so that you will lose money overall on average... See the payback spreadsheet image to see how the average payback works out to 94%.


But... one of the two programs has a hidden cheat where you can force a "Triple 7" jackpot if you do the right action at the right time! You will have to study the programming code to find out what it is...

Building Instructions

Slot Machine

Payback Chart

Programming

bottom of page