Skip to content
ショップ

Blink

Turns on and off the LEDs on the AVR MCU leaf every second.

Use the following leaves.

TypeNameQ’ty
AZ62Connector Cover1
AZ01USB1
AP01AVR MCU1
AV01CR20321
CR2032 coin cell battery1
M2*10mm screw2

Let’s assemble leaves as shown in the figure below.

assemble1

Write the following program in the Arduino IDE.

//=====================================================================
// Blink
//
// (c) 2020 Trillion-Node Study Group
// Released under the MIT license
// https://opensource.org/licenses/MIT
//
// Rev.00 2020/05/05 First release
//=====================================================================
void setup() {
// LEDピンを出力ピンに設定
pinMode(LED_BUILTIN, OUTPUT);
}
void loop() {
digitalWrite(LED_BUILTIN, HIGH); // LEDを点灯
delay(1000); // 1秒待つ
digitalWrite(LED_BUILTIN, LOW); // LEDを消灯
delay(1000); // 1秒待つ
}

Blink.ino

The LED on the AVR MCU leaf turns on and off every 1 second.