|
|
Riadok 1: |
Riadok 1: |
| [[Súbor:logoAjTyvIT.png|right|150px]] | | Robili sme: [[Svetielkujúci workshop]] |
|
| |
|
| = '''Svetielkujúci Workshop 18. 12. 2017''' =
| |
| <!--
| |
| = '''Svetielkujúci Workshop 7. a 14. 6. 2017''' =
| |
| -->
| |
|
| |
|
| <gallery widths=120px heights=120px perrow=4 caption="Svetielkujuci Workshop 1 (jún 2017)" mode="packed-hover">
| | [[Category:AjTyvIT]] [[Category:microbit]] |
| File:FotoBlikBlik01.jpg
| |
| File:FotoBlikBlik02.jpg
| |
| File:FotoBlikBlik03.jpg
| |
| File:FotoBlikBlik04.jpg
| |
| File:FotoBlikBlik05.jpg
| |
| File:FotoBlikBlik06.jpg
| |
| File:FotoBlikBlik07.jpg
| |
| File:FotoBlikBlik08.jpg
| |
| </gallery>
| |
| | |
| | |
| <gallery widths=120px heights=120px perrow=4 caption="Svetielkujuci Workshop 2 (december 2018)" mode="packed-hover">
| |
| File:FotoBlikBlik21.jpg
| |
| File:FotoBlikBlik22.jpg
| |
| File:FotoBlikBlik23.jpg
| |
| File:FotoBlikBlik24.jpg
| |
| File:FotoBlikBlik25.jpg
| |
| File:FotoBlikBlik26.jpg
| |
| File:FotoBlikBlik27.jpg
| |
| File:FotoBlikBlik28.jpg
| |
| </gallery>
| |
| | |
| | |
| [[Súbor:wearableDef.png|500px]] | |
| | |
| | |
| == Úvod ==
| |
| | |
| | |
| * [http://senzor.robotika.sk/balogh/wearable.pdf Úvodná prezentácia]
| |
| ** [https://player.vimeo.com/video/114828162 Spider dress video]
| |
| ** [https://www.youtube.com/watch?v=RkHnmhWYojo Cognitive Dress by Marchesa and IBM Watson] ([https://www.ibm.com/blogs/think/2016/04/watson-and-marchesa/ read more...])
| |
| ** [https://chromat.co/blogs/news/63131779-chromat-ss16-momentum Smart športová podprsenka] aj [https://www.wareable.com/fashion/new-york-fashion-week-wearable-tech-september-2015 tu] a [https://www.wareable.com/intel/intels-ayse-ildeniz-wearable-tech-is-all-fitness-fitness-fitness-which-needs-to-change-920 tuto]
| |
| ** Uzitocne oblecenia [https://www.wareable.com/smart-clothing/best-smart-clothing - vyber]
| |
| ** [https://www.dezeen.com/2017/10/22/ying-gaos-dresses-become-animated-in-the-presence-of-strangers/ Ying Gaos dress]
| |
| ** [https://cutecircuit.com/wearable-technology/ Cute Circuit]
| |
| ** [https://twitter.com/intelai/status/929473325428019200 Posilňovací oblek od IBM]
| |
| | |
| * [https://learn.adafruit.com/category/wearables Wearables od firmy Adafruit]
| |
| ** 1: [https://learn.adafruit.com/candle-flicker-hair-bow/ Mašľa]
| |
| ** 2: [https://learn.adafruit.com/sparkle-skirt/ Sukňa]
| |
| ** 3: [https://learn.adafruit.com/twinkling-led-parasol Dáždnik]
| |
| ** 4: [https://learn.adafruit.com/led-ampli-tie Kravata]
| |
| ** 5: [https://learn.adafruit.com/light-activated-pixel-heart/ Brošňa]
| |
| | |
| == '''1. Krok za krokom''' ==
| |
| | |
| == 1.1. '''Blink''' ==
| |
| | |
| * [http://ap.urpi.fei.stuba.sk/sensorwiki/index.php/Acrob02 Blink]
| |
| | |
| == 1.2. '''Železničné priecestie''' ==
| |
| | |
| * [https://youtu.be/YaH8DJpeYs0?t=1m6s Video]
| |
| | |
| == 1.3. '''K.I.T.T. 2000''' ==
| |
| | |
| * [https://youtu.be/iQwlrEdka6Q?t=5s Video]
| |
| | |
| == 1.4. Ak to nefunguje... ==
| |
| | |
| ...tak [[Acrob Settings|skontrolujte nastavenia]].
| |
| | |
| <BR>
| |
| <BR>
| |
| <BR>
| |
| | |
| = '''2. A teraz už naozaj...''' =
| |
| | |
| | |
| == 2.1. Adafruit Gemma ==
| |
| | |
| * [https://learn.adafruit.com/introducing-gemma/ Stránka u výrobcu so všetkými informáciami]
| |
| | |
| [[Súbor:AdafruitGemma.png|500px|center]]
| |
| | |
| V programovacom prostredí Arduino treba najprv nastaviť typ elektronickej dosky
| |
| na '''Adafruit Gemma 8MHz''' v menu Tools->Board.
| |
| | |
| [[Súbor:flora_gemmaselect.gif|center]]
| |
| | |
| | |
| Potom ešte treba vybrať vhodný programovací protokol -
| |
| vyeberiete ho z menu Tools->Programmer->'''USBtinyISP'''
| |
| | |
| [[Súbor:gemma_flora_selectusbtiny.gif|center]]
| |
| | |
| | |
| == 2.2. Blink ==
| |
| | |
| Príklad čiapky s obyčajnými LED diódami - ukážka šitia: https://learn.adafruit.com/adafruit-led-sequins/
| |
| | |
| Vyskúšame postupne jednoduché programy
| |
| | |
| <source lang="Cpp">
| |
| /* Blink 1 */
| |
|
| |
| #define RED_LED 1
| |
| | |
| void setup() {
| |
|
| |
| pinMode(RED_LED, OUTPUT);
| |
| | |
| }
| |
| | |
| void loop() {
| |
| digitalWrite(RED_LED, HIGH);
| |
| delay(200);
| |
| digitalWrite(RED_LED, LOW);
| |
| delay(200);
| |
| }
| |
| </source>
| |
| | |
| | |
| <source lang="Cpp">
| |
| /* Blink 3 */
| |
|
| |
| #define RED_LED 0
| |
| #define GREEN_LED 1
| |
| #define BLUE_LED 2
| |
| | |
| void setup() {
| |
|
| |
| pinMode(RED_LED, OUTPUT);
| |
| pinMode(GREEN_LED, OUTPUT);
| |
| pinMode(BLUE_LED, OUTPUT);
| |
| | |
| }
| |
| | |
| void loop() {
| |
| digitalWrite(RED_LED, HIGH);
| |
| delay(200);
| |
| digitalWrite(RED_LED, LOW);
| |
| delay(200);
| |
| | |
| digitalWrite(GREEN_LED, HIGH);
| |
| delay(200);
| |
| digitalWrite(GREEN_LED, LOW);
| |
| delay(200);
| |
| | |
| digitalWrite(BLUE_LED, HIGH);
| |
| delay(200);
| |
| digitalWrite(BLUE_LED, LOW);
| |
| delay(200);
| |
| | |
| }
| |
| </source>
| |
| | |
| | |
| Plynulá zmena intenzity svitu LED diody (funguje len na D0 a D1, na D2 NIE)
| |
| | |
| <source lang="C">
| |
| int intenzita;
| |
|
| |
| void setup() {
| |
| intenzita = 0;
| |
| pinMode(1,OUTPUT);
| |
| }
| |
| | |
| void loop() {
| |
| intenzita = 0;
| |
| for(int i=0; i<10 ; i++)
| |
| {
| |
| intenzita = intenzita + 25;
| |
| analogWrite(1,intenzita);
| |
| delay(50);
| |
| }
| |
| | |
| }
| |
| </source>
| |
| | |
| == 2.3. NeoPixel RGB ==
| |
| | |
| | |
| Priklady práce s inteligentnou RGB LED diódou [https://blog.adafruit.com/2013/08/30/adafruit-neopixel-uberguide/ Neopixel].
| |
| | |
| Napríklad takáto [https://learn.adafruit.com/led-masquerade-masks/neopixel-gemma-mask maska na maškarný bál...]
| |
| | |
| ToDo: niekoľko pekných ukážkových programov, ktoré by sa dali vlastne aplikovať aj na obyčajné diódy http://moving-rainbow.readthedocs.io/en/latest/guide/list-of-sample-programs/
| |
| Schéma pripojenia
| |
| | |
| [[Súbor:AdafruitNeoPixelConnection.jpg]]
| |
| | |
| | |
| Základný príklad s jednou diódou
| |
| | |
| <source lang="C">
| |
| #include <Adafruit_NeoPixel.h>
| |
|
| |
| #define PIN 1
| |
|
| |
| Adafruit_NeoPixel LED = Adafruit_NeoPixel(1, PIN, NEO_GRB + NEO_KHZ800);
| |
|
| |
| void setup() {
| |
|
| |
| LED.begin();
| |
| // LED.setPixelColor(n, red, green, blue);
| |
| LED.setPixelColor(0, 0, 0, 127);
| |
| LED.show(); // Show the preset color(s)
| |
| delay(2000);
| |
| LED.setBrightness(100);
| |
| }
| |
|
| |
| void loop() {
| |
| // n R G B
| |
| LED.setPixelColor(0, 255, 0, 127);
| |
| LED.show(); // Show the preset color(s)
| |
| delay(2000);
| |
| LED.setPixelColor(0, 0 , 0, 0);
| |
| LED.show(); // Show the preset color(s)
| |
| delay(2000);
| |
|
| |
| }
| |
|
| |
|
| |
| </source>
| |
| | |
| Základný príklad s dvoma diódami
| |
| <source lang="C">
| |
| #include <Adafruit_NeoPixel.h>
| |
|
| |
| #define PIN 1
| |
|
| |
| Adafruit_NeoPixel LED = Adafruit_NeoPixel(2, PIN, NEO_GRB + NEO_KHZ800);
| |
|
| |
| void setup() {
| |
|
| |
| LED.begin();
| |
| LED.show(); // Show the preset color(s)
| |
| LED.setBrightness(100); // Interval 0 - 255
| |
| }
| |
|
| |
| void loop() {
| |
|
| |
| // LED.setPixelColor(n, red, green, blue);
| |
| LED.setPixelColor(0, 255, 0, 0); // First LED Red
| |
| LED.setPixelColor(1, 0, 0, 127); // Second LED Blue
| |
| LED.show();
| |
| delay(300);
| |
| LED.setPixelColor(0, 0, 0, 127); // First LED Blue
| |
| LED.setPixelColor(1, 255, 0, 0); // Second LED Red
| |
| LED.show();
| |
| delay(300);
| |
|
| |
|
| |
| }
| |
| </source>
| |
| | |
| A celkom na záver: ako prať elektronické odevy?
| |
| https://learn.adafruit.com/washing-wearable-electronics/hand-wash?view=all
| |
| | |
| | |
| === Technicke informacie ===
| |
| | |
| * Adafruit Gemma Windows Driver: https://learn.adafruit.com/introducing-gemma/windows-setup
| |
| * Adafruit Board Arduino Manager: https://adafruit.github.io/arduino-board-index/package_adafruit_index.json
| |
| * Neopixel Library: https://github.com/adafruit/Adafruit_NeoPixel
| |