meddyliol
Posts: 118
Joined: Thu Mar 20, 2014 8:28 am
Location: South Wales

Relay board

Tue Apr 29, 2014 9:52 am

I am thinking about getting one of these from ebay: http://www.ebay.co.uk/itm/New-5V-8-Chan ... 8254400%26

It seems to be a good buy but will the Pi be able to switch the relays as they need 5V? I seem to remember reading that the Pi will only supply 3.3V.

Cheers

Brian
Raspberry Pi B, Raspberry Pi 2, monitor, powered hub, mouse, keyboard and Volvo V50 car

User avatar
joan
Posts: 14936
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Relay board

Tue Apr 29, 2014 10:11 am

The board needs 5V to energise the relay coils. You can supply that from the Pi's 5V rail.

Usually the logic circuitry can work at a lower level. See if you can find a listing which mentions compatibility with a 3V3 micro. I bought one which mentioned MSP (a 3V3 micro). I'm not sure if any of the micros mentioned in that listing are definitely 3V3.

If you can't find one just buy the one you list. If you are lucky it will just work, if not you'll need to spend another couple of quid on additional components.

My board https://www.youtube.com/watch?v=RDrZDYGRj90

meddyliol
Posts: 118
Joined: Thu Mar 20, 2014 8:28 am
Location: South Wales

Re: Relay board

Tue Apr 29, 2014 10:16 am

Thank you for that. You say you bought one that works on 3.3V. Could you give me a link to that one?

Thanks

Brian
Raspberry Pi B, Raspberry Pi 2, monitor, powered hub, mouse, keyboard and Volvo V50 car

User avatar
GTR2Fan
Posts: 1601
Joined: Sun Feb 23, 2014 9:20 pm
Location: South East UK

Re: Relay board

Tue Apr 29, 2014 10:17 am

The total energising current to switch all 8 relays could be up to 160mA according to the specs. Your Pi might not be happy supplying this amount of current from the 5V pin on the GPIO port if you're powering anything off the USB ports at the same time.
Pi2B Mini-PC/Media Centre: ARM=1GHz (+3), Core=500MHz, v3d=500MHz, h264=333MHz, RAM=DDR2-1200 (+6/+4/+4+schmoo). Sandisk Ultra HC-I 32GB microSD card on '50=100' OCed slot (42MB/s read) running Raspbian/KODI16, Seagate 3.5" 1.5TB HDD mass storage.

User avatar
joan
Posts: 14936
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Relay board

Tue Apr 29, 2014 10:23 am

I bought from http://www.ebay.co.uk/itm/400514325341

Caution: The 8ch relay I received was not identical to the photo. Mine has different silk screening without the Keyes logo.

User avatar
joan
Posts: 14936
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Relay board

Tue Apr 29, 2014 10:28 am

GTR2Fan wrote:The total energising current to switch all 8 relays could be up to 160mA according to the specs. Your Pi might not be happy supplying this amount of current from the 5V pin on the GPIO port if you're powering anything off the USB ports at the same time.
Good point.

The one I bought takes 70mA to energise a coil. If I try to switch them all on the Pi crashes.

http://www.raspberrypi.org/forums/viewt ... 59#p394659

meddyliol
Posts: 118
Joined: Thu Mar 20, 2014 8:28 am
Location: South Wales

Re: Relay board

Tue Apr 29, 2014 10:34 am

Thanks to the both of you for valuable advise. I will get one of those relay boards but build a buffer circuit at the 3v3 outputs.
Raspberry Pi B, Raspberry Pi 2, monitor, powered hub, mouse, keyboard and Volvo V50 car

Tarcas
Posts: 741
Joined: Thu Jan 09, 2014 5:38 am
Location: USA

Re: Relay board

Tue Apr 29, 2014 3:16 pm

meddyliol wrote:Thanks to the both of you for valuable advise. I will get one of those relay boards but build a buffer circuit at the 3v3 outputs.
No need for the buffer circuit. Just wire the VCC to 3.3 and JD-VCC to 5v.

This video explains more.

Return to “Beginners”