jacksonliam / mjpg-streamer

Fork of http://sourceforge.net/projects/mjpg-streamer/
2.96k stars 1.21k forks source link

how to use pi camera in jetson nano #359

Open MAKER-park opened 1 year ago

MAKER-park commented 1 year ago

(Question) Have you tried mjpg-streaming linkage when connecting with the camera connector provided in jetson nano? After installing the pi camera compatible with jetson nano, if you mix and use the mjpg-stream operation command and the command to operate the pi camera, the following error occurs. I'm posting this because I can't find any reference material to find out if the camera access is wrong in this way or not. jetsonpark@jetsonpark-desktop:~/Documents/mjpg-stream/tmp/mjpg-streamer/mjpg-streamer-experimental$ mjpg_streamer -o "output_http.so -w ./www" -i "

-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM),width=3820, height=2464, framerate=21/1, format=NV12' ! nvvidconv flip-method=0 ! 'video/x-raw,width=960, height=616' ! nvvidconv ! nvegltransform ! nveglglessink -e" MJPG Streamer Version.: 2.0 ERROR: could not find input plugin Perhaps you want to adjust the search path with:

export LD_LIBRARY_PATH=/path/to/plugin/folder

dlopen: -launch-1.0: cannot open shared object file: No such file or directory

use refer this https://jetsonhacks.com/2019/04/02/jetson-nano-raspberry-pi-camera/

jacksonliam commented 1 year ago

I'm not sure what you're trying to do with that command but the second half is a gstreamer command and not related to mjpg_streamer at all.

You could try input_uvc as it looks like there is a v4l2 device, though it looks like it might be RGB only so no idea if it would work. I don't have a Jetson board so cannot help any further.

MAKER-park commented 1 year ago

Thank you so much for your reply. Through the method you provided, I checked the list of supported cameras. Are these lists not applicable to these codes?

park@park-desktop:~/Documents/camera_stream/mjpg-streamer/mjpg-streamer-experimental$ sudo v4l2-ctl --device=/dev/video0 --all Driver Info (not using libv4l2): Driver name : tegra-video Card type : vi-output, imx219 7-0010 Bus info : platform:54080000.vi:0 Driver version: 4.9.253 Capabilities : 0x84200001 Video Capture Streaming Extended Pix Format Device Capabilities Device Caps : 0x04200001 Video Capture Streaming Extended Pix Format Priority: 2 Video input : 0 (Camera 0: no power) Format Video Capture: Width/Height : 3264/2464 Pixel Format : 'RG10' Field : None Bytes per Line : 6528 Size Image : 16084992 Colorspace : sRGB Transfer Function : Default (maps to sRGB) YCbCr/HSV Encoding: Default (maps to ITU-R 601) Quantization : Default (maps to Full Range) Flags :

Camera Controls

                 group_hold 0x009a2003 (bool)   : default=0 value=0 flags=execute-on-write
                sensor_mode 0x009a2008 (int64)  : min=0 max=0 step=0 default=0 value=0 flags=slider
                       gain 0x009a2009 (int64)  : min=0 max=0 step=0 default=0 value=16 flags=slider
                   exposure 0x009a200a (int64)  : min=0 max=0 step=0 default=0 value=13 flags=slider
                 frame_rate 0x009a200b (int64)  : min=0 max=0 step=0 default=0 value=2000000 flags=slider
                bypass_mode 0x009a2064 (intmenu): min=0 max=1 default=0 value=0
            override_enable 0x009a2065 (intmenu): min=0 max=1 default=0 value=0
               height_align 0x009a2066 (int)    : min=1 max=16 step=1 default=1 value=1
                 size_align 0x009a2067 (intmenu): min=0 max=2 default=0 value=0
           write_isp_format 0x009a2068 (bool)   : default=0 value=0
   sensor_signal_properties 0x009a2069 (u32)    : min=0 max=0 step=0 default=0 flags=read-only, has-payload
    sensor_image_properties 0x009a206a (u32)    : min=0 max=0 step=0 default=0 flags=read-only, has-payload
  sensor_control_properties 0x009a206b (u32)    : min=0 max=0 step=0 default=0 flags=read-only, has-payload
          sensor_dv_timings 0x009a206c (u32)    : min=0 max=0 step=0 default=0 flags=read-only, has-payload
           low_latency_mode 0x009a206d (bool)   : default=0 value=0
           preferred_stride 0x009a206e (int)    : min=0 max=65535 step=1 default=0 value=0
               sensor_modes 0x009a2082 (int)    : min=0 max=30 step=1 default=30 value=6 flags=read-only