hacking meatspace with arduino and pyfirmata
Post on 15-Jul-2015
68 Views
Preview:
TRANSCRIPT
HACKING MEATSPACE with Arduino and pyFirmata
!!!
Ches Martin http://chesmart.in | @ches
ThaiPy April 2015
WHAT IS ARDUINO?
• A microcontroller with I/O on a PCB
• Electronics teaching tool
• Interactive arts & media component
• Embedded systems prototyping environmentBring your Internet of Things buzzwords!
OPEN HARDWARE
• Specifications available to build your own
• Take your prototypes to productionno licenses needed
• Build a prototype, minimize it, design PCB, get it fabricated
• Open source software toolchain
WHAT’S A MICROCONTROLLER?
• Processor with program and data memory onboard in one chip
• Usually runs a single program, no operating system
• Most Arduinos are Atmel AVR family, 8-bit RISC
• Arduino AVR chips also have EEPROMnon-volatile storage, persists across power-offs
HOW DOES ARDUINO COMPARE TO OTHER PLATFORMS?
• Spark, Wiring, etc.AVR & other microcontroller alternatives
• Raspberry Pi, BeagleBone, Intel Edison Single-board computers or microcontroller hybrids
ELECTRONICS FUNDAMENTALS
• General-purpose IO (GPIO), analog & digital pins
• Digital pins generally read or write on/off (high/low) statesSimple two-way sensors like buttons
• Analog reads voltages 0-5V, translated to values 0-1023 (10-bit res. ADC)Continuous sensors, common real-world phenomena
• Pulse Width Modulation Switches on/off thousands of times per sec, simulating wave behavior of analog outputDimming, controlling speed of motors
• i2c (Two-wire Interface or TWI) is a special function Allows connecting network of many sensors/actuatorsCan also network many Arduino boards
DEVELOPING WITH ARDUINO
• Standalone (Embedded) Projects
• Client / Server Projects
STANDALONE PROJECTS
• Arduino language and IDE (C++)
• AVR C and assembly avr-gcc / avr-libc toolchain, LLVM
CLIENT/SERVER PROJECTS
• Processing, Max/MSPInteractive graphics and music environments
• Firmata • A specified serial protocol that has become a
common standard • Client libraries in numerous languages • Firmware can potentially run on other hardware
DEMO TIME!
RESOURCES• Part Sources in Thailand
• http://www.thaieasyelec.com/en/ • http://www.arduino.in.th/ • element14 - http://www.newark.com/ and http://th.element14.com/
• Starter Kits • Official Arduino Kit
• Video tour of Starter Kit projects with founder Massimo Banzi • Fritzing Creator Kit • Adafruit Starter Kit • Sparkfun Inventor’s Kit • Make Starter Kit
• Learning Hubs • https://learn.sparkfun.com/ • https://learn.adafruit.com/ • http://forum.arduino.cc/ and http://www.element14.com/community/groups/arduino • http://wiring.org.co/learning/tutorials/ • http://www.instructables.com/tag/type-id/category-technology/channel-arduino/
RESOURCES• Electronics Fundamentals
• https://learn.sparkfun.com/tutorials/what-is-an-arduino • https://processing.org/tutorials/electronics/ • https://learn.sparkfun.com/tutorials/serial-communication
• Hardware Info and Specs • Atmel AVR on Wikipedia • Atmel official AVR pages - specs, data sheets, etc.
• Software Resources - Libraries, Tools • Explanation of Arduino Build Process • Examples of Arduino Language & Library Usage • AVR LLVM backend • Firmata Spec • Firmata Libraries
• https://github.com/tino/pyFirmata and examples helpful for starting out • http://artoo.io/(Ruby) • http://gobot.io/ (Go) • http://cylonjs.com/ (JavaScript) • https://github.com/rwaldron/johnny-five (JavaScript)
• Fritzing - basic open-source schematic and PCB design • They aim to provide a complete pipeline with PCB fabrication services available
• EAGLE CAD - more advanced but an industry-standard PCB/schematic design package
top related