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
void PinoccioShell::setup() { | |
addBitlashFunction("power.ischarging", (bitlash_function) isBatteryCharging); | |
addBitlashFunction("power.percent", (bitlash_function) getBatteryPercentage); | |
addBitlashFunction("power.voltage", (bitlash_function) getBatteryVoltage); | |
addBitlashFunction("power.enablevcc", (bitlash_function) enableBackpackVcc); | |
addBitlashFunction("power.disablevcc", (bitlash_function) disableBackpackVcc); | |
addBitlashFunction("power.sleep", (bitlash_function) goToSleep); | |
addBitlashFunction("power.report", (bitlash_function) powerReport); | |
addBitlashFunction("mesh.config", (bitlash_function) meshConfig); |
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
bool WiFiBackpack::isAPConnected() { | |
gs.writeCommand("%s", "AT+NSTAT+?"); | |
byte buf[256]; | |
uint16_t size; | |
gs.readResponse(buf, &size); | |
if (strstr((const char *)buf, "WSTATE=CONNECTED") != NULL) { | |
return true; | |
} else { |
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
bool WiFiBackpack::isAPConnected() { | |
gs.writeCommand("%s", "AT+NSTAT+?"); | |
byte buf[256]; | |
uint16_t size = sizeof(buf); | |
gs.readResponse(buf, &size); | |
buf[size] = '\0'; | |
if (strstr((const char *)buf, "WSTATE=CONNECTED") != NULL) { | |
return 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
/Volumes/Data/Users/eric/Documents/Arduino/libraries/Pinoccio/utility/WiFiBackpack.cpp: In member function 'void WiFiBackpack::disassociate()': | |
/Volumes/Data/Users/eric/Documents/Arduino/libraries/Pinoccio/utility/WiFiBackpack.cpp:152:6: error: 'class GSModule' has no member named 'disassociate' |
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
char buffer[255]; | |
void testWifi() { | |
gs.writeCommand("AT+VER=?"); | |
gs.readResponse(print_line, &Serial); | |
if (strncmp(buffer, "S2W WLAN VERSION=2.5.1", 22) != 0) { | |
testFailed = true; | |
Serial.println(); | |
Serial.print("FAIL: Unexpected response from AT+VER=? command: "); |
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
/Applications/Pinoccio.app/Contents/Resources/Java/hardware/tools/avr/bin/avrdude -C/Applications/Pinoccio.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf -v -v -v -v -patmega256rfr2 -cstk500v1 -P/dev/cu.usbmodemfd121 -b19200 -e -Ulock:w:0x3F:m -Uefuse:w:0xFE:m -Uhfuse:w:0xD0:m -Ulfuse:w:0xFF:m | |
avrdude: Version 6.0rc1, compiled on Jan 15 2014 at 12:41:56 | |
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/ | |
Copyright (c) 2007-2009 Joerg Wunsch | |
System wide configuration file is "/Applications/Pinoccio.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf" | |
User configuration file is "/Users/eric/.avrduderc" | |
User configuration file does not exist or is not a regular file, skipping |
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
// ArduinoISP version 04m3 | |
// Copyright (c) 2008-2011 Randall Bohn | |
// If you require a license, see | |
// http://www.opensource.org/licenses/bsd-license.php | |
// | |
// This sketch turns the Arduino into a AVRISP | |
// using the following arduino pins: | |
// | |
// pin name: not-mega: mega(1280 and 2560) | |
// slave reset: 10: 53 |
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
[eric@ ~/BeanLabs/hardware/pinoccio/firmware-pinoccio] [master]:~$ sort --help | |
Usage: sort [OPTION]... [FILE]... | |
Write sorted concatenation of all FILE(s) to standard output. | |
Mandatory arguments to long options are mandatory for short options too. | |
Ordering options: | |
-b, --ignore-leading-blanks ignore leading blanks | |
-d, --dictionary-order consider only blanks and alphanumeric characters | |
-f, --ignore-case fold lower case to upper case characters |
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
const byte PROGMEM attiny13a_eeprom [] = { | |
0x01, 0x40, 0x3B, 0x01, 0x00, 0x01, 0x10, 0x00, 0x00, 0x01, 0x00, 0x01, 0x77, 0x69, 0x66, 0xE9, | |
0x01, 0x77, 0x69, 0x66, 0xE9, 0x07, 0x0F, 0x78, 0x04, 0x0E, 0x70, 0x67, 0xED, 0x02, 0x13, 0x00, | |
0x2A, 0x41, 0x01, 0x73, 0xE4, 0x07, 0x10, 0xA9, 0x02, 0x11, 0x00, 0x0A, 0x29, 0x01, 0x65, 0x65, | |
0xF0, 0x07, 0x07, 0xB0, 0x02, 0x11, 0x00, 0x02, 0x08, 0x4A, 0x66, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, | |
}; // end of attiny13a_eeprom |
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
const byte PROGMEM attiny13a_eeprom [] = { | |
0x01, 0x40, 0x3B, 0x01, 0x00, 0x01, 0x10, 0x00, 0x00, 0x00, 0x2F, 0x01, 0x77, 0x69, 0x66, 0xE9, | |
0x01, 0x77, 0x69, 0x66, 0xE9, 0x07, 0x0F, 0x7C, 0x04, 0x0E, 0x70, 0x67, 0xED, 0x02, 0x13, 0x39, | |
0xCA, 0xE1, 0x01, 0x73, 0xE4, 0x07, 0x10, 0xA9, 0x02, 0x11, 0x00, 0x00, 0xCB, 0x01, 0x65, 0x65, | |
0xF0, 0x07, 0x07, 0xC2, 0x02, 0x11, 0x05, 0x80, 0x9E, 0x51, 0xCC, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, | |
}; // end of attiny13a_eeprom |
OlderNewer