streaming to rtmp using avconv or ffmpeg

2

I have an IP webcam HiSilicon Hi3516C that I can successfully access from a raspberry pi. I can get still images by using a command like this:

avconv -i "rtsp://192.168.1.10:554" myfile.jpg

now instead of still images I would like to stream the video to youtube live. I have configured an event in my youtube live account and gotten a stream name and a rtmp url.

So far I have tried:

avconv -re -i rtsp://192.168.1.10:554 -r 20 -b 750 -f flv rtmp://a.rtmp.youtube.com/live2/<mystreamName>

and I get an error: RTMP_ReadPacket, failed to read RTMP packet header(full error below)

Any hint, suggestions? I know very little about, video formats, codecs and streaming in general so any help is welcome. I would not mind using ffmpeg instead if anyone knows what command to issue.


FULL ERROR:

[h264 @ 0x15a7400] RTP: missed 138 packets                                                                                                                                                          
[h264 @ 0x15a7400] RTP: missed 177 packets                                                                                                                                                          
[h264 @ 0x15a7400] RTP: missed 111 packets                                                                                                                                                          
[h264 @ 0x15a7400] RTP: missed 276 packets                                                                                                                                                          
[h264 @ 0x15a7400] RTP: missed 213 packets                                                                                                                                                          
[h264 @ 0x15a7400] RTP: missed 242 packets                                                                                                                                                          
[rtsp @ 0x15a3700] max_analyze_duration reached                                                                                                                                                     
[rtsp @ 0x15a3700] Estimating duration from bitrate, this may be inaccurate                                                                                                                         
Guessed Channel Layout for  Input Stream #0.1 : mono                                                                                                                                                
Input #0, rtsp, from 'rtsp://192.168.1.10':
  Metadata:
    title           :
    comment         : minisdp
  Duration: N/A, start: 0.040000, bitrate: N/A
    Stream #0.0: Video: h264 (Main), yuv420p, 1920x1080, 7.33 fps, 1k tbr, 90k tbn
    Stream #0.1: Audio: [0][0][0][0] / 0x0000, 8000 Hz, mono
RTMP_ReadPacket, failed to read RTMP packet header                                                                                                                                                  
rtmp://a.rtmp.youtube.com/live2p/cyrilbiz.31vj-y6k5-thpg-5tme: Unknown error occurred 

YOUTUBE INGESTION SETTINGS:

•   custom ingestion: bitrate 400kbps - 1000 kbps (360p)
•   encoder: Other encoder

WEBCAM SPECS:

Webcam: HiSilicon Hi3516C
Video Encoding
    •   H.264 baseline profile
    •   H.264 main profile Level 4.0
    •   MJPEG/JPEG baseline
Video Encoding Performance
    •   At most 2-megapixel resolution for H.264 encoding
    •   Real-time H.264&JPEG encoding of multiple types of streams: 1080p@30 fps+VGA@30 fps + JPEG snapshot 1080p@1 fps
    •   Supports constant bit rate (CBR) mode and variable bit rate (VBR) mode.
    •   Supports the output bit rate ranging from 32 Kbit/s to 40 Mbit/s.
    •   Encoding frame rate, ranging from 1/16 frame/s to 30 frame/s
    •   Eight ROIs
    •   OSD overlay of eight regions before encoding

Baba

Posted 2015-06-22T18:11:33.060

Reputation: 121

No answers