aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/usrp2/usrp2_impl.cpp
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-07-07 23:48:09 -0700
committerJosh Blum <josh@joshknows.com>2010-07-07 23:48:09 -0700
commitc72bc56ba6d5b0457f03967a8f8d8e5602fdf14d (patch)
tree13acfd23ac9906977c8364044e4cf0f90fb389a7 /host/lib/usrp/usrp2/usrp2_impl.cpp
parentbe430761fb7e526e80b67d70e3cf488c6dd02495 (diff)
downloaduhd-c72bc56ba6d5b0457f03967a8f8d8e5602fdf14d.tar.gz
uhd-c72bc56ba6d5b0457f03967a8f8d8e5602fdf14d.tar.bz2
uhd-c72bc56ba6d5b0457f03967a8f8d8e5602fdf14d.zip
usrp2: moved common defined for udp mtu and implemented change.
The uhp mtu is now defined in uhd_simple.hpp. The fw common code does not need to know this information. Fixed a calculation bug in the usrp2 impl code for max samples.
Diffstat (limited to 'host/lib/usrp/usrp2/usrp2_impl.cpp')
-rw-r--r--host/lib/usrp/usrp2/usrp2_impl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/host/lib/usrp/usrp2/usrp2_impl.cpp b/host/lib/usrp/usrp2/usrp2_impl.cpp
index 3402c26b1..9d1ac991f 100644
--- a/host/lib/usrp/usrp2/usrp2_impl.cpp
+++ b/host/lib/usrp/usrp2/usrp2_impl.cpp
@@ -99,8 +99,8 @@ static uhd::device_addrs_t usrp2_find(const device_addr_t &hint){
udp_transport->send(boost::asio::buffer(&ctrl_data_out, sizeof(ctrl_data_out)));
//loop and recieve until the timeout
- boost::uint8_t usrp2_ctrl_data_in_mem[USRP2_UDP_BYTES]; //allocate max bytes for recv
- usrp2_ctrl_data_t *ctrl_data_in = reinterpret_cast<usrp2_ctrl_data_t *>(usrp2_ctrl_data_in_mem);
+ boost::uint8_t usrp2_ctrl_data_in_mem[udp_simple::mtu]; //allocate max bytes for recv
+ const usrp2_ctrl_data_t *ctrl_data_in = reinterpret_cast<const usrp2_ctrl_data_t *>(usrp2_ctrl_data_in_mem);
while(true){
size_t len = udp_transport->recv(asio::buffer(usrp2_ctrl_data_in_mem));
//std::cout << len << "\n";