This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# find two handed rhythms | |
# every char in pattern represents a beat, clicks can happen on or off beat. | |
patterns = { | |
# heli | |
"h": [0, 0], | |
# den den | |
"dd": [1, 0, 1, 0], | |
# air turn | |
"at": [1, 0, 0, 0], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <SPI.h> // MAX6675 over hardware SPI | |
#define TC1_CS 12 // GPIO 12 | |
#define TC2_CS 13 // GPIO 13 | |
#define TC3_CS 15 // GPIO 15 | |
/* Note: All MAX6675 | |
* MAX6675 to EPS32 | |
* VCC -> 3.3V | |
* GND -> GND |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { Map, List } = require('immutable'); | |
const { createStore } = require('redux'); | |
const { combineReducers } = require('redux-immutable'); | |
// Constants | |
const TOGGLE_STARTING_PLAYER = 'gamecore/toggleStartingPlayer'; | |
const PLACE_PIECE = 'gamecore/placePiece'; | |
const TURN_PIECE = 'gamecore/turnPiece'; | |
const MOVE_PIECE = 'gamecore/movePiece'; | |
const SWITCH_PIECE_TURN = 'gamecore/switchPieceTime'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alphabet = 'abcdefghijklmnopqrstuvwxyz' | |
def shift(text, n): | |
answer = '' | |
for c in text: | |
if c in alphabet: | |
answer += alphabet[(alphabet.index(c)+n)%26] | |
continue | |
answer += c | |
return answer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
''' | |
Copyright (C) 2013 Al Grant, al@algrant.ca | |
This program is free software; you can redistribute it and/or modify | |
it under the terms of the GNU General Public License as published by | |
the Free Software Foundation; either version 2 of the License, or | |
(at your option) any later version. | |
This program is distributed in the hope that it will be useful, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys, pygame | |
import ImageGrab | |
import ImageFilter | |
import ImageChops | |
import ImageMath | |
from numpy import array | |
pygame.init() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RED = 0 | |
GREEN = 1 | |
BLUE = 2 | |
SHINY = 3 | |
SELLING = 0 | |
SUGGESTED = 1 | |
class Compound(): |