This file contains 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
/* | |
'Time Globe' - A lamp clock that shows time by the angle of its light | |
Midterm for 'Time' by Jason Gao | |
10/25/2021 | |
*/ | |
#include <Servo.h> | |
#include <Adafruit_NeoPixel.h> | |
#include <IRremote.h> |
This file contains 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 ledPin = 3; | |
int pushPin = 4; | |
int status = 0; | |
int delayPeriod = 200; | |
void setup() { | |
pinMode(ledPin, OUTPUT); | |
pinMode(pushPin, INPUT); | |
} |
This file contains 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
/* | |
Balance Ball - Hand | |
Five vibration motor | |
Arranged from LSM6DS3 example by Riccardo Rizzo | |
*/ | |
#include <Arduino_LSM6DS3.h> | |
const int motors[5] = {9, 6, 5, 3, 2}; |
This file contains 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
/* | |
Balancing Ball - Arduino part | |
More info: https://itp.jasongao.me/physical-computing/week-8-synchronous-serial | |
Arranged from LSM6DS3 example by Riccardo Rizzo | |
*/ | |
#include <Arduino_LSM6DS3.h> | |
const int leftVibPin = 2; | |
const int rightVibPin = 3; |
This file contains 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
/** | |
* Flappy Bird Game by Jason Gao | |
* | |
* Debounce part is arranged from | |
* https://www.arduino.cc/en/Tutorial/BuiltInExamples/Debounce | |
*/ | |
const int buttonPin = 2; // the number of the pushbutton pin | |
const int ledPin = 3; |