View Single Post
Copernicus's Avatar
Posts: 1,986 | Thanked: 7,698 times | Joined on Dec 2010 @ Dayton, Ohio
#562
Originally Posted by Estel View Post
BTW, as mentioned program is quite old, also doesn't use LIRC, and probably could use some new disable/standby codes - Copernicus, what do You think about updating that one too? It seems, that it's code is quite simple, and for someone already experienced in developing Ir application, updating code database *should* be trivial, as it seems.
Fascinating! I've just pulled down the tvbgone code (which is a nice little python script), and yeah, it doesn't use LIRC. Very nice. Their set of codes is very simple, and consists of entries like this:

Code:
      # code EU 0
      [ 35714, "510040000000000031026100400000000000310",
        [(430, 470), (430, 910), (430, 83240), (880, 470), (1330, 1330), (2640, 900), (2640, 910)]],
      # code EU 1
      [ 30303, "011111111143261111115326111111",
        [(470, 2650), (510, 540), (510, 1080), (510, 2630), (510, 20530), (510, 116470), (1000, 1090)]],
      # code EU 2
      [ 33333, "0122111222123112211122212",
        [(430, 2060), (460, 2040), (460, 4560), (460, 34880)]],
In these entries, the first value is the carrier frequency, the second value is a string of indexes, and the third value is an array of microsecond timing pairs. Constructing a shut-off command is then just a matter of building up an array of timings by going through the string, and for each index, selecting the appropriate timing pair.

There are protocols for which this mechanism would be inconvenient (not everybody uses simple pulse/space timings to encode individual bits of data), but you could probably hack it to work with most devices.

There's one big problem with maintaining this code, though: I have no clue which TVs are supported and which are not. I can probably pick out a few -- some protocols have odd timing values that are easy to recognize -- but for most of them, it'd take some effort to determine exactly what device they are for. Which makes it awfully hard to know what needs to be added!

I'm probably not going to get involved with that code (I'm having a hard enough time making enough time for my own projects ), but it looks easy enough for just about anybody to play with if you'd like to mess around with IR.
 

The Following 2 Users Say Thank You to Copernicus For This Useful Post: