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
#!/bin/bash | |
# Print data, rodata, bss sizes in bytes | |
# | |
# Usage: | |
# OBJDUMP=../xtensa-lx106-elf/bin/xtensa-lx106-elf-objdump ./mem_usage.sh app.out [total_mem_size] | |
# | |
# If you specify total_mem_size, free heap size will also be printed | |
# For esp8266, total_mem_size is 81920 | |
# |
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 <PubSubClient.h> | |
#include <ESP8266WiFi.h> | |
const char* ssid = "................."; | |
const char* password = "................"; | |
char* topic = "esp8266_arduino_out"; | |
char* server = "iot.eclipse.org"; | |
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 <ESP8266WiFi.h> | |
#include <ESP8266WebServer.h> | |
const char* ssid = ".............."; | |
const char* password = "................"; | |
String form = "<form action='led'><input type='radio' name='state' value='1' checked>On<input type='radio' name='state' value='0'>Off<input type='submit' value='Submit'></form>"; | |
String imagepage = "<img src='/led.png'>"; |
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 <ESP8266WiFi.h> | |
#include <WiFiUDP.h> | |
const char* ssid = ".........."; | |
const char* password = "..........."; | |
WiFiUDP listener; | |
void setup() { | |
Serial.begin(115200); |
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
#!/usr/bin/python | |
# | |
# this script will push an OTA update to the ESP | |
# | |
# use it like: python ota_server.py <ESP_IP_address> <sketch.bin> | |
# | |
# on the ESP side you need code like this: https://gist.github.com/igrr/43d5c52328e955bb6b09 to handle the update | |
# | |
import socket |
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 <Servo.h> | |
#include <ESP8266WiFi.h> | |
#include <ESP8266WebServer.h> | |
const char* ssid = "your-ssid"; | |
const char* pass = "your-password"; | |
ESP8266WebServer server(80); | |
Servo myservo; |
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
#ifndef ABOUT_PAGE_H | |
#define ABOUT_PAGE_H | |
#include <ESP8266WebServer.h> | |
class AboutPage : public RequestHandler { | |
public: | |
AboutPage(const char* uri = "about") | |
: _uri(uri) | |
{ |
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 <ESP8266WiFi.h> | |
const char* ssid = "........."; | |
const char* password = "........."; | |
const char* host = "api.thingspeak.com"; | |
void setup() { | |
delay(1000); |
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
#!/bin/bash | |
set -e | |
# get a fresh copy | |
git clone arduino arduino-new | |
cd arduino-new | |
git remote remove origin | |
# untie our commmits from master IDE branch | |
echo "a12c6fcea253a987e2b83aca2d9f717d0d201472" > .git/info/grafts |
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
/* | |
OTA update over HTTPS | |
As an example, we download and install ESP8266Basic firmware from github. | |
Requires latest git version of the core (November 17, 2015) | |
Created by Ivan Grokhotkov, 2015. | |
This example is in public domain. | |
*/ |
OlderNewer