Camera server aborting (python)

We could use some advice with an issue getting the camera server to launch with our python code.

The wpilib.cameraserver.CameraServer.launch() function is what is now recommended in the documentation but this always immediately aborts. From the logger we see “Launching CameraServer process” followed quickly by “CameraServer process exited with exitcode -6”.

Directly running cscore will start a stream on any other computer but in a shell to Roborio will immediately fail with the message Aborted. It works fine if we directly call cscore.CameraServer.startAutomaticCapture(), but that’s not recommended.

Any ideas? We’d like to be able to line up with the recommended camera server starting code, assuming that will lead to less potential complications, but ultimately we’re not planning any vision processing on the rio, we just want to get streams directed to the drivestation.

See QuickVision example fails with SIGABRT · Issue #61 · robotpy/mostrobotpy · GitHub

Oh that’s interesting.

… so, if you aren’t doing any image processing on the stream (eg, calling grabFrame and doing something with it), then that’s actually perfectly fine and won’t cause any performance issues.

Maybe should update the bug report with that advice too.

Thanks.

If startAutomaticCapture is safe enough in this context we might just stick with it.

It’s a bit hard to follow the stack trace without context, I’m assuming that’s from a similar exit of the process… ignore that, it’s in the title. Excuse me I’m still caffeinating. I’ll try disabling the NI webserver just to see if it helps, but I don’t really want to leave it that way. That seems like something we’ll forget about and trip over later.

Confirmed, disabling the ni webserver as suggested also works.

1 Like