Skip to content

Instantly share code, notes, and snippets.

View niemyjski's full-sized avatar
😀

Blake Niemyjski niemyjski

😀
View GitHub Profile
@niemyjski
niemyjski / docker-compose.yml
Last active October 15, 2021 02:36
Home Assistant Portainer docker-compose for double-take & compreface
version: '3.7'
volumes:
double-take:
postgres-data:
services:
double-take:
container_name: double-take
image: jakowenko/double-take:1.4.1
@niemyjski
niemyjski / save-camera-snapshot-notification-on-motion.yaml
Last active March 28, 2024 13:54
Home Assistant Blueprint - Save a camera snapshot with archive when motion is detected
blueprint:
name: Save a camera snapshot when motion is detected
description: Save a camera snapshot with archive when motion is detected
domain: automation
source_url: https://gist.github.com/niemyjski/08c566a4fe64fb2e70998ee4f38c9d1e
input:
motion_sensor:
name: Motion sensor
description: The sensor wich triggers the snapshot creation
selector:
@niemyjski
niemyjski / exceptionless.cs
Last active December 15, 2020 21:45
Exceptionless Ignore Third Party Exceptions
// Create our own client instance so we aren't conflicting if anyone else is using exceptionless in an addon.
private readonly ExceptionlessClient _client = new ExceptionlessClient();
_client.Configuration.AddPlugin<IgnoreLicensingAndNonGeneratorExceptionsPlugin>();
[Priority(30)]
private class IgnoreLicensingAndNonGeneratorExceptionsPlugin : IEventPlugin {
private static readonly List<string> _handledNamespaces = new List<string> {
"MyNamespace",
"MyThirdPartyDependencyNamespace"
};
@niemyjski
niemyjski / motion_switch_illuminance.yaml
Created December 15, 2020 01:41
homeassistant blueprint - Turn on a switch when motion is detected and Illuminance is low.
blueprint:
name: Turn the switch on when motion is detected
description: Turn on a switch when motion is detected and Illuminance is low.
domain: automation
source_url: https://github.com/niemyjski/home-assistant-config/tree/master/blueprints/automation/niemyjski/motion_switch.yaml
input:
motion:
name: Motion Sensor
description: The motion sensor wich triggers the light to turn on
selector:
@niemyjski
niemyjski / motion_light_illuminance.yaml
Created December 15, 2020 01:40
homeassistant blueprint - Turn on a light when motion is detected and Illuminance is low.
blueprint:
name: Turn the light on when motion is detected
description: Turn on a light when motion is detected and Illuminance is low.
domain: automation
source_url: https://github.com/niemyjski/home-assistant-config/tree/master/blueprints/automation/niemyjski/motion_light.yaml
input:
motion:
name: Motion Sensor
description: The motion sensor wich triggers the light to turn on
selector:
- badges: []
cards:
- entity: weather.smartweather
name: Forecast
show_forecast: true
type: weather-forecast
- entities:
- entity: sensor.smartweather_wind_bearing
- entity: sensor.smartweather_wind_chill
- entity: sensor.smartweather_wind_direction
@niemyjski
niemyjski / Python3 Virtualenv Setup.md
Created January 30, 2020 01:36 — forked from pandafulmanda/Python3 Virtualenv Setup.md
Setting up and using Python3 Virtualenv on Mac

Python3 Virtualenv Setup

Requirements
  • Python 3
  • Pip 3
$ brew install python3
@niemyjski
niemyjski / main.py
Created January 19, 2020 14:34
Kohler DTV+ Proxy Disconnect Issue
import aiohttp
import asyncio
import requests
async def main():
url = "http://IP_OF_SHOWER_CONTROLLER_HERE/values.cgi?_=1579384493390"
response = requests.get(url)
print(response.json())
@niemyjski
niemyjski / description.md
Last active June 8, 2023 15:33
Report Home Assistant Battery Levels With Node-RED

I decided to share this snippet based on seeing what others were doing in this thread: https://www.reddit.com/r/homeassistant/comments/emvk9y/how_do_you_monitor_sensor_battery_levels_looking/

Basically dome device types of battery report the state in different locations and with different string values that the change node or conditional logic just doesn't work nicely. Using the conditional logic on this string state value might not be working fully how we think it is or at least didn't for me. When I was debugging it and getting 10 outputted in a 100 bucket via the gt condition. The best way I've found to handle these conditions is with a function node.

Home Assistant Feedback

@niemyjski
niemyjski / configuration.yaml
Created December 26, 2019 22:21 — forked from AdamNaj/about.md
Z Wave Graph for Home Assistant
panel_custom:
- name: zwavegraph2
sidebar_title: Z-Wave Graph
sidebar_icon: mdi:access-point-network
url_path: zwave