Skip to content

Instantly share code, notes, and snippets.

Paul Battley threedaymonk

Block or report user

Report or block threedaymonk

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
threedaymonk /
Created Jan 14, 2020
Python barcode reader example
from import VideoStream
from pyzbar.pyzbar import decode
from pprint import pprint
import cv2
import time
vs = VideoStream(src=0).start()
threedaymonk /
Last active Oct 26, 2019
Roland SP-404SX sample format

Roland SP-404SX sample file format


Field types are marked using C-style notation:

  • char[4] indicates a 4-byte fixed-width string
  • uint[6] indicates a 6-byte sequence
  • uint8, uint16, and uint32 are unsigned byte, short, and long integers
  • int8, int16, and int32 are signed byte, short, and long integers
threedaymonk /
Last active Oct 5, 2019
Novation Launch Control Sysex


All sysex messages start with

Hex Field
F0 Start sysex
00 20 29 Manufacturer: Novation
02 Product type
0A Product ID
threedaymonk /
Last active Dec 31, 2019
Ubuntu post-install packages
sudo apt update
sudo apt install -y \
apt-file \
autoconf \
bison \
build-essential \
checkinstall \
View constitution.txt
Constitution of a Charitable Incorporated Organisation whose only voting
members are its charity trustees
(‘Foundation’ model constitution)
Date of constitution (last amended):
1. Name
threedaymonk / recipes.txt
Last active Jun 2, 2016
BBC Food recipe URLs
View recipes.txt
threedaymonk / annotate-failures.rb
Created Mar 29, 2016
Annotate failing Cucumber scenarios with @broken
View annotate-failures.rb
failures = {}\n/).each do |line|
matches = line.match(/\Acucumber ([^:]+):(\d+)/) or next
(failures[matches[1]] ||= []) << matches[2].to_i - 1
failures.each do |file, indices|
lines = File.readlines(file)
indices.reverse.each do |index|
indentation = lines[index][/\A\s+/]
threedaymonk / a
Last active Jan 20, 2016
Number of separate copies/versions of each npm module in the node_modules hierarchy
View a
Unique versions of each module
8 glob
8 async
7 qs
7 lodash
7 commander
6 source-map
5 uglify-js
5 strip-ansi
threedaymonk / benchmarking.rb
Created Oct 8, 2015
Ruby benchmarking example
View benchmarking.rb
require "benchmark"
Benchmark.benchmark do |b|"Some job"){ do_some_job }"Another job"){ do_another_job }
View bind.js
if (!Function.prototype.bind) {
Function.prototype.bind = function bind(thisValue){
var func = this;
return function() {
return func.apply(thisValue, arguments);
You can’t perform that action at this time.