This file contains hidden or 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
name := "sample-with-cucumber" | |
version := "1.0-SNAPSHOT" | |
libraryDependencies ++= Seq( | |
javaJdbc, | |
javaEbean, | |
cache | |
"info.cukes" % "cucumber-java" % "1.1.5" % "test", | |
"info.cukes" % "cucumber-junit" % "1.1.5" % "test" |
This file contains hidden or 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
$ mkdir features |
This file contains hidden or 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
name := "sample-with-cucumber" | |
version := "1.0-SNAPSHOT" | |
libraryDependencies ++= Seq( | |
javaJdbc, | |
javaEbean, | |
cache | |
"info.cukes" % "cucumber-java" % "1.1.5" % "test", | |
"info.cukes" % "cucumber-junit" % "1.1.5" % "test" |
This file contains hidden or 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
# Continuously read the serial port and process IO data received from a remote XBee. | |
from xbee import ZigBee | |
import serial | |
import struct | |
from array import array | |
import boto | |
import boto.s3 | |
from datetime import datetime, date, time | |
import sys |
This file contains hidden or 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 program takes a snapshot and sends it to the XBee module | |
#include <Adafruit_VC0706.h> | |
#include <SoftwareSerial.h> | |
#include <XBee.h> | |
#include <PString.h> | |
// On Uno: camera TX connected to pin 2, camera RX to pin 3: | |
SoftwareSerial cameraconnection = SoftwareSerial(2, 3); // Arduino RX, TX | |
Adafruit_VC0706 cam = Adafruit_VC0706(&cameraconnection); |
This file contains hidden or 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
// Specify the address of the remote XBee (this is the SH + SL) | |
XBeeAddress64 addr64 = XBeeAddress64(0x0, 0x0); // Coordinator address | |
// Create a TX Request | |
ZBTxRequest zbTx = ZBTxRequest(addr64, (uint8_t *)payload, sizeof(payload)); | |
// Send the request | |
xbee.send(zbTx); |
This file contains hidden or 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
char payload[2+info.length()]; | |
payload[0] = 0xf3; // payload type | |
PString infoString(&payload[1], sizeof(payload)-1); | |
infoString.print(info); |
This file contains hidden or 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 program takes a snapshot and sends it to the XBee module | |
#include <Adafruit_VC0706.h> | |
#include <SoftwareSerial.h> | |
#include <Base64.h> | |
// On Uno: camera TX connected to pin 2, camera RX to pin 3: | |
SoftwareSerial cameraconnection = SoftwareSerial(2, 3); // Arduino RX, TX | |
Adafruit_VC0706 cam = Adafruit_VC0706(&cameraconnection); | |
This file contains hidden or 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
require 'serialport' | |
require 'json' | |
require 'base64' | |
sp = SerialPort.new "/dev/cu.usbmodem1d11", 115200, 8, 1, SerialPort::NONE | |
imageBytes = "" | |
loop { | |
jsonMessage = sp.gets.tr("\n\r", "") | |
begin | |
parsedMessage = JSON(jsonMessage) |
This file contains hidden or 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
{ "type": "img", "msg": { "seg": { "rem": 345, "enc": "YW4gZW5jb2RlZCBtc2c=" } } } |