no front end or connection available. i can ssh and samba though
hold your horses… it’s just taking time. up now but no sensor info. says unknown
2017-06-02 07:43:47 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up platform sensehat
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/helpers/entity_component.py", line 155, in _async_setup_platform
entity_platform.schedule_add_entities, discovery_info
File "/usr/lib/python3.4/asyncio/futures.py", line 388, in __iter__
yield self # This tells Task to wait for completion.
File "/usr/lib/python3.4/asyncio/tasks.py", line 286, in _wakeup
value = future.result()
File "/usr/lib/python3.4/asyncio/futures.py", line 277, in result
raise self._exception
File "/usr/lib/python3.4/concurrent/futures/thread.py", line 54, in run
result = self.fn(*self.args, **self.kwargs)
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/sensor/sensehat.py", line 66, in setup_platform
dev.append(SenseHatSensor(data, variable))
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/sensor/sensehat.py", line 81, in __init__
self.update()
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/sensor/sensehat.py", line 100, in update
self.data.update()
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/util/__init__.py", line 303, in wrapper
result = method(*args, **kwargs)
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/sensor/sensehat.py", line 126, in update
from sense_hat import SenseHat
File "/home/homeassistant/.homeassistant/deps/sense_hat/__init__.py", line 2, in <module>
from .sense_hat import SenseHat, SenseHat as AstroPi
File "/home/homeassistant/.homeassistant/deps/sense_hat/sense_hat.py", line 10, in <module>
import RTIMU # custom version
ImportError: No module named 'RTIMU'
2017-06-02 07:43:47 ERROR (MainThread) [homeassistant.components.light] Error while setting up platform sensehat
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/helpers/entity_component.py", line 155, in _async_setup_platform
entity_platform.schedule_add_entities, discovery_info
File "/usr/lib/python3.4/asyncio/futures.py", line 388, in __iter__
yield self # This tells Task to wait for completion.
File "/usr/lib/python3.4/asyncio/tasks.py", line 286, in _wakeup
value = future.result()
File "/usr/lib/python3.4/asyncio/futures.py", line 277, in result
raise self._exception
File "/usr/lib/python3.4/concurrent/futures/thread.py", line 54, in run
result = self.fn(*self.args, **self.kwargs)
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/light/sensehat.py", line 32, in setup_platform
from sense_hat import SenseHat
File "/home/homeassistant/.homeassistant/deps/sense_hat/__init__.py", line 2, in <module>
from .sense_hat import SenseHat, SenseHat as AstroPi
File "/home/homeassistant/.homeassistant/deps/sense_hat/sense_hat.py", line 10, in <module>
import RTIMU # custom version
ImportError: No module named 'RTIMU'
last thing i tried
pi@hassbian:~ $ sudo pip3 install rtimulib
Requirement already satisfied (use --upgrade to upgrade): rtimulib in /usr/lib/python3/dist-packages
Cleaning up…
pi@hassbian:~ $ ln -s /usr/local/lib/python3.4/dist-packages/RTIMU.cpython-34m.so /home/homeassistant/.homeassistant/deps/
ln: failed to create symbolic link ‘/home/homeassistant/.homeassistant/deps/RTIMU.cpython-34m.so’: Permission denied
pi@hassbian:~ $ python3
Python 3.4.2 (default, Oct 19 2014, 13:31:11)
[GCC 4.9.1] on linux
Type “help”, “copyright”, “credits” or “license” for more information.
>>> from sense_hat import SenseHat
>>> sense = SenseHat()
>>> sense.show_message(“Hello world!”)
>>> sense.show_message(“Hello world!”)
>>> sudo apt-get install virtualenv python-dev python-pip libjpeg-dev sense-hat
File “”, line 1
sudo apt-get install virtualenv python-dev python-pip libjpeg-dev sense-hat
^
SyntaxError: invalid syntax
>>> exit
Use exit() or Ctrl-D (i.e. EOF) to exit
>>>
pi@hassbian:~ $ sudo apt-get install virtualenv python-dev python-pip libjpeg-dev sense-hat
Reading package lists… Done
Building dependency tree
Reading state information… Done
python-dev is already the newest version.
sense-hat is already the newest version.
The following extra packages will be installed:
libjpeg62-turbo-dev python-chardet python-colorama python-distlib python-html5lib python-ndg-httpsclient python-openssl python-pkg-resources python-pyasn1 python-requests python-setuptools
python-six python-urllib3 python-wheel python3-virtualenv
Suggested packages:
python-genshi python-lxml python-openssl-doc python-openssl-dbg python-distribute python-distribute-doc doc-base
Recommended packages:
python-dev-all
The following packages will be REMOVED:
libjpeg9-dev
The following NEW packages will be installed:
libjpeg-dev libjpeg62-turbo-dev python-chardet python-colorama python-distlib python-html5lib python-ndg-httpsclient python-openssl python-pip python-pkg-resources python-pyasn1 python-requests
python-setuptools python-six python-urllib3 python-wheel python3-virtualenv virtualenv
0 upgraded, 18 newly installed, 1 to remove and 0 not upgraded.
Need to get 1,736 kB of archives.
After this operation, 6,706 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://mirrordirector.raspbian.org/raspbian/ jessie/main libjpeg62-turbo-dev armhf 1:1.3.1-12 [400 kB]
Get:2 http://mirrordirector.raspbian.org/raspbian/ jessie/main libjpeg-dev all 1:1.3.1-12 [49.3 kB]
Get:3 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-pkg-resources all 5.5.1-1 [64.4 kB]
Get:4 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-chardet all 2.3.0-1 [96.2 kB]
Get:5 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-colorama all 0.3.2-1 [20.3 kB]
Get:6 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-distlib all 0.1.9-1 [113 kB]
Get:7 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-six all 1.8.0-1 [12.6 kB]
Get:8 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-html5lib all 0.999-3 [84.0 kB]
Get:9 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-openssl armhf 0.13.1-2 [85.5 kB]
Get:10 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-ndg-httpsclient all 0.3.2-1 [20.5 kB]
Get:11 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-urllib3 all 1.9.1-3 [55.4 kB]
Get:12 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-requests all 2.4.3-6 [204 kB]
Get:13 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-setuptools all 5.5.1-1 [242 kB]
Get:14 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-pip all 1.5.6-5 [114 kB]
Get:15 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-pyasn1 all 0.1.7-1 [49.3 kB]
Get:16 http://mirrordirector.raspbian.org/raspbian/ jessie/main python-wheel all 0.24.0-1 [47.5 kB]
Get:17 http://mirrordirector.raspbian.org/raspbian/ jessie/main python3-virtualenv all 1.11.6+ds-1 [60.5 kB]
Get:18 http://mirrordirector.raspbian.org/raspbian/ jessie/main virtualenv all 1.11.6+ds-1 [17.2 kB]
Fetched 1,736 kB in 8s (202 kB/s)
(Reading database … 42651 files and directories currently installed.)
Removing libjpeg9-dev:armhf (1:9a-2) …
Selecting previously unselected package libjpeg62-turbo-dev:armhf.
(Reading database … 42636 files and directories currently installed.)
Preparing to unpack …/libjpeg62-turbo-dev_1%3a1.3.1-12_armhf.deb …
Unpacking libjpeg62-turbo-dev:armhf (1:1.3.1-12) …
Selecting previously unselected package libjpeg-dev.
Preparing to unpack …/libjpeg-dev_1%3a1.3.1-12_all.deb …
Unpacking libjpeg-dev (1:1.3.1-12) …
Selecting previously unselected package python-pkg-resources.
Preparing to unpack …/python-pkg-resources_5.5.1-1_all.deb …
Unpacking python-pkg-resources (5.5.1-1) …
Selecting previously unselected package python-chardet.
Preparing to unpack …/python-chardet_2.3.0-1_all.deb …
Unpacking python-chardet (2.3.0-1) …
Selecting previously unselected package python-colorama.
Preparing to unpack …/python-colorama_0.3.2-1_all.deb …
Unpacking python-colorama (0.3.2-1) …
Selecting previously unselected package python-distlib.
Preparing to unpack …/python-distlib_0.1.9-1_all.deb …
Unpacking python-distlib (0.1.9-1) …
Selecting previously unselected package python-six.
Preparing to unpack …/python-six_1.8.0-1_all.deb …
Unpacking python-six (1.8.0-1) …
Selecting previously unselected package python-html5lib.
Preparing to unpack …/python-html5lib_0.999-3_all.deb …
Unpacking python-html5lib (0.999-3) …
Selecting previously unselected package python-openssl.
Preparing to unpack …/python-openssl_0.13.1-2_armhf.deb …
Unpacking python-openssl (0.13.1-2) …
Selecting previously unselected package python-ndg-httpsclient.
Preparing to unpack …/python-ndg-httpsclient_0.3.2-1_all.deb …
Unpacking python-ndg-httpsclient (0.3.2-1) …
Selecting previously unselected package python-urllib3.
Preparing to unpack …/python-urllib3_1.9.1-3_all.deb …
Unpacking python-urllib3 (1.9.1-3) …
Selecting previously unselected package python-requests.
Preparing to unpack …/python-requests_2.4.3-6_all.deb …
Unpacking python-requests (2.4.3-6) …
Selecting previously unselected package python-setuptools.
Preparing to unpack …/python-setuptools_5.5.1-1_all.deb …
Unpacking python-setuptools (5.5.1-1) …
Selecting previously unselected package python-pip.
Preparing to unpack …/python-pip_1.5.6-5_all.deb …
Unpacking python-pip (1.5.6-5) …
Selecting previously unselected package python-pyasn1.
Preparing to unpack …/python-pyasn1_0.1.7-1_all.deb …
Unpacking python-pyasn1 (0.1.7-1) …
Selecting previously unselected package python-wheel.
Preparing to unpack …/python-wheel_0.24.0-1_all.deb …
Unpacking python-wheel (0.24.0-1) …
Selecting previously unselected package python3-virtualenv.
Preparing to unpack …/python3-virtualenv_1.11.6+ds-1_all.deb …
Unpacking python3-virtualenv (1.11.6+ds-1) …
Selecting previously unselected package virtualenv.
Preparing to unpack …/virtualenv_1.11.6+ds-1_all.deb …
Unpacking virtualenv (1.11.6+ds-1) …
Processing triggers for man-db (2.7.0.2-5) …
Setting up libjpeg62-turbo-dev:armhf (1:1.3.1-12) …
Setting up libjpeg-dev (1:1.3.1-12) …
Setting up python-pkg-resources (5.5.1-1) …
Setting up python-chardet (2.3.0-1) …
Setting up python-colorama (0.3.2-1) …
Setting up python-distlib (0.1.9-1) …
Setting up python-six (1.8.0-1) …
Setting up python-html5lib (0.999-3) …
Setting up python-openssl (0.13.1-2) …
Setting up python-ndg-httpsclient (0.3.2-1) …
Setting up python-urllib3 (1.9.1-3) …
Setting up python-requests (2.4.3-6) …
Setting up python-setuptools (5.5.1-1) …
Setting up python-pip (1.5.6-5) …
Setting up python-pyasn1 (0.1.7-1) …
Setting up python-wheel (0.24.0-1) …
Setting up python3-virtualenv (1.11.6+ds-1) …
Setting up virtualenv (1.11.6+ds-1) …
Processing triggers for python-support (1.0.15) …
pi@hassbian:~ $ sudo pip install pillow
Requirement already satisfied (use --upgrade to upgrade): pillow in /usr/lib/python2.7/dist-packages
Cleaning up…
pi@hassbian:~ $ sudo su -s /bin/bash homeassistant
homeassistant@hassbian:/home/pi $ source /srv/homeassistant/homeassistant_venv/bin/activate
bash: /srv/homeassistant/homeassistant_venv/bin/activate: No such file or directory
homeassistant@hassbian:/home/pi $ python3
Python 3.4.2 (default, Oct 19 2014, 13:31:11)
[GCC 4.9.1] on linux
Type “help”, “copyright”, “credits” or “license” for more information.
>>> from sense_hat import SenseHat
>>> sense = SenseHat()
>>>
>>> sense.set_rotation(270)
>>> sense.show_message(“Hi!”, text_colour=(255, 0, 0))
>>> temp_frm_hmdty = sense.get_temperature_from_humidity()
>>> temp_frm_hmdty = sense.get_temperature_from_humidity()
>>>
homeassistant@hassbian:/home/pi $ exit
exit
pi@hassbian:~ $ pip3 install rtimulib
Requirement already satisfied (use --upgrade to upgrade): rtimulib in /usr/lib/python3/dist-packages
Cleaning up…
pi@hassbian:~ $ sudo addgroup homeassistant input
The user homeassistant' is already a member of
input’.
pi@hassbian:~ $ ln -s /usr/lib/python3/dist-packages/RTIMU.cpython-34m-arm-linux-gnueabihf.so /srv/homeassistant/lib/python3.4/
ln: failed to create symbolic link ‘/srv/homeassistant/lib/python3.4/RTIMU.cpython-34m-arm-linux-gnueabihf.so’: Permission denied
pi@hassbian:~ $ sudo su -s /bin/bash homeassistant
homeassistant@hassbian:/home/pi $ ln -s /usr/lib/python3/dist-packages/RTIMU.cpython-34m-arm-linux-gnueabihf.so /srv/homeassistant/lib/python3.4/
homeassistant@hassbian:/home/pi $ ln -s /usr/lib/python3/dist-packages/RTIMU.cpython-34m-arm-linux-gnueabihf.so /srv/homeassistant/homeassistant_venv/lib/python3.4/
ln: target ‘/srv/homeassistant/homeassistant_venv/lib/python3.4/’ is not a directory: No such file or directory
homeassistant@hassbian:/home/pi $ exit
exit
pi@hassbian:~ $ sudo reboot
still getting
2017-06-02 08:03:42 ERROR (MainThread) [homeassistant.components.light] Error while setting up platform sensehat
Traceback (most recent call last):
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/helpers/entity_component.py”, line 155, in _async_setup_platform
entity_platform.schedule_add_entities, discovery_info
File “/usr/lib/python3.4/asyncio/futures.py”, line 388, in iter
yield self # This tells Task to wait for completion.
File “/usr/lib/python3.4/asyncio/tasks.py”, line 286, in _wakeup
value = future.result()
File “/usr/lib/python3.4/asyncio/futures.py”, line 277, in result
raise self._exception
File “/usr/lib/python3.4/concurrent/futures/thread.py”, line 54, in run
result = self.fn(*self.args, **self.kwargs)
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/light/sensehat.py”, line 32, in setup_platform
from sense_hat import SenseHat
File “/home/homeassistant/.homeassistant/deps/sense_hat/init.py”, line 2, in
from .sense_hat import SenseHat, SenseHat as AstroPi
File “/home/homeassistant/.homeassistant/deps/sense_hat/sense_hat.py”, line 10, in
import RTIMU # custom version
ImportError: No module named ‘RTIMU’
Appears to be the error we solved on RTIMU installation in Hassbian 1.1 using sudo apt-get install python3-rtimulib
(not pip)
If all else fails I suggest a fresh install of Hassbian
here comes etcher…sigh
fresh hassbian install
pi@hassbian:~ $ sudo su -s /bin/bash homeassistant
homeassistant@hassbian:/home/pi $ source /srv/homeassistant/homeassistant_venv/bin/activate
bash: /srv/homeassistant/homeassistant_venv/bin/activate: No such file or directory
homeassistant@hassbian:/home/pi $ source /srv/homeassistant/bin/activate
(homeassistant) homeassistant@hassbian:/home/pi $ pip3 install sense-hat
Command “/srv/homeassistant/bin/python3 -u -c “import setuptools, tokenize;file=’/tmp/pip-build-v0y8bn21/pillow/setup.py’;f=getattr(tokenize, ‘open’, open)(file);code=f.read().replace(’\r\n’, ‘\n’);f.close();exec(compile(code, file, ‘exec’))” install --record /tmp/pip-jndmbz5a-record/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.4/pillow” failed with error code 1 in /tmp/pip-build-v0y8bn21/pillow/
Try apt-get
as per the link
cheers
thanks for sticking around @robmarkcole. I appreciate the help. Should I be doing
sudo apt-get install python3-rtimulib
at the pi level or the homeassistant@hassbian
I’ve been there… As Pi
figured that as the other wanted a password and none worked
so far i’ve done
sudo apt-get install python3-rtimulib
which seems to have worked
then
sudo apt-get install sense-hat
again seems to have worked
then
sudo addgroup homeassistant input
followed by
sudo addgroup homeassistant i2c
I am about to restart but am worried about the whole sym link thing from https://github.com/home-assistant/home-assistant/issues/5093
oh well…time to roll the dice
and no joy from me
2017-06-02 11:37:27 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up platform sensehat
Traceback (most recent call last):
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/helpers/entity_component.py”, line 155, in _async_setup_platform
entity_platform.schedule_add_entities, discovery_info
File “/usr/lib/python3.4/asyncio/futures.py”, line 388, in iter
yield self # This tells Task to wait for completion.
File “/usr/lib/python3.4/asyncio/tasks.py”, line 286, in _wakeup
value = future.result()
File “/usr/lib/python3.4/asyncio/futures.py”, line 277, in result
raise self._exception
File “/usr/lib/python3.4/concurrent/futures/thread.py”, line 54, in run
result = self.fn(*self.args, **self.kwargs)
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/sensor/sensehat.py”, line 66, in setup_platform
dev.append(SenseHatSensor(data, variable))
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/sensor/sensehat.py”, line 81, in init
self.update()
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/sensor/sensehat.py”, line 100, in update
self.data.update()
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/util/init.py”, line 303, in wrapper
result = method(*args, **kwargs)
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/sensor/sensehat.py”, line 126, in update
from sense_hat import SenseHat
File “/home/homeassistant/.homeassistant/deps/sense_hat/init.py”, line 2, in
from .sense_hat import SenseHat, SenseHat as AstroPi
File “/home/homeassistant/.homeassistant/deps/sense_hat/sense_hat.py”, line 10, in
import RTIMU # custom version
ImportError: No module named ‘RTIMU’
Afraid I am out of ideas. Can only say it is working for me…
TBH sense-hat is overkill, could just use a DHT sensor
DUUUUUUUDDDEEEE!!! you @robmarkcole and @TwanFox fixed specifically it was me not reading properly
I also had to make an adjustment to WHERE I put the symlink into the virtual environment. Specifically
ln -s /usr/lib/python3/dist-packages/RTIMU.cpython-34m-arm-linux-gnueabihf.so /srv/homeassistant/lib/python3.4/site-packages/
did that and it is up and running
c’est la vie…
HI,
Just installed the sense hat in my Hassio … any ideas how to switch the light OFF?
And get the 3 meters to display a value?
the log displays hefty errors
File “/usr/lib/python3.6/site-packages/homeassistant/helpers/entity_component.py”, line 216, in async_add_entity
yield from entity.async_device_update(warning=False)
File “/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py”, line 309, in async_device_update
yield from self.hass.async_add_job(self.update)
File “/usr/lib/python3.6/asyncio/futures.py”, line 331, in iter
yield self # This tells Task to wait for completion.
File “/usr/lib/python3.6/asyncio/tasks.py”, line 244, in _wakeup
future.result()
File “/usr/lib/python3.6/asyncio/futures.py”, line 244, in result
raise self._exception
File “/usr/lib/python3.6/concurrent/futures/thread.py”, line 55, in run
result = self.fn(*self.args, **self.kwargs)
File “/usr/lib/python3.6/site-packages/homeassistant/components/sensor/sensehat.py”, line 99, in update
self.data.update()
File “/usr/lib/python3.6/site-packages/homeassistant/util/init.py”, line 306, in wrapper
result = method(*args, **kwargs)
File “/usr/lib/python3.6/site-packages/homeassistant/components/sensor/sensehat.py”, line 125, in update
from sense_hat import SenseHat
File “/usr/lib/python3.6/site-packages/sense_hat/init.py”, line 2, in
from .sense_hat import SenseHat, SenseHat as AstroPi
File “/usr/lib/python3.6/site-packages/sense_hat/sense_hat.py”, line 10, in
import RTIMU # custom version
ModuleNotFoundError: No module named ‘RTIMU’
Thanks !
Marius
how did you install in hassio
by following this guideline:
Appears to be missing https://github.com/RPi-Distro/python-sense-emu/blob/master/sense_emu/RTIMU.py
I’d raise an issue. I recall having a headache getting sense hat up an running on regular Hassbian