Skip to content

Instantly share code, notes, and snippets.

View firnsy's full-sized avatar

Ian Firns firnsy

View GitHub Profile
@firnsy
firnsy / touch.ino
Created January 9, 2020 04:55
ESP32 Touch Hold Test
int threshold = 40;
bool touchDetected = false;
uint32_t lastTouch = 0;
uint32_t touchDuration = 0;
bool touchHeld = true;
void gotTouch() {
touchDetected = true;
}
@firnsy
firnsy / test.ino
Created January 9, 2020 03:23
ESP32 mode test
#include <WiFi.h>
#define LED 2
void setup() {
Serial.begin(115200);
pinMode(LED, OUTPUT);
// mode on power up (should be OFF)
@firnsy
firnsy / gist:9277682a2e5cbdd0a213c0bc6ada4173
Created November 17, 2019 02:22
KEF Status Response Code Format
bit 7 (POWER) 0 = On, 1 = Off
bit 6 (INVERSE) 0 = No, 1 = Inverse Yes
bit 5-4 (STAND BY) 00 = 20mins, 01 = 60mins, 10 = Never, 11 = Unknown
bit 3-0 (SOURCE) 0010 = WiFi, 1001 = BT, 1111 = BT, 1010 = Aux, 1011 = Optical
@firnsy
firnsy / 0_reuse_code.js
Created June 24, 2014 00:14
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@firnsy
firnsy / keybase.md
Last active September 12, 2019 06:34

Keybase proof

I hereby claim:

  • I am firnsy on github.
  • I am firnsy (https://keybase.io/firnsy) on keybase.
  • I have a public key whose fingerprint is 959D 0417 E317 5521 E312 F516 2715 E958 FC2A 5049

To claim this, I am signing this object: