With upcoming controllers like Espruino and Tessel as well as new, programmable input devices (leap motion, ocolus rift) and their respective JS-APIs, javascript is steadily evolving and shifting into the physical world.
Felix will give a short introduction about the current state of "javascript in the real world" and bring some ideas and stuff to play with.
14. INTERNET OF THINGS
A BRIEF INTRODUCTION
•
A connection of „Things“ (real world objects) with
our beloved InternetsTM
•
Enriches all day life experience with Facebook like
counters awesome metadata and functionality
•
Will hopefully make our lives a lot easier
!14
17. NOT SO OBVIOUS
EXAMPLES
http://commons.wikimedia.org/wiki/File:Cow_female_black_white.jpg
A street sign that adjusts
its contents and
directions based
on user input:
!
!
http://breakfastny.com/points/
Dutch Company „Sparked“
is using wireless sensors on cattle
!
!
!
!
http://www.iotworks.com/#!sensors/c14wo
!17
Dominic Wilcox has created a fully
functional prototype pair of shoes that will
guide the wearer to any destination
!
!
!
http://dominicwilcox.com/portfolio/gpsshoe/
19. IN THE BEGINNING THERE WAS
ARDUINO
• Created 2000 by Massimo Banzi
• Open Source Hardware and Software
• Extendable, Programmable
http://arduino.cc/
!19
20. !
RASPBERRY PI
• First version released in 2011
• credit-card-sized
single-board computer
http://www.raspberrypi.org/
!20
21. !
ESPRUINO
• 2013 (to be released)
• JavaScript interpreter for
microcontrollers
http://www.espruino.com/
!21
22. BONUS :)
MAKEY MAKEY
• An Invention Kit for Everyone
• Turn everyday objects into
touchpads and combine them with
the internet
http://www.makeymakey.com/
!22
25. !
LEAP MOTION
• Motion Sensing Device
• Browse the web, read articles,
flip through photos, and play
music just by lifting a finger
• API App ecosystem
https://www.leapmotion.com/ https://developer.leapmotion.com/ !25
26. !
SPHERO
• It's the world's first robotic ball
that you control with a tilt, touch,
or swing from your smartphone
or tablet
• API and SDK
www.gosphero.com https://developer.gosphero.com/
!26
27. !
OCULUS RIFT
• virtual reality head-mounted display
• API and SDK
http://www.oculusvr.com/ https://developer.oculusvr.com/
!27
33. SO LETS TALK ABOUT
ALL THE THINGS!
EXCEPT FOR THE COWS.
!33
34. SO LETS TALK ABOUT
JAVASCRIPT ALL THE THINGS!
!
!
!
… FINALLY! :)
!34
35. !
WHY JAVASCRIPT?
•
Easy to learn
•
Asynchronous
•
Popular, great Community
•
Awesome because it’s not C. :)
•
The last one might depend on who you’re talking to
!35
36. „Any application that can be written in JavaScript,
will eventually be written in JavaScript“
–Jeff Atwood / The Principle of Least Power
http://www.codinghorror.com/blog/2007/07/the-principle-of-least-power.html
!36
37. !
WHAT CAN BE DONE VIA JS?
Build the Frontend (if needed)
Build your Server/Services (i.e. with node.js)
End to end communication (WebRTC)
Hardware Read/Write (node-serialport)
!37
38. !
WHAT CAN BE DONE VIA JS?
Build the Frontend (if needed)
Build your Server/Services (i.e. with node.js)
End to end communication (WebRTC)
Hardware Read/Write (node-serialport)
!38
40. !
NODUINO
• A simple and flexible JavaScript
and Node.js Framework for accessing
basic Arduino controls from
Web Applications using HTML5,
Socket.IO and Node.js.
http://semu.github.io/noduino/
!40
42. !
JOHNNY FIVE
• Johnny-Five is an Open Source,
JavaScript Arduino programming
framework
• developed at Bocoup (yup: these
guys that contribute to almost all
major JS projects).
https://github.com/rwaldron/johnny-five http://bocoup.com/
!42
43. JOYSTICK CONTROLLED LASER
JOHNNY FIVE
var five = require(../lib/johnny-five.js),
board = five.Board({
debug: true
});
board.on(ready, function() {
var range, pan, tilt, joystick;
range = [ 0, 170 ];
// Servo to control panning
pan = five.Servo({
pin: 9,
range: range
});
// Servo to control tilt
tilt = five.Servo({
pin: 10,
range: range
});
// Joystick to control pan/tilt
// Read Analog 0, 1
// Limit events to every 100ms
joystick = five.Joystick({
pins: [ A0, A1 ],
freq: 100
});
// Center all servos
(five.Servos()).center();
joystick.on(axismove, function() {
tilt.move( Math.ceil(170 * this.fixed.y) );
pan.move( Math.ceil(170 * this.fixed.x) );
});
http://jsfiddle.net/rwaldron/YHb7A/show/light/
!43
44. !
NODE AR-DRONE
• An implementation of the
networking
protocols used by the Parrot
AR Drone 2.0.
https://github.com/felixge/node-ar-drone
!44
46. !
NODE AR-DRONE: NODECOPTER
• „There’s a meet up for that!“
• http://nodecopter.com/
• @nodeCopter
https://github.com/felixge/node-ar-drone
!46
47. OK, THIS WAS QUITE A LOT OF
GEEKY GADGET STUFF. BUT HOW
DOES THIS FIT INTO MY
BUSINESS MODEL?
!47
48. BRITISH AIRWAYS
BILLBOARD CAMPAIGN
• Combines IoT with Classic Campaign
• Get’s a lot of „buzz“
• Would be easy to implement with JS:
• Flights API
• Kinect (node-kinect )
• Some very expensive large screen :)
http://mashable.com/2013/11/25/british-airways-billboard/ https://github.com/pgte/node-kinect
!48
49. CA
FASHION LIKE
• Shows 'Likes' on their respective
Clothing Racks
• Combines IoT with Classic Campaign
• Get’s a lot of „buzz“
• Would be easy to implement with JS:
• Facebook Graph-API
• Arduino Mini
• Some very cheap small led screens :)
http://infosthetics.com/archives/2012/05/ca_fashion_like_real-time_facebook_likes_shown_on_clothing_racks.html
!49
55. QUESTIONS? FEEDBACK?
DROP ME A LINE:
@FELIXWAHNER
!
…AND BE SURE TO VISIT OUR BLOG. THERE WILL BE MORE
#IOT POSTS COMING SOON:
HTTP://NEUWAERTS.DE/EMERGE
!55