colinmower
Posts: 12
Joined: Thu Aug 14, 2014 8:38 pm

Piggy back on Sense HAT

Tue Jan 19, 2016 10:54 am

Hi,

I want to connect my Sense HAT to my Pi zero, but also add an IR controller. I thought from the pictures of Sense HAT that it already had passthrough GPIO pins, but when I received it I found that it doesn't unfortunately.

I'm not sure how I can do this - there is a Black HAT by Pimoroni which seems to breakout the GPIO onto another board with two sets of GPIO, but is this a sledgehammer to crack a nut? I don't really want all the extra boards and connectors if I can help it.

Any help or advice much appreciated!

Thanks

BMS Doug
Posts: 3824
Joined: Thu Mar 27, 2014 2:42 pm
Location: London, UK

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 11:07 am

colinmower wrote:Hi,

I want to connect my Sense HAT to my Pi zero, but also add an IR controller. I thought from the pictures of Sense HAT that it already had passthrough GPIO pins, but when I received it I found that it doesn't unfortunately.

I'm not sure how I can do this - there is a Black HAT by Pimoroni which seems to breakout the GPIO onto another board with two sets of GPIO, but is this a sledgehammer to crack a nut? I don't really want all the extra boards and connectors if I can help it.

Any help or advice much appreciated!

Thanks
Hi Colin,

There is a technique called "wire wrap" in which you wind bare strands of cable around the GPIO pin, you could do this on your desired pins and then push the HAT on top. Be careful that the HAT doesn't cause the wirewrap to make undesired contact anywhere else.
Doug.
Building Management Systems Engineer.

PiGraham
Posts: 3881
Joined: Fri Jun 07, 2013 12:37 pm
Location: Waterlooville

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 11:23 am

I haven't seen a sense HAT in person, but from photos it looks like it has a top-side gpio connector.

Image

Photos here https://shop.pimoroni.com/products/rasp ... -sense-hat

Video here https://www.adafruit.com/products/2738

Can you insert header pins into the top side header?
How about the male end of this sort of jumper wire?

Image

LeoWhite
Posts: 131
Joined: Mon Apr 08, 2013 9:20 am
Contact: Website

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 12:58 pm

Hi,
colinmower wrote: I want to connect my Sense HAT to my Pi zero, but also add an IR controller. I thought from the pictures of Sense HAT that it already had passthrough GPIO pins, but when I received it I found that it doesn't unfortunately.
The Sense HAT has a surface mounted GPIO header on it, with an 'extension header' already attached (See the bottom of the HAT release blog for an example). The header that is already attached to the Sense HAT can be removed (Remove it from the underside, its quite a tight fit and can be a struggle to get off first time) and then replaced with a GPIO header with extra tall pins so they stick out through the top.

You can then use jumpers to connect other components as required (such as the IR controller) as long as you don't clash with the GPIO pins that the Sense HAT itself uses.
colinmower wrote: I'm not sure how I can do this - there is a Black HAT by Pimoroni which seems to breakout the GPIO onto another board with two sets of GPIO, but is this a sledgehammer to crack a nut? I don't really want all the extra boards and connectors if I can help it.
You can use a Black HAT to achieve this, but obviously that's a bit bulky and more suited for testing on a desk, as opposed to use in a final product.

I've used a Adafruit Perma-Proto HAT (with extended GPIO headers) and then put the Sense HAT on top of that when I've needed multiple things connected. Otherwise I just use the jumper wire method mentioned earlier.

Leo

colinmower
Posts: 12
Joined: Thu Aug 14, 2014 8:38 pm

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 1:22 pm

Hi all

Many thanks for the replies, much appreciated.

Leo - I was hoping that I may be able to remove the header but I dared not try and prize it off, but that's fantastic news and solves the problem (but like you say I could get a clash if I try and use both together...that'll be a pain).

Do you know if I can just remove the top header (see photo) to expose the pins and sit my IR receiver onto those, or does the top and bottom header have to come off together leaving no pins, and therefore as you say I would need extra long ones in the zero to push through the HAT and the IR controller.

Thanks
Colin
IMG_3999.JPG
IMG_3999.JPG (34 KiB) Viewed 5450 times

LeoWhite
Posts: 131
Joined: Mon Apr 08, 2013 9:20 am
Contact: Website

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 1:35 pm

colinmower wrote: Many thanks for the replies, much appreciated.

Leo - I was hoping that I may be able to remove the header but I dared not try and prize it off, but that's fantastic news and solves the problem (but like you say I could get a clash if I try and use both together...that'll be a pain).

Do you know if I can just remove the top header (see photo) to expose the pins and sit my IR receiver onto those, or does the top and bottom header have to come off together leaving no pins, and therefore as you say I would need extra long ones in the zero to push through the HAT and the IR controller.
The top header is soldered to the PCB, so can't be removed (at least not without breaking the board!). Its the bottom header you need to remove and replace with a header with longer pins.

You can see it being removed on Episode 001 of the Pimoroni Bilge Tank series (Sense Hat section at the 44:20 mark)

Leo

colinmower
Posts: 12
Joined: Thu Aug 14, 2014 8:38 pm

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 1:41 pm

Got it, understood - I see now how it's been put together - the top header was confusing me as it looked like it should come off. Glad I didn't try!
The video is perfect, thanks for pointing that out.

Cheers!

LeoWhite
Posts: 131
Joined: Mon Apr 08, 2013 9:20 am
Contact: Website

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 1:48 pm

colinmower wrote:Got it, understood - I see now how it's been put together - the top header was confusing me as it looked like it should come off. Glad I didn't try!
It took me a little while to work it out too. Especially as the header was stiff enough that I thought it wasn't meant to come out!
colinmower wrote: The video is perfect, thanks for pointing that out.
its always nice to have a visual example with this sort of thing!

Happy to have helped.

Leo

alphanumeric
Posts: 2472
Joined: Tue Jan 19, 2016 2:17 pm
Location: Sydney, Nova Scotia, Canada

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 7:08 pm

I have a Pi 2B with a sense hat attached. I plan on adding a Real Time Clock module. And maybe a few other odds and ends. What I am going to do is take one of these, https://www.adafruit.com/products/2310 and solder this to it, https://www.adafruit.com/products/2223 instead of the header that comes with it. I will then solder my RTC breakout board to the proto board and wire it up on the proto board. The proto board will then plug in between the Pi and the sense hat. That's the plan anyway. I'm just waiting for my order to be delivered.

colinmower
Posts: 12
Joined: Thu Aug 14, 2014 8:38 pm

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 7:47 pm

Sounds good - would be interested to see how you get on...can you post pics after you've done it?
I've just ordered a set of longer pins to push through the Sense and (hopefully) up into the IR module. Will also post a pic if it works!
My zero is then going to be a environmental monitor to switch on/off devices - just starting with a dehumidifier - in one of our rooms that suffers from damp.
I did something similar with a B+ and a RTC with built in temp module to switch on/off an electric radiator and it works a treat! Much more efficient than leaving the radiator on all the time and just using the radiator's built in temperature control.

alphanumeric
Posts: 2472
Joined: Tue Jan 19, 2016 2:17 pm
Location: Sydney, Nova Scotia, Canada

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 8:32 pm

My sense hat is going to be a weather clock. I already have it all setup to show the date, time, temp, humidity and barometric pressure in a scrolling message on the led matrix. The date and time are out of whack on first boot up though until it syncs with the Internet. That's why I want to add a RTC. Plus I need some spacing between the Pi and the sense hat. The heat from the Pi's CPU is messing up the temp sensor. It's all headless, no mouse keyboard or monitor. I can shut down with the joystick. The final version won't have internet access. Right now it does so I can remote desktop in and play with my python code if need be. I'll post picks, assuming I remember to take some. ;)

colinmower
Posts: 12
Joined: Thu Aug 14, 2014 8:38 pm

Re: Piggy back on Sense HAT

Tue Jan 19, 2016 9:33 pm

Nice! I'm also planning to be completely headless and not connected to my network, and use the Matrix to display similar info....sounds excellent.

I've had the same problem with erroneous temp readings on the B+ and RTC/Temp sensor. It permanently over-reads by about 6 degrees, so I had to offset this in my Python code which was a bit annoying, but as I'm just using it as a thermostat and not a accurate temp gauge then it didn't really matter.

LeoWhite
Posts: 131
Joined: Mon Apr 08, 2013 9:20 am
Contact: Website

Re: Piggy back on Sense HAT

Wed Jan 20, 2016 7:58 am

alphanumeric wrote:I have a Pi 2B with a sense hat attached. I plan on adding a Real Time Clock module. And maybe a few other odds and ends. What I am going to do is take one of these, https://www.adafruit.com/products/2310 and solder this to it, https://www.adafruit.com/products/2223 instead of the header that comes with it. I will then solder my RTC breakout board to the proto board and wire it up on the proto board. The proto board will then plug in between the Pi and the sense hat. .
That's pretty much what I did, with the proto board looking like the attached.
ProtoPiHat2.jpg
Proto Pi Hat with long pins
ProtoPiHat2.jpg (61.42 KiB) Viewed 5152 times
ProtoPiHatWithSenseHAT.jpg
Proto Pi Hat With SenseHAT
ProtoPiHatWithSenseHAT.jpg (48.46 KiB) Viewed 5152 times
As I needed to leave space for the components (and didn't need the extra pins) I used the normal header on the Sense HAT so the long pins don't stick through the top.

Leo

alphanumeric
Posts: 2472
Joined: Tue Jan 19, 2016 2:17 pm
Location: Sydney, Nova Scotia, Canada

Re: Piggy back on Sense HAT

Wed Jan 20, 2016 11:07 am

Yeah, I wanted something stackable, and the same size as the sense hat. With the mounting holes in the same position. I have a Pi A+ in the order too that I plan to use for this project. I already have the RTC hooked up and running on my bread boarding Pi setup. My order just went through Canada Customs yesterday. I'm not likely to get it until early next week. It crossed the boarder from New York. It was all ordered from Adafruit. I picked the slowest cheapest shipping option to save a few bucks.

RichardatWillow
Posts: 25
Joined: Fri Jan 08, 2016 8:33 am

Re: Piggy back on Sense HAT

Wed Jan 20, 2016 2:25 pm

Hi

If you have space in terms of area, have a look at our FLAT Pi. You can fit a Pi plus 3 other boards without stacking.

Image

regards
Richard
http://www.willowcomponents.co.uk

alphanumeric
Posts: 2472
Joined: Tue Jan 19, 2016 2:17 pm
Location: Sydney, Nova Scotia, Canada

Re: Piggy back on Sense HAT

Sun Jan 24, 2016 4:55 pm

I mounted my sense hat on a Black hat mini kit, https://www.adafruit.com/products/2339 temps now read normal ambient. Having issues with my RTC though. Works then it doesn't work. Not sure what's going on. It's syncing the time with the Pi but it doesn't always keep an accurate time when the Pi is off. I have it hooked up to the Black hat mini kit's extra row of GPIO pins with jumper wires. I checked the battery and it reads OK on my battery tester. If I leave the Pi power pack plugged in, it keeps an accurate time, unplug it and it doesn't. Looks like I have a dud RTC or the battery is no good even though it checks OK? Will have to do more testing. The RTC is past its return date. I bought it back in early December. Will post more info when I get further along.

alphanumeric
Posts: 2472
Joined: Tue Jan 19, 2016 2:17 pm
Location: Sydney, Nova Scotia, Canada

Re: Piggy back on Sense HAT

Mon Jan 25, 2016 2:25 pm

Plugged everything together, minus the RTC for now. Temps are reading ambient as far as I can tell. Its staying steady at 23c. Here is a link to some pictures, https://onedrive.live.com/redir?resid=6 ... lder%2cjpg They were too big to upload here. If I make them small enough you can't see much. It's a link to my public Onedrive folder. I'm not sure if it expires after a certain time or not? I added a video of it in operation too.

Return to “HATs and other add-ons”