[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] r5672 - gnuradio/branches/developers/gnychis/inband/us
From: |
gnychis |
Subject: |
[Commit-gnuradio] r5672 - gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband |
Date: |
Mon, 4 Jun 2007 16:07:28 -0600 (MDT) |
Author: gnychis
Date: 2007-06-04 16:07:27 -0600 (Mon, 04 Jun 2007)
New Revision: 5672
Modified:
gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband/usrp_usb_interface_stub.cc
gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband/usrp_usb_interface_stub.h
Log:
Work-in-progress before starting RX and TX m-blocks
Modified:
gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband/usrp_usb_interface_stub.cc
===================================================================
---
gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband/usrp_usb_interface_stub.cc
2007-06-04 21:51:21 UTC (rev 5671)
+++
gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband/usrp_usb_interface_stub.cc
2007-06-04 22:07:27 UTC (rev 5672)
@@ -38,6 +38,7 @@
static pmt_t s_cmd_usrp_write = pmt_intern("cmd-usrp-write");
static pmt_t s_cmd_usrp_ntx_chan = pmt_intern("cmd-usrp-ntx-chan");
static pmt_t s_cmd_usrp_nrx_chan = pmt_intern("cmd-usrp-nrx-chan");
+static pmt_t s_cmd_usrp_start_reading = pmt_intern("cmd-usrp-start-reading");
static pmt_t s_response_usrp_ntx_chan = pmt_intern("response-usrp-ntx-chan");
static pmt_t s_response_usrp_nrx_chan = pmt_intern("response-usrp-nrx-chan");
static pmt_t s_response_usrp_open = pmt_intern("response-usrp-open");
@@ -86,31 +87,42 @@
pmt_t data = msg->data();
pmt_t invocation_handle;
- // message came in on our control/status port
+ //------------- CONTROL / STATUS -------------//
if (pmt_eq(port_id, d_cs->port_symbol())) {
+ //------------ OPEN --------------//
if (pmt_eq(event, s_cmd_usrp_open)){
handle_cmd_open(data);
return;
}
+ //----------- CLOSE -------------//
else if (pmt_eq(event, s_cmd_usrp_close)) {
handle_cmd_close(data);
return;
}
+ //---------- NTX CHAN ----------//
else if (pmt_eq(event, s_cmd_usrp_ntx_chan)) {
invocation_handle = pmt_nth(0, data);
d_cs->send(s_response_usrp_ntx_chan, pmt_list2(invocation_handle,
pmt_from_long(d_ntx_chan)));
return;
}
+ //---------- NRX CHAN ----------//
else if (pmt_eq(event, s_cmd_usrp_nrx_chan)) {
invocation_handle = pmt_nth(0, data);
d_cs->send(s_response_usrp_nrx_chan, pmt_list2(invocation_handle,
pmt_from_long(d_nrx_chan)));
return;
}
+ //------------ WRITE -----------//
else if(pmt_eq(event, s_cmd_usrp_write)) {
handle_cmd_write(data);
return;
}
+ //-------- START READING --------//
+ else if(pmt_eq(event, s_cmd_usrp_start_reading)) {
+ handle_cmd_start_reading(data);
+ return;
+ }
+
goto unhandled;
}
@@ -143,9 +155,6 @@
size_t n_bytes;
- size_t psize;
- bool underrun; // this will need to go, as it is taken care of in the
packet headers
-
d_cs->send(s_response_usrp_write, pmt_list3(invocation_handle,
pmt_from_long(channel), PMT_T));
if (verbose)
@@ -165,6 +174,14 @@
}
void
+usrp_usb_interface_stub::handle_cmd_start_reading(pmt_t data)
+{
+ pmt_t invocation_handle = pmt_nth(0, data);
+
+ return;
+}
+
+void
usrp_usb_interface_stub::handle_cmd_close(pmt_t data)
{
pmt_t invocation_handle = pmt_nth(0, data);
Modified:
gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband/usrp_usb_interface_stub.h
===================================================================
---
gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband/usrp_usb_interface_stub.h
2007-06-04 21:51:21 UTC (rev 5671)
+++
gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband/usrp_usb_interface_stub.h
2007-06-04 22:07:27 UTC (rev 5672)
@@ -54,6 +54,7 @@
void handle_cmd_open(pmt_t data);
void handle_cmd_close(pmt_t data);
void handle_cmd_write(pmt_t data);
+ void handle_cmd_start_reading(pmt_t data);
};
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Commit-gnuradio] r5672 - gnuradio/branches/developers/gnychis/inband/usrp/host/lib/inband,
gnychis <=