Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Beide Seiten der vorigen Revision Vorhergehende Überarbeitung Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
knowledgebase:arduinoide [2017/11/29 14:51] rolex |
knowledgebase:arduinoide [2017/12/19 11:38] (aktuell) rolex |
||
---|---|---|---|
Zeile 13: | Zeile 13: | ||
| while(statement){expression} | Keep doing expression while statement is true | | | while(statement){expression} | Keep doing expression while statement is true | | ||
| do{statement}while(expression); | | do{statement}while(expression); | ||
- | | switch (var) {case 1: statement | + | | switch(var){case |
| break; | Exit a for, while, do while loop or switch statement | | | break; | Exit a for, while, do while loop or switch statement | | ||
| continue; | Skip rest of current iteration of for, while, or do while loop, start next iteration | | | continue; | Skip rest of current iteration of for, while, or do while loop, start next iteration | | ||
| return value; | Terminate the function and optionally return value to the function that called it | | | return value; | Terminate the function and optionally return value to the function that called it | | ||
- | | goto label; | Send the program flow to `label:` | | + | | goto label; |Send the program flow to `label:` | |
== Comparison Operators == | == Comparison Operators == | ||
Zeile 24: | Zeile 24: | ||
| < | Less than | | | < | Less than | | ||
| > |Greater than | | | > |Greater than | | ||
- | | <= | Less than or equal to | | + | | < |
| >= | Greater than or equal to | | | >= | Greater than or equal to | | ||
== Boolean Operators == | == Boolean Operators == | ||
| && | And | | | && | And | | ||
- | | <code>||</code> | Or | | + | | <nowiki> || </nowiki> | Or | |
| ! | Not | | | ! | Not | | ||
== Bitwise Operators == | == Bitwise Operators == | ||
| & | And | | | & | And | | ||
- | | | | Or | | + | | < |
- | | ^ | Xor | | + | |
| ~ | Not | | | ~ | Not | | ||
| << | Bitshift left | | | << | Bitshift left | | ||
Zeile 49: | Zeile 48: | ||
| x %=y | x=the remainder of x/y | | | x %=y | x=the remainder of x/y | | ||
| x &=y | x=x&y | | | x &=y | x=x&y | | ||
- | | x |=y | x=x|y | | ||
== Constants == | == Constants == | ||
Zeile 80: | Zeile 78: | ||
| delayMicroseconds(n) | Pause program for n microseconds | | | delayMicroseconds(n) | Pause program for n microseconds | | ||
- | == Comments == | + | \\ |
- | | // stuff | Single-line comment | | + | \\ |
- | | /* many things */ | Multi-line comment | | + | mehr auf [[https://www.arduino.cc/reference/ |