Skip to content

Instantly share code, notes, and snippets.

@psct
psct / luftdaten2mqtt.txt
Created May 22, 2019 17:39
luftdaten.info per Node-Red in MQTT schieben
// Verarbeitet die JSON-Daten, die ein Sensor per Web-API abliefert
// und spuckt sie fertig formatiert zur Verarbeitung durch einen
// mqtt-Output-Node wieder aus. Funktioniert für Sensoren, die mit einem
// oder zwei Temperaturfühlern ausgestattet sind.
// Zur Entgegennahme in Node-Red eignet sich ein http-Input-Node, den
// man für die POST-Methode konfiguriert und uploads akzeptieren lässt.
var output_msgs = [];
for ( i= 0; i < 7; i++) {
#include <ESP8266WiFi.h>
#include <ESP8266WiFiMulti.h>
#include <ESP8266HTTPClient.h>
#include <PubSubClient.h>
//-------- Customise these values -----------
const char* homeSSID = "BTHub5-72W5";
const char* homePswd = "<homePswd>";
#include <Adafruit_NeoPixel.h>
#include "HSBColor.h"
// The pin that is connected to the NeoPixels
#define NEOPIXEL_PIN 1
// The pin connected to the button
#define BUTTON_PIN 2
// The amount of LEDs in the NeoPixels
@ajfisher
ajfisher / _Pebble controlled NeoPixels using ESP8266.md
Last active January 3, 2017 23:51
Using a pebble watch to control NeoPixel (WS2812 ) LEDs via an ESP8266 controller
@southwolf
southwolf / Pebble.ino
Last active January 26, 2020 20:40
Arduino code for Communicate with Pebble
#include <string.h>
#include <ctype.h>
#include <SoftwareSerial.h>
// the Bluetooth Shield connects to Pin D9 & D10
SoftwareSerial bt(9,10);
const uint8_t req[5] = {0x00, 0x01, 0x00, 0x11, 0x00};
const uint8_t cap[17] = {0x00, 0x0d, 0x00, 0x11, 0x01, 0xff, 0xff, 0xff, 0xff, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x32};
const uint8_t ping[9] = {0x00, 0x05, 0x07, 0xd1, 0x00, 0xde, 0xad, 0xbe, 0xef};
@twonjosh
twonjosh / Create iOS Icons.jsx
Last active April 25, 2023 08:41 — forked from ma11hew28/Create Icons.jsx
Photoshop Script to Create iOS Icons from a source image
// Photoshop Script to Create iPhone Icons from iTunesArtwork
//
// WARNING!!! In the rare case that there are name collisions, this script will
// overwrite (delete perminently) files in the same folder in which the selected
// iTunesArtwork file is located. Therefore, to be safe, before running the
// script, it's best to make sure the selected iTuensArtwork file is the only
// file in its containing folder.
//
// Copyright (c) 2010 Matt Di Pasquale
// Added tweaks Copyright (c) 2012 by Josh Jones http://www.appsbynight.com