Building an open Internet of Things with Java & Eclipse IoT - - PowerPoint PPT Presentation

building an open internet of things with java eclipse iot
SMART_READER_LITE
LIVE PREVIEW

Building an open Internet of Things with Java & Eclipse IoT - - PowerPoint PPT Presentation

Building an open Internet of Things with Java & Eclipse IoT Benjamin Cab Eclipse Foundation IoT is Big Java for IoT? 9+ million Java developers Java 8 & embedded are fun Lots of IoT devices running on ARM Tooling


slide-1
SLIDE 1

Building an open Internet of Things with Java & Eclipse IoT

Benjamin Cabé – Eclipse Foundation

slide-2
SLIDE 2

IoT is Big

slide-3
SLIDE 3
slide-4
SLIDE 4

Java for IoT?

  • 9+ million Java developers
  • Java 8 & embedded are fun
  • Lots of IoT devices running on ARM
  • Tooling
slide-5
SLIDE 5

Open IoT Stack for Java

slide-6
SLIDE 6

Actuators/Sensors + Gateway + [ Cloud ] + User front-end

End-to-end IoT with Java?

slide-7
SLIDE 7

Sensors / Actuators

  • Manipulate sysfs directly
  • Use Pi4J to have full support of GPIO/I2C/SPI
  • Device I/O API with Java or Java ME
slide-8
SLIDE 8

Sensors / Actuators

  • Pi4J – http://pi4j.com
  • Complete access to GPIOs/I2C/SPI
  • Very mature codebase, based on WiringPi
  • Support for popular shields (PiFace, Gertboard, …)
  • Lots of code samples
slide-9
SLIDE 9

Pi4J in action

GpioController gpio = GpioFactory.getInstance(); GpioPinDigitalOutput pin = gpio.provisionDigitalOutputPin( RaspiPin.GPIO_01, "MyLED", PinState.HIGH); Thread.sleep(5000); pin.low(); Thread.sleep(5000); pin.toggle(); gpio.shutdown();

slide-10
SLIDE 10

Gateway

slide-11
SLIDE 11

Gateway

slide-12
SLIDE 12

Gateway

slide-13
SLIDE 13

Gateway

Connect sensors to the world Manage the hardware and software running at the edge

slide-14
SLIDE 14

Connect?

  • CoAP
  • « HTTP over UDP »
  • Expose your device as a resource to the Internet of

Things

  • MQTT
  • Publish/Subscribe model
  • More room for local processing
slide-15
SLIDE 15

CoAP: The web-of-things

/walk /hand/left/raise /eye/picture /on /red /green /blue /mtbf /on /on /buttons /buttons/1/push /bat-level /engine/status /position /fuel /CO2 /noise /lights/on

slide-16
SLIDE 16

Eclipse Californium

  • Focus on scalability and usability
  • To be used in IoT cloud servers or M2M/IoT

devices running Java

  • Includes DTLS implementation (Scandium),

HTTP/CoAP bridge, Plugtests, … http://eclipse.org/californium

slide-17
SLIDE 17

MQTT: Publish & Subscribe

BROKER

slide-18
SLIDE 18

Eclipse Paho

  • Open-source MQTT clients
  • Pick your language!
  • Java
  • JavaScript
  • C/C++, Objective C
  • Go, Lua, Python, .NET, WinRT, …

http://eclipse.org/paho

slide-19
SLIDE 19

MQTT brokers

  • Eclipse Mosquitto
  • C implementation
  • Scalable (1000 clients == 3MB RAM)
  • Eclipse Moquette
  • Java implementation
  • Based on Netty and LMAX disruptor
slide-20
SLIDE 20

Manage?

  • Gateway itself
  • wireless modem, firewall, …
  • Applications
  • Install/Uninstall software packages
  • Start/Stop applications
  • Sensors
  • H/W abstraction layer
slide-21
SLIDE 21

Java VM OSGi Application Container Device Abstraction Gateway Basic Services

Network Configuration

Network Management Field Protocols Connectivity and Delivery Administration GUI Operation & Management

Linux Hardware

App 1 App 2 App n

. . . . Applications

Eclipse Kura

slide-22
SLIDE 22

Installing Kura

cd ¡~ ¡ sudo ¡apt-­‑get ¡update ¡ wget ¡https://s3.amazonaws.com/kura_downloads/raspbian/release/ ¡\ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡1.1.0/kura_1.1.0_raspberry-­‑pi_armv6.deb ¡ sudo ¡dpkg ¡-­‑i ¡kura_1.1.0_raspberry-­‑pi_armv6.deb ¡ sudo ¡apt-­‑get ¡install ¡-­‑f ¡ sudo ¡reboot ¡ ¡

slide-23
SLIDE 23

First steps with Kura

  • Network management
  • Cellular Modem, WiFi
  • Firewall
  • NAT
  • OSGi and system administration
  • IoT server communication settings
slide-24
SLIDE 24

Kura API

  • OSGi services that you can re-use in your own

components

  • ClockService
  • DataService, CloudService
  • CryptoService (AES, base64, SHA-1)
  • PositionService (geolocation)
  • … and many others
  • And of course you can leverage a huge

ecosystem of Java and OSGi libraries

slide-25
SLIDE 25

Demo time!

slide-26
SLIDE 26

End-user interaction

  • JavaFX Charts
  • Eclipse BIRT
  • Smartphone app (e.g Android)
  • https://www.eclipse.org/paho/clients/android
  • MQTT + WebSockets = ♡
  • https://www.eclipse.org/paho/clients/js
slide-27
SLIDE 27

Kura is awesome! Go download it now! http://eclipse.org/kura

If you had to remember only 3 things...

#1

slide-28
SLIDE 28

Build your own greenhouse & follow the tutorial http://iot.eclipse.org/java/tutorial

If you had to remember only 3 things...

#2

slide-29
SLIDE 29

Eclipse Open IoT Stack for Java is much more than Kura http://iot.eclipse.org/java

If you had to remember only 3 things...

#3

slide-30
SLIDE 30

Get Involved!

slide-31
SLIDE 31

Thank you! Questions?

benjamin@eclipse.org @kartben

http://iot.eclipse.org