Skip to content

Instantly share code, notes, and snippets.

Avatar
☠️
computing

Morgan Herlocker morganherlocker

☠️
computing
View GitHub Profile
View Effects Pedal hacking 101.md

General:

  • start simple
  • start with fuzz
  • don't even bother looking at building an analog delay pedal yet :)

All you really need to know about electrical components:

Resistors

@morganherlocker
morganherlocker / gist:7491657
Created Nov 15, 2013
ogr2ogr geojson to KML
View gist:7491657
ogr2ogr -f KML /full/path/a.kml /full/path/b.geojson
View states.topojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View states.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@morganherlocker
morganherlocker / README.md
Last active Aug 29, 2015
Geocolor Choloropleth with simplestyle-spec Styling
View README.md

sc_poverty_unstyled.geojson contains South Carolina's counties, with a poverty index. To create a choloropleth viewable in a gist, we can use geocolor.

var fs = require('fs'),
    geocolor = require('geocolor')

var geo = JSON.parse(fs.readFileSync(__dirname+'/in/sc_pov.geojson'))

geo = geocolor(geo, 'poverty', 'quantile', 7, ['blue', 'red'])
View npm-debug.log
0 info it worked if it ends with ok
1 verbose cli [ 'node', '/usr/local/bin/npm', 'publish' ]
2 info using npm@1.4.6
3 info using node@v0.10.26
4 verbose publish [ '.' ]
5 verbose cache add [ '.', null ]
6 verbose cache add name=undefined spec="." args=[".",null]
7 verbose parsed url { protocol: null,
7 verbose parsed url slashes: null,
7 verbose parsed url auth: null,
View npm-debug.log
0 info it worked if it ends with ok
1 verbose cli [ 'node', '/usr/local/bin/npm', 'publish' ]
2 info using npm@1.4.6
3 info using node@v0.10.26
4 verbose publish [ '.' ]
5 verbose cache add [ '.', null ]
6 verbose cache add name=undefined spec="." args=[".",null]
7 verbose parsed url { protocol: null,
7 verbose parsed url slashes: null,
7 verbose parsed url auth: null,
View README.md

Update a donut chart extent based on a dragged brush extent

View gist:10309418
var melody = [22,18,8,6,18,20,24,26,20,18,12,18]
return function (t) {
t = t/1.28
return drums1(t)/4 + drums2(t)/2.4 + drums3(t)/18 + synth1(t) + synth2(t);
}
function sin (x, t) { return Math.sin(2 * Math.PI * t * x *.6) * 1.5 }