Skip to content

Instantly share code, notes, and snippets.

View samr28's full-sized avatar

Sam Roquitte samr28

View GitHub Profile
#define GN 0
#define YN 1
#define GE 2
#define YE 3
#define BUTTON1_PIN 2
#define BUTTON2_PIN 3
typedef struct state {
uint8_t output;
long wait;
const int LED_PIN = 13;
bool isOk = false;
bool lose = false;
int counter = 0;
int millis1 = 0;
int millis2 = 0;
void setup() {
Serial.begin(9600);
pinMode(LED_PIN, OUTPUT);
wh#include <Wire.h>
#include "Adafruit_Trellis.h"
#include <LiquidCrystal.h>
LiquidCrystal lcd(12,11,5,4,3,2);
const int LCD_WIDTH = 16, LCD_ROWS = 2;
const int DISPLAY_CONTRAST = 130;
const int DISPLAY_PWM = 6;
#define MOMENTARY 0
#define LATCHING 1
#include <LiquidCrystal.h>
#include <EEPROM.h>
LiquidCrystal lcd(12,11,5,4,3,2);
const int LCD_WIDTH = 16, LCD_ROWS = 2;
const int motorPin = 9;
const int DISPLAY_PWM = 6;
int DISPLAY_CONTRAST = 90;
const int ON_BUTTON_PIN = 7, OFF_BUTTON_PIN = 8, EXTRA_BUTTON_PIN = 13;
const int POT1_PIN = 0;
#include <LiquidCrystal.h>
#include <EEPROM.h>
LiquidCrystal lcd(12,11,5,4,3,2);
const int LCD_WIDTH = 16, LCD_ROWS = 2;
const int motorPin = 9;
const int DISPLAY_PWM = 6;
int DISPLAY_CONTRAST = 90;
const int ON_BUTTON_PIN = 7, OFF_BUTTON_PIN = 8, EXTRA_BUTTON_PIN = 13;
const int POT1_PIN = 0;
#include <LiquidCrystal.h>
#include <Servo.h>
LiquidCrystal lcd(12,11,5,4,3,2); //Set LCD Pins
Servo servo1;
bool isOn = false; //Default state is off
const int BUTTON1_PIN = 7, BUTTON2_PIN = 8, BUTTON3_PIN = 6; //Button pins
const int LED_PIN = 13; //LED Pin
const int FLEX_PIN = 1; //Flex Sensor Pin