2009年4月22日 星期三

Smart Car API for smart tiles



int switchPin = 2; // switch input
int motor1go = 3; // H-bridge leg 1 (pin 2, 1A)
int motor1back = 4; // H-bridge leg 2 (pin 7, 2A)
int motor2go = 5; // H-bridge leg 1 (pin 2, 1A)
int motor2back = 6; // H-bridge leg 2 (pin 7, 2A)
int enablePin = 9; // H-bridge enable pin
int ledPin = 13; // LED

void setup() {
// set the switch as an input:
pinMode(switchPin, INPUT);

// set all the other pins you're using as outputs:
pinMode(motor1go, OUTPUT);
pinMode(motor1back, OUTPUT);
pinMode(motor2go, OUTPUT);
pinMode(motor2back, OUTPUT);
pinMode(enablePin, OUTPUT);
pinMode(ledPin, OUTPUT);

// set enablePin high so that motor can turn on:
digitalWrite(enablePin, HIGH);

// blink the LED 3 times. This should happen only once.
// if you see the LED blink three times, it means that the module
// reset itself,. probably because the motor caused a brownout
// or a short.
blink(ledPin, 3, 100);
}

void loop() {
// if the switch is high, motor will turn on one direction:
if (digitalRead(switchPin) == HIGH) {
digitalWrite(motor1go, LOW); // set leg 1 of the H-bridge low
digitalWrite(motor1back, HIGH); // set leg 2 of the H-bridge high

digitalWrite(motor2go, HIGH); // set leg 1 of the H-bridge low
digitalWrite(motor2back, LOW); // set leg 2 of the H-bridge high

}
// if the switch is low, motor will turn in the other direction:
else {
digitalWrite(motor1go, HIGH); // set leg 1 of the H-bridge high
digitalWrite(motor1back, LOW ); // set leg 2 of the H-bridge low

digitalWrite(motor2go, LOW); // set leg 1 of the H-bridge low
digitalWrite(motor2back, HIGH); // set leg 2 of the H-bridge high
}
}

/*
blinks an LED
*/
void blink(int whatPin, int howManyTimes, int milliSecs) {
int i = 0;
for ( i = 0; i < howManyTimes; i++) {
digitalWrite(whatPin, HIGH);
delay(milliSecs/2);
digitalWrite(whatPin, LOW);
delay(milliSecs/2);
}
}

References
ITP Physical Computing
Tamiya 70068 Wall-Hugging Mouse Kit
http://letsmakerobots.com/node/2278
http://akashxav.com/2009/04/18/arduino-l293d-dc-motor/

2009年4月15日 星期三

Call for Submission: Emerging Technologies (Siggraph Asia)


Adaptation
We live in a world of unprecedented complexity, where humanity, nature, and technology must adapt to rapidly changing conditions. Digital technology can provide new answers to these challenges, but it can also pose new problems.
Our technology has become so powerful we can now control the genetic makeup of living organisms and cause holes in the ozone layer. Yet some of the most impressive breakthroughs in art and technology happen by considering the gaps and opportunities in the existing landscape - by adapting what we know to what might be. Now, as the world evolves with exponential speed, we need artists and scientists to show us the infinite possibilities of adaptation.
Emerging Technologies is a showcase for innovations that will change the way we work, live, and play. For SIGGRAPH Asia 2009, we are seeking works that show how digital technology adapts, or can help us adapt, to a world in flux. Adaptation can have many meanings, from machines that repair themselves under stress to technologies that help humans survive in adverse conditions. Adaptations can also be unexpected or unwanted. We are particularly interested in seeing examples of how computer graphics and interactive techniques are evolving to adapt to new conditions: technical, social, environmental, or something else entirely.

Emerging Technologies Jury:
Chair
Lars Erik Holmquist
Swedish Institute of Computer Science and Södertörn University
Jury
Mark Billinghurst
HIT Lab New Zealand
Cynthia Breazeal
MIT Media Lab
Paul Debevec
USC Institute for Creative Technologies
Tom Igoe
New York University
Jun Rekimoto
The University of Tokyo
Kimiko Ryokai
University of California, Berkeley
Albrecht Schmidt
University of Duisburg-Essen
Annika Waern
Interactive Institute

2009年4月13日 星期一

Test: floor

1. 每一塊地磚發送自身的訊息至地磚表面
2. 當地磚上方有障礙物,地磚身份由生轉為死。終止訊息的處理。
3. 每塊地磚可以獨立設定成為任一種訊息的源頭。

因此:
機器車或智慧的物件能行走在地磚皮層上,應用環境皮層的資訊執行任務。
牆、障礙物(具相當重量)滯留在地磚上,傳達出障礙的訊息到地磚。

method
透過基因演算的模擬演化後,
我們可以獲得一套有效的設定方式。將最有效的資訊源頭的位置設定至空間中; 將最有效的訊息處理邏輯寫入進智慧物件中。
利用縮尺可互動模型實驗,已驗證假設。

實作功能:
1. 讓每一塊地磚能同時傳輸銲接收來自四個面向的3種訊息。
2. 每塊地磚針對四周與自身的同組訊息找出最大的遞減1,以此為傳遞訊息的邏輯。
3. 每塊地磚能即時將運作中的3組訊息由紅外線散佈到地磚表面,以供智慧物件讀取使用。
4. 每塊地磚可以由重量感測障礙物,當出現障礙時切換自身為死的狀態。
5. 每塊地磚可以各別的設定其成為訊號來源的角色

2009年4月7日 星期二

switch: 1.5v升壓5v控制



arduino角位只能輸出1.5v時
需要控制5v驅動的relay的解決辦法
需準備:tip122、pc817、2sc9013、220歐姆電阻、1k歐姆電阻
即可以自製功率放大器