首页 > 解决方案 > 使用 GStreamer 从 Pepper 机器人录制音频

问题描述

我正在使用来自 SoftBank Robotics 的 Pepper 机器人和 GStreamer 用于 RTP 流。我需要录制机器人的音频。我在我的计算机上使用 gstreamer1.0,并且在机器人上安装了 gstreamer0.10。这是我使用的命令行:

胡椒:

gst-launch-0.10 alsasrc name=mic provide-clock=true do-timestamp=true buffer-time=200000 mic. ! 'audio/x-raw-int, format=S16LE; channels=1, width=16, depth=16, rate=16000' ! udpsink host="computer_adress" port="speaker_port" sync=false

计算机:

gst-launch-1.0 -e udpsrc port="speaker_port" ! audio/x-raw, width=16, depth=16, rate=16000, channels=1 format=S16LE ! audioconvert ! filesink location=audio_file_name.mp3 sync=false

使用这些命令,我​​只能得到一个 mp3 文件,但其中没有声音。我知道有些事情是不正确的,但我不知道是什么。我是 Gstreamer 和 RTP 协议的初学者。有人可以帮我吗?也许可以解释一下如何使用机器人的 RTP 流式传输音频。

对不起,如果我犯了任何英语写作错误。

谢谢你的帮助。

标签: audiogstreameraudio-recordingrobotpepper

解决方案


推荐阅读