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
#include <Wire.h> | |
#include <Adafruit_GFX.h> | |
#include <Adafruit_SSD1306.h> | |
#define SCREEN_WIDTH 128 // OLED display width, in pixels | |
#define SCREEN_HEIGHT 64 // OLED display height, in pixels | |
// Declaration for an SSD1306 display connected to I2C (SDA, SCL pins) | |
Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, -1); | |
const int trigPin = 5; | |
const int echoPin = 18; //define sound speed in cm/uS | |
#define SOUND_SPEED 0.034 |
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
#include <splash.h> | |
#include <MFRC522.h> | |
#include <MFRC522Extended.h> | |
#include <deprecated.h> | |
#include <require_cpp11.h> | |
#include <SPI.h> | |
#include <Wire.h> | |
#include <Adafruit_GFX.h> | |
#include <Adafruit_SSD1306.h> | |
#include <Servo.h> // Include the Servo library |
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
#include <SPI.h> | |
int SPI_MOSI = 12; | |
int SPI_CLK = 11; | |
int SPI_CS = 10; | |
byte spidata[16]; | |
int a = 20; | |
int b = 20; | |
int c = 20; | |
int d = 20; |
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
#include <SPI.h> | |
int SPI_MOSI = 12; | |
int SPI_CLK = 11; | |
int SPI_CS = 10; | |
byte spidata[16]; | |
int a = 20; | |
int b = 20; | |
int c = 20; | |
int d = 20; |
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
#include <TinyGPSPlus.h> | |
TinyGPSPlus gps; | |
float lat, lng; | |
float latrad, lngrad; | |
float inilat = 0; //SET THIS TO LATITUDE IN DEGREES OF YOUR DESIRED GPS LOCATION | |
float inilng = 0; //SET THIS TO LONGITUDE IN DEGREES OF YOUR DESIRED GPS LOCATION | |
float inilatrad, inilngrad; | |
float diflat=0; | |
float diflng=0; | |
float calc1=0; |
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
const int PIN_RED = A0; | |
const int PIN_GREEN = A1; | |
const int PIN_BLUE = A2; | |
int buttonPause = 2; | |
int buttonNext = 3; | |
int buttonRepeat = 4; | |
int tracknum; | |
boolean isPlaying = false; | |
boolean Repeat = false; |
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
// Pin definitions | |
const int eyeBlinkSensorPin = 10; // Eye blink sensor connected to digital pin 10 | |
const int buzzerPin = 13; // Buzzer connected to digital pin 13 | |
const int motorControlPin = 7; // Relay control for motor connected to digital pin 7 | |
const int testSwitchPin = 4; // Test switch connected to digital pin 4 | |
const int resetSwitchPin = 5; // Reset switch connected to digital pin 5 | |
bool drowsinessDetected = false; | |
void setup() { |
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
#include <ESPAsyncUDP.h> | |
#include <NTPClient.h> | |
#include <TimeLib.h> | |
#include <DHT.h> | |
#include <DHT_U.h> | |
#include <SPI.h> | |
#include <ESP8266WiFi.h> | |
#include <Adafruit_GFX.h> | |
#include <WiFiUdp.h> | |
#include <Adafruit_ST7735.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
#include <WiFi.h> | |
#include <esp_now.h> | |
bool buttonDown = false; | |
bool ledOn = false; | |
#define STATUS_LED 23 | |
#define STATUS_BUTTON 22 | |
void formatMacAddress(const uint8_t *macAddr, char *buffer, int maxLength) |
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
#include <esp_now.h> | |
#include <WiFi.h> | |
int int_value; | |
float float_value; | |
bool bool_value = true; | |
//Receiver MAC Address | |
uint8_t broadcastAddress[] = {0x0c, 0xB8, 0x15, 0xCA, 0xE2, 0xD8}; |
NewerOlder