summaryrefslogtreecommitdiffstats
path: root/host/include
diff options
context:
space:
mode:
Diffstat (limited to 'host/include')
-rw-r--r--host/include/uhd/device_addr.hpp5
-rw-r--r--host/include/uhd/metadata.hpp8
-rw-r--r--host/include/uhd/time_spec.hpp8
-rw-r--r--host/include/uhd/transport/vrt.hpp14
-rw-r--r--host/include/uhd/usrp/dboard_id.hpp4
-rw-r--r--host/include/uhd/usrp/dboard_interface.hpp12
6 files changed, 25 insertions, 26 deletions
diff --git a/host/include/uhd/device_addr.hpp b/host/include/uhd/device_addr.hpp
index ed538453a..1b624b770 100644
--- a/host/include/uhd/device_addr.hpp
+++ b/host/include/uhd/device_addr.hpp
@@ -19,10 +19,9 @@
#define INCLUDED_UHD_DEVICE_ADDR_HPP
#include <uhd/dict.hpp>
+#include <boost/cstdint.hpp>
#include <string>
#include <iostream>
-#include <netinet/ether.h>
-#include <stdint.h>
#include <vector>
namespace uhd{
@@ -32,7 +31,7 @@ namespace uhd{
* Provides conversion between string and binary formats.
*/
struct mac_addr_t{
- struct ether_addr mac_addr;
+ boost::uint8_t mac_addr[6];
mac_addr_t(const std::string &mac_addr_str = "00:00:00:00:00:00");
std::string to_string(void) const;
};
diff --git a/host/include/uhd/metadata.hpp b/host/include/uhd/metadata.hpp
index 0588ef0ed..ce72ff14b 100644
--- a/host/include/uhd/metadata.hpp
+++ b/host/include/uhd/metadata.hpp
@@ -28,9 +28,9 @@ namespace uhd{
* The receive routines will convert IF data headers into metadata.
*/
struct rx_metadata_t{
- uint32_t stream_id;
- bool has_stream_id;
+ boost::uint32_t stream_id;
time_spec_t time_spec;
+ bool has_stream_id;
bool has_time_spec;
bool is_fragment;
@@ -44,9 +44,9 @@ struct rx_metadata_t{
* The send routines will convert the metadata to IF data headers.
*/
struct tx_metadata_t{
- uint32_t stream_id;
- bool has_stream_id;
+ boost::uint32_t stream_id;
time_spec_t time_spec;
+ bool has_stream_id;
bool has_time_spec;
bool start_of_burst;
bool end_of_burst;
diff --git a/host/include/uhd/time_spec.hpp b/host/include/uhd/time_spec.hpp
index 7e182236b..588758824 100644
--- a/host/include/uhd/time_spec.hpp
+++ b/host/include/uhd/time_spec.hpp
@@ -16,7 +16,7 @@
//
#include <boost/date_time/posix_time/posix_time.hpp>
-#include <stdint.h>
+#include <boost/cstdint.hpp>
#ifndef INCLUDED_UHD_TIME_SPEC_HPP
#define INCLUDED_UHD_TIME_SPEC_HPP
@@ -30,8 +30,8 @@ namespace uhd{
* and for controlling the start of streaming for applicable dsps.
*/
struct time_spec_t{
- uint32_t secs;
- uint32_t ticks;
+ boost::uint32_t secs;
+ boost::uint32_t ticks;
/*!
* Create a time_spec_t that holds a wildcard time.
@@ -44,7 +44,7 @@ namespace uhd{
* \param new_secs the new seconds
* \param new_ticks the new ticks (default = 0)
*/
- time_spec_t(uint32_t new_secs, uint32_t new_ticks = 0);
+ time_spec_t(boost::uint32_t new_secs, boost::uint32_t new_ticks = 0);
/*!
* Create a time_spec_t from boost posix time.
diff --git a/host/include/uhd/transport/vrt.hpp b/host/include/uhd/transport/vrt.hpp
index 1700d2785..3b5bf41bf 100644
--- a/host/include/uhd/transport/vrt.hpp
+++ b/host/include/uhd/transport/vrt.hpp
@@ -38,7 +38,7 @@ namespace vrt{
*/
void pack(
const tx_metadata_t &metadata, //input
- uint32_t *header_buff, //output
+ boost::uint32_t *header_buff, //output
size_t &num_header_words32, //output
size_t num_payload_words32, //input
size_t &num_packet_words32, //output
@@ -55,12 +55,12 @@ namespace vrt{
* \param packet_count the packet count sequence number
*/
void unpack(
- rx_metadata_t &metadata, //output
- const uint32_t *header_buff, //input
- size_t &num_header_words32, //output
- size_t &num_payload_words32, //output
- size_t num_packet_words32, //input
- size_t &packet_count //output
+ rx_metadata_t &metadata, //output
+ const boost::uint32_t *header_buff, //input
+ size_t &num_header_words32, //output
+ size_t &num_payload_words32, //output
+ size_t num_packet_words32, //input
+ size_t &packet_count //output
);
} //namespace vrt
diff --git a/host/include/uhd/usrp/dboard_id.hpp b/host/include/uhd/usrp/dboard_id.hpp
index 34406863d..62c61661c 100644
--- a/host/include/uhd/usrp/dboard_id.hpp
+++ b/host/include/uhd/usrp/dboard_id.hpp
@@ -15,15 +15,15 @@
// along with this program. If not, see <http://www.gnu.org/licenses/>.
//
+#include <boost/cstdint.hpp>
#include <string>
-#include <stdint.h>
#ifndef INCLUDED_UHD_USRP_DBOARD_ID_HPP
#define INCLUDED_UHD_USRP_DBOARD_ID_HPP
namespace uhd{ namespace usrp{
-typedef uint16_t dboard_id_t;
+typedef boost::uint16_t dboard_id_t;
static const dboard_id_t ID_NONE = 0xffff;
diff --git a/host/include/uhd/usrp/dboard_interface.hpp b/host/include/uhd/usrp/dboard_interface.hpp
index 84e1f5b22..b00643550 100644
--- a/host/include/uhd/usrp/dboard_interface.hpp
+++ b/host/include/uhd/usrp/dboard_interface.hpp
@@ -19,8 +19,8 @@
#define INCLUDED_UHD_USRP_DBOARD_INTERFACE_HPP
#include <boost/shared_ptr.hpp>
+#include <boost/cstdint.hpp>
#include <vector>
-#include <stdint.h>
namespace uhd{ namespace usrp{
@@ -33,7 +33,7 @@ namespace uhd{ namespace usrp{
class dboard_interface{
public:
typedef boost::shared_ptr<dboard_interface> sptr;
- typedef std::vector<uint8_t> byte_vector_t;
+ typedef std::vector<boost::uint8_t> byte_vector_t;
//tells the host which unit to use
enum unit_type_t{
@@ -96,7 +96,7 @@ public:
* \param rx_value 16-bits, 0=FPGA output low, 1=FPGA output high
* \param mask 16-bits, 0=software, 1=atr
*/
- virtual void set_atr_reg(gpio_bank_t bank, uint16_t tx_value, uint16_t rx_value, uint16_t mask) = 0;
+ virtual void set_atr_reg(gpio_bank_t bank, boost::uint16_t tx_value, boost::uint16_t rx_value, boost::uint16_t mask) = 0;
/*!
* Set daughterboard GPIO data direction register.
@@ -105,7 +105,7 @@ public:
* \param value 16-bits, 0=FPGA input, 1=FPGA output
* \param mask 16-bits, 0=ignore, 1=set
*/
- virtual void set_gpio_ddr(gpio_bank_t bank, uint16_t value, uint16_t mask) = 0;
+ virtual void set_gpio_ddr(gpio_bank_t bank, boost::uint16_t value, boost::uint16_t mask) = 0;
/*!
* Set daughterboard GPIO pin values.
@@ -114,7 +114,7 @@ public:
* \param value 16 bits, 0=low, 1=high
* \param mask 16 bits, 0=ignore, 1=set
*/
- virtual void write_gpio(gpio_bank_t bank, uint16_t value, uint16_t mask) = 0;
+ virtual void write_gpio(gpio_bank_t bank, boost::uint16_t value, boost::uint16_t mask) = 0;
/*!
* Read daughterboard GPIO pin values
@@ -122,7 +122,7 @@ public:
* \param bank GPIO_TX_BANK or GPIO_RX_BANK
* \return the value of the gpio bank
*/
- virtual uint16_t read_gpio(gpio_bank_t bank) = 0;
+ virtual boost::uint16_t read_gpio(gpio_bank_t bank) = 0;
/*!
* \brief Write to I2C peripheral