HELP! Passcode enabled blinking LEDs w/ arduino uno

Discussion in 'Programmer's Corner' started by habarabadabas, Aug 21, 2014.

  1. habarabadabas

    Thread Starter New Member

    Apr 16, 2014
    we were to do a program where we set a passcode (ex. 1-2-3) in order to activate the blinking of LEDs, and so far we're stumped! the program allows the leds to blink when we press only one key of the passcode (p.s. we are using tact switches as push buttons). we have used counters as an alternatove but still no go. :confused:

    here's our code:

    View attachment arduinoCode.txt
  2. shteii01

    AAC Fanatic!

    Feb 19, 2010
    Your buttons are set as outputs. That does not make sense.
    Your LED pins are outputs, you got that.
    Your buttons are inputs.
    pinMode(pushButton, INPUT);