Skip to content

Instantly share code, notes, and snippets.

View halfbyte's full-sized avatar
Doing stuff

Jan Krutisch halfbyte

Doing stuff
View GitHub Profile
halfbyte / package-lock.json
Last active March 9, 2018 12:23
Setup for npm --package-lock-only bug
"name": "package-lock-only-bug",
"version": "1.0.0",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
"acorn": {
"version": "5.5.3",
"resolved": "",
"integrity": "sha512-jd5MkIUlbbmb07nXH0DT3y7rDVtkzDi4XZOUVWAer8ajmF/DTSSbl5oNFyDOl/OXA33Bl79+ypHhl2pN20VeOQ==",
halfbyte / iocc.c
Created June 2, 2017 07:37
Reformatted entry for IOCC, originally planned to be in my aesthetics of code talk
# From:
int I=256, l, c, o, O=3;
void e(int L) {
for(l=8; L >> ++l && 16 > l; o += l << l - 1);
o += l * L - (l << l - 1);
if (pread(3, &L, 3, O + o / 8) < 2) exit(0);
L >>= 7 & o;
L %= 1 << l;
halfbyte /
Last active December 21, 2016 10:49
Format Description of Modal Electronics CRAFT SysEx messages

The Messages

When ever you switch or save presets from the hardware, the synth sends two sysex messages. They both start with a common header:

F0 00 21 07 64 CMD PATCHNO

Where CMD is 02 on the first message and 03 on the second and PATCHNO is 0-15 for the patch number.

halfbyte / lets talk about JS's
Last active April 3, 2016 17:05
A draft of an Article that wanted to be written after the left-pad drama and the parallel discussion on the super-small-npm-modules approach


I like to call myself a web developer. Some people would call me "full stack" developer, but I'm absolutely terrible at writing file system, so, no.

As a web developer, since 1996, I have written code, markup and styles in HTML, CSS, Perl, PHP, JavaScript, Java, Ruby, Tcl, Python, C (yes, at one point I wrote CGI-Scripts in C), Haxe, Flash, Coffeescript and probably also a handful of other more obscure languages I can't even remember. I'm not writing this to brag (although that's a nice side effect, of course) but to make clear to you, the reader, that the following is not a rant by a disgruntled Rubby engineer who hates JavaScript.

In terms of modern JavaScript, I've spent some time, on and off, during the last, say, 6 years, in dabbling with node.js,

halfbyte / Gemfile
Created December 21, 2014 01:22
A Simple Calendar generator. Very specific for my case - Probably going to make it more configurable one day.
source ""
gem "prawn"
halfbyte /
Last active January 6, 2024 17:39
Kurze Überschlagsrechnung für Pappteller vs. Handwäsche (Nur Energie)


Wild zusammengesuchte, kaum belastbare Zahlen, aber als Größenordnungseinschätzungsversuch vermutlich ausreichend.


"Graue Energie" für 500st Kopierpapier: 41kWh (pro Blatt: 5g, also für 2,5kg)

1 Pappteller: 18,53g (also 41kWh für ~135 Pappteller)

halfbyte /
Created March 29, 2014 12:33
Github proof

Keybase proof

I hereby claim:

  • I am halfbyte on github.
  • I am halfbyte ( on keybase.
  • I have a public key whose fingerprint is CF40 36B2 DBC8 83BA 29F1 3745 D400 34B1 A3E5 2A33

To claim this, I am signing this object:

halfbyte / index.js
Last active August 29, 2015 13:56
Super Simple Kritzler API
var port = "/dev/cu.usbmodem1421"
var serialPort = require("serialport");
var express = require('express');
var app = express();
var SerialPort = serialPort.SerialPort; // localize object constructor
var sp = new SerialPort(port, {
baudrate: 57600,
halfbyte / dub_techno.js
Created January 11, 2014 13:42
A demonstration of some new elements in liv3c0der I did for my WCDC talk.
// NAME: default
AE.Instance.tempo = 120;
AE.Instance.groove = 0.0;
function draw(c, s) {
halfbyte / lednet.cpp
Created November 29, 2013 22:43
Arduino experiment to drive some DIODER from IKEA via OSC by using an Arduino and a small ruby script.
#include <SPI.h>
#include <Dhcp.h>
#include <Dns.h>
#include <Ethernet.h>
#include <EthernetClient.h>
#include <EthernetServer.h>
#include <EthernetUdp.h>
#include <util.h>
// color swirl! connect an RGB LED to the PWM pins as indicated