Commit b6a9102a authored by Maxime Lefrançois's avatar Maxime Lefrançois

full comit

parent d608a324
target
/.nb-gradle/
\ No newline at end of file
File added
rm -f -r target && mkdir target
\ No newline at end of file
LAN NETGEAR95
manage at
admin@password:www.routerlogin.net
emprunts
Jimmy Atta raspberry pi + alim.
Safa utilise B8:27:EB:EF:A6:13 + alimentation + cable ethernet + routeur D-link
Lina utilise B8:27:EB:F5:34:FD (192.168.1.3)
Anthony Saade et Florian Tambon raspberry B8:27:EB:D9:97:C9 avec alimentation, cable USB
Alaa raspberry pi + cable ethernet + routeur netgear
Attention pour l'intant leur IP est dynamique.....
cp -r src/resources/* target
cp -r src/resources/.htaccess target
asciidoctor -D target src/doc/index.adoc
asciidoctor -D target src/doc/labhue.adoc
asciidoctor -D target src/doc/labmqtt.adoc
asciidoctor -D target src/doc/project.adoc
asciidoctor -T util/asciidoctor-deck.js/templates/haml -D target/1 src/doc/1/index.adoc
hue @ 192.168.220.52 NETGEAR 95
3ec2237c10728aa1771edc034ff30689
\ No newline at end of file
Valentin bouilli absence justifiée le 7dec.
\ No newline at end of file
cd target && scp -r . mlefranc@ci.emse.fr:/var/www/html/iot/2017 && cd ..
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
= Internet-of-things
Maxime Lefrançois <maxime.lefrancois@emse.fr>
v1.0, 04-10-2017
:imagesdir: images
:homepage: http://ci.emse.fr/iot/2017/
:stylesheet: github.css
:stylesdir: css
:linkcss:
:toc: left
//:backend: deckjs
//:deckjs_theme: web-2.0
Majeure Informatique / Master CPS2 (MINES Saint-Etienne)
== Introduction
image::Internet_of_Things.jpg[Logo,300,align="center"]
This course overviews the domain of Internet-of-things, which links physical world to the internet and the web. We put the emphasis on relevant technologies and real applications. Hardware-wise, we look at some technologies used in the industry (Orange), and some easy-to-develop ones, like Arduino and Raspberry. Communication-wise, we study the different layers (link, transport, application) required to develop an end-to-end IoT platform.
The course is also complemented by link:project.html[an integrative project] during which students have to applied and choose the relevant technologies and protocols to design a full physical world-to-internet system.
image::Approaches_on_Internet_of_Things_Solutions_Figure_2.png[Approaches]
== News
Website is online [04/10/2017]
Programmable Web and IoT common project description link:project.html[is online] [03/12/2017]
== Contents
|===
|Date |Room |Topic |Speaker|
|Thu 05/10/2017 08:00 - 12:15 |EF S1.32 |Introduction |Maxime Lefrançois | link:1/[Presentation]
|Thu 26/10/2017 08:00 - 10:00 |EF S1.32 |Applications in IoT and WoT: Insight from Orange |Pierre Rust | link:IotApplications.pdf[Applications for the Internet of Things] - link:IoTOrange.pdf[Telecommunication operator perspective]
|Thu 09/11/2017 10:15 - 12:15 |EF S2.23 |Diversity of hardware : an Overview |Pierre Rust | link:IoTHardware.pdf[Introduction to hardware]
|Thu 09/11/2017 08:00 - 10:00 |EF S1.32 |Interaction protocols and Data formats |Amélie Gyrard | link:CoursIoTAmelieGyrardV2.pdf[Presentation]
|Thu 09/11/2017 10:15 - 12:15 |EF S2.23 |Lab Philips Hue |Maxime Lefrançois, Amélie Gyrard| link:labhue.html[Philips Hue]
|Thu 23/11/2017 08:00 - 10:00 |EF S2.23 |Lab MQTT |Maxime Lefrançois | link:labmqtt.html[MQTT]
|Thu 23/11/2017 10:15 - 12:15 |EF S2.23 |Lab Hardware Arduino|Xavier Serpaggi|
|Thu 30/11/2017 08:00 - 10:00 |EF S1.32 |Context Management in IoT and WoT |Olivier Boissier | link:CoursIoTOlivierBoissier.pdf[Presentation]
|Thu 30/11/2017 10:15 - 12:15 |EF S2.23 |Lab MQTT avec Arduino|Xavier Serpaggi| http://forkbomb-blog.de/2015/all-you-need-to-know-about-mqtt
|Tue 05/12/2017 08:00 - 10:00 |EF S2.23 |Starting integration projects|Maxime Lefrançois| link:project.html[Project description]
|Tue 05/12/2017 10:15 - 12:15 |EF S2.23 |Projects|Maxime Lefrançois|
|Tue 07/12/2017 08:00 - 10:00 |EF S1.32 |Discoverability, Interoperability|Maxime Lefrançois |
|Tue 07/12/2017 10:15 - 12:15 |EF S2.23 |Projects|Maxime Lefrançois|
|Tue 12/12/2017 08:00 - 10:00 |EF S2.23 |Projects|Maxime Lefrançois|
|Tue 12/12/2017 10:15 - 12:15 |EF S2.23 |Projects|Maxime Lefrançois|
|Thu 14/12/2017 08:00 - 10:00 |EF S2.23 |Projects|Maxime Lefrançois|
|Thu 14/12/2017 10:15 - 12:15 |EF S2.23 |Projects|Maxime Lefrançois|
|Thu 11/01/2018 08:00 - 10:00 |EF S1.32 |Written exam | - |
|Thu 11/01/2018 10:15 - 12:15 |EF S2.11 & S2.23 |Projects evaluation | - |
|===
== Important dates
|===
|First session | 05/10/2017 08:00 - 12:15
|Exam | 11/01/2018 08:00 - 10:00
|Projects evaluation | 11/01/2018 10:15 - 13:15
|===
= Lab Philips Hue
Maxime Lefrançois maxime.lefrancois@emse.fr, Amelie Gyrard amelie.gyrard@emse.fr v1.1, 09-11-2017
:imagesdir: images
:homepage: http://ci.emse.fr/iot/2017/
:stylesheet: github.css
:stylesdir: css
:linkcss:
:toc: left
//:backend: deckjs
//:deckjs_theme: web-2.0
In this exercise, you are going to access and control Philips Hue lightbulbs via HTTP requests.
== Setup
The Philips Hue light bulbs communicate with a bridge using the ZigBee Light Link protocol. The bridge exposes a Web API that applications can access on the local network.
== Prerequisites
* Connect a laptop in your group to the WiFi with SSID and password written on the whiteboard.
* The bridge is set up and available on the local network (see whiteboard for its IP).
* The bridge provides a Web-based HTTP client that you can use to interact with the lights, called hereafter the debug tool, which is available at: http://<ip>/debug/clip.html .
== Documentation
* Access the Philips Hue API documented at http://www.developers.meethue.com/philips-hue-api , you need to sign in to access it (free).
* You will also need the latest HTTP 1.1 specification described in RFC 7230 to 7237.
* You can use the debug/clip.html
== Steps
. Register yourself as a new developer, set your group name as the name of the developer.
. Find the number of already available Philips Hue light bulbs:
** open the debug tool in your browser
** in the “URL” field, enter the following relative path: /api/<dev-id>/lights/
** click the “GET” button to send an HTTP GET request at this URI
** Examine the raw HTTP request being sent, using the “Developer Tools” in your browser and its “Network” tab (you may need to resend the GET request). Check the raw HTTP headers of the received response.
Question 1: What is the content type of the response?
Question 2: Based on the headers of the response issued by the Philips Hue bridge, what are the HTTP methods that can be performed on the requested resource?
[start=3]
. Find the identifier of the light bulb close to you changing the bulb states (on/off, color)
. Change the name this light bulb with your name(s)
. Group three bulbs as a room, schedule an alert for this group that should occur in a minute
. Create a scene and trigger it
= Lab MQTT
Maxime Lefrançois maxime.lefrancois@emse.fr, Amelie Gyrard amelie.gyrard@emse.fr v1.1, 09-11-2017
:imagesdir: images
:homepage: http://ci.emse.fr/iot/2017/
:stylesheet: github.css
:stylesdir: css
:linkcss:
:toc: left
In this exercise, you are going to create a MQTT broker on the cloud and publish and subcribe to topics using various endpoints.
== Setup
* create 'cute cat' (=free) cloud-based broker at cloudmqtt.com
* you get 'root' credentials for the server. allowed to publish/subscribe to all topics. Keep them secret
* create one or more client credentials (login/password) and allow them to publish/subscribe to specific topics. Example:
** sensor1:sensor1 allowed to publish to topic "sensor/1"
** sensor2:sensor2 allowed to publish to topic "sensor/2"
** actuator:actuator allowed to subscribe to topics "sensor/+" (all sensors)
== Using Node.js
Install Node.js on your computer (if not done already), and install node package MQTTJS globally https://github.com/mqttjs/MQTT.js
Beware: this does not work with the windows console. Windows users need to use git bash for example.
----
npm install mqtt -g
----
in one console, subscribe to root account and all topics (read the manual for mqtt sub command)
----
mqtt sub -t '#' -h 'm21.cloudmqtt.com' -p '<given mqtt port>' -u '<root login>' -P '<pwd>' -l 'mqtt' -v
----
in another console, subscribe to actuator account and all topics (read the manual for mqtt sub command).
----
mqtt sub -t '#' -h 'm21.cloudmqtt.com' -p '<given mqtt port>' -u '<login>' -P '<password>' -l 'mqtt' -v ----> will only receive sensor/+ anyways, because actuator is allowed to do only this
----
in a third consoles, publish with sensor accounts.
----
mqtt pub -t 'sensor/2' -h 'm21.cloudmqtt.com' -p '<mqtt port>' -u 'sensor2' -P 'sensor2' -C 'mqtt' -m "HIGH TEMPERATURE !!!" ---> should be received by all subscribers
mqtt pub -t 'topic/other' -h 'm21.cloudmqtt.com' -p '<mqtt port>' -u '<root login>' -P '<pwd>' -C 'mqtt' -m "hey" ---> should only be received by allowed subscribers (root account)
----
== Using javascript
Using Javascsript, download the sources of the following link:mqtt/client.html[html stub document] and fill in the blanks (we use a library that publishes/subscribes to topics using websocket).
== Using Mobile Application
Find one of the many available apps and configure it properly.
== Using Arduino
Using Arduino, an entry point is https://pubsubclient.knolleary.net/
= Programmable Web and Internet-of-things - Common project
Agnes Crepet agnes.crepet@emse.fr, Maxime Lefrançois maxime.lefrancois@emse.fr, Gauthier Picard gauthier.picard@emse.fr
v1.0, 01-12-2017
:imagesdir: images
:homepage: http://ci.emse.fr/iot/2017/
:stylesheet: github.css
:stylesdir: css
:linkcss:
:toc: left
Majeure Informatique / Master CPS2 (MINES Saint-Etienne)
== Overview
You learned the basics of multiple Web-related concepts and technologies. Your goal for the Programmable Web and Internet of Things common project is to design a solution for a secure, configurable, Smart Building solution, and develop a running Proof of Concept (PoC) that demonstrates a subset of your solution. This solution must be controllable remotely and/or locally using a Web interface and/or an Android app.
== Evaluation
You will have to describe your solution in a 10-20 pages report that describes:
** a functional description of your solution: use cases, functional description of scenarios;
** a technical description of your solution: design choices, architecture, technical description of the scenarios;
** a PoC, running and showcasing a coherent subset of your solution.
You will demonstrate your PoC and make a Powerpoint presentation with 4-5 slides that summarizes your solution on January 11th 2018, after the IoT exam. 20-30 min will be dedicated per group, including questions.
== Expectations
Think about the different phases in the life-cycle of the solution (discovery, configuration, re-configuration, context rule management), and think also in terms of simplicity, security, privacy, interoperability.
What we expect from the PoC is a coherent subset of your solution. That is, not necessarily a full-fledge, integrated and marketable solution, with local and remote clients for the smart environment, totally discoverable, secure, securely configurable.
=== Programmable Web
_coming shortly_
=== IoT
For the IoT module we are expecting from the PoC that it demonstrates at least:
. different things and protocols (at least HTTP and MQTT)
. local and remote API-based access, using a Gateway (Raspberry PI);
. automatic discovery and manual configuration capabilities
At your disposal, we have different Hubs, Raspberry PI, Philips Hue bridges and light bulbs, Arduinos. *You can ask for what you need and even bring them home, just tell us what you use.*
== Leads
This section contains a non-exhaustive list of leads, intended for you to design your solution in terms of (1) scenarios and use cases, (2) architecture.
*Be agile.*
Your solution can be totally cloud-based, and use the Heroku server as the platform to manage the setup, configure the app, design context management rules, etc. But what if I get disconnected from the internet? Shouldn't I still be able to manage my Smart Home on the Local Area Network?
The local area network can be connected to the internet using your phone as a modem, and a Raspberry PI configured as a WiFi-Ethernet bridge. The Raspberry PI is then connected in Ethernet to the 'internet' port of a Hub. Check out on-line tutorials. Different hardware can be connected on the LAN:
. A Philips Hue bridges enabling HTTP access to light bulbs;
. An arduino capable of managing sensor data and controlling other actuators;
. A second Raspberry that:
** acts as a Gateway (is the only thing that is accessible from the internet),
** contains a local MQTT broker,
** runs code with local context rules (potentially configurable)
** exposes an API accessible online and/or on the local WiFi
*Discoverability:* The gateway can:
* exposes a CoRE description of sensors and actuators it hosts, their type, their interface, at `/.well-known/core` (best would be that this description is generated automatically)
* exposes a more complete RDF description of sensors, actuators, and their context using a Turtle document accessible at `/.well-known/td` ('td' for 'Thing Description', the RDF would use the W3C SSN, the W3C WoT ontologies, completed with any vocabulary of your choice);
When a computer is connected on the LAN, you could:
* use a simple discovery app (to be developed) that probes the local network for the IP of the Gateway (the Raspberry that exposes some document at `/.well-known/core`, or `/.well-known/td`)
* access a local server exposed by the Raspberry PI to configure/control the setup using a Web client.
*Security:* Remember when and why you had to press a button on the Philips Hue bridge. Can something similar be done with the Arduino in some of the Life-Cycle phase(s)?
= My First Experience with the Dangers of Documentation
:linkcss:
In my world, we don't have to worry about mutant, script-injecting warlocks.
No.
We have something far worse.
We're plagued by Wolpertingers.
== Origins
You may not be familiar with these http://en.wikipedia.org/wiki/Wolpertinger[ravenous beasts], but, trust me, they'll eat your shorts and suck the loops from your code.
AddDefaultCharset utf-8
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
.alert {
font-weight: 700;
color: #cc0000;
}
.tiny {
font-size: .5em;
}
.scriptsize {
font-size: .7em;
}
.footnotesize {
font-size: .8em;
}
.small {
font-size: .9em;
}
.normalsize {
font-size: 1em;
}
.large {
font-size: 1.2em;
}
.Large {
font-size: 1.44em;
}
.LARGE {
font-size: 1.728em;
}
.huge {
font-size: 2.074;
}
.Huge {
font-size: 2.488em;
}
.center {
text-align: center;
}
.grey {
color: #BBB;
}
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
# Changelog
## v1.1.0
- Expand `beforeInit` event to allow halting of init event.
- Create alternative init signature with single options object using new `options.selectors.slides` option.
- Added methods `getTopLevelSlides` and `getNestedSlides`.
- Integrated hash plugin into core.
- Allow for touch swiping to be axis specific or disabled.
- Include ARIA attribute considerations in core and extensions.
The MIT License
Copyright (c) 2011-2014 Caleb Troughton
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
SASSOPTS=--scss --style expanded
default: generate
generate:
sass --update ${SASSOPTS} .
force:
sass --update ${SASSOPTS} --force .
watch:
sass --watch ${SASSOPTS} .
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
body {
font-size: 18pt;
}
h1 {
font-size: 48pt;
}
h2 {
font-size: 36pt;
}
h3 {
font-size: 28pt;
}
pre {
border: 1px solid #000;
padding: 10px;
white-space: pre-wrap;
}
.deck-container > .slide {
page-break-after: always;
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.