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
$(document).ready(function() { | |
(function(){ | |
var Modularity = function(sig) { | |
sigma.classes.Cascade.call(this); | |
var self = this, | |
domains = []; |
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
['code', 'art', 'boot', 'mix', 'verse'].each { |hack| re(hack) } |
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
~$ brew install openssl | |
==> Downloading http://openssl.org/source/openssl-1.0.1c.tar.gz | |
Already downloaded: /Users/alx/Library/Caches/Homebrew/openssl-1.0.1c.tar.gz | |
==> perl ./Configure --prefix=/usr/local/Cellar/openssl/1.0.1c --openssldir=/usr/local/etc/openssl zlib-dynamic shared darwin64-x86_64-cc | |
==> make | |
==> make test | |
==> make install MANDIR=/usr/local/Cellar/openssl/1.0.1c/share/man MANSUFFIX=ssl | |
==> Caveats | |
This formula is keg-only, so it was not symlinked into /usr/local. |
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
~$ rvm 1.9.3-p194 && cd ~/.rvm/src/ruby-1.9.3-p194/ext/openssl && ruby extconf.rb | |
=== OpenSSL for Ruby configurator === | |
=== Checking for system dependent stuff... === | |
checking for t_open() in -lnsl... no | |
checking for socket() in -lsocket... no | |
checking for assert.h... yes | |
=== Checking for required stuff... === | |
checking for openssl/ssl.h... yes | |
checking for openssl/conf_api.h... yes | |
checking for rb_str_set_len() in ruby.h... yes |
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
~$ git clone https://github.com/tetalab/deux-mille.git | |
Cloning into 'deux-mille'... | |
remote: Counting objects: 6, done. | |
remote: Compressing objects: 100% (4/4), done. | |
remote: Total 6 (delta 0), reused 6 (delta 0) | |
Unpacking objects: 100% (6/6), done. | |
~$ cd deux-mille/ | |
deux-mille (master)$ cp ../code/deux-mille/index.html . | |
deux-mille (master)$ gco "remove unused html" | |
[master 89b27d0] remove unused html |
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
# thsf.tetalab.org | |
server { | |
listen 80; | |
server_name thsf.tetalab.org; | |
access_log /var/log/nginx/thsf.access.log; | |
error_log /var/log/nginx/thsf.error.log; | |
location / { | |
root /var/www/thsf-2012; |
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
# | |
# input: | |
# | |
# >> log | |
# => [{:time=>201201, :x=>2}, {:time=>201201, :y=>7}, {:time=>201201, :z=>2}, {:time=>201202, :a=>3}, {:time=>201202, :b=>4}, {:time=>201202, :c=>0}] | |
# | |
result = {} | |
log.each do |line| | |
result[line[:time]] = result[line[:time]].nil? ? line : result[line[:time]].merge(line) |
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
var SerialPort = require("serialport").SerialPort; | |
var serialPort; | |
try { | |
serialPort = new SerialPort("/dev/ttyACM0", { baudrate: 38400 }); | |
} catch(e) { | |
console.error(e.stack); | |
serialPort = { write: console.log }; | |
} | |
setInterval(function() { |
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
import serial | |
import time | |
class pypong: | |
def __init__(self, port="/dev/ttyACM0", baudrate=38400): | |
self.__s = serial.Serial(port=port, baudrate=baudrate) | |
def send_text(self, data): | |
if len(data) == 432: | |
try: |
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
use <write.scad> | |
// Define box size | |
// it will compute the hole to leave inside these box | |
// depending on the wall size | |
box_size = [120,30,90]; | |
wall_size = 1.6; | |
inner_size = [ | |
box_size[0] - (wall_size * 2), | |
box_size[1] - (wall_size * 2), |