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
/* | |
** Read various sensor values and print them to serial port. | |
** | |
** Thomas Conté @tomconte | |
*/ | |
#include <Esplora.h> | |
int lightMin = 1023; // minimum sensor value | |
int lightMax = 0; // maximum sensor value |
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
#!/usr/bin/python | |
import sys | |
import commands | |
import re | |
import uuid | |
import serial | |
from proton import * | |
# Device ID |
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
#!/usr/bin/python | |
from azure.storage import BlobService | |
import argparse | |
parser = argparse.ArgumentParser() | |
parser.add_argument("container", help="the blob container") | |
parser.add_argument("blob", help="the blob name") | |
parser.add_argument("-s", "--snapshot", help="take a new snapshot", action="store_true") | |
parser.add_argument("-d", "--delete", help="delete a snapshot") |
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
/* | |
** This sample Arduino sketch uploads telemetry data to Azure Mobile Services on an Arduino Yun | |
** The Bridge library is used to run cURL to send the data securely using SSL. | |
** See the full article here: http://hypernephelist.com/2014/08/19/https_on_arduino_yun.html | |
** | |
** Thomas Conté @tomconte | |
*/ | |
#include <Process.h> |
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
var https = require('https'); | |
var crypto = require('crypto'); | |
// Event Hubs parameters | |
var namespace = 'tomhub-ns'; | |
var hubname ='tomtest001'; | |
var devicename = 'device-01'; | |
// Payload to send | |
var payload = '{\"Temperature\":\"37.0\",\"Humidity\":\"0.4\"}'; |
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
var fs = require('fs'); | |
var https = require('https'); | |
var blob_host = 'tconeu.blob.core.windows.net'; | |
var blob_container = 'tessel-uploads'; | |
// Use any tool to generate a Shared Access Key e.g. Azure Management Studio | |
var blob_sas = '?sr=c&sv=2014-02-14&si=tessel&sig=xxxxRv%2xxxxUTd8xxxxMKc0xxxxi%2Fxxxxw6VsxxxxGjdJxxxx'; | |
var blob_name = 'test.jpg'; |
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
var tessel = require('tessel'); | |
var https = require('https'); | |
// Upload parameters | |
var blob_host = 'tconeu.blob.core.windows.net'; | |
var blob_container = 'tessel-uploads'; | |
// Use any tool to generate a Shared Access Key e.g. Azure Management Studio | |
var blob_sas = '?sr=c&sv=2014-02-14&si=tessel&sig=xxxxRv%2xxxxUTd8xxxxMKc0xxxxi%2Fxxxxw6VsxxxxGjdJxxxx'; |
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
#!/usr/bin/python | |
import sys | |
import commands | |
import re | |
import uuid | |
import serial | |
from proton import * | |
# Device ID |
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
#!/usr/bin/python | |
# Send messages to an Azure Event Hub using the Apache Qpid Proton AMQP library. | |
import sys | |
import commands | |
from proton import * | |
# Event Hub address & credentials | |
# amqps://<keyname>:<key>@<namespace>.servicebus.windows.net/<eventhubname> |
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
#!/usr/bin/python | |
# Receive messages from an Azure Event Hub using the Apache Qpid Proton AMQP library. | |
import sys | |
import commands | |
import re | |
import uuid | |
import serial | |
from proton import * |