Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentes Révision précédente Prochaine révision | Révision précédente | ||
|
materiel:teensy:accueil [2015/02/13 10:07] resonance |
materiel:teensy:accueil [2016/02/01 00:05] (Version actuelle) resonance |
||
|---|---|---|---|
| Ligne 8: | Ligne 8: | ||
| * http:// | * http:// | ||
| * http:// | * http:// | ||
| + | |||
| + | |||
| + | ===== Teensy Vs Arduino ===== | ||
| + | * Tests de latence : http:// | ||
| ===== Pins ===== | ===== Pins ===== | ||
| + | * http:// | ||
| + | |||
| {{: | {{: | ||
| + | |||
| + | |||
| {{: | {{: | ||
| ===== Teensy et Raspberry Pi ===== | ===== Teensy et Raspberry Pi ===== | ||
| - | http:// | + | * http:// |
| {{: | {{: | ||
| + | |||
| + | |||
| + | |||
| + | ===== Ethernet ===== | ||
| + | * http:// | ||
| + | * http:// | ||
| + | * https:// | ||
| + | |||
| + | {{: | ||
| + | |||
| + | {{: | ||
| + | |||
| + | |||
| + | ===== Touch > Midi ===== | ||
| + | Envoie de valeurs avec touchRead() en MIDI. | ||
| + | |||
| + | <code cpp> | ||
| + | // adpapted from http:// | ||
| + | |||
| + | /* TOUCHPINS */ | ||
| + | int const nbTouch = 6; // number of pins to use as touchpins, sending note values | ||
| + | int touch[nbTouch]; | ||
| + | int touchOn[nbTouch]; | ||
| + | int touchPins[] = {15, | ||
| + | int touchPitch[] = {36, | ||
| + | int touchThreshold = 3200; | ||
| + | |||
| + | const int channel = 1; | ||
| + | |||
| + | void setup() { | ||
| + | | ||
| + | | ||
| + | |||
| + | void loop() { | ||
| + | | ||
| + | for (int i = 0; i < nbTouch; i++) { | ||
| + | | ||
| + | touch[i] = touchRead(touchPins[i]); | ||
| + | // | ||
| + | // | ||
| + | | ||
| + | if (touch[i] > touchThreshold && touchOn[i] == 0) { | ||
| + | usbMIDI.sendNoteOn(touchPitch[i], | ||
| + | touchOn[i] = 1; | ||
| + | } | ||
| + | if (touch[i] < touchThreshold && touchOn[i] == 1) { | ||
| + | usbMIDI.sendNoteOff(touchPitch[i], | ||
| + | touchOn[i] = 0; | ||
| + | } | ||
| + | } | ||
| + | | ||
| + | // | ||
| + | | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | {{tag> | ||