Skip to content

Instantly share code, notes, and snippets.

@muxa
muxa / TS0601.js
Created July 16, 2022 08:25
Moes 3 Gang Light Dimmer Switch ZS-USD3-WH-MS (Tuya "_TZE200_vm1gyrso", "TS0601")
const fz = require('zigbee-herdsman-converters/converters/fromZigbee');
const tz = require('zigbee-herdsman-converters/converters/toZigbee');
const exposes = require('zigbee-herdsman-converters/lib/exposes');
const utils = require('zigbee-herdsman-converters/lib/utils');
const reporting = require('zigbee-herdsman-converters/lib/reporting');
const extend = require('zigbee-herdsman-converters/lib/extend');
const tuya = require('zigbee-herdsman-converters/lib/tuya');
const e = exposes.presets;
const ea = exposes.access;
@muxa
muxa / gate.yaml
Created September 18, 2021 06:25
ESPHome Gate single button control with State Machine
substitutions:
device_name: Gate
esphome:
name: gate
platform: ESP8266
board: d1_mini
on_boot:
priority: 600
then:
@muxa
muxa / garage.yaml
Last active May 1, 2024 05:42
ESPHome Garage Switch with State Machine
substitutions:
room: Garage
device_name: Garage Switch
esphome:
name: garage_switch
platform: ESP8266
board: esp01_1m
wifi:
@muxa
muxa / garage-switch.h
Last active December 15, 2023 10:57
ESPHome cover single button control
#include "esphome.h"
const extern short STATE_UNKNOWN = 0;
const extern short STATE_CLOSED = 1;
const extern short STATE_OPENING = 2;
const extern short STATE_OPEN = 3;
const extern short STATE_OPENING_INTERRUPTED = 4;
const extern short STATE_CLOSING = 5;
const extern short STATE_CLOSING_INTERRUPTED = 6;
@muxa
muxa / render-success.json
Created March 18, 2016 19:25
JPEG upload tests
{
"Image": {
"Size": {
"Width": 3049,
"Height": 2105
},
"FileNodeId": 12525,
"Url": "/media/5165/r11796_z11904_t3780_150x150_none_landscape.jpeg",
"FileSize": 869449,
"ModifiedOn": "2016-03-18T19:14:48"