Config Files

My Home-Assistant configuration files below, as of 17th May 2017.

  • configuration.yaml
  • customize.yaml
  • automation.yaml
  • scenes.yaml
  • groups.yaml
  • sensors.yaml
  • switch.yaml
homeassistant:
  # Name of the location where Home Assistant is running
  name: Home
  # Location required to calculate the time the sun rises and sets
  latitude: <REDACTED>
  longitude: <REDACTED>
  # Impacts weather/sunrise data (altitude above sea level in meters)
  elevation: 8
  # metric for Metric, imperial for Imperial
  unit_system: metric
  # Pick yours from here: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
  time_zone: Australia/Sydney
  customize: !include customize.yaml

automation: !include automation.yaml
scene: !include scene.yaml
group: !include groups.yaml
sensor: !include sensor.yaml
switch: !include switch.yaml
light: !include light.yaml

# Enables the frontend
frontend:
# Enables configuration UI
config:

ios:

http:
   api_password: <REDACTED>
   ssl_certificate: /etc/letsencrypt/live/<REDACTED>.duckdns.org/fullchain.pem
   ssl_key: /etc/letsencrypt/live/<REDACTED>.duckdns.org/privkey.pem
  # Uncomment this if you are using SSL or running in Docker etc
   base_url: <REDACTED>.duckdns.org:8123

# Checks for available updates
updater:
# Discover some devices automatically
discovery:
# Enables support for tracking state changes over time.
history:
# View all events in a logbook
logbook:
# Track the sun
sun:

emulated_hue:
  type: alexa
  host_ip: 192.168.0.24
  listen_port: 8300
  expose_by_default: true
  exposed_domains:
    - light

device_tracker:
  - platform: netgear
    host: 192.168.0.1
    username: admin
    password: <REDACTED>
    interval_seconds: 85
    consider_home: 180
    track_new_devices: true
############ sensors ############
   sensor.cpu_use:
     friendly_name: CPU Usage
     icon: mdi:chip
   sensor.ram_use:
     friendly_name: RAM Usage
     icon: mdi:buffer
   sensor.since_last_boot:
     homebridge_hidden: true
     hidden: true
   sensor.last_boot:
     homebridge_hidden: true
     hidden: true
   sensor.since_last_boot_templated:
     friendly_name: Uptime
     icon: mdi:clock-start
   sensor.dark_sky_humidity:
     icon: mdi:water-percent
     friendly_name: Humidity
     homebridge_hidden: true
   sensor.dark_sky_temperature:
     icon: mdi:thermometer
     friendly_name: Outdoor Temperature
     homebridge_hidden: true
   sensor.dark_sky_daily_high_temperature:
     friendly_name: Max Temp
     homebridge_hidden: true
   sensor.dark_sky_summary:
     friendly_name: Summary
   sensor.dark_sky_wind_speed:
     friendly_name: Wind Speed   
   sensor.dark_sky_wind_bearing:
     friendly_name: Wind Bearing    
   sensor.dark_sky_precip_probability:
     friendly_name: Rain Probability    
   sensor.dark_sky_daily_summary:
     friendly_name: Daily Summary
   sensor.cpu_temperature:
     friendly_name: R-Pi CPU Temp
     homebridge_hidden: true
     icon: mdi:oil-temperature
   sensor.pihole:
     friendly_name: Ads Blocked Today
     icon: mdi:stop-circle-outline
   device_tracker.puk6s:
     icon: mdi:human
   device_tracker.000e8e24b7fb: #hide joggler from top
     hidden: true
   device_tracker.dc71442bb666:
     hidden: true
   sensor.joggler:
     icon: mdi:tablet
   device_tracker.888717ab18ce: #hide printer from top
     hidden: true
   sensor.canon:
     icon: mdi:printer
   device_tracker.<REDACTED>:  #hide macbook from top
     hidden: true
   sensor.macbook:
     icon: mdi:laptop-mac
   device_tracker.xboxsystemos: #hide xbox from top
     hidden: true
   sensor.xbox:
     icon: mdi:xbox
   device_tracker.<REDACTED>:
     icon: mdi:human-female
   sensor.dht_sensor_humidity:
     friendly_name: Flat Humidity
     icon: mdi:water-percent
     homebridge_name: Humidity
   sensor.dht_sensor_temperature:
     friendly_name: Flat Temperature
     icon: mdi:thermometer-lines
     homebridge_name: Temperature
############ Automation ############

- alias: lamp on 15min before sunset (dimmed)
  initial_state: true
  hide_entity: false
  trigger:
    platform: sun
    event: sunset
    offset: '-00:15:00'
  action:
    - service: scene.turn_on
      entity_id: scene.evening
- alias: Brighten evening lamp
  trigger:
    platform: sun
    event: sunset
    offset: '+01:00:00'
  action:
    - service: scene.turn_on
      entity_id: scene.normal
- alias: Morning Light On @ 6.30
  trigger:
    platform: time
    after: "06:30:00"
  condition:
    condition: time
    weekday:
      - mon
      - wed
      - fri
  action:
    service: homeassistant.turn_on
    entity_id: scene.morning

- alias: Gym Day Morning Light on @ 6am
  trigger:
    platform: time
    after: "06:00:00"
  condition:
    condition: time
    weekday:
      - tue
      - thu
      - sat
  action:
    service: homeassistant.turn_on
    entity_id: scene.morning

- alias: Morning lamp off at 7.45am
  trigger:
    platform: time
    after: "07:45:00"
  action:
    service: homeassistant.turn_off
    entity_id: light.lamp

- alias: Backlight on if TV on, when dark
  trigger:
    platform: sun
    event: sunset
    offset: "+01:30:00"
  condition:
    condition: state
    entity_id: device_tracker.dc71442bb666
    state: 'home'
  action:
    service: homeassistant.turn_on
    entity_id: light.backlight
############ SCENES ############

- name: Morning
  entities:
    light.lamp:
      state: on
      brightness: 150
      rgb_color: [255, 255, 255]
- name: Teal
  entities:
    light.backlight:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [0, 251, 128]
    light.lamp:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [0, 251, 128]
- name: Default
  entities:
    light.lamp:
      state: on
      brightness: 255
      rgb_color: [255, 255, 255]
- name: Evening
  entities:
    light.lamp:
      state: on
      brightness: 200
      rgb_color: [255, 255, 255]
- name: Normal
  entities:
    light.backlight:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [255, 255, 238]
    light.lamp:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [255, 255, 255]
- name: Purple
  entities:
    light.backlight:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [228, 151, 255]
    light.lamp:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [228, 151, 255]
- name: Green
  entities:
    light.backlight:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [100, 246, 63]
    light.lamp:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [100, 246, 63]
- name: Red
  entities:
    light.backlight:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [255, 48, 48]
    light.lamp:
      state: on
      transition: 2
      brightness: 255
      rgb_color: [255, 48, 48]
- name: Game Mode
  entities:
    light.backlight:
      state: on
      brightness: 255
      rgb_color: [255, 155, 126]
    light.lamp:
      state: on
      brightness: 255
      rgb_color: [139, 143, 255]
########### GROUPS #########

Lighting:
  - light.backlight
  - light.lamp
Device Tracking:
  - sensor.canon
  - sensor.joggler
  - sensor.macbook
  - sensor.xbox
Flat Temperatures:
  - sensor.cpu_temperature
  - sensor.dark_sky_temperature
  - sensor.dht_sensor_temperature
  - sensor.dht_sensor_humidity
Raspberry-Pi details:
  - sensor.cpu_use
  - sensor.cpu_temperature
  - sensor.ram_use
  - sensor.since_last_boot_templated
Pi-Hole Stats:
  - sensor.pihole
  - sensor.pihole_domains_blocked
  - sensor.pihole_percentage_today
  - sensor.pihole_queries_today
Who's Home?:
  - device_tracker.puk6s
  - device_tracker.bexsiphone
Balmain Weather:
  - sensor.dark_sky_summary
  - sensor.dark_sky_temperature
  - sensor.dark_sky_daily_high_temperature
  - sensor.dark_sky_humidity
  - sensor.dark_sky_wind_speed
  - sensor.dark_sky_wind_bearing
  - sensor.dark_sky_precip_probability
  - sensor.dark_sky_daily_summary
Dyson:
  control: hidden
  entities:
    - switch.dyson_power
    - switch.oscillate
    - switch.fan_up
    - switch.fan_down
    - switch.temp_up
    - switch.temp_down
########## SENSORS ##########
- platform: template
  sensors:
    canon:
       value_template: "{% if is_state('device_tracker.888717ab18ce', 'home') %}on{% else %}off{% endif %}"
       friendly_name: Canon Printer
    joggler:
       value_template: "{% if is_state('device_tracker.000e8e24b7fb', 'home') %}on{% else %}off{% endif %}"
       friendly_name: Joggler
    macbook:
       value_template: "{% if is_state('device_tracker.<REDACTED>', 'home') %}on{% else %}off{% endif %}"
       friendly_name: Macbook
    xbox:
       value_template: "{% if is_state('device_tracker.xboxsystemos', 'home') %}on{% else %}off{% endif %}"
       friendly_name: Xbox
- platform: darksky
  api_key: <REDACTED>
  monitored_conditions:
    - summary
    - temperature
    - temperature_max
    - humidity
    - wind_speed
    - wind_bearing
    - precip_probability
    - daily_summary
- platform: command_line
  scan_interval: 60 
  name: CPU_Temperature
  command: "cat /sys/class/thermal/thermal_zone0/temp"
  unit_of_measurement: "°C"
  value_template: '{{ value | multiply(0.001) | round(0) }}'
- platform: dht
  sensor: DHT22
  pin: 4
  name: dht_sensor
  monitored_conditions:
    - temperature
    - humidity     
- platform: systemmonitor
  resources:
  - type: last_boot
  - type: processor_use
  - type: memory_use_percent
  - type: since_last_boot
############ SWITCH ############
- platform: rest
  resource: http://localhost:4000/remotes/dyson/KEY_POWER
  name: "Dyson Power"
- platform: rest
  resource: http://localhost:4000/remotes/dyson/KEY_DIRECTION
  name: "Oscillate"
- platform: rest
  resource: http://localhost:4000/remotes/dyson/KEY_UP
  name: "Fan Up"
- platform: rest
  resource: http://localhost:4000/remotes/dyson/KEY_DOWN
  name: "Fan Down"
- platform: rest
  resource: http://localhost:4000/remotes/dyson/KEY_RED
  name: "Temp Up"
- platform: rest
  resource: http://localhost:4000/remotes/dyson/KEY_DOWN
  name: "Temp Down"
######### LIGHT #########
platform: limitlessled
bridges:
  - host: 192.168.0.25
    version: 5
    port: 8899
    groups:
    - number: 1
      type: rgbw
      name: Backlight
    - number: 2
      type: rgbw
      name: Lamp

 

lirc_web config files:

{
	"server": {
		"port": 4000,
		"ssl": false
	},
	"commandLabels": {
		"dyson": {
			"KEY_POWER": "ON/OFF",
			"KEY_DIRECTION": "Oscillate",
			"KEY_UP": "Increase Fan",
			"KEY_DOWN": "Decrease Fan",
			"KEY_RED": "Temperature Up",
			"KEY_BLUE": "Temperature Down"
		},
	"samsung": {
		"KEY_POWER": "Soundbar ON/OFF",
		"KEY_POWER2": "TV ON/OFF",
		"KEY_MUTE": "MUTE ",
		"KEY_VOLUMEUP": "VOLUME UP",
		"KEY_VOLUMEDOWN": "VOLUME DOWN",
		"KEY_AUX": "SOURCE"
                }
	},
	"remoteLabels": {
		"dyson": "Dyson Fan",
		"samsung": "Samsung Soundbar"
	},
	"blacklists": {
		"samsung": [
			"KEY_SAT",
			"KEY_SOUND",
			"KEY_LANGUAGE",
			"KEY_PROGRAM",
			"KEY_TAB",
			"KEY_BASSBOOST",
			"KEY_UP",
			"KEY_DOWN",
			"KEY_SCROLLUP",
			"KEY_SCROLLDOWN",
			"KEY_REDO",
			"KEY_D",
			"KEY_BRIGHTNESSDOWN",
			"KEY_OPTION",
			"KEY_REWIND",
			"KEY_STOP",
			"KEY_PLAY",
			"KEY_FASTFORWARD",
			"KEY_CHANNELUP",
			"KEY_CHANELLDOWN",
			"KEY_INFO",
			"KEY_LAST",
			"KEY_NEXT",
			"KEY_WAKEUP",
			"KEY_CHANNEL",
			"KEY_CHANNELDOWN",
			"KEY_NEXT"
		]
	}
}