Getting errors while live streaming from Theta Z1 + Jetson Nano to opencv

Hello @craig

I am using opencv and thetauvcsrc to get the live streaming on Jetson Nano

VideoCapture cap("thetauvcsrc ! decodebin ! autovideoconvert ! video/x-raw,format=BGRx ! queue ! videoconvert ! video/x-raw,format=BGR ! queue ! appsink");

this is working as expected but FPS is very-very low but I just wanted to know,

is there a command to stop live streaming ?


Regards,
Vijay Saw

You can use the USB API to:

  • put camera to sleep (which will stop the stream)
  • wake camera from sleep, which will restart the stream

Alternately, you can use the USB API to switch the camera to video or image mode, which will step the stream over the USB cable.

FPS should be in the 30fps range with a 4GB model of the Jetson Nano without opencv processing. It will drop if you’re using object detection.

I tried all of those command that you have mentioned but it is giving an error device is busy and this is only happening when I am trying to stream more than 15-20 minutes.

Running on Jetson Nano with libgphoto2

or, if you’re using libptp2

The Z1 provides an error with /osc/state Do you have an error occurring when you can’t put the camera to sleep?

RICOH THETA Z1 or prior

Error code Can/not shoot Desription Recommended action
NO_MEMORY Insufficient memory Delete files
FILE_NUMBER_OVER Maximum file number exceeded Delete 999 folder or delete 9999 file
NO_DATE_SETTING Camera clock not set Set Date/Time via API
ELECTRONIC_COMPASS_CALIBRATION Electronic compass error Move the camera with ∞ pattern
PLUGIN_BOOT_ERROR *1 Plugin start warning (IoT technical standards compliance) Disconnect from internet
HIGH_TEMPERATURE_WARNING *2 (Board) temperature warning Cool the camera
CAPTURE_HW_FAILED Shooting hardware failure Reboot the camera may help
INTERNAL_MEM_ACCESS_FAIL Internal memory access error Reboot the camera may help
UNEXPECTED_ERROR Undefined error Reboot the camera may help
BATTERY_CHARGE_FAIL Charging error Check USB cable or charger
HIGH_TEMPERATURE (Board) temperature error Cool the camera
BATTERY_HIGH_TEMPERATURE *1 Battery temperature error Cool the camera

*1 RICOH THETA Z1 or later
*2 RICOH THETA Z1 v2.20.3 or later

Getting this error while changing or trying to stop live streaming

theta --set-property=0x5013 --val=0x0001

Camera: RICOH THETA Z1

'Still Capture Mode' is set to: 0x8005 (-32763)

Changing property value to 0x0001 [(null)] FAILED!!!

PTP: Device Busy

image

it’ is only happening when I try to close this streaming after 20 min.

even on trying with libgphoto2 getting same error please see

gphoto2 --set-config=/main/other/d80e=1
                                                                               
*** Error ***              
The property 'PTP Property 0xd80e' / 0xd80e was not set (0x2019: PTP Device Busy).

seems like Gstreamer pipeline is not closing ?

I can replicate this problem if the camera is streaming and being used by libuvc.

ptpcam --set-property=0x5013 --val=0x0001

Camera: RICOH THETA Z1
'Still Capture Mode' is set to: 0x8005 (-32763)
Changing property value to 0x0001 [(null)] FAILED!!!
PTP: Device Busy

I can switch between live streaming and image when the camera is not being used by libuvc.

Can you try open an issue on GitHub?

@Vijay_Saw , I submitted a community inquiry to ricoh to clarify the USB API specification and I received a response.

During live streaming in “live streaming mode”, MTP commands for changing settings are not accepted.
During not live streaming in “live streaming mode”, MTP commands for changing settings are accepted.

How critical is this feature to your deployment?