作者lhz135 (PPP)
看板Electronics
標題[問題] nodeMCU在arduinoIDE的腳位定義
時間Sun Jan 5 02:05:46 2020
各位大嘍 想請教node MCU腳位的定義是多少呢?
如下述引用的網址中的nodemcu腳位
https://www.est.idv.tw/nodemcubme280建立氣象收集站並傳送到wunderground/
又如下的程式範例
LED_BULTIN腳位定義如(4 或D4 或GPIO或TXD1都不能取代LED_BULTIN)
請教該怎麼在程式碼中定義該D4腳呢?
謝謝
void setup() {
pinMode(LED_BUILTIN, OUTPUT); // Initialize the LED_BUILTIN pin as an output
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(LED_BUILTIN, LOW); // Turn the LED on (Note that LOW is the voltage level
// but actually the LED is on; this is because
// it is active low on the ESP-01)
delay(1000); // Wait for a second
digitalWrite(LED_BUILTIN, HIGH); // Turn the LED off by making the voltage HIGH
delay(2000); // Wait for two seconds (to demonstrate the active low LED)
}
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 111.243.146.116 (臺灣)
※ 文章網址: https://webptt.com/m.aspx?n=bbs/Electronics/M.1578161149.A.659.html
1F:→ lhz135: 找到了 估計是板子選錯了 拍謝~ 01/06 01:15