Arduino TKJHAT
Arduino library for Pico HAT extension board
Loading...
Searching...
No Matches
Led.ino
1
/*
2
LED Example
3
4
This example demonstrates how to use the TKJHAT library to control an LED.
5
The LED will toggle on and off every second.
6
7
Circuit:
8
- LED integrated in Pico HAT
9
10
created 2026
11
*/
12
13
#include "TKJHAT.h"
14
15
TKJHAT
hat;
// Create an instance of the TKJHAT class to access the LED
16
17
// LED initialization
18
void
setup() {
19
hat.
led
.
begin
();
20
}
21
22
// In this loop, we will toggle the LED on and off every second
23
void
loop() {
24
hat.led.toggle();
25
delay(1000);
26
}
Led::begin
void begin()
Initialize the LED.
TKJHAT
Main interface for accessing TKJHAT board features.
Definition
TKJHAT.h:35
TKJHAT::led
Led led
Onboard LED.
Definition
TKJHAT.h:44
examples
Led
Led.ino
Generated by
1.16.1