Skip to content

Instantly share code, notes, and snippets.

blueprint:
name: ZHA - Tuya 3-Button Scene Switch
description: Automate your Tuya 3-Button Scene Switch using ZHA events.
domain: automation
input:
tuya_3button_scene_switch:
name: Tuya 3-Button Scene Switch
description: Tuya 3-Button Scene Switch to use
selector:
device:
blueprint:
name: ZHA - Moes Smart Knob for lights
description: |
Control lights with a Moes Smart Knob.
https://gist.github.com/damonfred/63867d83acdb6e2556c2f1f4c0e7e124
Rotating left/right will change the brightness smoothly of the selected light.
Inspired from https://gist.github.com/seamus65/939a147634942dd885c8704334627f93
domain: automation
input:
remote:
# xorg.conf (X.Org X Window System server configuration file)
#
# This file was generated by dexconf, the Debian X Configuration tool, using
# values from the debconf database.
#
# Edit this file with caution, and see the xorg.conf manual page.
# (Type "man xorg.conf" at the shell prompt.)
#
# This file is automatically updated on xserver-xorg package upgrades *only*
# if it has not been modified since the last upgrade of the xserver-xorg
template < typename value_t >
void BogoSort( std::vector< value_t > & data )
{
while( !std::is_sorted(data.cbegin(), data.cend()) )
{
std::shuffle(data.begin(), data.end());
}
}
@dcbishop
dcbishop / languageideas.c
Last active August 29, 2015 14:06
Language Ideas
// What if a function and struct are the same 'thing', I'll just call it a 'block'.
MyStruct {
x : int = @ // @ here means not optional, *must* provide this when constructed.
y : int = 0 // Default but optional initilization
}
// And a function has the same syntax, just with code
// There is no function argument signature, it uses the decelerations in the order they appear.
my_func {