参考
結果
プログラム
//Grove_Relay_1S_M5NanoC6_1
// the setup function runs once when you press reset or power the board
void setup() {
// initialize digital pin as an output.
pinMode(1, OUTPUT); //1 = G1
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(1, HIGH); // turn the on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(1, LOW); // turn the off by making the voltage LOW
delay(1000); // wait for a second
}