My rtsp stream url is
rtsp://192.17.3.2/user=admin&password=&channel=2&stream=0.sdp?
The url works using VLC in Windows.
In Ubuntu, I used gst-launch as below.
gst-launch-1.0 --gst-debug=rtspsrc:5 rtspsrc location=rtsp://192.17.3.2/user=admin&password=&channel=2&stream=0.sdp? ! rtph264depay ! queue ! nvv4l2decoder ! queue ! nvvideoconvert ! nveglglessink
What could be issue?
The full error is
xavier#xavier-desktop:~$ gst-launch-1.0 --gst-debug=rtspsrc:5 rtspsrc location=rtsp://192.17.3.2/user=admin&password=&channel=2&stream=0.sdp? ! rtph264depay ! queue ! nvv4l2decoder ! queue ! nvvideoconvert ! nveglglessink
[2] 16954
[3] 16955
[4] 16956
bash: !: command not found
[1] Exit 1 gst-launch-1.0 --gst-debug=rtspsrc:5 rtspsrc location=rtsp://192.17.3.2/user=admin
[3]- Done password=
[4]+ Done channel=2
xavier#xavier-desktop:~$ 0:00:00.062975168 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:8617:gst_rtspsrc_uri_set_uri:<rtspsrc0> parsing URI
0:00:00.063076992 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:8624:gst_rtspsrc_uri_set_uri:<rtspsrc0> configuring URI
0:00:00.063111072 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:8640:gst_rtspsrc_uri_set_uri:<rtspsrc0> set uri: rtsp://192.17.3.2/user=admin
0:00:00.063131680 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:8642:gst_rtspsrc_uri_set_uri:<rtspsrc0> request uri is: rtsp://192.17.3.2/user=admin
Setting pipeline to PAUSED ...
0:00:00.063379360 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:8391:gst_rtspsrc_start:<rtspsrc0> starting
0:00:00.063515584 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:5567:gst_rtspsrc_loop_send_cmd:<rtspsrc0> sending cmd OPEN
0:00:00.063541280 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:5598:gst_rtspsrc_loop_send_cmd:<rtspsrc0> not interrupting busy cmd unknown
Pipeline is live and does not need PREROLL ...
0:00:00.063948992 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:8346:gst_rtspsrc_thread:<rtspsrc0> got command OPEN
0:00:00.063994560 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4748:gst_rtspsrc_connection_flush:<rtspsrc0> set flushing 0
0:00:00.064058752 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4614:gst_rtsp_conninfo_connect:<rtspsrc0> creating connection (rtsp://192.17.3.2/user=admin)...
Progress: (open) Opening Stream
0:00:00.064632000 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4625:gst_rtsp_conninfo_connect:<rtspsrc0> sanitized uri rtsp://192.17.3.2/user=admin
0:00:00.064716384 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4659:gst_rtsp_conninfo_connect:<rtspsrc0> connecting (rtsp://192.17.3.2/user=admin)...
Progress: (connect) Connecting to rtsp://192.17.3.2/user=admin
0:00:00.133218848 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:7342:gst_rtspsrc_retrieve_sdp:<rtspsrc0> create options... (async)
0:00:00.133296448 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:7351:gst_rtspsrc_retrieve_sdp:<rtspsrc0> send options...
0:00:00.133489696 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:476:default_before_send:<rtspsrc0> default handler
Progress: (open) Retrieving server options
0:00:00.133759744 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:476:default_before_send:<rtspsrc0> default handler
0:00:00.133788736 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5964:gst_rtspsrc_try_send:<rtspsrc0> sending message
0:00:00.136703776 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5866:gst_rtsp_src_receive_response:<rtspsrc0> received response message
0:00:00.136736352 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5885:gst_rtsp_src_receive_response:<rtspsrc0> got response message 200
0:00:00.136763936 16954 0x5565d205e0 INFO rtspsrc gstrtspsrc.c:7364:gst_rtspsrc_retrieve_sdp:<rtspsrc0> Now using version: 1.0
0:00:00.136794016 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:7371:gst_rtspsrc_retrieve_sdp:<rtspsrc0> create describe...
0:00:00.136816096 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:7388:gst_rtspsrc_retrieve_sdp:<rtspsrc0> send describe...
0:00:00.136872896 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:476:default_before_send:<rtspsrc0> default handler
0:00:00.136897760 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:476:default_before_send:<rtspsrc0> default handler
0:00:00.136917120 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5964:gst_rtspsrc_try_send:<rtspsrc0> sending message
Progress: (open) Retrieving media info
0:00:00.142664832 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5866:gst_rtsp_src_receive_response:<rtspsrc0> received response message
0:00:00.142694656 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5885:gst_rtsp_src_receive_response:<rtspsrc0> got response message 451
0:00:00.142748704 16954 0x5565d205e0 WARN rtspsrc gstrtspsrc.c:6161:gst_rtspsrc_send:<rtspsrc0> error: Unhandled error
0:00:00.142766432 16954 0x5565d205e0 WARN rtspsrc gstrtspsrc.c:6161:gst_rtspsrc_send:<rtspsrc0> error: ERROR (451)
0:00:00.142861824 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:7514:gst_rtspsrc_retrieve_sdp:<rtspsrc0> free connection
0:00:00.142881632 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4715:gst_rtsp_conninfo_close:<rtspsrc0> closing connection...
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Unhandled error
Additional debug info:
gstrtspsrc.c(6161): gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
ERROR (451)
0:00:00.142999552 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4721:gst_rtsp_conninfo_close:<rtspsrc0> freeing connection...
ERROR: pipeline doesn't want to preroll.
Setting pipeline to PAUSED ...
0:00:00.143094272 16954 0x5565d205e0 WARN rtspsrc gstrtspsrc.c:7548:gst_rtspsrc_open:<rtspsrc0> can't get sdp
0:00:00.143167552 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:8346:gst_rtspsrc_thread:<rtspsrc0> got command LOOP
0:00:00.143190560 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4748:gst_rtspsrc_connection_flush:<rtspsrc0> set flushing 0
0:00:00.143211872 16954 0x5565d205e0 WARN rtspsrc gstrtspsrc.c:5628:gst_rtspsrc_loop:<rtspsrc0> we are not connected
0:00:00.143229376 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5636:gst_rtspsrc_loop:<rtspsrc0> pausing task, reason flushing
0:00:00.143245600 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5567:gst_rtspsrc_loop_send_cmd:<rtspsrc0> sending cmd WAIT
0:00:00.143261536 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5585:gst_rtspsrc_loop_send_cmd:<rtspsrc0> cancel previous request LOOP
0:00:00.143277120 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:5593:gst_rtspsrc_loop_send_cmd:<rtspsrc0> connection flush busy LOOP
Setting pipeline to READY ...
0:00:00.143292736 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4748:gst_rtspsrc_connection_flush:<rtspsrc0> set flushing 1
0:00:00.143406048 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:5567:gst_rtspsrc_loop_send_cmd:<rtspsrc0> sending cmd CLOSE
0:00:00.144448928 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:5593:gst_rtspsrc_loop_send_cmd:<rtspsrc0> connection flush busy WAIT
0:00:00.144490976 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:4748:gst_rtspsrc_connection_flush:<rtspsrc0> set flushing 1
0:00:00.144570816 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:8346:gst_rtspsrc_thread:<rtspsrc0> got command CLOSE
0:00:00.144601280 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:4748:gst_rtspsrc_connection_flush:<rtspsrc0> set flushing 0
Setting pipeline to NULL ...
0:00:00.144779040 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:8422:gst_rtspsrc_stop:<rtspsrc0> stopping
0:00:00.144832896 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:5567:gst_rtspsrc_loop_send_cmd:<rtspsrc0> sending cmd WAIT
0:00:00.144854048 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:5593:gst_rtspsrc_loop_send_cmd:<rtspsrc0> connection flush busy CLOSE
0:00:00.144873824 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:4748:gst_rtspsrc_connection_flush:<rtspsrc0> set flushing 1
0:00:00.144906176 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:7569:gst_rtspsrc_close:<rtspsrc0> TEARDOWN...
0:00:00.144926176 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:7574:gst_rtspsrc_close:<rtspsrc0> not ready, doing cleanup
0:00:00.144944000 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:7637:gst_rtspsrc_close:<rtspsrc0> closing connection...
0:00:00.144960768 16954 0x5565d205e0 DEBUG rtspsrc gstrtspsrc.c:2058:gst_rtspsrc_cleanup:<rtspsrc0> cleanup
0:00:00.145016928 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:7569:gst_rtspsrc_close:<rtspsrc0> TEARDOWN...
0:00:00.145036704 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:7574:gst_rtspsrc_close:<rtspsrc0> not ready, doing cleanup
0:00:00.145054016 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:7637:gst_rtspsrc_close:<rtspsrc0> closing connection...
0:00:00.145070752 16954 0x5565d95150 DEBUG rtspsrc gstrtspsrc.c:2058:gst_rtspsrc_cleanup:<rtspsrc0> cleanup
Freeing pipeline ...
That error code implies a legal issue:
451 Unavailable For Legal Reasons
The HyperText Transfer Protocol (HTTP) 451 Unavailable For Legal Reasons client error response code indicates that the user requested a resource that is not available due to legal reasons, such as a web page for which a legal action has been issued.
However, given the URL works on windows, this may be misleading and it may simply be that Ubuntu is splitting the URL at the '&' symbol.
You can out the url in single or double quotes and try again an if that is the cause that should resolve it.
Related
I am trying to stream mp4 over rtsp url and read from other terminal but facing issue Service Unavailable (503)
Server Code : Reference From
./test-launch "filesrc location=./sample.mp4 \
! qtdemux \
! h264parse \
! decodebin \
! videoconvert \
! omxh264enc insert-sps-pps=true bitrate=16000000 \
! rtph264pay name=pay0"
Server Response :
stream ready at rtsp://127.0.0.1:8554/test
Client Code :
sudo gst-launch-1.0 -v rtspsrc location=rtsp://127.0.0.1:8554/test ! rtph264depay ! h264parse ! decodebin ! videoconvert ! autovideosink sync=false
Client Response :
Setting pipeline to PAUSED ...
error: XDG_RUNTIME_DIR not set in the environment.
Pipeline is live and does not need PREROLL ...
Got context from element 'autovideosink0': gst.gl.GLDisplay=context, gst.gl.GLDisplay=(GstGLDisplay)"\(GstGLDisplayX11\)\ gldisplayx11-0";
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://127.0.0.1:8554/test
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Unhandled error
Additional debug info:
gstrtspsrc.c(6161): gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
Service Unavailable (503)
ERROR: pipeline doesn't want to preroll.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...
Im working on this project :
https://www.hackster.io/jonmendenhall/jetson-nano-search-and-rescue-ai-uav-9ca547
At some point I will need to mount my camera (waveshare ; IMX219-77IR) on top of the drone and I would like to use vlc on Windows or Linux outside of nomachine (because I have installed nomachine server on the nano and the client on windows and because it will run in headless mode),to display what the camera sees when the drone is flying. For this reason I’m trying to configure a gstreamer with RTSP to start a streaming server on the Ubuntu 18.04 that I have installed on the jetson nano.
Below u can see what are the commands that I have issued :
$ ./test-launch "videotestsrc ! nvvidconv ! nvv4l2h264enc ! h264parse ! rtph264pay name=pay0 pt=96"
And on the same Jetson Nano, I opened another console where I ran this pipeline to decode the RTSP stream:
gst-launch-1.0 uridecodebin uri=rtsp://127.0.0.1:8554/test ! nvoverlaysink
I see this picture :
The picture is from videotestsrc plugin. I would like to replace videotestsrc with my video source,but I don't know how to do that.
I tried these combinations,but none of them worked :
./test-launch "v4l2src device=/dev/video0 ! nvvidconv ! nvv4l2h264enc ! h264parse ! queue ! rtph264pay name=pay0 pt=96"
./test-launch "device=/dev/video0 ! nvvidconv ! nvv4l2h264enc ! h264parse ! queue ! rtph264pay name=pay0 pt=96"
but the error is still the same :
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://127.0.0.1:8554/test
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
ERROR: from element /GstPlayBin:playbin0/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source: Could not read from resource.
Additional debug info:
gstrtspsrc.c(5917): gst_rtsp_src_receive_response (): /GstPlayBin:playbin0/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source:
Could not receive message. (Timeout while waiting for server response)
ERROR: pipeline doesn't want to preroll.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...
but why ? I know for sure that my camera (model waveshare ; IMX219-77IR) created a device called /dev/video0 and I know for sure that it works,because this command is able to show my face on the screen :
DISPLAY=:0.0 gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), width=3280, height=2464, format=(string)NV12, framerate=(fraction)20/1' ! nvoverlaysink -e
This is the pipeline that I use to display RTSP stream:
gst-launch-1.0 location="rtsp://192.168.82.51:554/axis-media/media.amp?videocodec=h264" latency=150 drop-on-latency=true tcp-timeout=50000 timeout=200000 teardown-timeout=10000000 do-retransmission=false ! decodebin ! videoconvert ! autovideosink
and it works.
Now, if I disconnect the cabel, and then try to unref the pipeline, it blocks for like 30 seconds. Part of the log is here:
0:00:35.688277878 3264 0x7f980392d0 DEBUG udpsrc gstudpsrc.c:1024:gst_udpsrc_fill: stop called
0:00:35.688318848 3264 0x7f980392d0 DEBUG basesrc gstbasesrc.c:1558:gst_base_src_default_create:<udpsrc2> fill returned -2 (flushing)
0:00:35.688355579 3264 0x7f980392d0 DEBUG basesrc gstbasesrc.c:513:gst_base_src_wait_playing_unlocked:<udpsrc2> live source waiting for running state
0:00:35.688432490 3264 0x7f980392d0 DEBUG basesrc gstbasesrc.c:515:gst_base_src_wait_playing_unlocked:<udpsrc2> live source unlocked
0:00:35.688464780 3264 0x7f980392d0 DEBUG basesrc gstbasesrc.c:526:gst_base_src_wait_playing_unlocked:<udpsrc2> we are flushing
0:00:35.688496800 3264 0x7f980392d0 DEBUG basesrc gstbasesrc.c:2653:gst_base_src_get_range:<udpsrc2> wait_playing returned -2 (flushing)
0:00:35.688527241 3264 0x7f980392d0 INFO basesrc gstbasesrc.c:2853:gst_base_src_loop:<udpsrc2> pausing after gst_base_src_get_range() = flushing
0:00:35.688757583 3264 0x7f980392d0 DEBUG basesrc gstbasesrc.c:3025:gst_base_src_loop:<udpsrc2> pausing task, reason flushing
0:00:35.688863824 3264 0x55a5839050 DEBUG basesrc gstbasesrc.c:3696:gst_base_src_set_flushing:<udpsrc2> flushing 0
0:00:35.688900794 3264 0x55a5839050 LOG udpsrc gstudpsrc.c:1628:gst_udpsrc_unlock_stop:<udpsrc2> No longer flushing
0:00:35.688962955 3264 0x55a5839050 DEBUG basesrc gstbasesrc.c:3114:gst_base_src_set_allocation:<udpsrc2> deactivate old pool
0:00:35.689132167 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:8014:gst_rtspsrc_close:<rtspsrc0> Teardown on rtsp://192.168.82.51:554/axis-media/media.amp?videocodec=h264
0:00:35.689223448 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:522:default_before_send:<rtspsrc0> default handler
0:00:35.689257778 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:522:default_before_send:<rtspsrc0> default handler
0:00:35.689287658 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:6367:gst_rtspsrc_try_send:<rtspsrc0> sending message
0:00:35.689316158 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9380:gst_rtspsrc_print_rtsp_message:<rtspsrc0> --------------------------------------------
0:00:35.689347549 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9383:gst_rtspsrc_print_rtsp_message:<rtspsrc0> RTSP request message 0x7fa4a37608
0:00:35.689390209 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9384:gst_rtspsrc_print_rtsp_message:<rtspsrc0> request line:
0:00:35.689449340 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9385:gst_rtspsrc_print_rtsp_message:<rtspsrc0> method: 'TEARDOWN'
0:00:35.689507710 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9387:gst_rtspsrc_print_rtsp_message:<rtspsrc0> uri: 'rtsp://192.168.82.51:554/axis-media/media.amp?videocodec=h264'
0:00:35.689562511 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9388:gst_rtspsrc_print_rtsp_message:<rtspsrc0> version: '1.0'
0:00:35.689589891 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9390:gst_rtspsrc_print_rtsp_message:<rtspsrc0> headers:
0:00:35.689625322 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9363:dump_key_value:<rtspsrc0> key: 'User-Agent', value: 'GStreamer/1.16.2'
0:00:35.689652172 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9392:gst_rtspsrc_print_rtsp_message:<rtspsrc0> body:
0:00:35.689679262 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9472:gst_rtspsrc_print_rtsp_message:<rtspsrc0> --------------------------------------------
void ifm::cam::dspl::{anonymous}::OnSurfaceChange(t_ilm_surface, ilmSurfaceProperties*, t_ilm_notification_mask)
surface = 8388864
mask = 0x2
0:01:06.479647990 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9380:gst_rtspsrc_print_rtsp_message:<rtspsrc0> --------------------------------------------
0:01:06.479757301 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9402:gst_rtspsrc_print_rtsp_message:<rtspsrc0> RTSP response message 0x7fa4a37660
0:01:06.479791031 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9403:gst_rtspsrc_print_rtsp_message:<rtspsrc0> status line:
0:01:06.479831082 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9404:gst_rtspsrc_print_rtsp_message:<rtspsrc0> code: '200'
0:01:06.479861612 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9405:gst_rtspsrc_print_rtsp_message:<rtspsrc0> reason: 'OK'
0:01:06.479892352 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9406:gst_rtspsrc_print_rtsp_message:<rtspsrc0> version: '1.0
0:01:06.479922453 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9408:gst_rtspsrc_print_rtsp_message:<rtspsrc0> headers:
0:01:06.479960243 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9363:dump_key_value:<rtspsrc0> key: 'CSeq', value: '6'
0:01:06.479997163 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9363:dump_key_value:<rtspsrc0> key: 'Server', value: 'GStreamer RTSP server'
0:01:06.480032784 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9363:dump_key_value:<rtspsrc0> key: 'Session', value: '9kyYyfRp36O0tMM8; timeout=60'
0:01:06.480067724 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9363:dump_key_value:<rtspsrc0> key: 'Date', value: 'Sun, 29 Dec 2024 04:00:47 GMT'
0:01:06.480100854 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9411:gst_rtspsrc_print_rtsp_message:<rtspsrc0> body: length 0
0:01:06.480131445 3264 0x55a5839050 LOG rtspsrc gstrtspsrc.c:9472:gst_rtspsrc_print_rtsp_message:<rtspsrc0> --------------------------------------------
0:01:06.480161405 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:6269:gst_rtsp_src_receive_response:<rtspsrc0> received response message
0:01:06.480193545 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:6288:gst_rtsp_src_receive_response:<rtspsrc0> got response message 200
0:01:06.480232436 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:8041:gst_rtspsrc_close:<rtspsrc0> closing connection...
0:01:06.480264636 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:5059:gst_rtsp_conninfo_close:<rtspsrc0> closing connection...
0:01:06.480415767 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:5065:gst_rtsp_conninfo_close:<rtspsrc0> freeing connection...
0:01:06.480472408 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:2336:gst_rtspsrc_cleanup:<rtspsrc0> cleanup
0:01:06.480506128 3264 0x55a5839050 DEBUG rtspsrc gstrtspsrc.c:2272:gst_rtspsrc_stream_free:<rtspsrc0> free stream 0x7f9801d490
0:01:06.480585459 3264 0x55a5839050 DEBUG udpsrc gstudpsrc.c:1639:gst_udpsrc_close: closing sockets
0:01:06.481007963 3264 0x55a5839050 DEBUG udpsrc gstudpsrc.c:1639:gst_udpsrc_close: closing sockets
0:01:06.481383237 3264 0x55a5839050 DEBUG basesrc gstbasesrc.c:3927:gst_base_src_change_state:<fakesrc0> PLAYING->PAUSED
I tried playing with various timeouts, but nothing helped.
So, is there a way to reduce the time it takes to go from READY to NULL state?
I use gstreamer 1.16.2 version, and I read this rtspsrc reference page.
I wanted to use gstreamer for network steaming. Intention is to launch a video content (from Transmitter) and play it on receiver side.
I wrote a sample test code for steaming network content.
At transmitter side:
GST_DEBUG="*:2" gst-launch-1.0 videotestsrc ! video/x-raw ! jpegenc ! rtpjpegpay ! udpsink host=127.0.0.1 port=5001
At Receiver side:
GST_DEBUG="*:2" gst-launch-1.0 udpsrc port=5001 ! application/x-rtp,encoding-name=JPEG,payload=26 ! rtpjpegdepay ! jpegdec ! autovideosink
At receiver I'm getting following error:
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
0:00:00.130187750 4589 0x1a690a0 WARN GST_PADS gstpad.c:3669:gst_pad_peer_query: could not send sticky events
0:00:00.130796352 4589 0x1a690a0 WARN basesrc gstbasesrc.c:2865:gst_base_src_loop: error: Internal data flow error.
0:00:00.130812589 4589 0x1a690a0 WARN basesrc gstbasesrc.c:2865:gst_base_src_loop: error: streaming task paused, reason not-negotiated (-4)
ERROR: from element /GstPipeline:pipeline0/GstUDPSrc:udpsrc0: Internal data flow error.
Additional debug info:
gstbasesrc.c(2865): gst_base_src_loop (): /GstPipeline:pipeline0/GstUDPSrc:udpsrc0:
streaming task paused, reason not-negotiated (-4)
Execution ended after 0:00:00.017176721
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...
Please guide me.
(note Im using Gstreamer in Ubuntu 14.04 PC. The same PC is being for transmitter and receiver purpose.)
you need to copy paste the caps like mentioned here
I am trying to stream adpcm (G726),32kbps audio from a host to a client through
RTP:
I have tried following commands from the client(receiver) and the host(sender).
Both boards are connected through IP.
I am getting "internal data flow error" at the receiver once i run the cmds on
the sender:
RECEIVER:
gst-launch -v udpsrc port=3004 caps="application/x-rtp” ! rtpg726depay !
ffdec_g726 ! alsasink
SENDER:
gst-launch -v autoaudiosrc ! audioconvert ! audioresample ! ffenc_g726
bitrate=32000 ! rtpg726pay ! udpsink host=192.168.1.104 port=3004
If I try the same with pcm, alaw encoder and decoder, then streaming works
fine. I can hear the live audio(when I speak on sender's Microphone) into
receiver's speakerphone:
commands I am running in this case:
RECEIVER:
gst-launch udpsrc port=3004 caps="application/x-rtp" ! rtppcmadepay ! alawdec
! alsasink
SENDER:
gst-launch autoaudiosrc ! audioconvert ! audioresample ! alawenc ! rtppcmapay
! udpsink host=192.168.1.104 port=3004
This seems to be an issue in the pipeline?
here is the full error I am getting at the receiver
///////////////
root#am335x-evm:~/EVM4# gst-launch udpsrc port=3004 caps="application/x-rtp" !
rtpg726depay ! ffdec_g726 ! alsasink
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
ERROR: from element /GstPipeline:pipeline0/GstUDPSrc:udpsrc0: Internal data
flow error.
Additional debug info:
gstbasesrc.c(2625): gst_base_src_loop ():
/GstPipeline:pipeline0/GstUDPSrc:udpsrc0:
streaming task paused, reason not-negotiated (-4)
Execution ended after 20828810227 ns.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...