From 0644b009591f4c63ed05a8095a0c54c1501bac71 Mon Sep 17 00:00:00 2001
From: Josh Blum
Date: Wed, 9 Mar 2011 11:44:35 -0800
Subject: audio: moved the grc audio blocks into gr-audio dir

---
 gr-audio/grc/.gitignore       |  2 +
 gr-audio/grc/Makefile.am      | 29 +++++++++++++++
 gr-audio/grc/audio_sink.xml   | 86 +++++++++++++++++++++++++++++++++++++++++++
 gr-audio/grc/audio_source.xml | 86 +++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 203 insertions(+)
 create mode 100644 gr-audio/grc/.gitignore
 create mode 100644 gr-audio/grc/Makefile.am
 create mode 100644 gr-audio/grc/audio_sink.xml
 create mode 100644 gr-audio/grc/audio_source.xml

(limited to 'gr-audio/grc')

diff --git a/gr-audio/grc/.gitignore b/gr-audio/grc/.gitignore
new file mode 100644
index 000000000..b336cc7ce
--- /dev/null
+++ b/gr-audio/grc/.gitignore
@@ -0,0 +1,2 @@
+/Makefile
+/Makefile.in
diff --git a/gr-audio/grc/Makefile.am b/gr-audio/grc/Makefile.am
new file mode 100644
index 000000000..36d9daa7a
--- /dev/null
+++ b/gr-audio/grc/Makefile.am
@@ -0,0 +1,29 @@
+#
+# Copyright 2011 Free Software Foundation, Inc.
+# 
+# This file is part of GNU Radio
+# 
+# GNU Radio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+# 
+# GNU Radio is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+# 
+# You should have received a copy of the GNU General Public License
+# along with GNU Radio; see the file COPYING.  If not, write to
+# the Free Software Foundation, Inc., 51 Franklin Street,
+# Boston, MA 02110-1301, USA.
+# 
+
+include $(top_srcdir)/Makefile.common
+
+grcblocksdir = $(grc_blocksdir)
+
+dist_grcblocks_DATA = \
+	audio_source.xml \
+	audio_sink.xml
+
diff --git a/gr-audio/grc/audio_sink.xml b/gr-audio/grc/audio_sink.xml
new file mode 100644
index 000000000..26e199d61
--- /dev/null
+++ b/gr-audio/grc/audio_sink.xml
@@ -0,0 +1,86 @@
+<?xml version="1.0"?>
+<!--
+###################################################
+##Audio Sink
+###################################################
+ -->
+<block>
+	<name>Audio Sink</name>
+	<key>audio_sink</key>
+	<category>Sinks</category>
+	<import>from gnuradio import audio</import>
+	<make>audio.sink($samp_rate, $device_name, $ok_to_block)</make>
+	<param>
+		<name>Sample Rate</name>
+		<key>samp_rate</key>
+		<value>samp_rate</value>
+		<type>int</type>
+		<option>
+			<name>16KHz</name>
+			<key>16000</key>
+		</option>
+		<option>
+			<name>22.05KHz</name>
+			<key>22050</key>
+		</option>
+		<option>
+			<name>24KHz</name>
+			<key>24000</key>
+		</option>
+		<option>
+			<name>32KHz</name>
+			<key>32000</key>
+		</option>
+		<option>
+			<name>44.1KHz</name>
+			<key>44100</key>
+		</option>
+		<option>
+			<name>48KHz</name>
+			<key>48000</key>
+		</option>
+	</param>
+	<param>
+		<name>Device Name</name>
+		<key>device_name</key>
+		<value></value>
+		<type>string</type>
+		<hide>#if $device_name() then 'none' else 'part'#</hide>
+	</param>
+	<param>
+		<name>OK to Block</name>
+		<key>ok_to_block</key>
+		<value>True</value>
+		<type>enum</type>
+		<hide>part</hide>
+		<option>
+			<name>Yes</name>
+			<key>True</key>
+		</option>
+		<option>
+			<name>No</name>
+			<key>False</key>
+		</option>
+	</param>
+	<param>
+		<name>Num Inputs</name>
+		<key>num_inputs</key>
+		<value>1</value>
+		<type>int</type>
+	</param>
+	<check>0 &lt; $num_inputs</check>
+	<sink>
+		<name>in</name>
+		<type>float</type>
+		<nports>$num_inputs</nports>
+	</sink>
+	<doc>
+Not all sampling rates will be supported by your hardware.
+
+Leave the device name blank to choose deafult audio device. \
+ALSA users with audio trouble may try setting the device name to plughw:0,0
+
+The audio sink can have multiple inputs depending upon your hardware. \
+For example, set the inputs to 2 for stereo audio.
+	</doc>
+</block>
diff --git a/gr-audio/grc/audio_source.xml b/gr-audio/grc/audio_source.xml
new file mode 100644
index 000000000..59b375244
--- /dev/null
+++ b/gr-audio/grc/audio_source.xml
@@ -0,0 +1,86 @@
+<?xml version="1.0"?>
+<!--
+###################################################
+##Audio Source
+###################################################
+ -->
+<block>
+	<name>Audio Source</name>
+	<key>audio_source</key>
+	<category>Sources</category>
+	<import>from gnuradio import audio</import>
+	<make>audio.source($samp_rate, $device_name, $ok_to_block)</make>
+	<param>
+		<name>Sample Rate</name>
+		<key>samp_rate</key>
+		<value>samp_rate</value>
+		<type>int</type>
+		<option>
+			<name>16KHz</name>
+			<key>16000</key>
+		</option>
+		<option>
+			<name>22.05KHz</name>
+			<key>22050</key>
+		</option>
+		<option>
+			<name>24KHz</name>
+			<key>24000</key>
+		</option>
+		<option>
+			<name>32KHz</name>
+			<key>32000</key>
+		</option>
+		<option>
+			<name>44.1KHz</name>
+			<key>44100</key>
+		</option>
+		<option>
+			<name>48KHz</name>
+			<key>48000</key>
+		</option>
+	</param>
+	<param>
+		<name>Device Name</name>
+		<key>device_name</key>
+		<value></value>
+		<type>string</type>
+		<hide>#if $device_name() then 'none' else 'part'#</hide>
+	</param>
+	<param>
+		<name>OK to Block</name>
+		<key>ok_to_block</key>
+		<value>True</value>
+		<type>enum</type>
+		<hide>part</hide>
+		<option>
+			<name>Yes</name>
+			<key>True</key>
+		</option>
+		<option>
+			<name>No</name>
+			<key>False</key>
+		</option>
+	</param>
+	<param>
+		<name>Num Outputs</name>
+		<key>num_outputs</key>
+		<value>1</value>
+		<type>int</type>
+	</param>
+	<check>0 &lt; $num_outputs</check>
+	<source>
+		<name>out</name>
+		<type>float</type>
+		<nports>$num_outputs</nports>
+	</source>
+	<doc>
+Not all sampling rates will be supported by your hardware.
+
+Leave the device name blank to choose deafult audio device. \
+ALSA users with audio trouble may try setting the device name to plughw:0,0
+
+The audio source can have multiple outputs depending upon your hardware. \
+For example, set the outputs to 2 for stereo audio.
+	</doc>
+</block>
-- 
cgit