Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Got an Idea but I need some thoughts on it

Status
Not open for further replies.

psecody

Member
Well I've gotten bck into electronics recently after not really messing with them in about 4 years and I've got a project going but I kinda want someone else to verify that my idea will work before I go hardcore building it. Now onto the project. I'm wanting to make an IR switch for my lights in my room, that being said my plan was I've got this IR Detector Module that I got in a grab bag at radioshack when they were selling off their inventory, its a GP1U52X Infarared Reciever/Demodulator its got 3 pins Vout, Vcc, and GND. would this work the same way as a transistor basically? my plan was to wire that (if it worked like a transistor where when it got ir signal it opened the way up) to a relay where the light switch is. Thebasic idea being the ir reciever completes the circuit when it recieves ir signal then activating the relay and flipping the switch. Can anyone verify that this ir reciever works like I am thinking? IR is confusing me but I'm trying to figure it out. Thanks for any replies and sorry you had to read all that.
 
The IR receiver's output is the demodulated IR signal with the carrier removed. These modules are really quiet useful, but it does not work like you think. The easiest way to use it as a switch as you're thinking about would be to create a transmitter that sent just a constant carrier signal (usually about 38khz but you'd have to check the specs for your module) then that output line would be high all the time, which you could use to drive a transistor to switch your relay. You could use the module with a PIC or AVR to add significantly more functionality past an on/off switch.
 
Last edited:
ok but minus the transmitter what would I need to add onto the recievers circuit to make this work? I don't quite get how the reciever module works with three leaad what is actually happening?
 
They're pretty simple. VCC is obviously power in, GND is obviously ground and "Out" is a logic output The module itself has circuitry which amplifies and demoduletes an IR carrier signal, most IR remotes work around 38khz or so. They have to modulate the light otherwise ambient sunlight or incandescant bulbs could cause your TV to turn on. You'd have to check the modules specs but it's likley just a transistor that connects the out line to VCC when it detects the carrier. It's not going to control a relay but it should be able to source enough current to trigger another transistor to drive your relay. Then when the IR carrier is detected it will turn the relay on and the relay will de-energize when the carrier is removed. This does NOT work like a normal remote control though, you'd have to send the carrier frequency all the time, TV style remotes only send small packets of data. A simple 555 timer could easily generate the carrier required, all you'd need is an IR LED
 
Last edited:
ok so is there anyway to wire this so that once the relay is activated it will stay in position until the ir reciever recieves another signal? because I don't want to have to keep sending it a constant signal to keep the lights on or off I just want to be able to send it a packet and activate it then another packet to stop it. By the way thanks Sceadwian for all the answers to all my stupid questions, I appreciate it.
 
You need encoders and decoders - basically you're looking at micro-controllers, either pre-programmed (try Holtek) or program them yourself - you can check my tutorials for doing just what you want!.
 
For simple on and off control, the IR receiver could trigger a flip-flop IC. Push the transmitter button and the light turns on. Push the button again and the light turns off. The flip-flop drives a transistor that drives the relay.

The IR receiver was made by Sharp and is 40kHz. Even they don't have a detailed datasheet for it anymore.
 
oh I have the datasheet for it still I jusat found it in my old electronics bin. Could you explain this flip flop IC, I've seen it mentioned but don't know anything about it. Sorry for all the ignorance but I never used IC's when I was into electronics way back when and am just now starting to experiment with them. Thanks for everything guys I really appreciate it.
 
I don't want to design a circuit for an obsolete IR receiver IC. RadioShack sells old crap. Like Maplin and Dick Smith.

There are some kits on the market and even some IR remote controlled light switch products. Some even dim the light.
 
yes but see I don't want to buy one pre made and I don't want anyone to design it for me I'm using this as a circuit to learn on. The only problems that I am having is that I'm not sure about IC's because I avoided them like the plague when I was into electronics back in the day because I saw them as hard to get in our little town. could you give me a number for the flip flop IC and I'll take it from there. With that IC I can avoid the microcontroller buying process because I don't feel that I'm ready to use them quite yet. Thanks
 
A CD4013 is a dual D flip-flop IC. It needs a positive-going clock input for its output to toggle, but your IR receiver's output might be negative-going so a transistor should be used as an inverter in between them.
Lookup how to power and how to connect a CD4013 D flip-flop in Google. You might even find a whole IR remote control circuit.
 
psecody said:
With that IC I can avoid the microcontroller buying process because I don't feel that I'm ready to use them quite yet. Thanks

It depends if you want it useable or not?, with a micro-controller you can turn the light on, you can turn if off - EXACTLY as I presume you want it to work. With the flip flop ANY remote control will turn it ON and OFF, possibly repeatedly? - and even incoming sunlight, or energy efficient lights, may trigger it.
 
I learned to program a micro controller before I even understood how a flipflop worked. You're never ready for them, you just have to dive in and go through the learning curve like anyone. They can be frustrating, but their main advantage of using them is the 'what else' factor. Once you're using a micro controller 'what else can I add' starts popping up everywhere and you'll never know why you tried to do it all with discrete logic before. You're liable to burn out your first few chips weather they're simple logic IC's or micro controllers, so just pic a nice cheap MCU and buy a half dozen of them.
 
psecody said:
could you give me a number for the flip flop IC and I'll take it from there. With that IC I can avoid the microcontroller buying process because I don't feel that I'm ready to use them quite yet. Thanks
Like Nigel mentioned, I would advise against the flip-flop because everytime you change channels on your TV, the lights would turn on/off. :rolleyes:
A microcontroller is the best choice for this project, with a PLL/tone detector a distant second.
 
A PIC or AVR will cost you less than 5 dollars, even for the high end ones. The cheapest AVR's and PIC's are under 50 cents per chip. Programmers are as simple as a few resistors/transistors hooked up to a parallel printer port home built. Or 20-50 dollars for an inexpensive development board.
 
Sceadwian said:
A PIC or AVR will cost you less than 5 dollars, even for the high end ones. The cheapest AVR's and PIC's are under 50 cents per chip. Programmers are as simple as a few resistors/transistors hooked up to a parallel printer port home built. Or 20-50 dollars for an inexpensive development board.

The Holtek encoder/decoder chips I mentioned earlier are even cheaper than PIC's, and don't require programming - right part for the right job!.
 
ok well I got the circuit part way done, that is I can turn the light on by remote but I can't figure out how to wire the 4013 IC to "loop" so that it keeps the relay on or off. Can anyone give me some hints or describe how I should go about using that? Thanks
 
True enough Nigel, especially for price =) But it's just so fun to say 'use an MCU' all the time =) And given what they can do nowadays, there's very little that can't be helped by using them, especially for the development of an idea. If you start out on good footing with an MCU, future 'branching' into other realms is easier and less costly. They really are 'what if' devices. The can do the simplest things easily, and are programming wise limited almost only by the programmers innovativeness and knowledge to obtain results. A big hunk of digital logic like an MCU and a little bit of analog or digital ingenuity will get you a lot farther than knowing the right part to use in every single macroscopic situation. The only thing better than an MCU is an FPGA, but those things are like digital magic, programmable hardware =)
 
If the output of your IR receiver goes low when it receives IR like newer ones, and if it has the same power supply voltage as the CD4013 flip-flop IC, then this circuit might work:
 

Attachments

  • 4013 Flip-flop.PNG
    4013 Flip-flop.PNG
    25.2 KB · Views: 307
Thank you audioguru this is exactly what I needed. I was trying to figure out how to wire one by looking at several schematics for IR switches but I couldn't really figure out the 4013 wireing for all the other stuff that I didn't care about. Thanks. I'm planning to redo this circuit when I have some microcontrollers and a programmer but I haven't had time to order one since today was payday I will get on that though but I just wanted to build this circuit with IC's and discreet components because thats what I have at my immediate disposal. I don't have the convenience of having a local place to get electronics, sure we have a radioshack but thats basically a glorified cell phone store that happens to have a few LED's. So I'm having to get everything through mail order. But I should have a STK500 in the mail to me by monday. Thanks for everything
 
Status
Not open for further replies.

Latest threads

Back
Top