时间:2024-5-20 作者:老大夫 分类: ARDUINO
https://www.bilibili.com/video/BV1RM4y1a7J5?p=7&vd_source=3c8c35a76bf8f011c75d2584ec4a3fda
// Basic Arduino Microcontroller empty code template
// The setup function runs once when you press Reset or power the board
//定义LED引脚
int led_pin = 5;
void setup() {
//设定引脚为输出模式
pinMode(led_pin,OUTPUT);
//点亮LED
}
// The loop function runs over and over again forever
void loop() {
digitalWrite(led_pin,HIGH);
delay(1000);
digitalWrite(led_pin,LOW);
delay(1000);
}
推荐阅读:
esp32-wroom-驱动CP2102
LED流水灯
按键实验
PWM实现呼吸灯效果
ADC数模转换
宏定义
使用platform IO 编译arduino时报错:collect2.exe: error: ld returned 1 exit status *** [.pio\build\uno\firmware.elf] Error 1
行动消除疑虑