Example GStreamer Code for the Jetson Nano
Posted: Wed Mar 30, 2022 10:58 am
Some time ago I described how I was using the Jetson Nano, controlled by the Portsdown 2020, to generate H265-encoded video for QO-100. I have recently started using a Polycomm EagleEye WebCam, which has mjpeg formatted output. I finally worked out the GStreamer incantation to make it work and thought that others might find these examples useful. Note that I have added line breaks to make it more readable.
Here is the GStreamer code for the EagleEye webcam with a standard USB audio dongle (the camera does not have a microphone):
For comparison, here is the code for an early Logitech C920 (the one with H264 output):
I hope to incorporate more Jeston Nano support in the next Portsdown 2020 update. It saves me having to set up my Windows 10 laptop every time that I want to transmit H265.
Dave
Here is the GStreamer code for the EagleEye webcam with a standard USB audio dongle (the camera does not have a microphone):
Code: Select all
gst-launch-1.0 -vvv -e
v4l2src device=/dev/video0 do-timestamp=true '!' 'image/jpeg,width=1280,height=720,framerate=25/1'
'!' jpegparse '!'jpegdec '!' nvvidconv
'!' "video/x-raw(memory:NVMM), width=(int)1280, height=(int)704, format=(string)I420"
'!' omxh265enc control-rate=2 bitrate=300232 peak-bitrate=330255 preset-level=3 iframeinterval=100
'!' 'video/x-h265,width=(int)1280,height=(int)704,stream-format=(string)byte-stream' '!' queue
'!' mux. alsasrc device=hw:2
'!' 'audio/x-raw, format=S16LE, layout=interleaved, rate=48000, channels=1' '!' voaacenc bitrate=20000
'!' queue '!' mux. mpegtsmux alignment=7 name=mux '!' fdsink
| ffmpeg -i - -ss 8
-c:v copy -max_delay 200000 -muxrate 440310
-c:a copy -f mpegts
-metadata service_provider="Portsdown_Jetson" -metadata service_name="G8GKQ"
-mpegts_pmt_start_pid 4095 -streamid 0:"256" -streamid 1:"257" -
| ../bin/limesdr_dvb -s "333"000 -f 2/3 -r 2 -m DVBS2 -c QPSK
-t "2409.75"e6 -g 0.95 -q 1
Code: Select all
gst-launch-1.0 -vvv -e
v4l2src device=/dev/video0 do-timestamp=true '!' 'video/x-h264,width=1280,height=720,framerate=30/1'
'!' h264parse '!' omxh264dec '!' nvvidconv
'!' "video/x-raw(memory:NVMM), width=(int)1280, height=(int)704, format=(string)I420"
'!' omxh265enc control-rate=2 bitrate=300232 peak-bitrate=330255 preset-level=3 iframeinterval=100
'!' 'video/x-h265,width=(int)1280,height=(int)704,stream-format=(string)byte-stream' '!' queue
'!' mux. alsasrc device=hw:2
'!' 'audio/x-raw, format=S16LE, layout=interleaved, rate=32000, channels=2'
'!' audioconvert '!' 'audio/x-raw, channels=1' '!' voaacenc bitrate=20000
'!' queue '!' mux. mpegtsmux alignment=7 name=mux '!' fdsink
| ffmpeg -i - -ss 8
-c:v copy -max_delay 200000 -muxrate 440310
-c:a copy -f mpegts
-metadata service_provider="Portsdown_Jetson" -metadata service_name="G8GKQ"
-mpegts_pmt_start_pid 4095 -streamid 0:"256" -streamid 1:"257" -
| ../bin/limesdr_dvb -s "333"000 -f 2/3 -r 2 -m DVBS2 -c QPSK
-t "2409.75"e6 -g 0.95 -q 1
Dave