Explorer HAT install instructions

Guys,
Think there might be a few issues with Explorer HAT documentation;
I had a look at Github, and either I’m being even more stupid than usual but I ran the i2c script and installed python sm-bus and tried to pip install explorerhat but it returns an error, ‘no package found’ (or words to that effect)

As an aside the page link on the packaging doesn’t give any install or ‘getting started’ instructions.

What I am doing wrong :)

Cheers,

Gordon

I’m wanting to get an Explorer Hat too so I thought I’d try and install anyway even though I don’t have the hardware to test with. I found this page but it has references to Pibrella so that won’t help :)

https://pypi.python.org/pypi/Explorer/0.1

(and this too https://pypi.python.org/pypi/ExplorerHAT/0.1 but doesn’t seem to help much)

edit: pip search explorerhat does return an entry but like you I can’t install it

Good evening all,

I bought an Explorer Pro HAT at the glorious Raspberry Pi Birthday Party yesterday from some extremely helpful Pimoroni guys who used their kit and software to power my tank project.

Unfortunately, now I am having exactly the same issues as Gordon.

I have tried to run welcome.py without success.

I eagerly await some help.

Kind regards

TankMan

Try using pip to install git and then git clone http://github.com/pimoroni/explorer-hat then cd explorer-hat/library then sudo python setup.py install.

1 Like

Hello TankMan! Glad to see you found your way here :-)

I’ll ask @gadgetoid to step in and help you get up and running!

1 Like

It’s highly probable that I totally missed the pip upload step for the shiny new library! I’ll have to sort that this evening when I’m back in front of a computer.

For now you’ll need to clone the GitHub repo, as Sandy suggests, and install by running:

sudo ./setup.py install

In the library directory!

D’oh!

Okay I’ve pushed up to pip!

sudo pip install explorerhat

Should now work.

Hooray for modern phones!

1 Like

works* for me now!

(*works == installs and I can run a script that uses it and I get an IO error, which I’d expect!)

Thanks all, sadly I’m travelling for the next few days so won’t get a chance to play, but as it’s now working for others I’m optimistic of achieving success!

Gordon

Hi Jon,

Thanks for getting this sorted so quickly. I have just run test.py and have lights activating on touch. The tank is one step closer to completion.

1 Like

Hi gadgetoid,

Many thanks for your help.

Hi Sandy,

Many thanks for your input. All is up and running now.

1 Like

Having a bunch of fun with mine. Hooked up the IR sensor from my CamJam #2 kit to input one (wasn’t really sure what I was doing but it seemed to work!).

import explorerhat

def alert(pin):
  print "*** WARNING!!! INTRUDER ALERT!!! ***"
  print("Zone : " + pin.name)
  return

explorerhat.input.one.pressed(alert)
explorerhat.pause()

was all it took to get something working

Hi gadgetoid,

I’m still having some teething problems with installation.

I run welcome.py and all is well. The last couple of lines of the program are:

Now, run the next tutorial with:

sudo ./outputs.py

This returns the message:

sudo: ./outputs.py: command not found

I’d be very grateful for any assistance you are able to offer.

Kind regards,

TankMan

I haven’t yet got 'round to producing outputs.py- which was going to be the next step in the tutorial. I decided to wait for some feedback on welcome.py, to see if the format ( which is a little unconventional to say the least ) would be useful to people before I went off and spent lots of time on it.

So… what did you think? :D

Hi gadgetoid,

welcome.py worked very well for me.

I am new to the world of linux / raspbian / electronics / Pi and am drawing on experiences from 30 years ago using an Apple II.

Please, please, please document the hardware and software fully for us newbies.

Kind regards,

TankMan

Hi everybody. I took delivery of an Explorer Hat Pro yesterday and installed it on a Pi 2 running a fresh install of the latest Wheezy (3.18).
I enabled I2C during the initial config and I’ve since installed python-smbus, python-pip and the Explorer hat library.
I tried the simple things like lighting the LEDs or detecting a press on a touchpad, but running welcome.py from the tutorial folder of GitHub - pimoroni/explorer-hat: Python library for Explorer HAT I get the following errors:-


Output of Welcome.py

Hi! Who are you?

[32mandy
[39m
Welcome to Explorer HAT [34mandy [39m…
Inthisintroduction,we’llshowyouthebasics. [39m
[39m
You’ll learn how to turn alight on and off, [39m
and how to use a fancy pulse effect too! [39m

Press to continue…
Trace back (most recent call last):
File “/home/pi/explorer-hat-master/tutorial/welcome.py”, line 215, in
msg()
File “/home/pi/explorer-hat-master/tutorial/welcome.py”, line 127, in
lambda:waitforspace(),
File" /home/pi/explorer-hat-master/tutorial/welcome.py", line 104, in waitforspace
waitfor(‘’,False,0.1)
File “/home/pi/explorer-hat-master/tutorial/welcome.py”, line 96, in waitfor
whilekeypress()!=char:
File “/home/pi/explorer-hat-master/tutorial/welcome.py”, line 49, in keypress
returngetch()
File “/home/pi/explorer-hat-master/tutorial/welcome.py”, line 23, in getch
fd = sys.stdin.fileno()
AttributeError: fileno

Thanks for any advice!

Andrew

Summoning @gadgetoid!

This looks like it’s a problem with running the welcome script in IDLE, rather than anything wrong with your Explorer HAT install, have you tried running any of the examples?

How are you running welcome.py? A quick google says that running it in IDLE probably wont work since IDLE doesn’t provide an “stdin” ( console input ) to the Python script. It produces this exact error.

Try starting LXTerminal, and typing sudo python /home/pi/explorer-hat-master/tutorial/welcome.py

Sorry for not getting back for soooo long!

Only just got round to experimenting with the EHP today having just upgraded to Jessie (which seems very fast!). I simply followed the setup instructions in the Readme.md file and all is now working. I ran the welcome.py from the LXTerminal as advised and it worked a treat :-)

So thanks to Gadgetoid. I’ll work my way through the docs and see what else I can do with this HAT.

Cheers,

Andrew