Arduino Programming Notebook
written an compiled by Brian W. Evans
?
With information or inspiration taken from:
http://www.arduino.cc
http://www.wiring.org.co
http://www.arduino.cc/en/Booklet/HomePage
http://cslibrary.stanford.edu/101/
?
Including material written by:
Massimo Banzi
Hernando Barragan
David Cuartielles
Tom Igoe
Daniel Jolliffe
Todd Kurt
David Mellis
and others
?
Published:
First Edition August 2007
?
This work is licensed under the Creative Commons
Attribution-Noncommercial-Share Alike 3.0 License.
?
To view a copy of this license, visit:
http://createivecommons.org/licenses/by-nc-sa/3.0/
Or send a letter to:
?
Creative Commons
171 Second Street, Suite 300
San Francisco, California, 94105, USA
?
?
contents
structure
structure
setup()
loop()
functions
{} curly braces
; semicolon
/*... */ block comments
// line comments
variables
variables
variables declaration
variable scope
datatype
byte
int
long
float
arrays
arithmetic
arithmetic
compound assignments
comparison operators
logical operators
constants
constants
true/false
high/low
input/output
flow control
if
if... else
for
while
do... while
digital i/o
pinMode(pin, mode)
digitalRead(pin)
digitalWrite(pin, value)
analog i/o
analogRead(pin)
analogWrite(pin, value)
time
delay(ms)
millis()
math
min(x,y)
max(x,y)
random
randomSeed(seed)
random(min, max)
serial
Serial.begin(rate)
Serial.println(data)
appendix
digital output
digital input
high current output
pwm output
potentiometer input
variable resistor input
servo output
โน๊ตบุ๊คโปรแกรม Arduino เขียนเรียบเรียงโดยไบรอันอีแวนส์ W. ? ด้วยข้อมูลหรือแรงบันดาลใจในการดำเนินการ วัสดุที่เขียนโดย: Massimo Banzi เฮอร์นานโดราCuartielles เดวิดทอม Igoe โจลิฟฟ์แดเนียลทอดด์เคิร์ตเดวิด Mellis และคนอื่น ๆ? Published: ฉบับพิมพ์ครั้งแรกสิงหาคม 2007 ? งานนี้ได้รับใบอนุญาตภายใต้ Creative Commons Attribution-Share Alike 3.0 ใบอนุญาต. ? หากต้องการดูสำเนา ใบอนุญาตนี้เข้าชม: http://createivecommons.org/licenses/by-nc-sa/3.0/ หรือส่งจดหมายไปที่: ? Creative Commons 171 สอง Street, Suite 300 San Francisco, California, 94105, USA ? ? เนื้อหาโครงสร้างโครงสร้างการติดตั้ง () ห่วง () ฟังก์ชั่น{} วงเล็บปีกกา; อัฒภาค/ * ... * / บล็อกความคิดเห็น// สายความคิดเห็นตัวแปรตัวแปรตัวแปรประกาศขอบเขตตัวแปรประเภทข้อมูลไบต์int ยาวลอยอาร์เรย์เลขคณิตเลขคณิตสารประกอบการกำหนดผู้ประกอบการเปรียบเทียบตรรกะประกอบการคงที่ค่าคงที่จริง / เท็จสูง / ต่ำเข้า / ส่งออกการควบคุมการไหลถ้าหาก .. อื่นสำหรับในขณะที่ทำ ... ในขณะที่ดิจิตอล I / O pinMode (pin, โหมด) digitalRead (ขา) digitalWrite (pin, ค่า) อนาล็อก I / O analogRead (ขา) analogWrite (pin, ค่า) เวลาล่าช้า (ms) MILLIS () คณิตศาสตร์นาที (x, y) สูงสุด (x, y) สุ่มrandomSeed (เมล็ด) โดยสุ่ม (นาที, สูงสุด) อนุกรมSerial.begin (อัตรา) Serial.println (ข้อมูล) ภาคผนวกดิจิตอลเอาท์พุทดิจิตอลอินพุทเอาท์พุทสูงในปัจจุบันPWM เอาท์พุทมิเตอร์ ป้อนข้อมูลต้านทานอินพุตตัวแปรเอาท์พุทเซอร์โว
การแปล กรุณารอสักครู่..
