setup()

[Sketch]

描述

The setup() function is called when a sketch starts. Use it to initialize variables, pin modes, start using libraries, etc. The setup function will only run once, after each powerup or reset of the 86Duino board.

Example Code

int buttonPin = 3;
 
void setup()
{
  Serial.begin(9600);
  pinMode(buttonPin, INPUT);
}
 
void loop()
{
  // ...
}

語法參考主頁面

86Duino 參考的文本是根據 Creative Commons Attribution-ShareAlike 3.0 License,部分文本是從the Arduino reference修改的。 參考中的代碼示例已發佈到公共領域。

發表評論

上部へスクロール