Skip to content

Instantly share code, notes, and snippets.

View unixunion's full-sized avatar

Kegan Holtzhausen unixunion

View GitHub Profile
@unixunion
unixunion / app.js
Created June 19, 2015 21:39
angular-vertxbus duplicate messages
/* global angular:false,console:false */
(function () {
'use strict';
angular.module('app', ['ng', 'knalli.angular-vertxbus'])
.config(function(vertxEventBusProvider) {
vertxEventBusProvider
.useDebug(true)
.useUrlServer('http://localhost:8080');
})
@unixunion
unixunion / dust.ino
Last active December 22, 2021 19:01
Sharp Dust Sensor
/*
Standalone Sketch to use with a Arduino Fio and a
Sharp Optical Dust Sensor GP2Y1010AU0F
Blog: http://arduinodev.woofex.net/2012/12/01/standalone-sharp-dust-sensor/
Code: https://github.com/Trefex/arduino-airquality/
For Pin connections, please check the Blog or the github project page
Authors: Cyrille Médard de Chardon (serialC), Christophe Trefois (Trefex)
Changelog:
@unixunion
unixunion / TcpIpJoinerOverAWS.java
Created April 10, 2015 11:25
ec2 joiner patch for hazelcast
package com.hazelcast.cluster;
import static com.amazonaws.regions.RegionUtils.getRegion;
import static org.apache.commons.lang3.StringUtils.isBlank;
import static org.apache.commons.lang3.StringUtils.isNotBlank;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
@unixunion
unixunion / JeremyCricket.ino
Last active August 29, 2015 14:17
Jeremy Cricket Day / Night edition
/*
_____ _ _ _ ____ _____
/ ____| (_) | | | | / __ \ / ____|
| | _ __ _ ___| | _____| |_| | | | (___
| | | '__| |/ __| |/ / _ \ __| | | |\___ \
| |____| | | | (__| < __/ |_| |__| |____) |
\_____|_| |_|\___|_|\_\___|\__|\____/|_____/ 2.0
CricketOS chirps at configured day/night/day transitions for a certain amount of songs, then waits until
the next transistion. Prank your firends, they will have a hard time locating it.
@unixunion
unixunion / SerialCallbackTest.cs
Created January 20, 2015 16:04
Arduino's don't seem to trigger the callback onDataReceived.
using System;
using System.IO.Ports;
using System.Threading;
using System.ComponentModel;
class Program
{
public static void Main()
{
SerialPort mySerialPort = new SerialPort("/dev/tty.usbmodem621", 9600, Parity.None, 8, StopBits.One);