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 blePort = tessel.port['A']; | |
var bleLib = require('ble-ble113a'); | |
var data = new Buffer('0201061aff4c000215e2c56db5dffb48d2b060d0f5a71096e000000000c6','hex'); | |
var ble = bleLib.use(blePort, function(err) { | |
if (err) return console.log("Error connecting to slave", err); | |
ble.setAdvertisingData(data, function (e2){ | |
if (e2) console.log("Error set adv", e2); |
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
/* | |
MIT License | |
ui-router Port of Firebase Simple Login RouteSecurityManager from | |
https://github.com/firebase/angularFire-seed/blob/master/app/js/module.routeSecurity.js | |
For any state that requires security, setup a custom data authRequired flag: | |
.state('profile', { | |
url: '/acct/profile', | |
templateUrl: 'views/account/profile.html', |
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 pcap=require('pcap'); | |
pcap.createSession("mon0", '(type mgt) and (type mgt subtype probe-req )'). | |
on('packet', function (raw_packet) { | |
with(pcap.decode.packet(raw_packet).link.ieee802_11Frame) | |
if (type == 0 && subType == 4) | |
console.log("Probe request",shost, "-> ",bssid); | |
} | |
); |
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
// Required modules. | |
var cradle = require('cradle'); | |
var util = require('util'); | |
var http = require('http'); | |
// Config. | |
var config = require('./config'); | |
// Variable to hold chunked data from Postmark. | |
var mailRaw = ''; |
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 name="viewport" content="width=device-width"> | |
<script type="text/javascript" src="jquery-1.8.1.min.js"></script> | |
<script type="text/javascript" src="http://www.parsecdn.com/js/parse-1.0.23.min.js"></script> | |
<script> | |
var SightingObject; | |
$(document).ready(function() { |
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 name="viewport" content="width=device-width"> | |
<script type="text/javascript" src="jquery-1.8.1.min.js"></script> | |
<script type="text/javascript" src="http://www.parsecdn.com/js/parse-1.0.23.min.js"></script> | |
<script> | |
var SightingObject; | |
var db; |
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
/** | |
* POST data from a Google Spreadsheet to a remote URL, via menu option Add-ons > Post values | |
* See: http://www.google.com/google-d-s/scripts/guide.html for more info | |
*/ | |
var ss = SpreadsheetApp.getActiveSpreadsheet(); | |
var sheet = ss.getSheets()[0]; | |
var r = sheet.getRange("B5"); | |
function onOpen() { |
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> | |
<title>NativeControls Example</title> | |
<!-- PhoneGap Stuff --> | |
<script src="phonegap-1.0.0.js" type="text/javascript" charset="utf-8"></script> | |
<script src="NativeControls.js" type="text/javascript" charset="utf-8"></script> | |
<!-- /PhoneGap Stuff --> |
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
<?php | |
require("postmark.php"); | |
$postmark = new Postmark("your-api-key","from-email","optional-reply-to-address"); | |
$result = $postmark->to("[email protected]") | |
->subject("Email Subject") | |
->plain_message("This is a plain text message.") | |
->attachment('File.pdf', base64_encode(file_get_contents('sample.pdf')), 'application/pdf') |
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 name="viewport" content="user-scalable=no,initial-scale=1.0,maximum-scale=1.0" /> | |
<style> | |
body { padding:10px; margin:0px; background-color: #ccc; } | |
#main { margin: 10px auto 0px auto; } | |
</style> |
NewerOlder