Menticol
Active Member
Hello guys
I'm trying to decode the different patterns of a standard TV remote control on my computer. I know that these USB remote control gadgets are already sold on the market, I'm working on this project just for the sake of knowledge.
Given that I have zero experience with micro controllers I worked with what I had in hand. I scrapped an IR receiver module from a stereo, connected it to a 2N3906 transistor and then to a Optocoupler. The optocoupler then bypasses one of the switches on a USB joystick, and the computer reads the input every time the remote control is pressed.

The circuit somehow works, as reported by the software included with windows.

Now I'm in the quest of decoding different remote control buttons, and for that I'm making a small Visual basic 6 application. But I'm stuck in this point!
At first I had the impression that Visual Basic could not understand events happening faster than 1 millisecons. But the existence of this parallel port "oscilloscope" program proves that is not a limitation. (Off topic: I tested that very same oscilloscope trying to understand the IR signal but it didn't worked)

My question is, can the joystick button interface provide the required response speed? Do you know about a piece of code that can understand these pulse sequences?
If it can't, it's possible to use some kind of buffer to slow down the signal and make it more intelligible to my software?
Or is better to throw away the idea and start from scratch?
Thank you
PS: The reason because I've used an optocoupler was because I couldn't figure out the joystick circuitry's logic. There are 8 buttons in total, and each button have two leads: lead "A" (apparently) carries +5 and the lead "B" goes to the microcontroller. Oh, simple! shorting lead B to +Vcc would simulate that the button was pressed. But I got nothing, each button would only work exclusively with its corespondent lead.
I'm trying to decode the different patterns of a standard TV remote control on my computer. I know that these USB remote control gadgets are already sold on the market, I'm working on this project just for the sake of knowledge.
Given that I have zero experience with micro controllers I worked with what I had in hand. I scrapped an IR receiver module from a stereo, connected it to a 2N3906 transistor and then to a Optocoupler. The optocoupler then bypasses one of the switches on a USB joystick, and the computer reads the input every time the remote control is pressed.



The circuit somehow works, as reported by the software included with windows.

Now I'm in the quest of decoding different remote control buttons, and for that I'm making a small Visual basic 6 application. But I'm stuck in this point!
At first I had the impression that Visual Basic could not understand events happening faster than 1 millisecons. But the existence of this parallel port "oscilloscope" program proves that is not a limitation. (Off topic: I tested that very same oscilloscope trying to understand the IR signal but it didn't worked)

My question is, can the joystick button interface provide the required response speed? Do you know about a piece of code that can understand these pulse sequences?
If it can't, it's possible to use some kind of buffer to slow down the signal and make it more intelligible to my software?
Or is better to throw away the idea and start from scratch?
Thank you
PS: The reason because I've used an optocoupler was because I couldn't figure out the joystick circuitry's logic. There are 8 buttons in total, and each button have two leads: lead "A" (apparently) carries +5 and the lead "B" goes to the microcontroller. Oh, simple! shorting lead B to +Vcc would simulate that the button was pressed. But I got nothing, each button would only work exclusively with its corespondent lead.