OUT OF THE BOX – BREAKDOWN

Gilda Coustier teilt mit uns ihre Erfahrungen mit Arduinos und Roboterschwärmen im Theater.

How to let robots play theater

15:30 – 16:00 Live Tutorial

16:00 – 16:30 Gespräch / Q&A

BACKGROUND

https://www.hfs-berlin.de/studium/puppenspielkunst/

ARDUINO: SENSOR > OUPUT

z.B. LightTheremin:

/*
Arduino Starter Kit example
Project 6 – Light Theremin

This sketch is written to accompany Project 6 in the Arduino Starter Kit

Parts required:

  • photoresistor
  • 10 kilohm resistor
  • piezo created 13 Sep 2012
    by Scott Fitzgerald http://www.arduino.cc/starterKit This example code is part of the public domain.
    */

// variable to hold sensor value
int sensorValue;
// variable to calibrate low value
int sensorLow = 1023;
// variable to calibrate high value
int sensorHigh = 0;
// LED pin
const int ledPin = 13;

void setup() {
// Make the LED pin an output and turn it on
pinMode(ledPin, OUTPUT);
digitalWrite(ledPin, HIGH);

// calibrate for the first five seconds after program runs
while (millis() < 5000) { // record the maximum sensor value sensorValue = analogRead(A0); if (sensorValue > sensorHigh) {
sensorHigh = sensorValue;
}
// record the minimum sensor value
if (sensorValue < sensorLow) {
sensorLow = sensorValue;
}
}
// turn the LED off, signaling the end of the calibration period
digitalWrite(ledPin, LOW);
}

void loop() {
//read the input from A0 and store it in a variable
sensorValue = analogRead(A0);

// map the sensor values to a wide range of pitches
int pitch = map(sensorValue, sensorLow, sensorHigh, 50, 4000);

// play the tone for 20 ms on pin 8
tone(8, pitch, 20);

// wait for a moment
delay(10);
}

https://www.avant-verlag.de/comics/pinocchio/

Uncanny valley: https://de.wikipedia.org/wiki/Uncanny_Valley

1/0/1 robots – hacking the binary code

PID regler: https://de.wikipedia.org/wiki/Regler

SCHWARM?

Positionierung:

Infrarot LED + Kamera

RFID: https://de.wikipedia.org/wiki/RFID

UWB positionierung

INTERAKTION?

erfassung:

open CV

kinect

ROBOTER SPIEL:

LED

https://learn.adafruit.com/adafruit-neopixel-uberguide/arduino-library-use

0 bis 39
LED nummer

https://create.arduino.cc/editor

// NeoPixel test program showing use of the WHITE channel for RGBW
// pixels only (won’t look correct on regular RGB NeoPixel strips).

#include <Adafruit_NeoPixel.h>
#ifdef __AVR__
#endif

// Which pin on the Arduino is connected to the NeoPixels?
#define LED_PIN     6

// How many NeoPixels are attached to the Arduino?
#define LED_COUNT  40

// NeoPixel brightness, 0 (min) to 255 (max)
#define BRIGHTNESS 255

// Declare our NeoPixel strip object:
Adafruit_NeoPixel pixels(LED_COUNT, LED_PIN, NEO_GRBW + NEO_KHZ800);
// Argument 1 = Number of pixels in NeoPixel strip
// Argument 2 = Arduino pin number (most are valid)
// Argument 3 = Pixel type flags, add together as needed:
//   NEO_KHZ800  800 KHz bitstream (most NeoPixel products w/WS2812 LEDs)

void setup() {
  pixels.begin();           // INITIALIZE NeoPixel strip object (REQUIRED)
  pixels.show();            // Turn OFF all pixels ASAP
  pixels.setBrightness(255); // Set BRIGHTNESS to about 1/5 (max = 255)

}

void loop() {

   //various colors… 50 brightness
  //(255,   0,   0)     , 50); // Red
  //(  0, 255,   0)     , 50); // Green
  //(  0,   0, 255)     , 50); // Blue
  //(  0,   0,   0, 255), 50); // True white (not RGB white)

    // pixels.Color() takes RGB values, from 0,0,0 up to 255,255,255
    // Here we’re using a moderately bright green color:
    pixels.setPixelColor(2, pixels.Color(0, 0, 250, 0));
  //  pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(3, pixels.Color(0, 0, 250, 0));
 //   pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(4, pixels.Color(0, 0, 250, 0));
  //  pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(5, pixels.Color(0, 0, 250, 0));
  //  pixels.show();   // Send the updated pixel colors to the hardware

    pixels.setPixelColor(9, pixels.Color(0, 0, 250, 0));
  //  pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(14, pixels.Color(0, 0, 250, 0));
  //  pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(23, pixels.Color(0, 0, 250, 0));
 //   pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(16, pixels.Color(0, 0, 250, 0));
 //   pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(25, pixels.Color(0, 0, 250, 0));
 //   pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(30, pixels.Color(0, 0, 250, 0));
 //   pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(34, pixels.Color(0, 0, 250, 0));
 //   pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(35, pixels.Color(0, 0, 250, 0));
  //  pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(36, pixels.Color(0, 0, 250, 0));
//    pixels.show();   // Send the updated pixel colors to the hardware.

    pixels.setPixelColor(37, pixels.Color(0, 0, 250, 0));
    //pixels.show();   // Send the updated pixel colors to the hardware.

//pupille
    pixels.setPixelColor(20, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(20, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(19, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(19, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(18, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(18, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(17, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(17, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(18, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(18, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(19, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(19, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(20, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(20, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(21, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(21, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(22, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(22, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    pixels.setPixelColor(21, pixels.Color(250, 250, 250, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
    delay(100);
    pixels.setPixelColor(21, pixels.Color(0, 0, 0, 0));
    pixels.show();   // Send the updated pixel colors to the hardware.
}

https://theater.digital/