AZSupra
(Nick)
February 24, 2018, 11:42pm
1
I’m having trouble getting the device tracker widget to display state information. I don’t see an icon or state text.
Here is what I have as my widget definition:
nick_presence:
widget_type: device_tracker
title: Nick
device: a019c664e60a
state_text: 1
icon_on: fa-male
icon_off: fa-male
And here is what is in known_devices.yaml:
a019c664e60a:
hide_if_away: false
mac: A0:19:C6:64:E6:0A
name: Nick
picture: /local/images/nick.jpg
track: true
All I see is a blank tile with the title ‘Nick’. Any ideas?
When I inspect element I also see no state text:
<h1 class="state_text" data-bind="text: state_text, attr: {style: state_text_style}" style="color: #646464;"></h1>
aimc
(Andrew Cockburn)
February 25, 2018, 2:03pm
2
This all points to your device_tracker not having a recognized state of either home
or not_home
. Can you verify what it’s state is with the dev tools?
AZSupra
(Nick)
February 25, 2018, 5:13pm
3
I double checked that and it looks right.
device_tracker.a019c664e60a home
I also disconnected from wifi and verified that the away state switches to not_home
aimc
(Andrew Cockburn)
February 25, 2018, 5:18pm
4
Are you having problems with any other widget types?
keithh666
(Keith Hull)
February 25, 2018, 5:37pm
5
keith_presence:
widget_type: device_tracker
title: Keith
device: samsungs5
enable: 1
icon_on: fa-male
icon_style_active: "color: #4bcdea"
This is what mine looks like.
AZSupra
(Nick)
February 25, 2018, 5:50pm
6
No other widget problems. I created a new test dashboard and copied the device tracker widget definition over and it works fine so it must be something on my end with my existing dashboard.
1 Like