This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int timer = 0; | |
| void setup() { | |
| size(300, 300); | |
| } | |
| void draw() { | |
| background(255); | |
| fill(0); | |
| textSize(20); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Click within the image to change | |
| // the value of the rectangle after | |
| // after the mouse has been clicked | |
| int value = 255; | |
| PImage img; | |
| int mode = 0; | |
| int keyMode = 0; | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <Servo.h> | |
| Servo myservo; | |
| int trigPinABC = 12; // Trig Pin | |
| int echoPin = 13; // Echo Pin | |
| long duration, cm, inches; | |
| void setup() { | |
| Serial.begin (9600); // Serial Port begin win com X / | |
| myservo.attach(9); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "Keyboard.h" | |
| void setup() { | |
| Keyboard.begin(); | |
| delay(3000); | |
| for( int i = 0 ; i< 5 ;i++){ | |
| Keyboard.press(218); | |
| delay(100); | |
| Keyboard.release(218); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int x = 100, y=100; | |
| void setup() { | |
| size(300, 300); | |
| } | |
| void draw() { | |
| rect(x, y, 30, 30); | |
| } | |
| void keyPressed() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| void setup() { | |
| Serial.begin(9600); | |
| pinMode(13, OUTPUT); | |
| } | |
| void loop() { | |
| Serial.println(analogRead(A0)); | |
| digitalWrite(13, HIGH); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| void setup() { | |
| pinMode(13, OUTPUT); | |
| } | |
| void loop() { | |
| digitalWrite(13, HIGH); | |
| delay(100); | |
| digitalWrite(13, LOW); | |
| delay(100); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int a = 1; | |
| void setup() { | |
| Serial.begin(9600); | |
| pinMode(13, OUTPUT); | |
| } | |
| void loop() { | |
| a = a + 1; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int a = 1; | |
| void setup() { | |
| pinMode(13, OUTPUT); | |
| } | |
| void loop() { | |
| a = a + 1; | |
| if( a > 255){ | |
| a = 1; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int a = 1; | |
| void setup() { | |
| pinMode(13,OUTPUT); | |
| } | |
| void loop() { | |
| a = a + 1; | |