Just one thing I want to point out to everyone, was that point of this experiment was to see an electrical singal get converted into light, transmitted and then turned back into an electrical signal by means of a mosfet.
The experiment was successful I was able to control a relay through low frequency PWM (about 10hz anything higher made it hum) which would also cause a small motor to switch on with the relay clicks. It also raised some other questions, like the one being asked in OP.
@ alexan_e
I can't provide a schematic at the moment but to describe it like so might bring clarity.
I have the pot in series with a multimeter mearsuring current (I screwed up when I said resistance) which then runs into relay's coil.
When the relay's coil pulls in or I hear the click, then current drops. (Just one point, I'm just testing the relays coil, nothing is at the terminals.)
One thing I want to know is what is driving the relay's coil? Is it the voltage? or is it the Current? I'm thinking it's current because the greater the curren,t the stronger the electromagnetic becomes.
@ asimkumar
The mosfet is driving it as planned, I've connected the frequency generator directly to the gate to see if that was the problem. The only thing I've done when using the sensing diode (it looks like an led but emitts no light and is clear) is I have a pot to bais the gate to ground which allows me to adjust it's sensivity to the IR led connected to the frequency gen. (of course I have to hold the IR led relatively close because I don't have a focusing lens fixed to the sense diode)
However one thing to consider, is that it only works when I am using a 9 volt battery. When I use a wall wort that should give me half an amp of current (rated as half an amp) running through a 7805 to bring it down to 5 volts, it seems as if I lose all my current through the regulating process.