Quantcast
Channel: Configuration - Home Assistant Community
Viewing all 106096 articles
Browse latest View live

Extending entities with custom attributes

$
0
0

@FutureTense wrote:

I forgot where I discovered this, so if you know where the documentation is, please remind me, but I know it’s possible to ”extend” an entity using customize: to allow you to create a custom attribute for an existing entity.

input_boolean.myboolean_a:
  mapped_input_text_entityid: 'input_text.foo'

input_boolean.myboolean_b:
  mapped_input_text_entityid: 'input_text.bar'

So the above is used to create and set a custom attribute named mapped_input_text_entityid for two input booleans. Then I’m able to use that attribute in an automation. For example, say I have a trigger for when input_boolean.myboolean_a has a state change from false to true, I can then use that attribute to find the entityid of an expected input_text and do something with it.

    action:
      - service: input_text.set_value
        data_template:
          entity_id: trigger.to_state.attributes.mapped_input_text_entityid
          value: "666"

Is it possible to do the same thing for other entities like a binary_sensor? And is there a way to do this on the fly when you create entities instead of having to do this across different locations like customize currently requires? I find tremendous value in the ability to link controls together using this concept.

Posts: 1

Participants: 1

Read full topic


Lovelace ui and Lottie animations

$
0
0

@Sennevds wrote:

Hi,

Don’t know if this is really the right sub but I’ve recently found a nice way for showing animations.


This uses a json file(which could be exported from after effects) and then renders it as a animation.
It’s a lot smaller then a gif file or mp4 and looks really smooth.
With this we maybe could pretty easy add animations to our frontend!

I’ve thought of creating a custom card to integrate this but my web development skills aren’t super(I’m backend developer in .Net).

If someone would like to help me with this project that would be awesome.
(Google uses lottie for all the animations in the Google Home App and you can easilly extract there json files from the apk)

Posts: 1

Participants: 1

Read full topic

Hue Motion Sensor - Adjust Rules via Hue API based on toggle in HALT

$
0
0

@christian.huppertz wrote:

Hey everyone,

I want to integrate a day and night mode in my HA for my Philips Hue motion sensors used in the corridors. As I want to keep the sensor integrated into my Hue Bridge I came up with the following Idea:

I want to create an automation that is triggered by changing a custom toggle “Night Mode”. When “Night Mode” is turned on, HA should manipulate the rule on the Hue Bridge so that the time for switching to the night setup is set to the current time.

How to send the API call from the HA ist not the issue - I already finished that part. Im more struggling with the Hue API as I do not understand how rules are defined and how I can manipulate those. Does somebody have experience with that kink adjustment on the Hue Bridge?

Thank you so much!

P.S. Hope this is the right category and well explained. Im new to the form :slight_smile:

Posts: 1

Participants: 1

Read full topic

Volumio not resuming Songs

$
0
0

@The-May wrote:

Hi Guys,

I recently managed to get a Raspberry Pi 2b working with Volumio to handle as an additional Speaker for my Phone.
I currently have two additional Sonos Speakers and I managed to create automations to “transfer” my currently playing Spotify-Song (via Spotify Connect) from one to the respective Sonos-Speaker and they work flawlessly.
They either:

  • pass the song from one Sonos-Speaker to each other (depending what automation gets triggered)
    or
  • they “grab” the currently playing Song on my Mobile phone and start playing it. (When I come in Home e.g. )
    One specific Example for my bathroom:
- id: '1578940391679'
  alias: Auto_Bad_Beleuchtung_An_Morgens_Abends
  description: ''
  trigger:
  - device_id: ccb3a8a9976f4d408686a7b669a6c3ee
    domain: binary_sensor
    entity_id: binary_sensor.prox_bad
    platform: device
    type: motion
  condition:
  - after: '23:00'
    before: '11:00'
    condition: time
  action:
  - data:
      brightness_pct: 10
      transition: 5
    entity_id: light.bad
    service: light.turn_on
  - entity_id: media_player.sonos_bed
    service: media_player.media_pause
  - entity_id: media_player.volumio
    service: media_player.media_pause
  - entity_id: media_player.sonos_bad
    service: media_player.media_play

To my Problem:

I tried the same thing on Volumio thanks to the “Spotify Connect” Plugin, but it seems to not fully “follow/grab” what I was playing and it starts playing the last played song (or a random one) in the Playlist of Volumio and completely ignores what has been played on my Sonos-Speakers OR my Phone.

The only thing that bugs me is that the sonos-speakers DO grab the song from Volumio, (they resume the song that is currently playing) so Volumio is keeping somehow the connection to the Servers.

My automation for Volumio uses the same scheme:
(please dont mind the trigger and the alias)

- id: '1580321733318'
  alias: test
  description: ''
  trigger:
  - event: sunrise
    platform: sun
  condition: []
  action:
  - entity_id: media_player.sonos_bed
    service: media_player.media_pause
  - entity_id: media_player.volumio
    service: media_player.play_media

I am afraid that this is a Volumio-Specific thing, but I thought maybe someone got it working by doing something like a snapshot of the attributes of the currently playing song from the last active speaker and apply it to the media_player (volumio)? Is this even possible?

Please advise and tell me what you might think of it and maybe how you managed to get it working.
I am always open for other solutions.

Thank you for the wall of text and cheers.

Posts: 1

Participants: 1

Read full topic

Turn off music playing playing on Sonos after 30 minutes

$
0
0

@ibstyln wrote:

I want to be able to stop music/radio station stream playing on Sonos speaker after 30 minutes.
Below is what I currently have to get the music playing. I need to know what lines to add to the automation or script to stop the music after 30 minutes.

automation

# Morning Wakeup
- alias: 'morning wakeup'
  condition:
    condition: time
    weekday:
    - mon
    - tue
    - wed
    - thu
    - fri
  trigger:
    - platform: time
      at: "06:45:00"
  action:
    - service: script.masterbedroomwakeup

script

masterbedroomwakeup:
  alias: 'Master Bedroom Wake Up Routine'
  sequence:
    - service: media_player.select_source
      data:
        entity_id: media_player.office
        source: "104.3 | Q104 (Country Music)"

FYI: The source is playing from my Sonos favorites

Posts: 6

Participants: 2

Read full topic

Overriding Themes

$
0
0

@Guillaume_Corgnet wrote:

Hi,

I have installed a few themes through HACS and I would like to know what the best way would be to override a few colours. I have done it straight on the yaml file but obviously this gets overwritten when the themes gets updated through HACS.

Would there be a way to override a few variables in a separate files that could stay intact through updates?

Thanks

G

Posts: 2

Participants: 2

Read full topic

Lovelace UI error: circle-sensor-card.js - State is not a number

$
0
0

@m4rk wrote:

Hello,

I am trying to use the gh0s7 Hristo Atanasov’s card without any success.

ui-lovelace.yaml

title: Home
resources:
  - url: /local/card-modder.js
    type: module
  - url: /local/circle-sensor-card.js?v=2
    type: module
  - url: /local/vertical-stack-in-card.js
    type: module
views:
  - !include /config/lovelace_views/home.yaml
  - !include /config/lovelace_views/test.yaml

home.yaml

title: Home
#background: url("/local/home.png") fixed
icon: mdi:home
#badges:
#  !include /config/lovelace_views/badges.yaml
cards:
    - elements:
        - entity: sensor.purifier_filter_hours_used
          prefix: 'Used: '
          style:
            background-color: 'rgba(0, 0, 0,.0)'
            border-color: 'rgb(34, 154, 210,.0)'
            border-left-style: solid
            color: dodgerblue
            font-size: 100%
            font-weight: bold
            left: 1.5%
            opacity: 1
            pointer-events: none
            top: 5%
            transform: 'translate(0%,-50%)'
          type: state-label
        - icon: 'mdi:water-percent'
          style:
            '--iron-icon-height': 20px
            '--iron-icon-width': 20px
            color: dodgerblue
            left: 8%
            position: absolute
            top: 17%
          tap_action: none
          type: icon
        - entity: sensor.purifier_humidity
          fill: 'rgba(0,0,0,0.3)'
          font_style:
            color: white
          gradient: true
          max: 100
          min: 0
          show_card: null
          stroke_width: 10
          style:
            height: 17%
            left: 15%
            top: 25%
            width: 17%
          type: 'custom:circle-sensor-card'
          units: '%'
        - icon: 'mdi:thermometer'
          style:
            '--iron-icon-height': 20px
            '--iron-icon-width': 20px
            color: dodgerblue
            left: 7.5%
            position: absolute
            top: 37%
          tap_action: none
          type: icon
        - entity: sensor.purifier_temperature
          fill: 'rgba(0,0,0,0.3)'
          font_style:
            color: white
          gradient: true
          max: 50
          min: 0
          show_card: false
          stroke_width: 10
          style:
            height: 17%
            left: 15%
            top: 45%
            width: 17%
          type: 'custom:circle-sensor-card'
          units: °C
        - icon: 'mdi:air-filter'
          style:
            '--iron-icon-height': 17px
            '--iron-icon-width': 17px
            color: dodgerblue
            left: 8%
            top: 56%
          tap_action: none
          type: icon
        - entity: sensor.purifier_filter_life_remaining
          fill: 'rgba(0,0,0,0.3)'
          font_style:
            color: white
          gradient: true
          max: 100
          min: 0
          show_card: false
          stroke_width: 10
          style:
            height: 17%
            left: 15%
            top: 65%
            width: 17%
          type: 'custom:circle-sensor-card'
          units: ''
        - entity: sensor.purifier_aqi
          fill: 'rgba(0,0,0,0.3)'
          font_style:
            color: white
          gradient: true
          max: 600
          min: 0
          show_card: false
          stroke_width: 10
          style:
            height: 13%
            left: 50%
            top: 18.5%
            width: 13%
          type: 'custom:circle-sensor-card'
          units: p
        - icon: 'mdi:speedometer'
          style:
            '--iron-icon-height': 17px
            '--iron-icon-width': 17px
            color: dodgerblue
            left: 8%
            top: 76%
          tap_action: none
          type: icon
        - entity: sensor.purifier_fan_speed
          fill: 'rgba(0,0,0,0.3)'
          font_style:
            color: white
          gradient: true
          max: 1700
          min: 0
          show_card: false
          stroke_width: 10
          style:
            height: 17%
            left: 15%
            top: 85%
            width: 17%
          type: 'custom:circle-sensor-card'
          units: ''
        - entity: sensor.purifier_fan_mode
          max: 2000
          min: 0
          prefix: 'Mode: '
          style:
            background-color: 'rgba(0, 0, 0,.0)'
            border-color: 'rgb(34, 154, 210,.0)'
            border-left-style: solid
            color: dodgerblue
            font-size: 100%
            font-weight: bold
            opacity: 1
            pointer-events: none
            right: 1%
            top: 1%
            transform: none
          type: state-label
        - entity: fan.xiaomi_air_purifier_2s
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            margin-right: '-10%'
            right: 17%
            top: 17%
          tap_action:
            action: call-service
            service: fan.toggle
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
          type: state-icon
        - icon: 'mdi:brightness-auto'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            right: 4%
            top: 17%
          tap_action:
            action: call-service
            service: fan.set_speed
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
              speed: Auto
          type: icon
        - icon: 'mdi:power-sleep'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            margin-right: '-10%'
            right: 22%
            top: 34%
          tap_action:
            action: call-service
            service: fan.set_speed
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
              speed: Silent
          type: icon
        - icon: 'mdi:account-heart'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            right: 4%
            top: 34%
          tap_action:
            action: call-service
            service: fan.set_speed
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
              speed: Favorite
          type: icon
        - icon: 'mdi:monitor'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            margin-right: '-10%'
            right: 22%
            top: 51%
          tap_action:
            action: call-service
            service: fan.XIAOMI_MIIO_SET_LED_ON
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
          type: icon
        - icon: 'mdi:monitor-off'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            right: 3%
            top: 51%
          tap_action:
            action: call-service
            service: fan.XIAOMI_MIIO_SET_LED_OFF
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
          type: icon
        - icon: 'mdi:bell'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            margin-right: '-10%'
            right: 22%
            top: 68%
          tap_action:
            action: call-service
            service: fan.XIAOMI_MIIO_SET_BUZZER_ON
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
          type: icon
        - icon: 'mdi:lock-alert'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            margin-right: '-10%'
            right: 22%
            top: 87%
          tap_action:
            action: call-service
            service: fan.XIAOMI_MIIO_SET_CHILD_LOCK_ON
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
          type: icon
        - icon: 'mdi:bell-off-outline'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            right: 3%
            top: 68%
          tap_action:
            action: call-service
            service: fan.XIAOMI_MIIO_SET_BUZZER_OFF
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
          type: icon
        - icon: 'mdi:lock-open-outline'
          style:
            '--iron-icon-height': 22px
            '--iron-icon-width': 22px
            right: 3%
            top: 87%
          tap_action:
            action: call-service
            service: fan.XIAOMI_MIIO_SET_CHILD_LOCK_OFF
            service_data:
              entity_id: fan.xiaomi_air_purifier_2s
          type: icon
      image: /local/xiaomi-mi-air-purifier-2s.jpg
      type: picture-elements
type: 'custom:vertical-stack-in-card'
style:
  background-image: url("/local/xiaomi-mi-air-purifier-2s.jpg")
  background-repeat: no-repeat
  background-size: 100% 100%
  height: 100%
  position: relative
  type: 'custom:card-modder'</sub>
home-assistant.log
[frontend.js.latest.202001082] https://192.168.xxx.xxx:xxx/local/circle-sensor-card.js?v=2:76:79 Uncaught TypeError: Cannot read property 'state' of undefined
configuration.yaml

# Configure a default setup of Home Assistant (frontend, api, etc)
default_config:

# Uncomment this if you are using SSL/TLS, running in Docker container, etc.
# http:
#   base_url: example.duckdns.org:8123

# Text to speech
tts:
  - platform: google_translate

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
sensor: !include sensors.yaml

homeassistant:
  latitude: deleted
  longitude: deleted
  elevation: deleted
  unit_system: deleted
  time_zone: deleted
  name: Home

xiaomi_aqara:
  discovery_retry: 5
  gateways:
  - mac: deleted
    key: !secret gw_password

vacuum:
  - platform: xiaomi_miio
    host: deleted
    token: !secret roborock_token

discovery:
  ignore:
    - yeelight
yeelight:
  devices:
    deleted:
      name: Dining room light
    deleted:
      name: Kitchen light
    deleted:
      name: Bedroom left light
    deleted:
      name: Bedroom right light
    deleted:
      name: Living room light

http:
  base_url: deleted
  ssl_certificate: /ssl/cert.pem
  ssl_key: /ssl/key.pem
  
frontend:
  extra_html_url:
    - /local/custom_ui/state-card-floorplan.html
panel_custom:
  - name: floorplan
    sidebar_title: Floorplan
    sidebar_icon: mdi:home
    url_path: floorplan
    config: !include floorplan.yaml

lovelace:
  mode: yaml

www folder contains the following three JS: card-modder, circle-sensor-card, vertical-stack-in-card

sensors.yaml
#fan:
  - platform: xiaomi_miio
    host: deleted
    token: !secret airpurifier_token
    #name: "Xiaomi Air Purifier 2S"
    #model: zhimi.airpurifier.ma2

#sensor:
#  - platform: template
#sensors:
  - platform: template
    sensors:
      purifier_fan_mode:
         friendly_name: "Mode"
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.speed }}"
      purifier_fan_speed:
         friendly_name: "Motor speed"
         unit_of_measurement: 'rpm'
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.motor_speed }}"
      purifier_temperature:
         friendly_name: "Temperature"
         unit_of_measurement: 'C°'
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.temperature }}"
      purifier_humidity:
         friendly_name: "Humidity"
         unit_of_measurement: '%'
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.humidity }}"
      purifier_aqi:
         friendly_name: "Air Quality Index"
         unit_of_measurement: 'aqi'
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.aqi }}"
      purifier_favspeed:
         friendly_name: "Favourite Level"
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.favorite_level }}"
      purifier_filter_hours_used:
         friendly_name: "Hours Used"
         unit_of_measurement: 'h'
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.filter_hours_used }}"
      purifier_filter_life_remaining:
         friendly_name: "Filter"
         unit_of_measurement: '%'
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.filter_life_remaining }}"
      purifier_child_lock:
         friendly_name: "Child Lock"
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.child_lock }}"
      purifier_display:
         friendly_name: "Display"
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.led }}"
      purifier_button_pressed:
         friendly_name: "Button Pressed"
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.button_pressed }}"
      purifier_buzzer:
         friendly_name: "Buzzer"
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.buzzer }}"
      purifier_filter_type:
         friendly_name: "Filter Type"
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.filter_type }}"
      purifier_ligt_sensor:
         friendly_name: "Light Sensor"
         unit_of_measurement: 'lux'
         value_template: "{{ states.fan.xiaomi_air_purifier_2s.attributes.illuminance }}"</sub>

Could you help me what am I doing wrong?

Posts: 1

Participants: 1

Read full topic

Reinitialize HA instead of restart if an entity is not available

$
0
0

@gilbert-grape wrote:

Hello

I have some entities which are sometimes not available. For example: My wife has a switch unplugged, or there is a network problem. If I restart home assistant when the entity is currently offline, I see the entity as “unavailable” in Home Assistant. In that case I have to restart Home Assistant again and if the entity is available I get it back.

Instead of restarting, is there a simple trick like “re-initialize home assistant”, re-initialize an entity or reload a group of entities?

Thanks for answering
Gilbert

Posts: 4

Participants: 2

Read full topic


Picture element with changing colour border depending on state

$
0
0

@m90att wrote:

Hi,

I’ve searched for a way of doing this but cannot find any. I’ve got Custom Button Card but it doesn’t appear to do what I need.

I’d like a border on a picture element/entity (of my garage door camera, camera.garage) which will show a thick green border when the door opener (cover.garage) is closed and red when it is open.

Can anyone suggest how this can be achieved please?

Thanks,

Matt

Posts: 1

Participants: 1

Read full topic

Proxy through Nabu Casa?

$
0
0

@jjross wrote:

I am really enjoying using Nabu Casa to pass through to my HA instance and I was wondering if it’s possible for me to add other services (tautulli for instance) to my HA side bar so I can access them through the same interface.

Has anyone done this before? Is it allowed under the NC terms?

Posts: 1

Participants: 1

Read full topic

Fritz device_tracker doesn't find all devices

$
0
0

@hneel wrote:

I have included the Fritz!box device tracker in my configuration:

device_tracker:
  - platform: fritz  
    new_device_defaults:
      track_new_devices: true
      hide_if_away: false
    interval_seconds: 30
    consider_home: 300     

It does find some devices, but only a few. And none of them are mobile devices, which was what I wanted. The devices that are found are: dsesktop pc’s, printer, audio amplifier, etc.

The Fritzbox is type 7340. Most of the mobile devices are connected through a different wifi AP which is connected to the fritzbox via WDS over ethernet. But some are on the Fritzbox wifi. All devices can be seen in the “Home Network” list of the Fritzbox. Is it because android devices use google dns instead of the ip of the fritzbox or the provider?

Posts: 1

Participants: 1

Read full topic

What else to automate/integrate

$
0
0

@sd_dracula wrote:

On a HA binge here and looking for more ideas on what to automate/integrate :slight_smile:
Currently got a bunch setup:

  • All internal lights
  • All outdoor lights
  • Temp monitoring in all rooms
  • Heating and Valves
  • Air quality
  • UV values
  • Weather
  • Ring doorbell
  • Exterior cameras
  • Gates
  • My alarm system
  • Vacuum robot
  • My car & commute times
  • Alexa TTS
  • Harmony remote control
  • Smartthings (buttons, water sensors, motion sensors)

Things I’d like to do in the near future:

  • Replace all sockets with smart sockets
  • Integrate my Netatmo smoke alarms
  • Bed occupancy sensor
  • Auto-batcave under the kitchen counters for the robovac

Any other suggesitons?

Posts: 8

Participants: 6

Read full topic

Configuration for HA -QT-OpenZWave

$
0
0

@dooz127 wrote:

I’ve previously successfully set up my z-wave network using the built-in z-wave integration as well as zwave2mqtt. Now trying to integrate the new qt-open z-wave integration but not having a whole lot of luck.

Things I’ve tried:

  • I’ve verified my MQTT integration is working via Developer Tools
  • Disabled user/pw authentication on the default listener for the MQTT broker
  • Numerous combinations of restarting hass, adding/removing the hacs integration, restarting the MQTT client

But I seem to get the same error:

[20200130 22:01:59.893 UTC] [ozw.library] [info]: Info - Node: 0 Queuing Lookup on mfs.db.openzwave.com for Node 0
[20200130 22:01:59.894 UTC] [ozw.library] [info]: Info - Node: 0   Opening controller /dev/ttyACM2
[20200130 22:01:59.894 UTC] [ozw.library] [info]: Info - Node: 0 Trying to open serial port /dev/ttyACM2 (attempt 1)
[20200130 22:01:59.894 UTC] [ozw.library] [info]: Info - Node: 0 Timer: thread starting
[20200130 22:01:59.894 UTC] [ozw.library] [debug]: Detail - Node: 0 Timer: waiting with timeout -1 ms
[20200130 22:01:59.894 UTC] [ozw.library] [info]: Info - Node: 0 Starting DNSThread
[20200130 22:01:59.894 UTC] [ozw.library] [info]: Info - Node: 0 mgr,     Added driver for controller /dev/ttyACM2
[20200130 22:01:59.894 UTC] [ozw.manager] [debug]: AddDriver Completed
[20200130 22:01:59.894 UTC] [ozw.library] [info]: Info - Node: 0 Serial port /dev/ttyACM2 opened (attempt 1)
[20200130 22:01:59.894 UTC] [ozw.library] [info]: Info - Node: 0 LookupTxT Checking mfs.db.openzwave.com
[20200130 22:01:59.894 UTC] [qt.mqtt.connection] [debug]: void QMqttConnection::transportError(QAbstractSocket::SocketError) QAbstractSocket::HostNotFoundError
[20200130 22:01:59.894 UTC] [ozw.mqtt.publisher] [debug]: MQTT State Change 0
[20200130 22:01:59.894 UTC] [ozw.library] [debug]: Detail - Node: 255 Queuing (Command) FUNC_ID_ZW_GET_VERSION: 0x01, 0x03, 0x00, 0x15, 0xe9
[20200130 22:01:59.894 UTC] [ozw.mqtt.publisher] [warning]: Exiting on Failure

Anything else I need to do?

Didn’t want to pollute the thread, but this one is most relevant:

Posts: 4

Participants: 3

Read full topic

Dafang Hacked camera MQTT not updating. Any help?

$
0
0

@VGE wrote:

Hi guys,

I have the same problem. Im using Hass.io with the Mosquitto Broker Add-on. I have the Dafang hack working an i can reach and use the RTSP stream.

I edited /system/sdcard/config/mqtt.conf

And put in my information:

# Options for mosquitto_sub & mosquitto_pub
USER=USER1234
PASS=PW1234
HOST=192.168.1.125
PORT=1883

# Define a location
LOCATION="myhome"

# Define device name
DEVICE_NAME="dafang_cam_1"

# Define the base topic used by the camera
# send a message to myhome/dafang/set with the payload help for help.
# Results will be placed in myhome/dafang/${command} or topic/dafang/error - so please subscribe topic/d
TOPIC="$LOCATION/$DEVICE_NAME"

When i look in the Add-on logs i see the following:

1580413963: Client mosqpub|7223-DAFANG_CAM disconnected.
1580413963: New connection from 192.168.1.181 on port 1883.
1580413963: New client connected from 192.168.1.181 as mosqpub|7228-DAFANG_CAM (p1, c1, k60, u'Mosquitto').
1580413963: Client mosqpub|7228-DAFANG_CAM disconnected.
1580413964: New connection from 192.168.1.181 on port 1883.
1580413964: New client connected from 192.168.1.181 as mosqpub|7236-DAFANG_CAM (p1, c1, k60, u'Mosquitto').
1580413964: Client mosqpub|7236-DAFANG_CAM disconnected.
1580413964: New connection from 192.168.1.181 on port 1883.
1580413964: New client connected from 192.168.1.181 as mosqpub|7244-DAFANG_CAM (p1, c1, k60, u'Mosquitto').
1580413964: Client mosqpub|7244-DAFANG_CAM disconnected.
1580413965: New connection from 192.168.1.181 on port 1883.
1580413965: New client connected from 192.168.1.181 as mosqpub|7276-DAFANG_CAM (p1, c1, k60, u'Mosquitto').
1580413965: Client mosqpub|7276-DAFANG_CAM disconnected.

Mosquitto add-on config:

{
  "logins": [
    {
      "username": "USER1234",
      "password": "PW1234"
    }
  ],
  "anonymous": true,
  "customize": {
    "active": false,
    "folder": "mosquitto"
  },
  "certfile": "fullchain.pem",
  "keyfile": "privkey.pem",
  "require_certificate": false,
  "quiet_logs": true
}

I got one time discovery of the MQTT entities but now there not updating anymore or reacting to input. I restarted HA and the camera, and tried to stop/start the MQTT services on the camera but no succes.

Any help?

Posts: 2

Participants: 2

Read full topic

How to use Portainer?

$
0
0

@Andarras wrote:

Hi,

I’m new to the world of docker. I’ve been able to install some Web services but there are some that I would like to use a docker container.

My understanding is that as Hass.io runs within a docker container, Portainer can allow me to load docker images which allow me to run other Web services within Hass.io?

I went into images and tried to load a tarball docker file and direct url but none deployed.

Am I misunderstood the purpose of Portainer? If no is there atut somewhere to help me?

Thanks heaps

Posts: 10

Participants: 2

Read full topic


Can't create custom more info card

$
0
0

@marcomartins wrote:

Hello,

I’m trying to create a new more info card but I’m getting an error extending Polymer.Element, If I past the script on the browser console, it works, but when I’m loading the component I get Uncaught TypeError: Class extends value undefined is not a constructor or null

My code:


<dom-module id='more-info-plant'>
  <template>
    <style>

    </style>
    <textarea>[[_toStr(stateObj)]]</textarea>
  </template>
</dom-module>

<script>
  class MoreInfoPlant extends Polymer.Element {
    static get is() { return 'more-info-plant'; }

    static get properties() {
      return {
        // Home Assistant object
        hass: Object,
        // inDialog is true if shown as more-info-card
        inDialog: {
          type: Boolean,
          value: true,
        },
        // includes state, config and more information of the entity
        stateObj: Object,
      };
    }

    _toStr(obj) {
      return JSON.stringify(obj, null, 2);
    }
  }

  customElements.define(MoreInfoPlant.is, MoreInfoPlant);
</script>

Posts: 1

Participants: 1

Read full topic

Need help in setting up sonoff switch in Home Assistant

$
0
0

@mcnaveen wrote:

Finally I flashed my sonoff basic with Tasmota. But I can’t find any perfect guide for setting up in Home Assistant :sob:

Can you guys help me out!!

Posts: 21

Participants: 4

Read full topic

Web UI links for Addons not loading code HA Cloud

$
0
0

@Andarras wrote:

Hi all,

I successfully set up HA Cloud and can access my setup through my phone. All soft bar links work, however where I have to go into the add on and open Web UI these time out.

Is this a limitation or do I have to do something to get these working?

Thanks!

Posts: 1

Participants: 1

Read full topic

Trouble with creating scene on the fly, flash lights, then restore scene

$
0
0

@EcoJoe wrote:

I’m working on setting up an automation when a certain NHL team scores, my lights flash red and then go back to their previous state. I have it successfully triggering and flashing red, but it isn’t reverting the light to it’s previous color and brightness, it stays red. Below is the script that I’m calling from the automation:

blackhawksgoal:
  sequence:
    - service: scene.create
      data_template:
        scene_id: before
        snapshot_entities:
          - light.couch_left:
    - service: light.turn_on
      data:
        entity_id: light.couch_left
        brightness: 255
        rgb_color: [255, 0, 0]
        flash: long
    - delay:
        seconds: 20
    - service: scene.turn_on
      data:
        entity_id: scene.before

Here is the documentation I was following for creating scenes on the fly - https://www.home-assistant.io/integrations/scene/#creating-scenes-on-the-fly

Posts: 4

Participants: 2

Read full topic

Having trouble POSTing input_select options with RESTapi

$
0
0

@Curtis_Bishop wrote:

I am using the RESTapi to POST data into an input_select entity, but am having difficulty, not sure if it is a bug or something I’m doing wrong…

In my configuration.yaml, I have an input_select setup

input_select:
  pc_modes:
    options:
      - none
    name: PC Video Modes
    initial: none

which gives me this in lovelace
image

I am using Python on an separate (from HASS.IO) computer to send a POST request to home assistant.

{'User-Agent': 'python-requests/2.20.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'content-type': 'application/json', 'Accept-Charset': 'UTF-8', 'Authorization': 'Bearer REDACTED', 'Content-Length': '70'}
b'{"state": "2k.xml", "attributes": {"options": ["2k.xml", "4k.xml"]}}'

Home assistant accepts the request and returns a status 200

Everything looks good with the input_select on lovelace - it shows the options and current state correctly. Using the states inspector, again everything looks good.
image

But when I try to use the input_select in lovelace to change to one of the different options, I get the error,
Invalid option: 4k.xml (possible options: none)

It seems like the input_select will only accept the original “none” option, even though “none” is no longer an option for the entity.

Hoping someone can see something I’ve missed,
Thanks!

Posts: 1

Participants: 1

Read full topic

Viewing all 106096 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>