commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] r10899 - in gnuradio/branches/developers/eb/vrt/vrt: i


From: eb
Subject: [Commit-gnuradio] r10899 - in gnuradio/branches/developers/eb/vrt/vrt: include/vrt lib
Date: Wed, 22 Apr 2009 22:34:24 -0600 (MDT)

Author: eb
Date: 2009-04-22 22:34:24 -0600 (Wed, 22 Apr 2009)
New Revision: 10899

Added:
   gnuradio/branches/developers/eb/vrt/vrt/lib/rx_udp.cc
Modified:
   gnuradio/branches/developers/eb/vrt/vrt/include/vrt/rx_udp.h
   gnuradio/branches/developers/eb/vrt/vrt/lib/Makefile.am
Log:
work-in-progress: passes distcheck

Modified: gnuradio/branches/developers/eb/vrt/vrt/include/vrt/rx_udp.h
===================================================================
--- gnuradio/branches/developers/eb/vrt/vrt/include/vrt/rx_udp.h        
2009-04-23 04:00:37 UTC (rev 10898)
+++ gnuradio/branches/developers/eb/vrt/vrt/include/vrt/rx_udp.h        
2009-04-23 04:34:24 UTC (rev 10899)
@@ -23,6 +23,7 @@
 
 #include <boost/shared_ptr.hpp>
 #include <boost/utility.hpp>
+#include <vrt/rx_packet_handler.h>
 
 namespace vrt {
 
@@ -32,7 +33,7 @@
    * (We'll refactor this if/when we use a non-UDP transport.)
    * No VRT control issues are addressed here.
    */
-  class rx_udp : boost::nocopyable
+  class rx_udp : boost::noncopyable
   {
     int                d_socket_fd;
 
@@ -40,7 +41,7 @@
     /*!
      * Shared pointer to this class
      */ 
-    typedef boost::shared_ptr<usrp2> sptr;
+    typedef boost::shared_ptr<rx_udp> sptr;
 
     /*! 
      * \brief Static function to return an instance of rx_udp as a shared 
pointer.
@@ -69,7 +70,7 @@
      * Handler will be invoked for all available packets.
      * This function blocks until at least one packet has been processed.
      */
-    bool rx_packets(rx_sample_handler *handler);
+    bool rx_packets(rx_packet_handler *handler);
 
     /*
      * \returns the socket_fd.   Useful for select or poll.

Modified: gnuradio/branches/developers/eb/vrt/vrt/lib/Makefile.am
===================================================================
--- gnuradio/branches/developers/eb/vrt/vrt/lib/Makefile.am     2009-04-23 
04:00:37 UTC (rev 10898)
+++ gnuradio/branches/developers/eb/vrt/vrt/lib/Makefile.am     2009-04-23 
04:34:24 UTC (rev 10899)
@@ -29,7 +29,8 @@
 
 libvrt_la_SOURCES = \
        expanded_headers.cc \
-       rx_packet_handler.cc
+       rx_packet_handler.cc \
+       rx_udp.cc
 
 libvrt_la_LIBADD =
 

Added: gnuradio/branches/developers/eb/vrt/vrt/lib/rx_udp.cc
===================================================================
--- gnuradio/branches/developers/eb/vrt/vrt/lib/rx_udp.cc                       
        (rev 0)
+++ gnuradio/branches/developers/eb/vrt/vrt/lib/rx_udp.cc       2009-04-23 
04:34:24 UTC (rev 10899)
@@ -0,0 +1,54 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2009 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 this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+#include <vrt/rx_udp.h>
+#include <unistd.h>
+
+namespace vrt {
+  
+  rx_udp::sptr
+  rx_udp::make(int socket_fd)
+  {
+    return sptr(new rx_udp(socket_fd));
+  }
+
+  rx_udp::rx_udp(int socket_fd)
+    : d_socket_fd(socket_fd)
+  {
+  }
+
+  rx_udp::~rx_udp()
+  {
+    ::close(d_socket_fd);
+  }
+
+
+  bool
+  rx_udp::rx_packets(rx_packet_handler *handler)
+  {
+    // FIXME do something ;-)
+
+    return true;
+  }
+
+}; // vrt


Property changes on: gnuradio/branches/developers/eb/vrt/vrt/lib/rx_udp.cc
___________________________________________________________________
Added: svn:eol-style
   + native





reply via email to

[Prev in Thread] Current Thread [Next in Thread]