Instructions how to install and build HAP-NodeJS on a Raspberry Pi
- Raspberry Pi Model B or newer
- SD card with latest Raspbian installed and configured with SSH enabled
Instructions how to install and build HAP-NodeJS on a Raspberry Pi
#include <ESP8266WiFi.h> | |
#include <WiFiClient.h> | |
#include <ESP8266mDNS.h> | |
#include <WiFiUdp.h> | |
#include <PubSubClient.h> | |
#include <Adafruit_NeoPixel.h> | |
#define PIN 4 | |
Adafruit_NeoPixel strip = Adafruit_NeoPixel(4, PIN, NEO_GRB + NEO_KHZ800); |
Amazon has a really good deal on an ESP8266 board in stock with prime. http://www.amazon.com/Gikfun-ESP8266-ESP-12-Industrial-version/dp/B00RK1W7R6
There are no instructions with it so I bought one and between probing with my multimeter and trying different things, I was able to get nodemcu running.
Yellow jumper seems to toggle between flash mode and at mode, closed is flash mode.
three pins labeled gnd, tx, tr are for uart and are what you should plug in. tx-tx,rx-rx,gnd-gnd.
You can leave power dangling
source "https://rubygems.org" | |
gem 'eventmachine' | |
gem 'rubysl-stringio' | |
gem 'sinatra' | |
gem 'yajl-ruby', require: 'yajl' | |
gem 'thin' | |
gem 'em-websocket', :git=>'https://github.com/igrigorik/em-websocket.git' |
# Author: Pieter Noordhuis | |
# Description: Simple demo to showcase Redis PubSub with EventMachine | |
# | |
# Update 7 Oct 2010: | |
# - This example does *not* appear to work with Chrome >=6.0. Apparently, | |
# the WebSocket protocol implementation in the cramp gem does not work | |
# well with Chrome's (newer) WebSocket implementation. | |
# | |
# Requirements: | |
# - rubygems: eventmachine, thin, cramp, sinatra, yajl-ruby |
# Based on https://github.com/kripken/emscripten/wiki/Tutorial | |
# prerequisites | |
cd ~/ | |
brew install node | |
sudo ln -s /usr/bin/python2.7 /usr/bin/python2 | |
curl http://llvm.org/releases/3.2/clang+llvm-3.2-x86_64-apple-darwin11.tar.gz > llvm.tgz | |
tar xzvf llvm.tgz | |
ln -s clang+llvm-3.2-x86_64-apple-darwin11 llvm |
// This hack works with com.android.tools.build:gradle:0.2, won't work in later version without modification | |
apply plugin: 'android' | |
targetCompatibility = 1.6 | |
sourceCompatibility = 1.6 | |
android { | |
target = 'android-14' |
<!-- Angular JQM --> | |
<xsd:attribute name="jqm-caching-view" vs:category="Angular" /> | |
<xsd:attribute name="jqm-footer" vs:category="Angular" /> | |
<xsd:attribute name="jqm-button" vs:category="Angular" /> | |
<xsd:attribute name="jqm-checkbox" vs:category="Angular" /> | |
<xsd:attribute name="jqm-flip" vs:category="Angular" /> | |
<xsd:attribute name="jqm-header" vs:category="Angular" /> | |
<xsd:attribute name="jqm-page" vs:category="Angular" /> | |
<xsd:attribute name="jqm-panel" vs:category="Angular" /> | |
<xsd:attribute name="jqm-panel-container" vs:category="Angular" /> |
# From Andrzej Szelachowski's ~/.bash_profile: | |
# Note that a variable may require special treatment | |
#+ if it will be exported. | |
DARKGRAY='\e[1;30m' | |
LIGHTRED='\e[1;31m' | |
GREEN='\e[32m' | |
YELLOW='\e[1;33m' |