Relays for dummies

It saves you a lot of time and has many additional features. I like it!

How would your solution communicate with node-RED? there is no WiFi in the garage, and the garage is 35mts from the house, as described in post #1.

I would try to put a wifi repeater at the most nearest point to the garage. You could ckeck it with your mobile phone if the signal is strong enough.

Alternatively you could put the relay into your house and from there a cable to the motor.

Hi Andrei (@iungo),
Would be nice if you could edit your post, and add some links to the sites that offer those devices. Thanks!

Hey Johannes (@juntiedt),
Thanks, that could indeed be a solution for other people. But like Paul already mentioned, I don't have wifi in the garage. Moreover I have already installed a cat6 cable, because I like to keep the wireless connections to a minimum. You can call me the 'cable guy' :wink:

1 Like

Dear Bart,

It's my own project. Unfortunately, it's not fully completed(I need to do some additional tests). I think I will finish it before September.

If you are interested, you can see progress and some information here.

1 Like

Hey David (@dynamicdave),
Probably the most stupid question on this forum today, but what do I need to do with the 3 grounded wires on the other side of the cable?

  • Just leave them unconnected
  • Connect them together like on the other side (see cable drawing)
  • Connect them all to a ground pin of my Raspberry?
  • Anything else?

I assume I might create such a ground-loop by doing it wrong...
Bart

Hi Bart,
I would just ground all three wires at ONE end of the cable.
It looks like you are powering the optocoupler from the RPi, so that might be the most convenient end to find a good ground pin.

1 Like

Hi folks,

My hardware has arrived from Ali, so wife "advised" me kindly to get started with it :wink:
But I'm abit afraid of damaging my (rather expensive) garage door opener PCB, so would like to be very sure that I don't make any mistakes ...

Too me it looks like the pin 5 and pin 1 are directly connected (via the diodes), so which means a short-circuit. But probably there is something wrong in my thinking ...

So question is do I need to put something in between (like resistor ...)?
@Paul-Reed has been so kind yesterday to visualize my question:

image

Anybody has any advise ?

1 Like

Do you measure a voltage between PIN1 and PIN5?

Which optocouplers do you use?

How does your door controller activate? By short PIN10 with PIN1 or something else?

Hey Andrei (@iungo),
The drawings from Paul and the links to both optocoupler types are above in this post. I need to measure of voltage of 23,4 V on pin 5 and 6 of my garage door openers. By combining both measurements in my Node-RED flow, I should be able to determine the current status of the door (see curve in this post).
Bart

You do not need 220R resistor.

At first, try to test modules. For MRI-3.3D48:

Disconnect power from your raspberry.

Please, use good convenient connector wires. Don't short 3.3v raspberry pin with 5V, or you will destroy your raspberry!!!

  1. Connect red wire to the A1 terminal and black wire to the A2 terminal.
  2. Connect the black wire to your raspi gnd pin(PIN6).
  3. Connect the red wire to your raspi 3.3v pin(PIN1).
  4. Connect power to your raspberry. The led on MRI-3.3D48 must light on.
  5. Connect the yellow wire between the MRI-3.3D48 (+) terminal and raspberry pi 5v (PIN2)
  6. Measure voltage between (PIN6 raspberry) and terminal A MRI-3.3D48, when led I on you will see 5V on the multimeter, after disconnecting the wire from A1 terminal, the multimeter must show 0V.
    (if you don't have a multimeter, use led and 1k resistor instead)

I think you DON'T need the pulldown resistor (0 terminal) at your project. I think your door controller has pulldown inside.

In addition, I can't figure out how your door controller work, because don't have any user manual for it, therefore don't know door controller pinout and pins control voltage.

For MRI-24D4:

Just connect door controller PIN5 to A1 MRI-24D4and door controller PIN1 to A2 MRI-24D4.

When the door open/close you must see led light on/off

This connection is absolutely safe if the voltage between PIN1 and PIN5 < 30V

If it work, connect + terminal MRI-24D4 to raspberry pi 3v3 (PIN1) and A terminal to raspi GPIO (input)pin, configure your GPIO input as pull-down .

Enjoy)

@iungo - Andrey, having read your earlier post and visited www.ioton.ru I can see that you have experience in hardware development, so thanks for commenting.

I can see in your first post above that you have described a way to test the function of the MRI-3.3D48 without attaching it to the door controller, by using the Raspberry Pi 3.3V & 5V power lines.

Is your opinion that the MRI-24D48 has an internal series resistor or other current limiting circuitry, so that the internal LEDs are not damaged when +24V is applied to A1?

Paul

As I can see on in the description on Ali for MRI-24D48:

Disclaimer: I didn't developed this device, therefore I can trust only datasheet on Ali, which says

Input Voltage 24VDC +/-20% (description from ali)

So, max input voltage is: 24 + 24/10020 = 24V+4.8V = 28.8V .

I have simple understaning how the optocouplers works, typically, optocouplers led has max current around 10-20ma, but I see only 7ma in the description.
Input Current 7mA (description from ali)

So, I think this optocoupler it will work from 9V to 36 VDC w/o any problems.

Yes, IOTON is my project, you can also look:




It's all mine)

2 Likes

Evening Andrei (@iungo),
Really appreciate you spending time on my little project ...

About these 6 steps to test the MRI-3.3D48. Is it just to test whether the optocoupler is working correctly, or can I deduce extra information from this test?

So do I understand correctly that both drawings from Paul shoud be correct, without need for extra components?

That is so true ...
On page 15 of the manual there is some description of the 10-pins connector. Not sure if that gives you extra information ...

I'm impressed!

Now you've posted the schematic for the door controller, the ground for the door status indicator should be PIN2 and not PIN1.

I wish you had posted this earlier, because I'm now wondering if the electrical path through the opto-isolator will replace the FCA/FCC microswitches and give a false indication if the door is open or closed. This will need to be tested.

pin2

scheme

---About these 6 steps to test the MRI-3.3D48. Is it just to test whether the optocoupler is working correctly, or can I deduce extra information from this test?---

I advised those steps because before connecting any device to the system it will be good to test it separately. I always did it for any new device, not because I'm dumb(I think), but because of my experience).

--So do I understand correctly that both drawings from Paul shoud be correct, without need for extra components?--

For MRI-24D48 it's not correct schematic.
For open signalization you need to connect A1 to PIN3(+24V), A2 to pin FCA(PIN5).
For close signalization you need to connect A1 to PIN3(+24V), A2 to pin FCC(PIN6).

For MRI-3.3D48:
I don't understand how your door work now. Please, explain what you are doing to open and close it. What buttons you are pressing for door opening and for closing and in which sequence.

Also, as I see in the manual by your link, the OPEN button grounding PIN10 of your door controller, but MRI-3.3D48 is a positive voltage interrupter. I think you will need an additional relay for your system.

Hi Bart,
glad to hear the parts have arrived. :+1:

What I understand from the schematic is that pin5 and pin 6 (J2 terminal) are used as opening/closing limit-switch contact,
depends of cams on the motor/gearbox shaft (Fig.11,part "D").

This doesnt mean that they cannot be used to detect the position of the door, according to the diagram from post # 9.

Qquestions:

  • are security devices connected (pin7/8)?
  • are pin5/6 connected to pin2 (jumper)?

For protection, I can see that there is an accessory fuse (500mA for max.load 300mA) so no additional fuse is needed.

Attach a series resistor to protect the Raspberry/Garage electronic.

For a GPIO on a Raspberry 390ohm (8,5mA @ 3.3V) or more, I really don't know what mean 7mA on the opto element (min, max, recommended, ...).

On the garage side, again,from the "datasheet" (opto element input working voltage = 19-28V), so if put 470ohm / 510ohm,
the opto element should have enough current / voltage, while in the case of a breakdown (short circuit) the current would be limited to some 50mA .

It's the current on nominal input voltage, (3.3v) I think.

It's not necessary, but not a bad idea. Yes, it will work with 470ohm resistor. The voltage on the input will be 21.1v and consumed current 6.15ma. I think it will work stable.

@Paul-Reed: Sorry for that! Wasn't aware that it was so important ...

This is not good for my self esteem :wink:
Ok, I have reopened the case and this is how the electrician has wired it:

image

On the top left you see a grey cable with a blue and brown wire, which go to the manual switch that I use currently to open/close the garage door manually. The blue wire is connected to pin 1 and the brown wire to pin 2. Don't know where the other (thinner) cables are used for: I was only interested in the manual switch, since I wanted to have a relay switch in parallel with it ...

:joy: Your devices prove that you are not dumb, so I will surely run your tests !!!

@iungo: I have only one push button for each garage door: the button returns to its default position immediately when I release it, so it generates a pulse. I press it once to open the door. Some time afterwards I press it once again to close the door. So 1 pulse to open the door and another pulse to close the door (like in the above diagrams).

@markost: Ali still doesn't deliver the next day :wink:

There is only the garage door opener, that is located in the middle of the door. But there are no external sensors. It is just the opener. But it detects somehow (internal sensors?) that the door is entirely open/closed or when an object is blocking the movement (for safety).

Will need to check that tommorrow ...

Ok good to know !

Can I conclude that opening/closing of the door could be measured like this:

image

Have told my wife that I have mobilized half of the planet for my garage project :roll_eyes: