Manual channel tuning in ivtv_xine_tv.py continues to be inaccurate due to the use of tuning by index rather than tuning by number.
For most countries, TV channels are tuned by a specific number which a user should be able to enter via their remote. Currently, although a number can be entered, the number may not correspond to that specific channel due to some channels being removed from the user's TV_CHANNELS list in local_conf.py. Removing a single channel misaligns the index, forcing the user to try to remember which number equals what channel.
A patch to correct this oversight is attached.
Patch to fix manual channel tuning.
2 patches to complete manual channel change fix.
Logged In: YES
user_id=1766386
Originator: YES
Adding 2 patches to cover changes since previous version tests for this fix...
File Added: ivtv_fix_diffs.tar.gz
Logged In: YES
user_id=104395
Originator: NO
Can you provide an example of TV_CHANNELS so that I know what you mean.
TV_CHANNELS = [
('CNI04C1', u'SF1', 'K05'),
('CNI04C7', u'SFzwei', 'K10'),
('CNI04CC', u'SFinfo', 'K35'),
...
]
So what happens when there are no numbers to map to?
Logged In: YES
user_id=1766386
Originator: YES
TV_CHANNELS = [
('I11771.labs.zap2it.com','2 WPBT','2'),
('I10240.labs.zap2it.com','3 HBO','3'),
('I11349.labs.zap2it.com','4 WFOR','4'),
#('I12013.labs.zap2it.com','5 WAMI','5'),
('I11916.labs.zap2it.com','6 WTVJ','6'),
('I11857.labs.zap2it.com','7 WSVN','7'), ...
]
Note the missing channel...
What happens when there are no numbers to map to?? The tuner control then attempts a lookup using the opposite method. Since I don't have anything other than what I have, I can't really code for or test this at the moment. I can try if someone wants to pass over their TV_CHANNELS listing. (Hint, Hint...) There may even be a way of detecting prefix via the remote if I get creative enough about it.
So far, pretty much every country I've been to (Japan, Korea, Philippines, Guam, ...) uses a number without a prefix or suffix for TV channel tuning. I know Europe is decidedly different on this because of the use of multiple standards like PAL and SECAM with the occasional NTSC variant thrown in just to confuse things. Due to the international scope of Freevo, I think we need to insure it works as expected (read, like everything you've used before) "out of the box."
Logged In: YES
user_id=104395
Originator: NO
Now that I fully understand the problem, sorry but I don't like this solution :(
What I would suggest is that we use a dict mapping for buttons:
TV_CHANNELS_BUTTONS = {
'2': 'I11771.labs.zap2it.com',
'3': 'I10240.labs.zap2it.com',
...
}
When this is set to None then the current behaviour is used.
Would you be happy with this proposal?
Logged In: YES
user_id=1766386
Originator: YES
That's ugly and I don't like it either. How about a TUNING_METHOD setting in local_conf? A simple check of the setting and we choose the right method; quick, simple and much easier to implement (albeit a semi-dirty hack...)
Better than the previous idea???
Logged In: YES
user_id=182311
Originator: NO
Yes, a boolean like TUNING_METHOD will do nicely.
I have a rather large patch for ivtv_xine_tv waiting for submission. It a.o. fixes issues with switching video groups. The patch also adds this config variable.
If you want I can send you the patch. But, in order to use it, you should update xine-lib to v1.1.9 or later *and* you must install the cvs version of xine-ui.