Q9

Week 9 Quiz

Arduino Digital I/O and Sensors

Student Information

Question 1: Multiple Choice (2 points)

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

Question 2: Multiple Choice (2 points)

Which function reads the value from a digital pin?

Question 3: Short Answer (3 points)

Write Arduino code to read a button connected to pin 2 and turn on an LED on pin 13 when the button is pressed:

Question 4: True/False (2 points)

A pull-up resistor is used to ensure a digital input pin reads HIGH when no button is pressed.

Question 5: Multiple Choice (1 point)

What does PWM stand for in Arduino programming?

← Back to Lesson Semester Overview Next Lesson →