Skip to content

Instantly share code, notes, and snippets.

View vicatcu's full-sized avatar

Victor Aprea vicatcu

View GitHub Profile
Using previously compiled: J:\Users\VIC\AppData\Local\Temp\build1787282909712164483.tmp\Adafruit_CC3000_Library\utility\security.cpp.o
Using previously compiled: J:\Users\VIC\AppData\Local\Temp\build1787282909712164483.tmp\Adafruit_CC3000_Library\utility\sntp.cpp.o
Using previously compiled: J:\Users\VIC\AppData\Local\Temp\build1787282909712164483.tmp\Adafruit_CC3000_Library\utility\socket.cpp.o
Using previously compiled: J:\Users\VIC\AppData\Local\Temp\build1787282909712164483.tmp\Adafruit_CC3000_Library\utility\wlan.cpp.o
Using previously compiled: J:\Users\VIC\AppData\Local\Temp\build1787282909712164483.tmp\WildFire_CC3000_Library\ccspi.cpp.o
Using previously compiled: J:\Users\VIC\AppData\Local\Temp\build1787282909712164483.tmp\WildFire_CC3000_Library\WildFire_CC3000.cpp.o
Using previously compiled: J:\Users\VIC\AppData\Local\Temp\build1787282909712164483.tmp\WildFire_CC3000_Library\WildFire_CC3000_Server.cpp.o
Using previously compiled: J:\Users\VIC\AppData\Local\Temp\build178728290971216
J:\Users\VIC\Documents\Arduino\libraries\WildFire_CC3000_Library\utility\wlan.cpp:634: warning: comparison between signed and unsigned integer expressions
J:\Users\VIC\Documents\Arduino\libraries\WildFire_CC3000_Library\utility\wlan.cpp:658: warning: comparison between signed and unsigned integer expressions
J:\Users\VIC\Documents\Arduino\libraries\WildFire_CC3000_Library\utility\wlan.cpp:664: warning: comparison between signed and unsigned integer expressions
J:\Users\VIC\Documents\Arduino\libraries\WildFire_CC3000_Library\utility\wlan.cpp:695: warning: comparison between signed and unsigned integer expressions
J:\Users\VIC\Documents\Arduino\libraries\WildFire_CC3000_Library\utility\wlan.cpp:696: warning: comparison between signed and unsigned integer expressions
J:\Users\VIC\Documents\Arduino\libraries\WildFire_CC3000_Library\utility\wlan.cpp: In function 'long int wlan_ioctl_set_scan_params(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int, long int, long unsigne
var commandList = ["a", "b", "c"];
var commandFuncs = [];
for(var i = 0; i < commandList.length; i++){
var cmd = commandList[i];
commandFuncs.push( function(callback){
setTimeout(function(){
console.log(cmd);
callback(null);
}, 500);
0000: 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0010: 0x00 0x72 0x00 0x46 0xFE 0xFF 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0020: 0x10 0x33 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0030: 0x00 0x41 0x00 0x46 0xFE 0xFF 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0040: 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0050: 0x12 0xD1 0xFF 0x29 0x51 0x39 0x61 0x31 0x95 0xF6 0x20 0xE8 0x03 0x30 0x32 0xA0
0060: 0x38 0x03 0x49 0x71 0xA0 0x03 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0070: 0x40 0x41 0x00 0x46 0xFE 0xFF 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0080: 0x06 0x08 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x40 0x1F 0x21 0x22 0x22
0090: 0x00 0x00 0x00 0xE0 0xF3 0x00 0x00 0x40 0x28 0xE3 0x00 0x40 0x00 0x00 0x00 0x00
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
Serial.setDebugOutput(true);
}
void loop() {
// put your main code here, to run repeatedly:
}
int gpio0 = 21;
int enable = 23;
enum {uart, flash} mode = flash;
void setup() {
Serial.begin(115200);
if(mode == flash){
Serial1.begin(76800);
return Promise.try(function () {
//return fs.readFileAsync(status.filename, 'utf8');
return MongoClient.connectAsync(MONGODB_CONNECTION_STRING)
.then(function(db){
return db.collection("downloads").findOneAsync({key: status.filename});
});
}).then(function(content) {
// ...
});
return Promise.try(function () {
//return fs.readFileAsync(status.filename, 'utf8');
return MongoClient.connectAsync(MONGODB_CONNECTION_STRING).then(function(db){
var results = null;
return Promise.try(function(){
return db.collection("downloads").findOneAsync({key: status.filename});
}).then(function(item){
results = item;
return db.closeAsync();
}).then(function(){
@vicatcu
vicatcu / blah.js
Last active January 13, 2016 16:05
var config = require('../../eggdataconfig')();
var express = require('express');
var router = express.Router();
var Promise = require("bluebird");
var bhttp = Promise.promisifyAll(require("bhttp"));
function urlParams(params){
var ret = "";
if(Object.keys(params).length > 0){ // if there are any optional params
ret += '?';
gulp.task("babel-routes", function () {
return gulp.src("routes/*.es6")
.pipe(babel())
.pipe(gulp.dest("routes/"));
});
gulp.task("babel-public-javascripts", function () {
return gulp.src("public/javascripts/**/*.es6")
.pipe(babel())
.pipe(gulp.dest("public/javascripts/"));