Simon Says Game (Patrick Groh)

I worked on my Simon game with Emily and Bikel, and we encountered many problems with our game. The hardware itself was fairly straightforward, as it was only 4 buttons and 4 lights that were very easy to solder together to make a simple circuit. I tested these with some very “Hello World” functions, where if the button was pressed the light would turn on just to make sure that the hardware was working fine. The one problem we found that we could not fix appeared to be an issue with debouncing, where we could get a rough program to work with digitalRead but once we went to debouncer it would not register any button presses, even when tested with Serial.println. It also does not want to swap states for some reason, as if it gets stuck in either START or LIGHT_BLINK. We ended up getting desperate and copying the example code verbatim, but that didn’t quite fix our problem.

More troubleshooting later, we realized that after pulling up a button that there was an improperly soldered joint for a button,  which might have messed up the code making the button think it was getting pressed at random times or not at all, possibly due to the implementation of INPUT_PULLUP instead of just INPUT. This was later fixed and we were able to figure out how to get the function working at a basic level, although it ran into a problem that only the first light of a sequence would light up. Emily was able to realize that it was a problem with the lights being turned on by pressing the buttons and figuring out what was actually going on, since we had the pre-programmed initializing pattern still in the code.

Our hardware was fairly simple, with only 4 buttons and 4 LEDs, with all of the buttons originating from the 5V pin and individually going into the 2, 3, 4, and 5 pins of the Arduino. The LEDs were all getting their power from the 8, 9, 10, an 11 pins of the arduino and soldered together for a common ground. The enclosure around it was a foam core cylinder that was painted 4 colors to match the 4 light colors we had.

First off we hae a video of my struggle to get buttons to work, partially caused by bad soldering.

We have a video of what we could get working, demonstrated by Emily.


Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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 )

Connecting to %s