wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Arduino programing

Total questions: 31

Worksheet time: 18mins

Name
Class
Date
1.

How do you write a pinmode function correctly

(a)  

2.

What is one way you begin the Serial monitor correctly?

a)

serial.begin(9600)

b)

Serial.println(msg);

c)

Serial.print()

d)

Serial.begin(9600);

3.

Can you change the name of an int?

a)

No

b)

Yes

c)

Only sometimes

d)

Always

4.

How do you write a string variable?

(a)  

5.

What is a way without using a string that you can display text?

(a)  

6.

Is the labeling of the breadboard correct?

a)

Yes

b)

No

7.

What is a float?

a)

A decimal number

b)

a whole number

c)

a int

d)

a float

8.

What is this circuit componet?

a)

led

b)

LED

c)

RGB led

d)

RGB LED

9.

What function turns an led on?

a)

digitalRead( led1, High);

b)

digitalWrite(led1, HIGH)

c)

DigitalWrite(led1, HIGH);

d)

digitalWrite(led1, HIGH);

10.

What function slows down code or an object?

a)

a delay

b)

a wait

c)

a stop

d)

a hold

11.

How do you turn an led off?

a)

digitalWRite(led1, LOW);

b)

writeDigital(led1, LOW):

c)

Serial.begin(9600);

d)

digitalWrite(led1, OFF);

12.

int LED1= 4;

What statement is this?

a)

Void Loop

b)

Void Setup

c)

Declaration

d)

C language

13.

int LED1=4;

What is 'int= integer' used for?

a)

Alphabets

b)

Capital and small letters

c)

Combination of Numbers and Alphabets

d)

Numbers

14.

int LED2=8;

What is number eight is referring in the coding above?

a)

Analog Pin

b)

5V

c)

Ground

d)

Digital Pin

15.

LED is setup-up to blink. LEDs is an

a)

Output

b)

Input

c)

pinMode

d)

digitalWrite

16.

delay (1000);

1000 in delay is equivalent to how many second?

a)

10s

b)

2s

c)

60s

d)

1s

17.

digitalWrite (LED1, HIGH);

delay(1000);

digitalWrite (LED1, LOW);

What does the program do?

a)

LED Switch Off at the beginning, wait for 60s and then switch ON.

b)

LED Switch ON at the beginning, wait for 10s and then Switch OFF.

c)

LED Switch ON at the beginning, wait for 1s and then switch ON.

d)

LED Switch ON at the beginning, wait for 1s and then switch OFF.

18.

R1: int Led1=4;

R2: void setup(){

R3: digitalWrite (LED1, High);

R4: }

LED1 was not declared above void setup. Which row is the error?

a)

R1

b)

R2

c)

R3

d)

R4

19.
A function is a series of programming statements that can be called by name. Which command is called repetitively over and over again as long as the Arduino has power.
a)
loop()
b)
setup()
c)
(output)
d)
(input)
20.

A==7 means

a)

A is equal to 7

b)

7 is assigned as an int A

c)

A is not equal to 7

d)

A is greater than 7

21.
A function is a series of programming statements that can be called by name. Which command is called repetitively over and over again as long as the Arduino has power.
a)
loop()
b)
setup()
c)
(output)
d)
(input)
22.

int Led1=4;

void setup(){

digitalWrite (LED1, High);

}

Find the errors?

a)

LED 1

b)

DigitalWrite

c)

HIGH

d)

Void Setup

23.

What is one correct way of reading a value of a potentiometer without using the Serial montior?

a)

int potPin = A0;

int potVal = 13;

void setup(){

pinMode(potPin, OUTPUT);


}

void lop(){

potPin = analogWrite(potPin)

}

b)

int potPin = A0;

int potVal;


void setup(){

pinMode(potPin, INPUT);


}


void loop(){

potVal = analogRead(potPin);


}

24.

Do you have to assign a number to an int all of the time or can you just declare it like this int redled;?

a)

Yes, you have to assign a value

b)

No, you don't have to assign a value

25.

What function is used to read an analog Pin?

Hint: a function includes ()

(a)  

26.
What is an LED?
a)
a light
b)
a light emitting diode
c)
a part of a circuit
27.
The (+) column on your breadboard represents the positive charge or power to your circuit.
a)
True
b)
False
28.
The (-) column on your breadboard represents the ground.
a)
True
b)
False
29.
In the RGB LED, the R stands for ___________
a)
Ready
b)
Red
c)
Read only
30.
An output is something that happens when a circuit is in use.  An example of an output is:
a)
Light flashing
b)
Buzzer sounding
c)
Temperature being given
d)
All of the answers are correct
31.

Which of the following are outputs?

a)

LED

b)

Push Button

c)

Photoressitor