Results for “LED_BUILTIN”
Small, practical examples. Search by task or narrow things down below.
Turn on the built-in LED
Configure the Uno’s LED pin as an output and drive it high.
LED_BUILTIN✓ Tested
Give an LED pin a constant name
Arduino / C: Use const to name the built-in LED pin and reuse it in output instructions.
Arduino / C✓ Tested
Blink the built-in LED three times
Alternate the built-in LED with a short blocking delay.
blink✓ Tested
Capture output while handling a failed command
Bash Scripts: An assignment inherits the status of its command substitution, allowing both output and status to be handled.
Bash Scripts✓ Tested
Change an LED delay with a variable
Arduino / C: Assign a new value to a variable to change the next LED pulse duration.
Arduino / C✓ Tested
Check for an installed command
Bash Scripts: command -v checks command resolution without assuming a specific installation path.
Bash Scripts✓ Tested
Choose a local file through a labeled control
HTML: A file input exposes selected file metadata to the page without providing arbitrary filesystem access.
HTML✓ Tested
Control an LED from a button
Translate an active-low button input into an LED output.
button✓ Tested
Count five LED flashes with a for loop
Arduino / C: Repeat an LED action a known number of times and print the current count.
Arduino / C✓ Tested
Divide decimal values with controlled precision
Java: Choose both scale and rounding for a quotient that does not terminate in base ten.
Java✓ Tested
Draw a basic rectangle on a labeled canvas
HTML: Canvas requires script to draw pixels; provide alternative content and an accessible label.
HTML✓ Tested
Drive the built-in LED low after turning it on
Arduino / C: digitalWrite changes the actual output level of a configured pin.
Arduino / C✓ Tested