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
using System; | |
using System.IO; | |
using System.Net; | |
using System.Text; | |
using System.Collections.Generic; | |
public class SSEvent { | |
public string Name { get; set; } | |
public string Data { get; set; } |
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
#define MICROPHONE_PIN A5 | |
#define AUDIO_BUFFER_MAX 8192 | |
int audioStartIdx = 0, audioEndIdx = 0; | |
uint16_t audioBuffer[AUDIO_BUFFER_MAX]; | |
uint16_t txBuffer[AUDIO_BUFFER_MAX]; | |
// version without timers | |
unsigned long lastRead = micros(); |
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
#include "WifiScan.h" | |
#include "application.h" | |
void parseScanResultToJson(WifiScanResults_t result, char *line); | |
void bytesToHex(unsigned char *data, int length, char* buffer); | |
void wipeStr(char *str, int len) { | |
for(int i = 0; i < len ;i++) { | |
str[i] = 0; | |
} |
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 state = false; | |
void setup() { | |
pinMode(D7, OUTPUT); | |
Particle.keepAlive(1.5 * 60); | |
//Serial1.begin(9600); // crashes, uncomment to run normally. | |
Particle.function("test", doTest); |
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
#define SMTP_SERVER "smtp.yourserver.com" | |
#define SMTP_USER_BASE64 "base64_encode_your_user" | |
#define SMTP_PASS_BASE64 "base64_encode_your_pass" | |
#define SMTP_FROM_EMAIL "email@from.com" | |
#define SMTP_TO_EMAIL "email@to.com" | |
#define SMTP_SUBJECT "Email from a Core!" | |
#define SMTP_BODY "Body body body" | |
#include "application.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
#include "application.h" | |
class TempSensor { | |
public: | |
char *id ; | |
uint8_t rom[8]; | |
float value ; | |
int updated ; | |
}; |
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
#include "HttpClient.h" | |
#define LOGGING | |
#define TIMEOUT 5000 // Allow maximum 5s between data packets. | |
/** | |
* Constructor. | |
*/ | |
HttpClient::HttpClient() | |
{ |
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
#define STARTING_LATITUDE_LONGITUDE_ALTITUDE NULL | |
uint8_t internalANT[]={0xB5,0x62,0x06,0x13,0x04,0x00,0x00,0x00,0xF0,0x7D,0x8A,0x2A}; | |
uint8_t externalANT[]={0xB5,0x62,0x06,0x13,0x04,0x00,0x01,0x00,0xF0,0x7D,0x8B,0x2E}; | |
... | |
setup() { | |
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
#define MICROPHONE_PIN A5 | |
#define AUDIO_BUFFER_MAX 8192 | |
int audioStartIdx = 0, audioEndIdx = 0; | |
uint16_t audioBuffer[AUDIO_BUFFER_MAX]; | |
uint16_t txBuffer[AUDIO_BUFFER_MAX]; | |
// version without timers | |
unsigned long lastRead = micros(); |
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 is our GPS library | |
Adafruit invests time and resources providing this open source code, | |
please support Adafruit and open-source hardware by purchasing | |
products from Adafruit! | |
Written by Limor Fried/Ladyada for Adafruit Industries. | |
BSD license, check license.txt for more information | |
All text above must be included in any redistribution |
NewerOlder