Making a TV card always the same /dev/video node

Asked by Aaron Whitehouse

I have two TV capture in my computer set up in MythTV. On about half of my reboots, the two cards change between being /dev/video0 and /dev/video1. This causes no end of grief, so I usually just reboot and hope it changes back.

Is there some udev rule or hal thing that would make sure that each card is always the /dev node?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Aaron Whitehouse
Solved:
Last query:
Last reply:
Revision history for this message
Aaron Whitehouse (aaron-whitehouse) said :
#1

I just solved this using KillerKiwi's script:
http://ubuntuforums.org/showthread.php?t=753434

I looked in MythBackend (or MythFrontend under Information Center, tuner status) to determine which /dev/ node each card was set up to be at the moment, then ran:
sudo python udev_rules.py /dev/video0 /dev/video_pvr150
and then sudo python udev_rules.py /dev/video1 /dev/video_bttv

I then went back into MythBackend and changed the device from /dev/video0 to /dev/video_pvr150 and changed the other card from /dev/video1 to /dev/video_bttv.

All seems to be working correctly and it theoretically shouldn't change on boot, because those symlinks should always link to the correct card. Thanks KillerKiwi!