PDA

View Full Version : TV bGONE on the prop?



Oldbitcollector (Jeff)
12-29-2009, 07:50 AM
Has anyone done a conversion for TV bGone using a Propeller yet?

OBC

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
New to the Propeller?

Visit the: The Propeller Pages (http://www.warrantyvoid.us/tiki-index.php?page=Propeller) @ Warranty Void.

JonnyMac
12-29-2009, 07:55 AM
I've had fun with SIRCS and controlling my TV/DVD player, but haven't explored any of the other protocols.

Little-endian
12-29-2009, 11:54 AM
I'd be interested in building one if a conversion is available.

MagIO2
01-11-2010, 02:18 AM
Any activities here?

I'm not working on a TV b gone as such, but I want to replace 5 IR remote controls plus some RF remote switches. What I currently have is a little program that allows to record an IR signal and store it on SD card for manual analysis.

First you give the filename (so different remote controls can be recorded) and then you enter the key you want to record and push the button on the IR.

Additionally it can search for a big gap and playback from beginning up to that gap. For playback one pin gives a 33kHz signal, another pin gives the signal. So, you only have to connect an IR LED to those pins - with a resistor of course.

Needs:
keyboard
TV
SD card
TSOP 33 for receiving
IR LED for sending

Anyone interested?

JonnyMac
01-11-2010, 02:23 AM
@MagIO2: Have you considered analysis and identification of the protocol on-the-fly? I'm not sure how one would approach this, but it could be kind of neat, and useful for that drawer full of remotes that I no longer have the instructions for! http://forums.parallax.com/images/smilies/tongue.gif

BTW, what's the file format for your manual analysis tool? I'd certainly be interested in experimenting with it, too.

Post Edited (JonnyMac) : 1/10/2010 7:30:11 PM GMT

Shawn Lowe
01-11-2010, 02:30 AM
Now I'm not saying I could do this (ROOKIE!) but I think you would have to build a generic IR anaylizer, maybe sample on off times and show them on a screen or maybe compare with timing/speed lists in memory and see if they compare? Of course with different modulation frequencies, that would make it harder. I don't even know if they make a generic IR receiver sensor. IR diode, maybe?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Shawn Lowe


When all else fails.....procrastinate!

MagIO2
01-11-2010, 02:53 AM
It's just plain bits ( "0" and "1" ) with 32 bits per line in a text-file that you can open with any editor. For example:
Filename: JVC.txt
power:
00000000000000000000000000000000
00000000000000111111111111111111
11100000000001111111111000000000
.....

I checked out some remote controls and the signals are very different. Some have alternating bits, some repeat the signal n times and then send a "repeat"-signal which is much easier. Some start the first signal with a long "0" .....
I know there must be some descriptions out there, but I'm not really interested in the protocols. I just want to replay whatever is there.

My next goal is to count the 0s and 1s (measure the time) and create a map of 0 times and 1 times - translating the raw signal in comparable strings or numbers. This way a later version can decide whether the signal of one key is altered or maybe sends a repeat signal after a while. I guess this would also give a fingerprint of the protocol.

Currently all my remote controls use the 33kHz modulation.

I'll post my current version later this evening.

Oldbitcollector (Jeff)
01-11-2010, 03:28 AM
I've got too many irons in the fire, but this might be useful..

OBC

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
New to the Propeller?

Visit the: The Propeller Pages (http://www.warrantyvoid.us/tiki-index.php?page=Propeller) @ Warranty Void.

MagIO2
01-11-2010, 03:55 AM
Here's my current code!

Please don't forget to change crystal frequency and pins.

How it works:

First it asks for the name of the file to store the recordings in (without extension). Then you need to give the key-name you want to record. For example "1", "2", "down", "power". You will find these as labels in the record-file later on. CR will end label input. Then the measurement COG waits until it sees the first 0 and start measurement. It always samples 256 longs = 8192 bits = 409.6 ms. If you want you can change the sample rate in the PASM variable ir_smpl_time.

This is 'work in progress' and coding-style is not state of the art ;o) Just added a few comments before posting.

Have fun!

MagIO2
01-12-2010, 04:48 AM
@oldbitcollector: thanks for the codes.

What I don't understand is that I use the TSOP 33 which removes a 33kHz "carrier" frequency and only gives the· pure signal. But even though I have a lot of different remote controls I can see the signals of ALL. Souldn't there be some running at 37kHz? I guess I need a pure IR receiver LED and watch what the carrier is.

Anyway ... I updated the code a bit ... now it's even more messy ;o) But it shows good results in doing some basic analysis and a translation. First I create a list of 1 and 0 timings allowing a little deviation. For example when a row of 1 is there having 10 1's, I create an entry in the table for that. Whenever I find 12-14 1's in a row again nothing is added to the table. Same for 0's
This gives a list of 1 and 0 timings which should be unique for a certain encoding - maybe together with the "packet" sizes.

( I have to say that this list is sorted ascending. ) In the next step the first sequence is translated to a easy to read (and later on to compare) code. Whenever a row of 1's is found which is close to the first 1 entry in the list of 1 timings I replace it with A. If a row of 1's is found close to the second entry it's replaced with B and so on. For the 0 bits I use lowercase letters. For example:
List of 0s:
20, 37
List of 1s:
16,34,1793
Signal is then translated to:
aAbAaAaAaAaAaAaAaAaAaAaBaC26
next push of the same button is translated to:
aAaAbAaAaAaAaAaAaAaAaAaBaC26

So, it's easy to find out that 2nd and 3rd low bits are used to find out whether the button has been pushed again or if it's held down.

I think in the next step I'll clean up the code a bit, before I do a complete translation of the 256 longs.

VIRAND
01-12-2010, 02:33 PM
My guess is that 33 KHz is lower than all IR remotes and it is being used like a Local Oscillator, as if the signal was Morse Code.
There is no need for accurate frequency, because it is modulated it will not just be exactly whatever it is supposed to be, and
I always thought the IR modulation frequency was always "supposed to be" 40 KHz for all remotes. I wouldn't be surprised if
no IR detector had a crystal, or in the case of 33KHz, it may be a common 32.768 watch crystal. Without a crystal, there can
be thermal or arbitrary frequency drift all around 40 KHz and nobody else in the room to cause or complain about interference.
The BANDWIDTH of the modulated signal must be greater than Morse Code, which is usually given a 0.5KHz channel bandpass
filter. If a 33 KHz filter had zero bandwidth and high gain, it would either receive it's own output, or pull a pure 33 KHz unmodulated
frequency out of the static, and both results are effectively identical since white noise by definition is a sum of all frequencies,
just as white light splits into a rainbow of all the pure colors.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
VIRAND, If you spent as much time SPINNING as you do Trolling the Forums,
you'd have tons of awesome code to post! (Note to self)

Toby Seckshund
01-12-2010, 07:05 PM
The carrier freq of remotes vary around the 35 - 40 KHz mark for most domestic kit, some others venture up to 60KHz (projectors etc). The IR receivers do a lot of work, first the case filters out unwanted light wavelenths, then the signal is amplified and quite tightly filtered for the carrier freq then it is squared up and outputed.

The codes are then varied for the make, model ....

The best way to get working codes for all kit would be to record real data burst from a real remote, that way both the carrier freq and bit patterns would be correct, but the file lenth would increase.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Style and grace : Nil point

MagIO2
01-12-2010, 10:23 PM
I just wondered because those TSOPs are available for a lot of frequencies. So, what's the sense of that if the bandwidth is covering all those frequencies anyway. And why do they define an exact frequency in the .c file that oldbitcollector posted? Are the receivers of the TV, DVD-player ... more accurate? Or can I even send it with 33kHz carrier and it will be recognized?

That was my first guess, when I replayed a recorded code of a digital picture frame and id did not respond. But it might also be the problem that I only send the first sequence whilst the original IR control just sends this sequence once and then sends a repeat sequence.

Toby Seckshund
01-12-2010, 11:44 PM
Some send the repeat sequence bit inverted as a "CRC". Some codes are resent as long as the button is pressed but with one bit toggling each time.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Style and grace : Nil point