[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] r3844 - in gnuradio/branches/developers/eb/power: . co
From: |
eb |
Subject: |
[Commit-gnuradio] r3844 - in gnuradio/branches/developers/eb/power: . config gr-error-correcting-codes/src/lib gr-error-correcting-codes/src/lib/libecc gr-howto-write-a-block gr-howto-write-a-block/config gr-howto-write-a-block/src/lib |
Date: |
Tue, 24 Oct 2006 14:46:10 -0600 (MDT) |
Author: eb
Date: 2006-10-24 14:46:10 -0600 (Tue, 24 Oct 2006)
New Revision: 3844
Modified:
gnuradio/branches/developers/eb/power/config/gr_boost.m4
gnuradio/branches/developers/eb/power/configure.ac
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.cc
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.h
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.i
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/libecc/code_metrics.cc
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/README
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/config/gr_boost.m4
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/src/lib/Makefile.am
Log:
merged trunk r3777:3834 into branch
Modified: gnuradio/branches/developers/eb/power/config/gr_boost.m4
===================================================================
--- gnuradio/branches/developers/eb/power/config/gr_boost.m4 2006-10-24
17:41:15 UTC (rev 3843)
+++ gnuradio/branches/developers/eb/power/config/gr_boost.m4 2006-10-24
20:46:10 UTC (rev 3844)
@@ -43,8 +43,8 @@
[path to boost c++ include files]),
[
# "yes" and "no" are bogus answers
- if test x"$with_boost_include_dir" == xyes ||
- test x"$with_boost_include_dir" == xno; then
+ if test x"$with_boost_include_dir" = xyes ||
+ test x"$with_boost_include_dir" = xno; then
gr_boost_include_dir=
else
gr_boost_include_dir=$with_boost_include_dir
Modified: gnuradio/branches/developers/eb/power/configure.ac
===================================================================
--- gnuradio/branches/developers/eb/power/configure.ac 2006-10-24 17:41:15 UTC
(rev 3843)
+++ gnuradio/branches/developers/eb/power/configure.ac 2006-10-24 20:46:10 UTC
(rev 3844)
@@ -171,7 +171,7 @@
GRC_GR_AUDIO_WINDOWS
GRC_GR_ATSC
GRC_GR_COMEDI
-#GRC_GR_ERROR_CORRECTING_CODES
+GRC_GR_ERROR_CORRECTING_CODES
GRC_GR_GSM_FR_VOCODER
GRC_GR_RADAR
GRC_GR_RADIO_ASTRONOMY
Modified:
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.cc
===================================================================
---
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.cc
2006-10-24 17:41:15 UTC (rev 3843)
+++
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.cc
2006-10-24 20:46:10 UTC (rev 3844)
@@ -29,11 +29,11 @@
#include <assert.h>
ecc_syms_to_metrics_sptr
-ecc_make_syms_to_metrics (gr_feval_ff* pdf_fcn_0_bit,
- gr_feval_ff* pdf_fcn_1_bit,
+ecc_make_syms_to_metrics (gr_feval_dd* pdf_fcn_0_bit,
+ gr_feval_dd* pdf_fcn_1_bit,
int n_samples,
- float min_sample,
- float max_sample,
+ double min_sample,
+ double max_sample,
int sample_precision)
{
return ecc_syms_to_metrics_sptr
@@ -46,29 +46,29 @@
}
/*
- * dummy functions and variables to get the float(*)(float) function
+ * dummy functions and variables to get the double(*)(double) function
* to work properly with the gr_feval_XX stuff.
*/
-static gr_feval_ff* l_pdf_fcn_0_bit;
-static gr_feval_ff* l_pdf_fcn_1_bit;
+static gr_feval_dd* l_pdf_fcn_0_bit;
+static gr_feval_dd* l_pdf_fcn_1_bit;
-static float pdf_fcn_0 (float x)
+static double pdf_fcn_0 (double x)
{
return (l_pdf_fcn_0_bit->eval (x));
}
-static float pdf_fcn_1 (float x)
+static double pdf_fcn_1 (double x)
{
return (l_pdf_fcn_1_bit->eval (x));
}
ecc_syms_to_metrics::ecc_syms_to_metrics
-(gr_feval_ff* pdf_fcn_0_bit,
- gr_feval_ff* pdf_fcn_1_bit,
+(gr_feval_dd* pdf_fcn_0_bit,
+ gr_feval_dd* pdf_fcn_1_bit,
int n_samples,
- float min_sample,
- float max_sample,
+ double min_sample,
+ double max_sample,
int sample_precision)
: gr_block ("syms_to_metrics",
gr_make_io_signature (1, -1, sizeof (float)),
@@ -84,7 +84,7 @@
// use the static "create" member function to create the actual
// code_metrics to use.
- d_code_metrics_table = libecc_code_metrics_create_table<float>
+ d_code_metrics_table = libecc_code_metrics_create_table<double>
(&pdf_fcn_0,
&pdf_fcn_1,
n_samples,
@@ -132,7 +132,7 @@
size_t l_n_output_items = noutput_items;
for (size_t n = 0; n < input_items.size(); n++) {
- float* t_in_buf = (float*)(&input_items[n]);
+ double* t_in_buf = (double*)(&input_items[n]);
void* t_out_buf_0_bit = (void*)(&(output_items[2*n]));
void* t_out_buf_1_bit = (void*)(&(output_items[(2*n)+1]));
d_code_metrics_table->convert (l_n_output_items, t_in_buf,
Modified:
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.h
===================================================================
---
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.h
2006-10-24 17:41:15 UTC (rev 3843)
+++
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.h
2006-10-24 20:46:10 UTC (rev 3844)
@@ -32,11 +32,11 @@
typedef boost::shared_ptr<ecc_syms_to_metrics> ecc_syms_to_metrics_sptr;
ecc_syms_to_metrics_sptr ecc_make_syms_to_metrics
-(gr_feval_ff* pdf_fcn_0_bit,
- gr_feval_ff* pdf_fcn_1_bit,
+(gr_feval_dd* pdf_fcn_0_bit,
+ gr_feval_dd* pdf_fcn_1_bit,
int n_samples,
- float min_sample,
- float max_sample,
+ double min_sample,
+ double max_sample,
int sample_precision);
/*!
@@ -53,11 +53,11 @@
{
protected:
friend ecc_syms_to_metrics_sptr
- ecc_make_syms_to_metrics (gr_feval_ff* pdf_fcn_0_bit,
- gr_feval_ff* pdf_fcn_1_bit,
+ ecc_make_syms_to_metrics (gr_feval_dd* pdf_fcn_0_bit,
+ gr_feval_dd* pdf_fcn_1_bit,
int n_samples,
- float min_sample,
- float max_sample,
+ double min_sample,
+ double max_sample,
int sample_precision);
/*
@@ -70,10 +70,10 @@
* faster processing.
*
* pdf_fcn_0_bit: point to a probability distribution function which
- * takes a float and returns a float, for the 0-bit probabilities.
+ * takes a double and returns a double, for the 0-bit probabilities.
*
* pdf_fcn_1_bit: point to a probability distribution function which
- * takes a float and returns a float, for the 1-bit probabilities.
+ * takes a double and returns a double, for the 1-bit probabilities.
*
* n_samples: the number of samples between min_sample and max_sample
* to store in the lookup table. Must be at least 2, but
@@ -98,15 +98,15 @@
*
*/
- ecc_syms_to_metrics (gr_feval_ff* pdf_fcn_0_bit,
- gr_feval_ff* pdf_fcn_1_bit,
+ ecc_syms_to_metrics (gr_feval_dd* pdf_fcn_0_bit,
+ gr_feval_dd* pdf_fcn_1_bit,
int n_samples,
- float min_sample,
- float max_sample,
+ double min_sample,
+ double max_sample,
int sample_precision);
size_t d_out_item_size_bytes;
- code_metrics_table<float>* d_code_metrics_table;
+ code_metrics_table<double>* d_code_metrics_table;
public:
~ecc_syms_to_metrics() {delete d_code_metrics_table;};
Modified:
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.i
===================================================================
---
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.i
2006-10-24 17:41:15 UTC (rev 3843)
+++
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/ecc_syms_to_metrics.i
2006-10-24 20:46:10 UTC (rev 3844)
@@ -23,19 +23,19 @@
GR_SWIG_BLOCK_MAGIC(ecc,syms_to_metrics);
ecc_syms_to_metrics_sptr ecc_make_syms_to_metrics
-(gr_feval_ff* pdf_fcn_0_bit,
- gr_feval_ff* pdf_fcn_1_bit,
+(gr_feval_dd* pdf_fcn_0_bit,
+ gr_feval_dd* pdf_fcn_1_bit,
int n_samples,
- float min_sample,
- float max_sample,
+ double min_sample,
+ double max_sample,
int sample_precision);
class ecc_syms_to_metrics : public gr_block
{
- ecc_syms_to_metrics (gr_feval_ff* pdf_fcn_0_bit,
- gr_feval_ff* pdf_fcn_1_bit,
+ ecc_syms_to_metrics (gr_feval_dd* pdf_fcn_0_bit,
+ gr_feval_dd* pdf_fcn_1_bit,
int n_samples,
- float min_sample,
- float max_sample,
+ double min_sample,
+ double max_sample,
int sample_precision);
};
Modified:
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/libecc/code_metrics.cc
===================================================================
---
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/libecc/code_metrics.cc
2006-10-24 17:41:15 UTC (rev 3843)
+++
gnuradio/branches/developers/eb/power/gr-error-correcting-codes/src/lib/libecc/code_metrics.cc
2006-10-24 20:46:10 UTC (rev 3844)
@@ -339,6 +339,16 @@
float max_sample,
int sample_precision);
+template
+code_metrics_table<double>*
+libecc_code_metrics_create_table<double>
+(double (*pdf_fcn_0_bit) (double),
+ double (*pdf_fcn_1_bit) (double),
+ size_t n_samples,
+ double min_sample,
+ double max_sample,
+ int sample_precision);
+
#if 0
// for compute_all_outputs
Modified: gnuradio/branches/developers/eb/power/gr-howto-write-a-block/README
===================================================================
--- gnuradio/branches/developers/eb/power/gr-howto-write-a-block/README
2006-10-24 17:41:15 UTC (rev 3843)
+++ gnuradio/branches/developers/eb/power/gr-howto-write-a-block/README
2006-10-24 20:46:10 UTC (rev 3844)
@@ -1,5 +1,5 @@
#
-# Copyright 2005 Free Software Foundation, Inc.
+# Copyright 2005, 2006 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
@@ -23,6 +23,9 @@
demonstrate how to write signal processing blocks for the GNU Radio
system.
+This package requires that gnuradio-core is already installed. It
+also depends on some GNU Radio prerequisites, such as boost.
+
To build the examples from the tarball use the normal recipe:
$ ./configure
Modified:
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/config/gr_boost.m4
===================================================================
---
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/config/gr_boost.m4
2006-10-24 17:41:15 UTC (rev 3843)
+++
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/config/gr_boost.m4
2006-10-24 20:46:10 UTC (rev 3844)
@@ -43,8 +43,8 @@
[path to boost c++ include files]),
[
# "yes" and "no" are bogus answers
- if test x"$with_boost_include_dir" == xyes ||
- test x"$with_boost_include_dir" == xno; then
+ if test x"$with_boost_include_dir" = xyes ||
+ test x"$with_boost_include_dir" = xno; then
gr_boost_include_dir=
else
gr_boost_include_dir=$with_boost_include_dir
Modified:
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/src/lib/Makefile.am
===================================================================
---
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/src/lib/Makefile.am
2006-10-24 17:41:15 UTC (rev 3843)
+++
gnuradio/branches/developers/eb/power/gr-howto-write-a-block/src/lib/Makefile.am
2006-10-24 20:46:10 UTC (rev 3844)
@@ -73,7 +73,7 @@
-lstdc++
howto.cc howto.py: howto.i $(ALL_IFILES)
- $(SWIG) $(SWIGPYTHONARGS) -module howto -o howto.cc $<
+ $(SWIG) $(SWIGPYTHONARGS) -module howto -o howto.cc howto.i
# These headers get installed in ${prefix}/include/gnuradio
grinclude_HEADERS = \
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Commit-gnuradio] r3844 - in gnuradio/branches/developers/eb/power: . config gr-error-correcting-codes/src/lib gr-error-correcting-codes/src/lib/libecc gr-howto-write-a-block gr-howto-write-a-block/config gr-howto-write-a-block/src/lib,
eb <=