This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"device_id": 562949953534211, | |
"timestamp": "2016-09-04T15:36:27.637Z", | |
"data": { | |
"push": 1 | |
}, | |
"device_properties": { | |
"appeui": "70b5e59ca0000001", | |
"decoding_ok": true, | |
"decryption_ok": true, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Blink | |
* Turns on an LED on for one second, | |
* then off for one second, repeatedly. | |
*/ | |
#include "Arduino.h" | |
void setup() | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Project Configuration File | |
# | |
# A detailed documentation with the EXAMPLES is located here: | |
# http://docs.platformio.org/en/latest/projectconf.html | |
# | |
# A sign `#` at the beginning of the line indicates a comment | |
# Comment lines are ignored. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
owner: "Kadda SAHNINE", | |
isNear: false, | |
addr: "80:71:7A:A9:17:27" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import socket | |
# Peudo code | |
def notify(tcpHost, tcpPort, device, logger): | |
# Create a socket (SOCK_STREAM means a TCP socket) | |
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) | |
data = json.dumps(device) | |
try: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import bluetooth | |
import yaml | |
# Pseudo code | |
def main(argv): | |
configFile = "devices.yml" | |
# Loads the configuration file | |
if os.path.isfile(configFile): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Delay between 2 BLE discoveries (in seconds) | |
delay: 4 | |
# Checks the proximity of the following devices | |
devices: | |
- owner: Kadda SAHNINE | |
addr: 80:71:7A:A9:17:27 | |
- owner: Bob L'EPONGE | |
addr: 18:9E:FC:26:03:55 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import {RatpStatusBar} from './RatpStatusBar'; | |
import {RatpHeader} from './RatpHeader'; | |
import './css/ratp-widget.css'; | |
export let RatpWidget = React.createClass({ | |
getInitialState() { | |
return { | |
station: "", | |
destination: "", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
... | |
"scripts": { | |
"dev": "webpack-dev-server --config webpack.config.js --devtool eval --progress --colors --content-base build" | |
} | |
... | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"/> | |
</head> | |
<body> | |
<h1>Widget RATP</h1> | |
<script src="bundle.js"></script> | |
</body> | |
</html> |
NewerOlder