Skip to content

Instantly share code, notes, and snippets.

@shigaku
shigaku / minimum-cassandra-ruby-by-thrift
Created Jul 10, 2010
Using Cassandra on Mac OS X with Ruby
View minimum-cassandra-ruby-by-thrift
#!/usr/bin/ruby
$KCODE='u'
require 'cassandra'
transport = Thrift::BufferedTransport.new(Thrift::Socket.new("127.0.0.1","9160"))
transport.open
client = CassandraThrift::Cassandra::Client.new(Thrift::BinaryProtocol.new(transport))
View Simple way to eliminate tags
echo "<p>hogehoe&nbsp;hoeghoge</p>" | w3m -T text/html -dump
@shigaku
shigaku / A.P. Shield Demo Program for Arduino 0018
Created May 26, 2010
Arduino用心拍センサーシールドのデモプログラムです。詳細はこちら: http://koress.jp/2010/05/arduinoap_shield.html
View A.P. Shield Demo Program for Arduino 0018
/*
A.P. Shield 05 Demo Program
Created by @shigaku / KORESS
http://koress.jp/
http://twitter.com/shigaku
*/
int sensorPin = 4;
int ledPin = 13;
int sensorValue = 0;