I have a Jetson Nano and would like to connect both CSI camera and a Go-Pro Hero 6 (video not detect

Items:
Jetson Nano Developer Kit
NVIDIA DLI AI Jetson Nano SD Card Image v1.1.1
CSI Camera - attached to MIPI CSI port
Go Pro Hero 6 - Not detected when connected using USB or Micro-HDMI

I am having problems detecting GoPro while CSI camera is plugged in as well.

Does anyone have a solution or help to first get my Go Pro video to be detected using Jetson Nano.

Then once Go-Pro video works then I can see how to get both videos.

Any help is appreciated :).

You need an HDMI to USB-3 Converter, see my picture.

You can do it via wifi with nginx and gstreamer – at least that setup works with my Hero 7 black. The basic idea is to run the nginx rtmp module (docker works great for this), and then serve that same stream right back up (not transcode), so you can use it with gstreamer’s rtmpsrc. Uridecodebin probably also works.

Once nginx is up and running, you then point the GoPro app at the rtmp server you created, and then start gstreamer. Sorry, but I don’t have any more detailed instructions at the moment. I decided the lag was insufficient for my purposes (it’s like half a second), so I abandoned that setup. It may be appropriate to your use case, however.

Cpu usage by nginx was not bad, since there is no transcoding going on. A hdmi-usb converter like WiSi-TestPilot suggested will probably give you lower latency and higher quality. The stream sent from the GoPro via rtmp is a low quality one mostly meant for YouTube livestreams.

Thank WiSi-Testpilot and mdegans, for sharing suggestions. Both look to be good solutions and should work well.

Thank you both for the replies. I will go for the USB 3.0 to HDMI adapter. Is there any cheap one you found?

I only found some that are 25 dollars +

I want the video to be in real-time and utilize both cameras. I have the adapter coming in tomorrow. I want to see if it will work.

You need an HDMI to USB3 adapter, not an USB to HDMI adapter, see my photo! They are starting as far as I know at least at $50. I’m also looking for further parts.

I have connected two of them, see #2, and it works fine. However now I connected one adapter with a gopro and another USB-camera directly to the nano. Then I have problems, see my recent thread:

https://devtalk.nvidia.com/default/topic/1072401/jetson-nano/how-to-composite-a-thermalcamera-and-a-gopro-/post/5432952/#5432952

I think it is a format problem….and still need help.

I also will combine a CSI camera and the USB3 adapter, so I’m afraid, that we get the same problem, when we combine CSI and USB3 cameras.

Best regards,
Wilhelm

see also my Jetson Nano Project:
https://devtalk.nvidia.com/default/topic/1064908/jetson-projects/jetson-nano-on-a-drone-multicopter/

Hi Wilhelm,

Thank you for letting me know! Can you link me to the model that you have so I can purchase one that actually works? It seems I misread and thought it was just an adapter. I typed the exact thing on Amazon and only saw adapters.

I really want to make the go-pro live feed data work as soon as possible so I can begin testing my python code.

Best,
Vasu

I got it from Amazone, but it is sold out.
Search for: if-link Video Capture
It has a very low latency.

This weekend I will order this one to test it:
https://direkt.jacob.de/produkte/usb-3-1-hdmi-video-grabber-43235-artnr-3886400.html?utm_source=billiger.de&utm_medium=cpc&utm_campaign=Preisvergleich&ref=132

You need also a micro HDMI to HDMI cable for example like this:
https://www.globe-flight.de/GF-UltraThin-Kabel-Standard-HDMI-auf-Micro-HDMI-40cm

Best regards,
Wilhelm

Hi Wilhelm,

I got this one today
https://www.amazon.com/gp/product/B07YHRFGN9/ref=ppx_yo_dt_b_asin_title_o00_s00?ie=UTF8&psc=1

I tested it and found that I am getting both videos from CSI and Go-Pro
code: !ls -ltrh /dev/video*
Output:
crw-rw----+ 1 root video 81, 0 Feb 3 20:35 /dev/video0
crw-rw----+ 1 root video 81, 3 Feb 3 20:36 /dev/video1

However, I am unable to see the video / live feed from the Go-Pro. Below is the code from the Nvidia Deep learning course.

Code:
from jetcam.usb_camera import USBCamera

#TODO change capture_device if incorrect for your system
camera = USBCamera(width=224, height=224, capture_width=640, capture_height=480, capture_device=1)

ERROR Output:

RuntimeError Traceback (most recent call last)
/usr/local/lib/python3.6/dist-packages/jetcam-0.0.0-py3.6.egg/jetcam/usb_camera.py in init(self, *args, **kwargs)
23 if not re:
—> 24 raise RuntimeError(‘Could not read image from camera.’)
25

RuntimeError: Could not read image from camera.

During handling of the above exception, another exception occurred:

RuntimeError Traceback (most recent call last)
in
2
3 #TODO change capture_device if incorrect for your system
----> 4 camera = USBCamera(width=224, height=224, capture_width=640, capture_height=480, capture_device=0)

/usr/local/lib/python3.6/dist-packages/jetcam-0.0.0-py3.6.egg/jetcam/usb_camera.py in init(self, *args, **kwargs)
26 except:
27 raise RuntimeError(
—> 28 ‘Could not initialize camera. Please see error trace.’)
29
30 atexit.register(self.cap.release)

RuntimeError: Could not initialize camera. Please see error trace.

Do you know any solution to this? Or even a workaround to see the live feed that is coming from the camera?

Best,
Vasu

Hi Vasu,
see the link for the CSI camera.
There are also some JetsonHacks Videos.

https://github.com/JetsonHacksNano/CSI-Camera

Take this to test the Gopro: (choose 0 or 1)

gst-launch-1.0 v4l2src device=/dev/video1 ! xvimagesink

Best regards,
Wilhelm

Hi Wilhelm,

Thanks for letting me about resources!

I got the CSI camera to work.

Go-Pro I am still having trouble.

Input:

gst-launch-1.0 v4l2src device=/dev/video1 ! xvimagesink

Output:

dlinano@jetson-nano:~$ gst-launch-1.0 v4l2src device=/dev/video1 ! xvimagesinkSetting pipeline to PAUSED ...
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstPipeline:pipeline0/GstXvImageSink:xvimagesink0: Could not initialise Xv output
Additional debug info:
xvimagesink.c(1773): gst_xv_image_sink_open (): /GstPipeline:pipeline0/GstXvImageSink:xvimagesink0:
Could not open display (null)Setting pipeline to NULL ...Freeing pipeline ...
dlinano@jetson-nano:~$

The GoPro is working and I even tested it multiple ways, like while recording and even when it’s idle. Do you know why it’s not showing the display after the gst-launch?

Please show the result of this command:

v4l2-ctl --list-formats-ext -d /dev/video1

If it not works install it:

sudo apt-get install v4l-utils

Just saw you have Nano SD Card Image v1.1.1

I’m using
jetson-nano-sd-r32.2.1.zip

and on the B01 kit
nv-jetson-nano-sd-card-image-r32.3.1.zip

Hi,
Same as WiSi-Testpilot suggests, if it can be run through v4l2, you can also refer to FAQ
Q: I have a USB camera. How can I lauch it on Jetson Nano?

Hey Wilhelm,

I tried all the above and it seems I’m getting some weird network error when I am doing both:

sudo apt install v41-utils

Which gave me this error:

dlinano@jetson-nano:~$ sudo apt-get install v4l-utils
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  libv4l2rds0
The following NEW packages will be installed:
  libv4l2rds0 v4l-utils
0 upgraded, 2 newly installed, 0 to remove and 99 not upgraded.
Need to get 399 kB of archives.
After this operation, 1,553 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Err:1 http://ports.ubuntu.com/ubuntu-ports bionic/main arm64 libv4l2rds0 arm64 1.14.2-1
  Could not resolve 'ports.ubuntu.com'
Err:2 http://ports.ubuntu.com/ubuntu-ports bionic/universe arm64 v4l-utils arm641.14.2-1
  Could not resolve 'ports.ubuntu.com'
E: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/pool/main/v/v4l-utils/libv4l2rds0_1.14.2-1_arm64.deb  Could not resolve 'ports.ubuntu.com'
E: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/pool/universe/v/v4l-utils/v4l-utils_1.14.2-1_arm64.deb  Could not resolve 'ports.ubuntu.com'
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

I then tried to do

sudo apt-get update

which also gave me the same error:

Err:13 http://ports.ubuntu.com/ubuntu-ports bionic InRelease
  Could not resolve 'ports.ubuntu.com'
Err:14 https://repo.download.nvidia.com/jetson/common r32 InRelease
  Could not resolve 'repo.download.nvidia.com'
Err:15 http://ports.ubuntu.com/ubuntu-ports bionic-updates InRelease
  Could not resolve 'ports.ubuntu.com'
Err:16 https://repo.download.nvidia.com/jetson/t210 r32 InRelease
  Could not resolve 'repo.download.nvidia.com'
Err:17 http://ports.ubuntu.com/ubuntu-ports bionic-backports InRelease
  Could not resolve 'ports.ubuntu.com'
Err:18 http://ports.ubuntu.com/ubuntu-ports bionic-security InRelease
  Could not resolve 'ports.ubuntu.com'
Reading package lists... Done
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-updates/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-backports/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-security/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch https://repo.download.nvidia.com/jetson/common/dists/r32/InRelease  Could not resolve 'repo.download.nvidia.com'
W: Failed to fetch https://repo.download.nvidia.com/jetson/t210/dists/r32/InRelease  Could not resolve 'repo.download.nvidia.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.

I will try to fix this error, but it seems the network I am on is not even able to

dlinano@jetson-nano:~$ ping ports.ubuntu.com
ping: ports.ubuntu.com: Name or service not known

Also, I am using the

NVIDIA DLI AI Jetson Nano SD Card Image v1.1.1
which allows me to use Jupyter Notebook to interface with the jetson nano in “headless” mode.

Should I use another one image instead?

Seems like network issues. You might try confguring google dns to use alternate name resolution, or set that on your router (same page). Can you at least ping 8.8.8.8? If not, that’s a separate issue.

Hi Mdegans,

I am able to ping 8.8.8.8, but I still do not understand how to configure google dns to make this work.

dlinano@jetson-nano:~$ ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
^C
--- 8.8.8.8 ping statistics ---
2 packets transmitted, 0 received, 100% packet loss, time 1012ms

dlinano@jetson-nano:~$ sudo apt-get update
Get:1 file:/var/cuda-repo-10-0-local-10.0.326  InRelease
Ign:1 file:/var/cuda-repo-10-0-local-10.0.326  InRelease
Get:2 file:/var/visionworks-repo  InRelease
Ign:2 file:/var/visionworks-repo  InRelease
Get:3 file:/var/visionworks-sfm-repo  InRelease
Ign:3 file:/var/visionworks-sfm-repo  InRelease
Get:4 file:/var/visionworks-tracking-repo  InRelease
Ign:4 file:/var/visionworks-tracking-repo  InRelease
Get:5 file:/var/cuda-repo-10-0-local-10.0.326  Release [574 B]
Get:6 file:/var/visionworks-repo  Release [1,999 B]
Get:7 file:/var/visionworks-sfm-repo  Release [2,003 B]
Get:5 file:/var/cuda-repo-10-0-local-10.0.326  Release [574 B]
Get:8 file:/var/visionworks-tracking-repo  Release [2,008 B]
Get:6 file:/var/visionworks-repo  Release [1,999 B]
Get:7 file:/var/visionworks-sfm-repo  Release [2,003 B]Get:8 file:/var/visionworks-tracking-repo  Release [2,008 B]
Err:13 https://repo.download.nvidia.com/jetson/common r32 InRelease  Could not resolve 'repo.download.nvidia.com'
Err:14 http://ports.ubuntu.com/ubuntu-ports bionic InRelease  Could not resolve 'ports.ubuntu.com'
Err:15 https://repo.download.nvidia.com/jetson/t210 r32 InRelease  Could not resolve 'repo.download.nvidia.com'
Err:16 http://ports.ubuntu.com/ubuntu-ports bionic-updates InRelease  Could not resolve 'ports.ubuntu.com'
Err:17 http://ports.ubuntu.com/ubuntu-ports bionic-backports InRelease  Could not resolve 'ports.ubuntu.com'
Err:18 http://ports.ubuntu.com/ubuntu-ports bionic-security InRelease  Could not resolve 'ports.ubuntu.com'
Reading package lists... Done
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-updates/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-backports/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-security/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch https://repo.download.nvidia.com/jetson/common/dists/r32/InRelease  Could not resolve 'repo.download.nvidia.com'
W: Failed to fetch https://repo.download.nvidia.com/jetson/t210/dists/r32/InRelease  Could not resolve 'repo.download.nvidia.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.

Any help is appreciated, as I am not that knowledgable of network changes to get this simple command to work.

Instructions are here. The problem is 100% DNS if you can ping 8.8.8.8 but can’t resolve various hosts.

Note on those instructions: you may find it easier to use “nano” than “vi”. You can install “nano” with “sudo apt install nano”.

Just edit /etc/resolv.conf, replacing or adding the nameserverlines with:

nameserver 8.8.8.8
nameserver 8.8.4.4

Then save, exit, and try again. I don’t think you’ll need to reboot, but it can’t hurt.

So I am unable to install nano since that also needs to connect to ports.ubuntu.com :(

I changed the /etc/resolv.conf through vi

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
# 127.0.0.53 is the systemd-resolved stub resolver.
# run "systemd-resolve --status" to see details about theactual nameservers.

nameserver 8.8.8.8
nameserver 8.8.4.4

I still get the same error

dlinano@jetson-nano:~$ sudo vi /etc/resolv.conf
dlinano@jetson-nano:~$ sudo apt-get update
Get:1 file:/var/cuda-repo-10-0-local-10.0.326  InReleaseIgn:1 file:/var/cuda-repo-10-0-local-10.0.326  InRelease
Get:2 file:/var/visionworks-repo  InRelease
Ign:2 file:/var/visionworks-repo  InReleaseGet:3 file:/var/visionworks-sfm-repo  InRelease
Ign:3 file:/var/visionworks-sfm-repo  InRelease
Get:4 file:/var/visionworks-tracking-repo  InReleaseIgn:4 file:/var/visionworks-tracking-repo  InRelease
Get:5 file:/var/cuda-repo-10-0-local-10.0.326  Release [574 B]
Get:6 file:/var/visionworks-repo  Release [1,999 B]
Get:7 file:/var/visionworks-sfm-repo  Release [2,003 B]
Get:5 file:/var/cuda-repo-10-0-local-10.0.326  Release [574 B]
Get:8 file:/var/visionworks-tracking-repo  Release [2,008B]
Get:6 file:/var/visionworks-repo  Release [1,999 B]
Get:7 file:/var/visionworks-sfm-repo  Release [2,003 B]
Get:8 file:/var/visionworks-tracking-repo  Release [2,008B]
Err:13 https://repo.download.nvidia.com/jetson/common r32InRelease
  <b>Could not resolve 'repo.download.nvidia.com'</b>
Err:14 http://ports.ubuntu.com/ubuntu-ports bionic InRelease
  <b>Could not resolve 'ports.ubuntu.com'</b>
Err:15 https://repo.download.nvidia.com/jetson/t210 r32 InRelease
  Could not resolve 'repo.download.nvidia.com'
Err:16 http://ports.ubuntu.com/ubuntu-ports bionic-updates InRelease
  Could not resolve 'ports.ubuntu.com'
Err:17 http://ports.ubuntu.com/ubuntu-ports bionic-backports InRelease
  Could not resolve 'ports.ubuntu.com'
Err:18 http://ports.ubuntu.com/ubuntu-ports bionic-security InRelease
  Could not resolve 'ports.ubuntu.com'
Reading package lists... Done
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-updates/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-backports/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch http://ports.ubuntu.com/ubuntu-ports/dists/bionic-security/InRelease  Could not resolve 'ports.ubuntu.com'
W: Failed to fetch https://repo.download.nvidia.com/jetson/common/dists/r32/InRelease  Could not resolve 'repo.download.nvidia.com'
W: Failed to fetch https://repo.download.nvidia.com/jetson/t210/dists/r32/InRelease  Could not resolve 'repo.download.nvidia.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.

I appreciate all the help and guides you sent me. But I feel as though this is the image error that I downloaded.

The Jetson Nano course has an image of 7.1 GB titled: ‘ainano_v1-1-1_20GB_200203B’ that I am using.

Any other suggestions?

You may try the Gopro again. Set the camera and the pipeline to the same values.

gst-launch-1.0 v4l2src device=/dev/video<b>1</b> ! nvvidconv ! \
  video/x-raw, framerate=30/1, width=1280, height=720 ! \
  nvvidconv ! nv3dsink

My adapter (I can not find a distributor at the moment)
https://if-link.manufacturer.globalsources.com/si/6008849860518/pdtl/Video-capture/1166112129/Video-capture-cards-Video-capture-dongle.htm

can automatically detect the input video formats and adjusts the output size and frame rate automatically (according to the settings of the gstreamer). (see website)

Also the Homful hdmi capture seems to have this feature.
https://www.amazon.com/Capture-Broadcast-Nintendo-Consoles-Camcorder/dp/B07HK5NTL8

Best regards,
Wilhelm

Hi,

I tried the below code and got the same error from above. Maybe it is the capture card I got.

This is the output:

dlinano@jetson-nano:~$ gst-launch-1.0 v4l2src device=/dev/video1 ! nvvidconv ! \>   video/x-raw, framerate=30/1, width=1280, height=720 !\>   nvvidconv ! nv3dsink
Setting pipeline to PAUSED ...
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstPipeline:pipeline0/GstNv3dSink:nv3dsink0: GStreamer error: state change failed and some element failed to post a proper error message with the reasonfor the failure.
Additional debug info:
gstbasesink.c(5265): gst_base_sink_change_state (): /GstPipeline:pipeline0/GstNv3dSink:nv3dsink0:
Failed to start
Setting pipeline to NULL ...
Freeing pipeline ...

I will

I will purchase the one above and see if that helps. But I do not believe it is the capture card error.

I am still getting an error connecting to ports.ubuntu.com when trying

sudo apt-get update

Which seems ridiculous but maybe it’s my image. I will try to use a different image, what image do you use Wilhelm?