Advanced Arduino Robotics Project #4, Arduino based Fastest Figure First Controlling System for Quiz Competition

With this system we can detect the Arduino based Fastest Figure First Controlling System for Quiz Competition conducted in schools & colleges. For this project you require following components.

Required Components

  1. Arduino UNO/Nano – 1
  2. 5mm Red LEDs – 5
  3. 10mm Red LEDs – 5
  4. RC sockets – 5
  5. RC pins – 5
  6. 1k, 330ohm resistors
  7. 12V adapter socket – 1
  8. 12V DC Adapter – 1
  9. 9V, 1A transformer – 1
  10. 1N4007 diodes – 2
  11. Regulator IC 7805 – 1
  12. 1000uF capacitor – 2
  13. Small size zero PCB – 1
  14. PVC boxes 10” x 12” – 2
  15. PVC boxes 4” x 4” – 5
  16. Push-to-on switches – 5
  17. Connecting wires, etc.

Circuit Diagram of the Project

image 4 Vidyasagar Academy Akola

IMPORTANT NOTE: This code of this project is so designed that there is no need for resetting the fastest finger first result, each time, when the competitors press their buttons. The circuit automatically resets itself after 5 seconds and then gets ready for next round.

Practical Guide Video

Prototype Gallery

Pin Configuration Details of Arduino Nano

Comparison of Arduino Nano with Arduino Uno

The following diagram shows the pin configuration details of Arduino Nano with Arduino Uno. You can use either Arduino Nano or Arduino Uno in this project. Be careful to use the particular microcontroller board. Refer this diagram and change the coding lines accordingly.

Comparison of Arduino UNO Nano Vidyasagar Academy Akola

The Code

/* This code was developed by Vidyasagar Academy Akola,
 * www.vsa.edu.in
 * License: You can use it for any purpose as long as you don't 
 * claim that you are its author and
 * you don't alter License terms and 
 * formulations (lines 1-9 of this file). 
 * Project: The 5 Channel Quiz Controlling System with auto reset using Arduino nano
 * Date of Creation: 17.02.2020
*/

/*    
    ======= Connection details =======
    Switches connections: 
    player1: A0, player2: A1, player3: A2, player4: A3, player5: A4
    LED1: pin-D2, LED2: pin-D3, LED3: pin-D4, LED4: pin-D5, LED5: pin-D6
    Buzzer: pin-D7
*/

int x=1;
int LED1=2;
int LED2=3;
int LED3=4;
int LED4=5;
int LED5=6;
int buzzer=7; 

void setup() 
{
  pinMode(A0,INPUT); // player1 switch input
  pinMode(A1,INPUT); // player2 switch input
  pinMode(A2,INPUT); // player3 switch input
  pinMode(A3,INPUT); // player4 switch input
  pinMode(A4,INPUT); // player5 switch input 
  
  pinMode(LED1,OUTPUT);
  pinMode(LED2,OUTPUT);
  pinMode(LED3,OUTPUT);
  pinMode(LED4,OUTPUT);
  pinMode(LED5,OUTPUT);

  pinMode(buzzer,OUTPUT);
  reset();
  delay(1000);
  reset();
  delay(1000);
  reset();
  delay(1000);
  reset();
  delay(1000);
}

void loop() 
{
  int a=digitalRead(A0);   // reading pin values for 5 buttons
    int b=digitalRead(A1);
      int c=digitalRead(A2);
        int d=digitalRead(A3);
          int e=digitalRead(A4);
                       
  if(a==LOW) // if player1 presses button
  { 
    if(x==1) // check if x is 1, if yes then execute the code
    {
      digitalWrite(buzzer,HIGH); // buzzer alert that a switch is pressed
      digitalWrite(LED1,HIGH); 
      x++;
      
      delay(3000);
      digitalWrite(buzzer,LOW);
    }
  }

  if(b==LOW) // if player2 presses button
  { 
    if(x==1) // check if x is 1, if yes then execute the code
    {
      digitalWrite(buzzer,HIGH); // buzzer alert that a switch is pressed
      digitalWrite(LED2,HIGH); 
      x++;

      delay(3000);
      digitalWrite(buzzer,LOW);
    }
  }

  if(c==LOW) // if player3 presses button
  { 
    if(x==1) // check if x is 1, if yes then execute the code
    {
      digitalWrite(buzzer,HIGH); // buzzer alert that a switch is pressed
      digitalWrite(LED3,HIGH); 
      x++;

      delay(3000);
      digitalWrite(buzzer,LOW);
    }
  }

  if(d==LOW) // if player4 presses button
  { 
    if(x==1) // check if x is 1, if yes then execute the code
    {
      digitalWrite(buzzer,HIGH); // buzzer alert that a switch is pressed
      digitalWrite(LED4,HIGH); 
      x++;

      delay(3000);
      digitalWrite(buzzer,LOW);
    }
  }

  if(e==LOW) // if player5 presses button
  { 
    if(x==1) // check if x is 1, if yes then execute the code
    {
      digitalWrite(buzzer,HIGH); // buzzer alert that a switch is pressed
      digitalWrite(LED5,HIGH); 
      x++;

      delay(3000);
      digitalWrite(buzzer,LOW);
    }
  }

   if(x==2)
   {
      delay(6000);
      digitalWrite(LED1,LOW);
      digitalWrite(LED2,LOW);
      digitalWrite(LED3,LOW);
      digitalWrite(LED4,LOW);
      digitalWrite(LED5,LOW);
      delay(4000);
      reset();
      delay(1000);
      reset();
      delay(1000);
      x=p;
   }
}

  void reset()
  {
    for(int i=0;i<4;i++)
    {
    digitalWrite(LED1,HIGH);
    digitalWrite(LED2,HIGH);
    digitalWrite(LED3,HIGH);
    digitalWrite(LED4,HIGH);
    digitalWrite(LED5,HIGH);
    digitalWrite(buzzer,HIGH);
    delay(100);
    digitalWrite(LED1,LOW);
    digitalWrite(LED2,LOW);
    digitalWrite(LED3,LOW);
    digitalWrite(LED4,LOW);
    digitalWrite(LED5,LOW);
    digitalWrite(buzzer,LOW);
    delay(100);
    }
  }

Learn Basics of Arduino Nano

Arduino Nano is a microcontroller board designed by Arduino.cc. The microcontroller used in the Arduino Nano is Atmega328, the same one as used in Arduino UNO. It has a wide range of applications and is a major microcontroller board because of its small size and flexibility.

Download PDF file to understand complete details of Arduino Nano

Share on your network!
Dattaraj Vidyasagar
Dattaraj Vidyasagar

Author on this website. He is veteran of Core Electronics since last 36+ years. ATL Mentor of Change, Niti Ayog, Govt. of India, Google Certified Educator, International Robotics Trainer and author of 18 books on electronics, robotics, programming languages and web designing... ➤➤

6 Comments

  1. I like what you guys are up too. Such intelligent work and reporting! Keep up the excellent works guys I’ve incorporated you guys to my blogroll. I think it’ll improve the value of my website 🙂

  2. The logic behind the coding of this project is excellent.
    Taking a variable and making its value change at the hit of a button is really appreciated.

Leave a Reply

Your email address will not be published. Required fields are marked *