Skip to content

Instantly share code, notes, and snippets.

Avatar
🎓
preparing the MLH Fellowship

Jonathan Gottfried jonmarkgo

🎓
preparing the MLH Fellowship
View GitHub Profile
View abc.xyz.html
<!doctype html>
<!--[if lt IE 7]> <html class="ie7 oldie" lang="en"> <![endif]-->
<!--[if IE 8]> <html class="ie8 oldie" lang="en"> <![endif]-->
<!--[if IE 9]> <html class="ie9 oldie" lang="en"> <![endif]-->
<!--[if gt IE 9]><!--> <html lang="en"> <!--<![endif]-->
<head>
<title>Alphabet</title>
<meta charset="utf-8">
View abc.xyz
<!doctype html>
<!--[if lt IE 7]> <html class="ie7 oldie" lang="en"> <![endif]-->
<!--[if IE 8]> <html class="ie8 oldie" lang="en"> <![endif]-->
<!--[if IE 9]> <html class="ie9 oldie" lang="en"> <![endif]-->
<!--[if gt IE 9]><!--> <html lang="en"> <!--<![endif]-->
<head>
<title>Alphabet</title>
<meta charset="utf-8">
View app.rb
require 'sinatra'
get '/hi' do
"Hello World!"
end
View config.ru
require './app'
run Sinatra::Application
View Gemfile
source 'https://rubygems.org'
gem 'sinatra'
View nodelock.ino
#include <Servo.h>
Servo myservo;
int servoPin = 12;
int lock = 0;
int unlock = 180;
void setup() {
// initialize serial:
Serial.begin(9600);
View nodelock.js
var twilio = require('twilio'),
SerialPort = require("serialport").SerialPort,
express = require('express');
var app = express();
function sendMessage(res, message) {
var resp = new twilio.TwimlResponse();
resp.message(message);
res.type('text/xml');
View pirlock.ino
#include <Servo.h>
int pirPin = 2; //digital 2
int servoPin = 12; //digital 12
int lock = 0;
int unlock = 180;
Servo myservo;
void setup(){
View verifiedrfidservo.ino
// Modified by Worapoht K. and Jonathan Gottfried
#include <SoftwareSerial.h>
#include <Servo.h>
int val = 0;
char code[10];
int bytesread = 0;
int rfidPin = 2;
#define rxPin 8
View rfidservo.ino
// Modified by Worapoht K. and Jonathan Gottfried
#include <SoftwareSerial.h>
#include <Servo.h>
int val = 0;
char code[10];
int bytesread = 0;
int rfidPin = 2;
#define rxPin 8