Skip to content

Commit

Permalink
Imported upstream version '0.3.18' of 'upstream'
Browse files Browse the repository at this point in the history
  • Loading branch information
knorth55 committed Aug 13, 2024
1 parent eb1c34c commit 353197d
Show file tree
Hide file tree
Showing 12 changed files with 57 additions and 7 deletions.
3 changes: 3 additions & 0 deletions audio_capture/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
Changelog for package audio_capture
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

0.3.18 (2024-08-13)
-------------------

0.3.17 (2023-06-08)
-------------------
* Merge pull request `#220 <https://github.com/ros-drivers/audio_common/issues/220>`_ from v4hn/master
Expand Down
2 changes: 1 addition & 1 deletion audio_capture/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<package>
<name>audio_capture</name>
<version>0.3.17</version>
<version>0.3.18</version>
<description>
Transports audio from a source to a destination. Audio sources can come
from a microphone or file. The destination can play the audio or save it
Expand Down
3 changes: 3 additions & 0 deletions audio_common/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
Changelog for package audio_common
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

0.3.18 (2024-08-13)
-------------------

0.3.17 (2023-06-08)
-------------------

Expand Down
2 changes: 1 addition & 1 deletion audio_common/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<package>
<name>audio_common</name>
<version>0.3.17</version>
<version>0.3.18</version>
<description>
Common code for working with audio in ROS
</description>
Expand Down
3 changes: 3 additions & 0 deletions audio_common_msgs/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
Changelog for package audio_common_msgs
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

0.3.18 (2024-08-13)
-------------------

0.3.17 (2023-06-08)
-------------------

Expand Down
2 changes: 1 addition & 1 deletion audio_common_msgs/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<package>
<name>audio_common_msgs</name>
<version>0.3.17</version>
<version>0.3.18</version>
<description>
Messages for transmitting audio via ROS
</description>
Expand Down
6 changes: 6 additions & 0 deletions audio_play/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
Changelog for package audio_play
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

0.3.18 (2024-08-13)
-------------------
* Merge pull request `#238 <https://github.com/ros-drivers/audio_common/issues/238>`_ from Kanazawanaoaki/add-record-to-file-launch
* Add record to file launch
* Contributors: Kanazawanaoaki, Shingo Kitagawa

0.3.17 (2023-06-08)
-------------------

Expand Down
25 changes: 25 additions & 0 deletions audio_play/launch/record_to_file.launch
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<launch>
<arg name="dst" default="/tmp/output_audio.mp3"/>
<arg name="device" default=""/>
<arg name="do_timestamp" default="false"/>
<arg name="format" default="mp3"/>
<arg name="channels" default="1"/>
<arg name="depth" default="16"/>
<arg name="sample_rate" default="16000"/>
<arg name="sample_format" default="S16LE"/>
<arg name="ns" default="audio"/>
<arg name="audio_topic" default="audio" />

<include file="$(find audio_play)/launch/play.launch">
<arg name="dst" value="$(arg dst)"/>
<arg name="device" value="$(arg device)"/>
<arg name="do_timestamp" value="$(arg do_timestamp)"/>
<arg name="format" value="$(arg format)"/>
<arg name="channels" value="$(arg channels)"/>
<arg name="depth" value="$(arg depth)"/>
<arg name="sample_rate" value="$(arg sample_rate)"/>
<arg name="sample_format" value="$(arg sample_format)"/>
<arg name="ns" value="$(arg ns)"/>
<arg name="audio_topic" value="$(arg audio_topic)" />
</include>
</launch>
2 changes: 1 addition & 1 deletion audio_play/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<package>
<name>audio_play</name>
<version>0.3.17</version>
<version>0.3.18</version>
<description>
Outputs audio to a speaker from a source node.
</description>
Expand Down
7 changes: 7 additions & 0 deletions sound_play/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@
Changelog for package sound_play
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

0.3.18 (2024-08-13)
-------------------
* Merge pull request `#249 <https://github.com/ros-drivers/audio_common/issues/249>`_ from peci1/patch-1
festival_plugin: add support for different encodings
* festival_plugin: add support for different encodings
* Contributors: Martin Pecka, Shingo Kitagawa

0.3.17 (2023-06-08)
-------------------
* Merge pull request `#231 <https://github.com/ros-drivers/audio_common/issues/231>`_ from knorth55/no-wait-mode
Expand Down
2 changes: 1 addition & 1 deletion sound_play/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>sound_play</name>
<version>0.3.17</version>
<version>0.3.18</version>
<description>
sound_play provides a ROS node that translates commands on a ROS topic (<tt>robotsound</tt>) into sounds. The node supports built-in sounds, playing OGG/WAV files, and doing speech synthesis via festival. C++ and Python bindings allow this node to be used without understanding the details of the message format, allowing faster development and resilience to message format changes.
</description>
Expand Down
7 changes: 5 additions & 2 deletions sound_play/src/sound_play/festival_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ def __init__(self):
def sound_play_say_plugin(self, text, voice):
if voice is None or voice == '':
voice = self._default_voice
encoding = 'ISO-8859-15'
if ':' in voice:
voice, encoding = voice.split(':', maxsplit=1)
txtfile = tempfile.NamedTemporaryFile(
prefix='sound_play', suffix='.txt')
(wavfile, wavfilename) = tempfile.mkstemp(
Expand All @@ -26,10 +29,10 @@ def sound_play_say_plugin(self, text, voice):
try:
if hasattr(text, 'decode'):
txtfile.write(
text.decode('UTF-8').encode('ISO-8859-15'))
text.decode('UTF-8').encode(encoding))
else:
txtfile.write(
text.encode('ISO-8859-15'))
text.encode(encoding))
except UnicodeEncodeError:
if hasattr(text, 'decode'):
txtfile.write(text)
Expand Down

0 comments on commit 353197d

Please sign in to comment.