Wall Mounted Dashboard (now known as HADashboard)

I have all in one and i tried it but it doesn’t start automatically. Any idea, In init.d/dashing i changed the path -
NAME=dashing
DASHING_DIR=/home/pi/hadashboard
DAEMON=/usr/local/bin/dashing

and in HAPUSH i changed -
NAME=hapush
HAPUSH_DIR=/home/pi/hadashboard/hapush

I can manually start both.

1 Like

You need to copy those files to the /etc/init.d/ directory so that the pi will know to run those on boot.

In the first few lines of those files are instructions in the comments, this bit from dashing…

# Dashing service
# Add this file to /etc/init.d/
# $ sudo cp dashboard /etc/init.d/
# Update variables DASHING_DIR, GEM_HOME, & PATH to suit your installation
# $ sudo nano /etc/init.d/dashboard
# Make executable
# $ sudo chmod 755 /etc/init.d/dashboard
# Update rc.d
# $ sudo update-rc.d dashboard defaults
# Dashboard will start at boot. Check out the boot log for trouble shooting "/var/log/boot.log"
# USAGE: start|stop|status|logs

I to am strugling with this autostart.
So have a couple of questions myself:
I manually copy the 2 files to the etc/init.d directory and the run the sudo commands listet in the 2 files, or should i just follow the commands and then the files gets copied?

Shall i write anything in the dashboard file? Can see i need to nano it? but its a new file and nothing is in it.

Got it working… thanks

Sorry for spamming this thread, but i really need some help with this autostart.
i have copied Dashing and Hapush files to /etc/init.d directory and updated the DASHING_DIR and HAPUSH_DIR to the correct ones (or atleast i think)
But what more do i need to do?

From my files, just the lines I had to change…

hapush

HAPUSH_DIR=/home/pi/hadashboard/hapush

dashing

DASHING_DIR=/home/pi/hadashboard
...
GEM_HOME=/usr/local/lib/site_ruby/gems/1.9.1

After you change these files, save and copy to /etc/init.d you need to make them executable. I think maybe there is an error in the instructions but can’t remember what I typed for this next bit.

From putty if that is what you use you type.

sudo chmod 755 /etc/init.d/dashing

and do the same for hapush

sudo chmod 755 /etc/init.d/hapush

then

sudo update-rc.d dashboard defaults

If not you may have to hope @vageesh79 can tell you what he did yesterday.

I have configured the HA-Dashboard perfectly and I only had to do a complete reinstall of everything to get it working… Yay!!! :smiley:

Unfortunately I have an issue with hapush when i start ./hapush.py hapush.cfg it runs without error, however when i make changes to the HASS Web UI lighting I get the following error in the hapush command line, has anyone got any suggestions?

2016-12-11 23:18:16,382 INFO Reading dashboard: /home/pi/hadashboard/dashboards/main.erb
2016-12-11 23:18:26,105 INFO switch.living_room -> state = off, brightness = 30
2016-12-11 23:18:26,122 WARNING Unexpected error calling Dashing: HTTPConnectionPool(host='http', port=80): Max retries exceeded with url: //10.3.6.250:3030/widgets/living_room (Caused by NewConnectionError('<requests.packages.urllib3.connection.HTTPConnection object at 0x7623b690>: Failed to establish a new connection: [Errno -2] Name or service not known',))

hapush.cfg
ha_url = “http://10.3.6.250:8123
ha_key = API-Key-Here
dash_host = “http://10.3.6.250:3030
dash_dir = “/home/pi/hadashboard/dashboards”
logfile = “/etc/hapush/hapush.log”

ha_confi.rb
$ha_url = “http://10.3.6.250:8123
$ha_apikey = “API-Key-Here”

$news_feeds = {
“Traffic” => “Trafikredaktionen”,
“News” => “<![CDATA[BBC News]]>”,
}

When I send commands from HADashboard they are reflected on the HASS Web UI, so the problem is with data coming into the HADashboard, but i have no idea what is causing it :angry:

in your conf. rb you have set the url from your dashboard at the place where you should set the url from hass :wink:

Doh!!!

Thanks a lot… It was typo copying the config I have amended the post it’s now correct and the problem persists :frowning:

My weather tab is not getting updated. I am using darksky and i can see the entites in HA but not in dashboard. The config i am using for both is -
HA config –

  • platform: darksky
    api_key: xxxx
    monitored_conditions:
    • temperature
    • hourly_summary
    • humidity
    • wind_bearing
    • pressure
      Dashboard config –
      li data-row=“1” data-col=“3” data-sizex=“2” data-sizey=“2”>
      div data-id=“weather” data-view=“Haweather” data-unit=“°C” data-color="#FF0000"></div
    </li

I have to remove <> from the dashboard config to display here but its ther ein config.
Do we have to change anything else also for to get the tab updated.

@noodlemctwoodle it seems like you have trouble with 1 widget.
try removing the widget livingroom and see if the problem stays.
if thats not enough try removing the one before or after it in your main.erb.

@vageesh79 what entity_id can you see in ha?

My entity_id’s are different than ‘weather’ . I am using data-id weather because it says in the website to use it.
“The data-id of the Haweather widget must be set to weather or the widget will not work.”

i dont use that weather part but i asked because if they are different, the program wont recoqnize it.

i see that they should be:

sensor.dark_sky_temperature
sensor.dark_sky_humidity
sensor.dark_sky_precip_probability
sensor.dark_sky_precip_intensity
sensor.dark_sky_wind_speed
sensor.dark_sky_pressure
sensor.dark_sky_wind_bearing
sensor.dark_sky_apparent_temperature

in HA.

do you see any kind off error in your logs?

Yes they are the same in HA for darksky

do other parts get updated?
if i read the “job” well they should be updated every 15 minutes.

I tried using darksky weather id in different column and it works but how to update the default weather options. Do i use all different id for it.

the weather widget is like it is.

but you can use the sensor widget also for every element you want to see seperatly.

edit: you could also make changes to the haweather.html part from the widget.

Thank you for you answer. When typing:
sudo update-rc.d dashboard defaults
I get the following errors:

pi@raspberrypi:~/hadashboard $ sudo update-rc.d dashboard defaults
insserv: warning: script ‘K01dashboard’ missing LSB tags and overrides
insserv: warning: script ‘dashboard’ missing LSB tags and overrides
insserv: script dashing: service dashboard already provided!

Any help would be nice :slight_smile:

@vageesh79 I had this exact same issue when setting up HADashboard. I added all of the dark sky sensors to my sensors.yaml

# Weather
  - platform: darksky
    api_key: API-KEY-HERE
    monitored_conditions:
      - summary
      - icon
      - nearest_storm_distance
      - nearest_storm_bearing
      - precip_type
      - precip_intensity
      - precip_probability
      - temperature
      - apparent_temperature
      - dew_point
      - wind_speed
      - wind_bearing
      - cloud_cover
      - humidity
      - pressure
      - visibility
      - ozone
      - minutely_summary
      - hourly_summary
      - daily_summary
      - temperature_max
      - temperature_min
      - apparent_temperature_max
      - apparent_temperature_min
      - precip_intensity_max

You could go through each one and figure out which one is required, however I just hid all the ones I didn’t want from the HA UI.

1 Like

Following on from my previous issue I have done a bit more troubleshooting and this is the error I get when I make a change on HADash,

2016-12-12 19:26:22,932 INFO switch.bedroom -> state = off, brightness = 30
2016-12-12 19:26:22,946 WARNING Unexpected error calling Dashing: HTTPConnectionPool(host='http', port=80): Max retries exceeded with url: //10.3.6.250:3030/widgets/bedroom (Caused by NewConnectionError('<requests.packages.urllib3.connection.HTTPConnection object at 0x762d0710>: Failed to establish a new connection: [Errno -2] Name or service not known',))

When I make a change on the HASS web UI I get the following error:

2016-12-12 19:28:38,073 INFO switch.bedroom -> state = on, brightness = 100
2016-12-12 19:28:38,090 WARNING Unexpected error calling Dashing: HTTPConnectionPool(host='http', port=80): Max retries exceeded with url: //10.3.6.250:3030/widgets/bedroom (Caused by NewConnectionError('<requests.packages.urllib3.connection.HTTPConnection object at 0x762d08f0>: Failed to establish a new connection: [Errno -2] Name or service not known',))

The errors appear to be the same apart from this value 0x762d0710 in the HAS web UI change and this value 0x762d08f0 in the HADash change. I’m not sure if this is a red herring as this 0x value changes each time you toggled a light switch on or off on either the HADash or the HASS web UI.

Here is another error output when you CTRL+C out of hapush:
> 2016-12-12 21:01:45,142 CRITICAL Traceback (most recent call last):
> File “./hapush.py”, line 265, in run
> for msg in messages:
> File “/usr/local/lib/python3.4/dist-packages/sseclient.py”, line 64, in next
> nextline = self.resp_file.readline()
> File “/usr/local/lib/python3.4/dist-packages/requests/packages/urllib3/response.py”, line 380, in read
> data = self._fp.read(amt)
> File “/usr/lib/python3.4/http/client.py”, line 500, in read
> return super(HTTPResponse, self).read(amt)
> File “/usr/lib/python3.4/http/client.py”, line 529, in readinto
> return self._readinto_chunked(b)
> File “/usr/lib/python3.4/http/client.py”, line 614, in _readinto_chunked
> chunk_left = self._read_next_chunk_size()
> File “/usr/lib/python3.4/http/client.py”, line 552, in _read_next_chunk_size
> line = self.fp.readline(_MAXLINE + 1)
> File “/usr/lib/python3.4/socket.py”, line 371, in readinto
> return self._sock.recv_into(b)
> File “/usr/lib/python3.4/ssl.py”, line 745, in recv_into
> return self.read(nbytes, buffer)
> File “/usr/lib/python3.4/ssl.py”, line 617, in read
> v = self._sslobj.read(len, buffer)

Regardless of the error if I make a change and toggle a light on/off on the HASS web UI or I repeat the process on the HADash the changes are synced between each other, although you have to refresh the HADash webpage to see each change made from the HASS web UI.

@ReneTode I have tested removing every widget in main.erb except for 1 light switch (switch,bedroom) and I still get the above error on any light widget. This is how my widget is configured:

  <ul>
     <li data-row="1" data-col="1" data-sizex="2" data-sizey="1">
      <div data-id="bedroom" data-view="Hadimmer" data-title="Bedroom" data-color="255,255,255"></div>
    </li>

I have also tried this as the widget, but get same issue

  <ul>
     <li data-row="1" data-col="1" data-sizex="2" data-sizey="1">
      <div data-id="bedroom" data-view="Hadimmer" data-title="Bedroom" data-color="#FF0000"></div>
    </li>

The entity_id in HASS is light.bedroom, I read in the wiki that it is not possible to add the full entity_id such as light.bedroom into the widget. the “data-id” must be everything after the dot of the first part of the “entity_id” so “light.bedroom” would become “bedroom”. However this didn’t stop me from testing it with the full “entity_id” in “data-id” this didn’t work as expected :slight_smile:

I’ve now also tested this with and without a HASS API-Key, with HASS on HTTPS and HTTP -no change in error

Any insight would be great