tony619
Published

Incognito Glasses

9 volt powered incognito glasses, inspired by MacGyver, that block out any security camera that does not have an IR filter.

IntermediateShowcase (no instructions)908
Incognito Glasses

Things used in this project

Hardware components

DigiSpark
DigiSpark
×1
LED, Infrared
LED, Infrared
×1
MOSFET Transistor, Switching
MOSFET Transistor, Switching
×1
Resistor 220 ohm
Resistor 220 ohm
×1
Resistor 10k ohm
Resistor 10k ohm
×2
Battery, 9 V
Battery, 9 V
×1
9V Battery Clip
9V Battery Clip
Full battery holder could be easier but not necessary
×1
Lab glasses/goggles
×1
ESD Tape, Masking
ESD Tape, Masking
×1

Software apps and online services

Arduino IDE
Arduino IDE

Hand tools and fabrication machines

Soldering iron (generic)
Soldering iron (generic)
Solder Wire, Lead Free
Solder Wire, Lead Free

Story

Read more

Schematics

Tinkercad circuit

Sketch 1

Sketch 2

Code

CODE

Arduino
There are two integers in the code. These are “buttonState” and “buttonCounter”. These integers are used to represent the pressing of the push button. The commands digital read and digitalwrite are used to read the voltages from the pushbutton to then tell whether or not to turn the leds on.
int buttonState = 0;
int buttonCounter = 0;
void setup()
{
  pinMode(0, OUTPUT); // Transistor
  pinMode(1, INPUT); // Read Pushbutton

}

void loop()
{
  do {

    buttonState = digitalRead(1); // check button

    if (buttonState == HIGH) {
      buttonCounter++;
    }

  } while (buttonState == LOW);



  do {

    buttonState = digitalRead(1);

  } while (buttonState == HIGH);



  if (buttonCounter == 1) { // If buttonCounter = 1, turn on leds
    digitalWrite(0, HIGH);
  }

  else if (buttonCounter == 2) { // If buttonCounter = 2,turn off leds
    digitalWrite(0, LOW);
    buttonCounter = 0;
  }
  delay(20); // helps with simulation
}

Credits

tony619
1 project • 0 followers
Contact

Comments

Please log in or sign up to comment.