Skip to content

Instantly share code, notes, and snippets.

View ajfisher's full-sized avatar

ajfisher ajfisher

View GitHub Profile
@ajfisher
ajfisher / blink.js
Last active July 30, 2019 03:50
BT LED Blinker
@ajfisher
ajfisher / esp8266_mqtt.ino
Created August 29, 2016 11:06
Bits for an MQTT server from ESP8266
/*
Basic ESP8266 MQTT example
This sketch demonstrates the capabilities of the pubsub library in combination
with the ESP8266 board/library.
It connects to an MQTT server then:
- publishes "hello world" to the topic "outTopic" every two seconds
- subscribes to the topic "inTopic", printing out any messages
it receives. NB - it assumes the received payloads are strings not binary
@ajfisher
ajfisher / package.json
Created August 18, 2016 08:47
Laser pan tilt code
{
"name": "lasertest",
"version": "1.0.0",
"description": "Used to pan tilt and fire a laser",
"main": "led.js",
"dependencies": {
"johnny-five": "^0.9.53"
},
"devDependencies": {},
"scripts": {
@ajfisher
ajfisher / matrix.js
Created July 30, 2016 06:12
Dirty version of mbot LED matrix working with johnny-five
var five = require("johnny-five");
var board = five.Board();
//Define Data Command Parameters
var Mode_Address_Auto_Add_1 = 0x40 //0100 0000 B
var Mode_Permanent_Address = 0x44 //0100 0100 B
board.on("ready", function() {
@ajfisher
ajfisher / __Notes.md
Created July 7, 2016 14:25
PoC for ProximityArray

To try it out make sure you use the latest backpack from ajfisher/nodebots-hcsr04 using i2c_multiping branch

@ajfisher
ajfisher / _brexit.md
Last active June 27, 2016 01:03
A quick little slack bot to report of brexit results

This is a little slack bot I made which is used to get results for the EU Referendum in the UK

Set up

npm install cheerio botkit request

Log into slack, create a new bot and then get the token for it.

Drop the token into the brexitbot.js file where it says "PUT YOUR TOKEN HERE"

@ajfisher
ajfisher / info.md
Last active January 22, 2016 08:04
NodePixel flashing to edison

Get bin file from this gist.

Copy bin file into a location on the edison side. I'll call this /tmp/firmware

ssh onto edison then cd into /tmp/firmware

from there:

npm install avrgirl-arduino
@ajfisher
ajfisher / LICENSE
Last active May 3, 2016 10:31
Preparation for BuzzConf
The MIT License (MIT)
Copyright (c) 2015 ajfisher
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
@ajfisher
ajfisher / app.js
Created June 8, 2015 10:12
Beginning version colour sensor module support
var five = require("johnny-five");
var colour_sensor = require("./coloursensor.js")
var board = five.Board();
var led;
board.on('ready', function() {
var cs = new colour_sensor({
address: 0x29,
@ajfisher
ajfisher / 0x00000.bin
Last active October 10, 2021 00:51
ESP8266 Transparent bridge to J5