Programming Concepts in Arduino

Programming Concepts in Arduino

8th Grade

15 Qs

quiz-placeholder

Similar activities

Y9 Microbit

Y9 Microbit

8th - 9th Grade

10 Qs

Arduino - P2uur - deel 2

Arduino - P2uur - deel 2

6th - 12th Grade

12 Qs

Solar Lamp Project

Solar Lamp Project

8th Grade

16 Qs

ICT 2 - I/O Devices

ICT 2 - I/O Devices

6th - 10th Grade

20 Qs

Microbit 3

Microbit 3

6th Grade - University

10 Qs

MP2-3wks.Test-IM

MP2-3wks.Test-IM

8th Grade

10 Qs

prep2 lesson 1-2

prep2 lesson 1-2

8th Grade

20 Qs

Saklar | Push Button

Saklar | Push Button

8th Grade

10 Qs

Programming Concepts in Arduino

Programming Concepts in Arduino

Assessment

Quiz

Computers

8th Grade

Hard

Created by

jesmar santillan

Used 1+ times

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What function is used to configure a pin as an input or output in Arduino?

digitalRead()

pinMode()

digitalWrite()

analogRead()

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In the code digitalRead(2), what does the number 2 represent?

The button state

The LED pin

The pin number connected to the button

The value to write to the pin

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of a pull-down resistor in a button circuit?

To increase the brightness of the LED

To keep the button pin in a known state when not pressed

To prevent the button from bouncing

To reduce the current flowing through the LED

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which function is used to turn an LED on or off in Arduino?

pinMode()

digitalWrite()

delay()

digitalRead()

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

If a button is pressed, what value is read using digitalRead()?

0

1

LOW

HIGH

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In the code snippet below, what is the purpose of the if statement?

if (buttonState == HIGH) {

digitalWrite(ledPin, HIGH);

}

To configure the LED pin as an output

To read the button state

To turn on the LED when the button is pressed

To toggle the state of the button

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will happen if a delay is added inside the loop function?

It will increase the brightness of the LED.

It will prevent the button from working.

It will slow down the execution of the loop.

It will turn off the LED automatically.

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?