[pvrusb2] Weird behavior with my Happauge UB-PVR

Mike Isely isely at isely.net
Thu Mar 20 09:15:14 CDT 2008


On Thu, 20 Mar 2008, mailinglists at vanhlebarsoftware.com wrote:

> So everything has been working fairly well with my Myth setup for the  
> last month or so. I haven't really been using it a  lot as I still am  
> having issues getting a front end working so that it will display on  
> my tv. (this is an issue with the computer, not Myth)
> 
> I have been seeing a situation that occurs more frequently than I  
> would like and I was wondering if anyone else is seeing this and if  
> there is a solution to it.
> 
> Normally my PVR is mounted at /dev/video0, however, frequently it will  
> change to /dev/video1 without any reason. Normally I had seen this  
> when I would shutdown the backend in order to run mythfilldatabase and  
> then restart the backend. When this does occur, from the command like  
> it looks like the backend starts, but upon review of the log file, you  
> can see an error that the backend could not read from /dev/video0 or  
> /dev/video1, depending on what I had it set to previously.
> 
> Last night I saw something really really strange happen. Right in the  
> middle of a 1 hour show, somehow the the PVR when from being active on  
> /dev/video0 to /dev/video1! Myth was recording just fine and then it  
> just stopped.
> 
> I do have a script that runs each morning at 6:45am that shuts down  
> the backend, runs mythfilldatabase and then starts the backend up  
> again. Now that I know my issue, I have thought about creating a  
> script that would run after the backend has been restarted and test to  
> see if /dev/video0 or /dev/video1 should be used. Is the configuration  
> file for the capture card just a text file that I could write to in  
> order to do this in a script? Does anyone have any other suggestions  
> to get this to work properly or is this just one of the issues you run  
> into while using USB since there is no guarentee with USB that it will  
> always be the same?
> 
> For what it's worth, I have the same issue with my 4 USB External HDs  
> also. They don't always get the same device id on a reboot and I have  
> to manually correct them so that my exported NFS stuff is correct.
> 

I could see this happening if the device's USB connection get 
"glitched".  When you unplug the pvr-usb2 device - like just about any 
USB device - there is going to be some delay as the driver is notified 
of the disconnect and various bits of state are torn down.  If the 
device gets rapidly reconnected before the disconnect is completed, then 
it is going to appear to the Linux kernel to be "another" device because 
the old driver instance is still (temporarily) present.  Thus it gets 
assigned a different ID when the new pvrusb2 driver instance 
initializes.

I'd suspect your USB controller or any interconnecting cables.  Also 
make sure you aren't having any problems with power spikes / surges 
where the equipment is located (a power glitch could also disconnect the 
device).  You mention that you've also see this with your USB hard 
drives - are any of them USB-powered?  If so then you've ruled out dirty 
power as a cause.  If not, see if you can reproduce this glitchy 
behavior with a USB device that does not require an external power 
supply.  Knowing that will help you figure out where you need to be 
looking.

  -Mike


-- 

Mike Isely
isely @ pobox (dot) com
PGP: 03 54 43 4D 75 E5 CC 92 71 16 01 E2 B5 F5 C1 E8


More information about the pvrusb2 mailing list