EmbDev.net

Forum: µC & Digital Electronics Solid State Relay and PCF8574


Author: Michael_mhr (Guest)
Posted on:

Rate this post
0 useful
not useful
Hi all,

I've a Rasperry Pi that is connected to an 8-Bit IO-expander (PCF8574) 
over I2C. The IO-expander should control a Solid State Relay Board from 
SainSmart. The name of the Relays is "Omron G3MB-202P".

But when I connect the Relayboard to the IO-expander (pins configured 
correctly as output) the pins will change to HIGH in the console and are 
not controllable anymore until I disconnect the RelayBoard from the 
IO-exapnder.

The setup works for me, when I connect a normal Relay board (like the 
Board from SunFounder that is made for Arduino) to the IO-expander.

Thanks in advance,
Michael Mayerhofer

Author: Lothar Miller (lkmiller) (Moderator)
Posted on:

Rate this post
0 useful
not useful
Michael_mhr wrote:
> But when I connect the Relayboard to the IO-expander
Show a schematic of the complete wiring including the supply/supplies.

Author: Michael_mhr (Guest)
Posted on:

Rate this post
0 useful
not useful
There is no special wiring.

I have a breakout board from Waveshare with the PCF8574 on it that is 
directly connected to the relay board from Sainsmart. The RelayBoard 
Power-in is wired to the RaspberryPi 5V.

The Power supply and I2C of the breakout board is also directly 
connected to the RaspberryPi.

As I wrote above, this setup works perfectly with a normal RelayBoard.

Michael_mhr

Author: Lothar Miller (lkmiller) (Moderator)
Posted on:

Rate this post
0 useful
not useful
Michael_mhr wrote:
> As I wrote above, this setup works perfectly with a normal RelayBoard.
Anyway: electricians talk to other electricians by using schematics. So 
just draw 2 schematics. One of the working configuration and one of the 
faulty. Add as much information to those schematics. It will help you 
further on...

> I have a breakout board from Waveshare with the PCF8574 on it that is
> directly connected to the relay board from Sainsmart.
Add information and/or a link to those boards also. There is more than 1 
relay board availabe from sainsamrt. No one of those relay boards can be 
directly connected to the IO expander. There must be done some wiring. 
Maybe you can post a photo of that.

Author: Svenska (Guest)
Posted on:

Rate this post
0 useful
not useful
Michael_mhr wrote:
> But when I connect the Relayboard to the IO-expander (pins configured
> correctly as output) the pins will change to HIGH in the console

You can't configure a PCF8574 pin as output (there is no direction 
register). Reading the data register just returns the pin state.

If you set the pin to LOW,  the chip will strongly pull down the line.
If you set the pin to HIGH, the chip will weakly   pull up   the line.

So if you output a LOW and you see a HIGH, then something is driving 
against the PCF8574, and is stronger than that chip. This might already 
have killed the PCF8574. Check your wiring for shorts.

Reply

Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]




Bild automatisch verkleinern, falls nötig