| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
The prefs API is supposed to load the config files once, and stash them
away for the process to consume at will. Because the init_done is never
set, it will read the config files every time it's asked for them. This
is usually not a problem, but it causes the logging output to be messy.
|
|
|
|
|
|
| |
The filter bank and antenna switches have different configuration
for channel 0 and channel 1. This commit fixes the issue where
channel 0 produces only noise due to incorrect switches.
|
|
|
|
|
|
| |
Only update DDC/DUC samp_rate properties if the number is substantially
different (don't update for sub-1Hz property calculations). This fixes
resolver exceptions for certain rates.
|
| |
|
| |
|
|
|
|
|
| |
This is a more portable option to set thread names. References to
pthreads are now limited to thread.cpp, where they belong.
|
|
|
|
|
| |
We call set_thread_name() on the claimer loop so the thread can be
identified using OS utilities.
|
|
|
|
| |
Signed-off-by: Virendra Kakade <virendra.kakade@ni.com>
|
|
|
|
| |
Signed-off-by: Virendra Kakade <virendra.kakade@ni.com>
|
|
|
|
|
|
|
| |
This fixes behavior where we would get long 100 sec timeouts
on fifo waits instead of 100 ms timeouts.
Signed-off-by: Virendra Kakade <virendra.kakade@ni.com>
|
|
|
|
|
| |
Individual API calls might have to call each other (e.g., like
set_rate() will call set_rx_frequency()), which would cause a deadlock.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The N310 cannot set the MCR for its daughterboards separately. This
patch modifies the radio block controller such that any block
controller, when requested to change the master clock rate, will first
change Radio 0, and then Radio 1.
This fixes the following issues:
- In multi_usrp, calling set_master_clock_rate() will not necessarily
call set_rate() on the radios in any particular order, which will
break when calling Radio 1 first
- In RFNoC apps, it wasn't possible to run off of slot B alone without
this change.
Note: When calling set_rate() on one radio, the other radio is in an
invalid state until its set_rate() is also called.
|
|
|
|
|
|
|
| |
This is a data structure intended for use by the DPDK I/O service.
It uses DPDK's lockless ring in multi-producer, single-consumer mode
to allow clients to submit requests to the DPDK I/O service's worker
thread. Clients can specify a timeout for the requests to be fulfilled.
|
| |
|
|
|
|
|
| |
It used to produce the individual name of the USRP, but it should return
a product name.
|
|
|
|
|
| |
This enables the use of the dboard and FP GPIOs. The problem was that
the register offset of 8 was not encoded.
|
|
|
|
|
| |
- Move the SPI addresses out of radio_control_impl
- Fix the GPIO address spaces for N310/N300
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes a bug where get_gpio_attr(bank, "CTRL") would return the
inverted value of what was written. Reason is that the underlying
register was an ATR disable register.
The fix is to invert the cached values of the register.
Now, the following Python code will work:
>>> U = uhd.usrp.MultiUSRP("type=x300")
>>> atr_enable = 0xF # Enable ATR on lower 4 pins, rest is GPIO
>>> U.set_gpio_attr("FP0A", "CTRL", atr_enable)
>>> U.get_gpio_attr("FP0A", "CTRL") == atr_enable
True
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the existing graph, when the shutdown was simply a release. However,
any outstanding actions would trigger warnings (because released graphs
aren't supposed to still have actions being passed around), which would
sometimes be visible at the end of an application.
This is a safer solution than simply releasing, because it explicitly
sets a shutdown flag that all graph-affecting functions (property
propagation and action handling) respect. Once the flag is set, the
graph can no longer be booted up again.
|
|
|
|
|
|
|
|
|
|
|
| |
- Remove superfluous INFO logging
- Improve formatting in many places
- Improve Pylint score in various places
- Add tear_down to DB object
- Simplify custom EEPROM code for E310
- Fix time source selection code
- Remove references to GPS_CTRL and GPS_STATUS (are E320 only)
- Move clock source control out of MboardRegs object
|
|
|
|
|
| |
This removes the token requirement for get_proto_ver() and
get_chdr_width().
|
|
|
|
|
|
| |
Rename thread affinity args such that they do not end with an integer.
Arg names ending with an integer are interpreted as being targeted at a
specific motherboard index in device_addr methods.
|
|
|
|
|
|
| |
Allow device args that contain an integer within the name, such as
recv_offload_thread_0_cpu. Previously this would cause an invalid format
exception.
|
|
|
|
| |
The DPDK files are left behind as a reference, for now.
|
|
|
|
|
|
|
|
|
|
|
|
| |
dpdk_ctx represents the central context and manager of all memory
and threads allocated via the DPDK EAL. In this commit, it parses
the user's arguments, configures all the ports, and brings them up.
dpdk_port represents each DPDK NIC port's configuration, and it
manages the allocation of individual queues and their flow rules.
It also would provide access to an ARP table and functions for
handling ARP requests and responses. The flow rules and ARP
functions are not yet implemented.
|
|
|
|
|
| |
Swap out hyphens for underscores in the DPDK args. Also update list
of distributions with the correct DPDK version in the repos.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With this patch, the elements of of the return value of find_blocks()
are sorted lexicographically (specifically, using
uhd::rfnoc::block_id_it::operator<()).
The underlying block_container class stores the blocks in an unordered
set, so the return value for find_blocks() was always sorted randomly.
multi_usrp_rfnoc had to sort the return values every time find_blocks()
was used to get a useful return value.
Because find_blocks() had no contract for the order of returned blocks,
this change simply sorts the return value before returning it.
multi_usrp_rfnoc is modified to remove all the sorts that are now
superfluous.
A good way to see the change is to run uhd_usrp_probe, which will now
contain content like this:
| _____________________________________________________
| /
| | RFNoC blocks on this device:
| |
| | * 0/DDC#0
| | * 0/DDC#1
| | * 0/DUC#0
| | * 0/DUC#1
| | * 0/DmaFIFO#0
| | * 0/Radio#0
| | * 0/Radio#1
Assuming the blocks don't change, the order of this list will always be
the same following this patch. Note that the order is unrelated to the
order on the control crossbar, which it never was.
|
|
|
|
|
|
|
|
|
|
| |
When calling a multi_usrp object like this:
usrp->set_gpio_attr("TXB", "CTRL", 0xFFFF);
Previously, it would only be able to address daughterboard A. Now, there
is a full backward-compatible solution (compatible with 3.15), that will
address either daughterboard's GPIOs.
|
|
|
|
| |
Fixes 85f0551 ("rfnoc: Add I/O service manager to X300 and MPMD")
|
|
|
|
|
|
| |
Add a new method to io_service::send_io to check whether the destination
is ready for data, to make it possible to poll send_io rather than block
waiting for flow control credits.
|
| |
|
|
|
|
|
|
|
|
| |
This API call is a more explicit way of setting the spp than passing in
an spp value in the args of the stream args when creating streamers. For
pre-RFNoC devices, this is done by injecting the spp arg back into the
stream args. For RFNoC devices, the set_property() call on the radio is
called.
|
|
|
|
|
|
|
|
| |
SEPs on the FPGA can only occupy multiples of the CHDR width in their
FIFOs, unlike SW, where buffers are stored in RAM and can be aligned
anyhow. Therefore, we align the counting of bytes for FC purpose and
count multiples of CHDR width instead of the true number of bytes per
packet.
|
|
|
|
|
| |
For links that do not support releasing buffers out of order, restrict
the I/O service manager to always select the inline I/O service.
|
| |
|
|
|
|
|
| |
This makes it possible for users to put I/O service-related args in
either the device args or stream args.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This replaces all of the following with standard C++ features:
- boost::tuple
- boost::make_tuple
- boost::tuple::get
- #include <boost/tuple/tuple.hpp>
All usages were replaced with search-and-replace scripts (the usages of
get could be automatically replaced with a vim macro, the rest was
straightforward search-and-replace).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Note: Replacing everything with a lambda would be even better, but that
can't be easily scripted so we'll do this as a first step to reduce the
Boost footprint.
This also removes occurences of #include <boost/bind.hpp>, and makes
sure all usages of std::bind have an #include <functional>. clang-format
wasn't always applied to minimize the changeset in this commit, however,
it was applied to the blocks of #includes.
Due to conflicts with other Boost libraries, the placeholders _1, _2,
etc. could not be directly used, but had to be explicitly called out
(as std::placeholders::_1, etc.). This makes the use of std::bind even
uglier, which serves as another reminder that using std::bind (and even
more so, boost::bind) should be avoided.
nirio/rpc/rpc_client.cpp still contains a reference to boost::bind. It
was not possible to remove it by simply doing a search and replace, so
it will be removed in a separate commit.
|
|
|
|
|
|
|
| |
Adding graph_utils to keep rfnoc_graph utilities to contain helper
function and commonly used algorithms for the rfnoc_graph. These
functions aren't core to the rfnoc_graph's functionality, so we'll keep
them out of its API.
|
|
|
|
|
|
|
|
|
|
| |
This device arg will avoid printing old log messages by dumping all log
messages in the buffer immediately after claiming a device. This can be
helpful because reading old log messages can be confusing during debug
situations, or simply during situations where we expect errors to
contain warnings or errors, but we want to hide them.
skip_oldlog defaults to off, i.e., the previous behaviour.
|
|
|
|
|
|
|
|
|
| |
The mpmd_mb_controller requires access to the fully functional FPGA,
which in turn assumes flawless initialization. skip_init doesn't init at
all, so inializing an mb_controller may not be possible, and shouldn't
be attempted. This skips init of both mb_iface and mb_controller for
skip_init, leaving it to the other code to figure out if they are
initialized.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Implement I/O service detach link methods
- The I/O service manager instantiates new I/O services or connects
links to existing I/O services based on options provided by the user
in stream_args.
- Add a streamer ID parameter to methods to create transports so that
the I/O service manager can group transports appropriately when using
offload threads.
- Change X300 and MPMD to use I/O service manager to connect links to
I/O services.
- There is now a single I/O service manager per rfnoc_graph (and it is
also stored in the graph)
- The I/O service manager now also knows the device args for the
rfnoc_graph it was created with, and can make decisions based upon
those (e.g, use a specific I/O service for DPDK, share cores between
streamers, etc.)
- The I/O Service Manager does not get any decision logic with this
commit, though
- The MB ifaces for mpmd and x300 now access this global I/O service
manager
- Add configuration of link parameters with overrides
Co-Authored-By: Martin Braun <martin.braun@ettus.com>
Co-Authored-By: Aaron Rossetto <aaron.rossetto@ni.com>
|
|
|
|
|
|
|
| |
Make transports safe to use with an offload thread by ensuring that the
callbacks and the API methods can execute concurrently. Also, ensure
that the transports release their I/O service clients prior to allowing
their other member variables be destroyed.
|
| |
|
|
|
|
|
|
|
|
| |
boost::regex was a requirement until the minimum version of gcc was
increased. Since it is at version 5.3 now, using Boost.Regex is no
longer necessary.
This change is a pure search-and-replace; Boost and std versions of
regex are compatible and use the same syntax.
|
|
|
|
|
|
|
| |
This is mostly a search-and-replace operation, with few exceptions:
- boost::function has a clear() method. In C++11, this is achieved by
assigning nullptr to the std::function object.
- The empty() method is replaced by std::function's bool() operator
|
|
|
|
|
| |
Also removes all references to boost/foreach.hpp. BOOST_FOREACH is no
longer necessary since all headers require C++11 anyway.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This removes the following Boost constructs:
- boost::shared_ptr, boost::weak_ptr
- boost::enable_shared_from_this
- boost::static_pointer_cast, boost::dynamic_pointer_cast
The appropriate includes were also removed. All C++11 versions of these
require #include <memory>.
Note that the stdlib and Boost versions have the exact same syntax, they
only differ in the namespace (boost vs. std). The modifications were all
done using sed, with the exception of boost::scoped_ptr, which was
replaced by std::unique_ptr.
References to boost::smart_ptr were also removed.
boost::intrusive_ptr is not removed in this commit, since it does not
have a 1:1 mapping to a C++11 construct.
|
|
|
|
|
|
|
| |
The offload_io_service executes another I/O service instance within an
offload thread, and provides synchronization mechanisms to communicate
with clients. Frame buffers are passed from the offload thread to the
client and back via single-producer, single-consumer queues.
|