Skip to content

Instantly share code, notes, and snippets.

Aaron Harris aamharris

Block or report user

Report or block aamharris

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@aamharris
aamharris / light_mqtt_template.ino
Created Mar 26, 2020
ESP32 IoT Light Controller with CloudMqtt
View light_mqtt_template.ino
#include <WiFi.h>
#include <PubSubClient.h>
//replace details with your wifi credentials
const char* ssid = "your-ssid";
const char* password = "your-password";
const int buttonPin = 17;
const int ledPin = 21;
@aamharris
aamharris / button_state.ino
Created Jan 31, 2020
Control LED in Arduino
View button_state.ino
const int buttonPin = 17;
const int ledPin = 21;
int buttonState = 0;
int lastButtonState = 0;
bool isLightOn = false;
void setup() {
pinMode(buttonPin, INPUT);
pinMode(ledPin, OUTPUT);
View crud_step_by_step.md

Step by Step CRUD

Understand the Domain

  1. Discuss the domain (with others or yourself).
  2. Write down the user stories (features that you plan to support).
  3. Develop an understand of how each noun (model/table) will relate to each other.

Schema

  1. Draw the schema. Don't name any join tables as the combination of two other tables, find a unique noun.
  2. Double check your schema for any columns that don't follow convention (e.g. foreign keys should end in _id).
You can’t perform that action at this time.