Logitech920 frame-rate issue following MacMini restart


#1

I have an installation that uses a Logitech 920 camera to record and display video. The camera is hanging at the end of a 15 foot powered USB extension. After restarting the MacMini and launching my application, the feed from the webcam runs at only 1-2fps. Relaunching the app does not fix the issue, but power-cycling the camera (unplugging then plugging in) does.

When I open PhotoBooth, the frame-rate is always good, even when my application is running at the same time with 1-2fps.

Has anyone seen anything like this? Is there a way to power-cycle the camera from software?


#2

I’ve used this same setup for a couple of projects and have never experienced anything like that. I don’t think there is a way to… Maybe there is something wrong with the USB extension? Or something is up in the OS. Have you tried it without the cable and on another mac?


#3

I have been able to recreate the issue on a different MacMini with a different USB power hub and cable.
It is not 100% consistent. If I change ports, sometimes it will boot up a couple times with a good frame-rate but the issue eventually returns.


#4

How about another camera? The only issue that I have run into was it somehow becoming de-attached by the computer and it wasn’t showing even in the system profiler. Plug cycle fixed it though.


#5

Using another Logitech920, the issue persists. Using a Logitech310 the issue does not occur. I would swap cameras but I need the higher resolution of the Logitech920.

In code, I’ve tried adding a delay before initializing the camera, as well as closing then re-opening the camera stream. Neither had an effect.

Any other ideas?


#6

I’ve used that setup many times and haven’t experienced this issue, but I have experienced some less-than-great performance in general using the slower Minis and full-screen video.

Out of curiosity, are you using ofxUVC with the app? I don’t suspect it’d cause the issue, but adding some level of hardware control may help…

You could try the Logitech c930e camera, it’s field of view is a bit wider than the c920, but that may be a good thing?


#7

I am not. I didn’t need that kind of control, but will give it a try. Maybe explicitly setting exposure/focus will break it out of whatever is happening. Also looking into using an BlackMagic box with a non-USB camera.


#8

I highly recommend the BlackMagic route. Recently did a project with a Hero4 and it’s made me never want to use a webcam ever again.

Recording the video is not nearly as easy as with the “stock” OF video classes, but is doable. For my project I used ‘ofxVideoRecorder’ which uses ffmpeg for the writing, but doesn’t give you a reliable “video completed” event. I’m happy to elaborate on how we used it more if you are interested. Also, I’m in the middle of writing an AVFoundation/AssetWriter add-on, but it’s had to take a back seat to other work.


#9

I had this exact same problem a few years ago with a mac mini and logitech webcam (can’t remember the exact model but I think it was the C920 - at least similar to that). I ended up building a small relay box that sat in between the mini and the camera. It would cut the USB power lines for a few seconds after booting, simulating an unplug/replug scenario. Of course not the most elegant solution but it worked like a charm.


#10

Hi all here, I know this is an old thread, but I’m having a similar problem right now with an installation. The strange thing is: I have two installations running next to each other, both on a mac mini and both using the Logitech C920 camera. One setup has no problems whatsoever, the other installation has the camera stop working at random times. Sometimes the camera intermittently shows new frames, but mostly it keeps showing the same frame on which it is stuck.

The installation that has problems is connected to a projector, the one without problems is connected to a screen.

Extra weird: when the projector is switched off and on again, the camera sometimes resumes working normally!!!

Do the people who have experienced the same issue have more information on their setups: screen / or projector etc… ?

thanks,
Tim


#11

My Mac Mini was connected to a single screen. I never tried to turn it off and on though… Does a USB replug help at all?


#12

hmm interesting.
In my case, the camera is installed more or less in the ceiling of the space, so getting to the USB cable is difficult.

But when I just restart the software, the camera always works as expected again.

It’s very difficult to reproduce because I can restart the software 10 times with everything working fine and then the 11th time the camera will start freezing up randomly without any real difference in the setup.


#13

That must be a different issue then - in my case restarting the software didn’t fix it. I guess maybe you could keep track of the framerate and detect the issue. Restart the software until the issue isn’t detected anymore.

A little hacky I know but I’m guessing its a driver issue and if that’s true your chances of really fixing the issue (except by maybe trying a different camera) are very slim to say the least.


#14

Hi Daan,
Thanks for the answer! Yes that sounds like two different issues. Very strange that I never had your problem either… I have been working with Logitech C920s for a long time, they are my default camera to use when I want to control focus or exposure from software.

Are you sure you were using C920, I’m considering switching to a different model to solve my problem, but don’t want to run into your issue… :slight_smile:

Another weird symptom I forgot to mention: The exposure of the camera is controlled through UVC (ofxUVC) and when I switch the connected projector off and on, the camera’s exposure changes!
I have never ever seen anything like this before, and I can’t figure out how switching off a display could affect the camera exposure??


#15

Little update on this issue: it turned out to be a faulty Mac Mini. I replaced the machine and all the issues went away. The first time I ever experienced this.