Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
| Beide Seiten der vorigen RevisionVorhergehende Überarbeitung | |||
| fablab:battlebot:arena [17.12.2024 09:52] – christian.prim | fablab:battlebot:arena [17.12.2024 09:56] (aktuell) – [Arduino-Programm] christian.prim | ||
|---|---|---|---|
| Zeile 10: | Zeile 10: | ||
| <file c arena.ino> | <file c arena.ino> | ||
| - | // NeoPixel Ring simple sketch (c) 2013 Shae Erisson | + | // Antweight-Arena |
| - | // Released under the GPLv3 license to match the rest of the | + | // Kantonsschule Zürich Nord |
| - | // Adafruit NeoPixel library | + | |
| #include < | #include < | ||
| Zeile 18: | Zeile 17: | ||
| #include < | #include < | ||
| - | // Which pin on the Arduino is connected to the NeoPixels? | + | #define NEOPIXEL_PIN |
| - | #define NEOPIXEL_PIN | + | |
| #define LIFT_PIN1 9 | #define LIFT_PIN1 9 | ||
| #define LIFT_PIN2 10 | #define LIFT_PIN2 10 | ||
| Zeile 26: | Zeile 24: | ||
| #define BUMPER_LED_PIN 4 | #define BUMPER_LED_PIN 4 | ||
| - | // How many NeoPixels are attached to the Arduino? | ||
| #define PIT_PIXEL_START 0 | #define PIT_PIXEL_START 0 | ||
| #define PIT_PIXEL_END 4 | #define PIT_PIXEL_END 4 | ||
| Zeile 34: | Zeile 31: | ||
| #define ARENA_PIXEL_END 91 // Popular NeoPixel ring size | #define ARENA_PIXEL_END 91 // Popular NeoPixel ring size | ||
| - | |||
| - | |||
| - | // When setting up the NeoPixel library, we tell it how many pixels, | ||
| - | // and which pin to use to send signals. Note that for older NeoPixel | ||
| - | // strips you might need to change the third parameter -- see the | ||
| - | // strandtest example for more information on possible values. | ||
| Adafruit_NeoPixel pixels(ARENA_PIXEL_END, | Adafruit_NeoPixel pixels(ARENA_PIXEL_END, | ||
| Buzzer buzzer(11); | Buzzer buzzer(11); | ||
