Commit Graph

10135 Commits

Author SHA1 Message Date
michael-west
cea9b945bc Prepare branch for 4.4.0.0 release
- Updated version string
- Updated CHANGELOG
- Updated Debian-related files
- Updated images

Signed-off-by: michael-west <michael.west@ettus.com>
2023-01-23 23:13:06 -08:00
michael-west
92c09f7f76 fpga: Update copyright
Update copyright on recently changed files.

Signed-off-by: michael-west <michael.west@ettus.com>
2023-01-19 15:55:56 -08:00
michael-west
b2d4eaa8e5 FPGA: Fix overflows in DDC
Added proper clipping of halfband filter output to handle potential
overflow.

Signed-off-by: michael-west <michael.west@ettus.com>
2023-01-19 10:05:27 -06:00
michael-west
c27519624e FPGA: Restore FIR filter in rx_frontend_gen3
The FIR filter applied gain.  Removing it caused incorrect scaling and
signals where every other sample was zero.  Also parameterized heterodyne
frontend processing so it would not use resources in images not
requiring it.

Signed-off-by: michael-west <michael.west@ettus.com>
2023-01-19 10:05:27 -06:00
michael-west
e3ffef975d FPGA: Fix warnings in dds_freq_tune module
Added missing tuser connections.

Signed-off-by: michael-west <michael.west@ettus.com>
2023-01-19 10:05:27 -06:00
Virendra Kakade
1d0e9a2a38 tests: add x310 raw udp tests
Adds tests for X310 10GBE interface.

Signed-off-by: Virendra Kakade <virendra.kakade@ni.com>
2023-01-17 13:33:49 -06:00
David Raeman
51d4411ec1 e3xx: add support for power calibration api
This commit adds support for the UHD power calibration API on the E3xx
family of radios. It also updates the documentation to reflect this
support, and it adds support to the uhd_power_cal.py utility by adding a
"calibrator" subclass for E3xx radios.
2023-01-17 11:30:53 -08:00
Larissa Phillip
f6f1dec85a fpga: rfnoc: Add align_samples testbench 2023-01-12 21:42:13 -06:00
Sam James
3acf784e98 Fix build with GCC 13 (add missing <cstdint> include)
GCC 13 (as usual for new compiler releases) shuffles around some
internal includes and so <cstdint> is no longer transitively included.

Explicitly include <cstdint> for uint8_t.

```
/var/tmp/portage/net-wireless/uhd-4.3.0.0/work/uhd-4.3.0.0/host/include/uhd/rfnoc/defaults.hpp:43:14: error: 'uint32_t' does not name a type
   43 | static const uint32_t DEFAULT_NOC_ID  = 0xFFFFFFFF;
      |              ^~~~~~~~
/var/tmp/portage/net-wireless/uhd-4.3.0.0/work/uhd-4.3.0.0/host/include/uhd/rfnoc/defaults.hpp:1:1: note: 'uint32_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
  +++ |+#include <cstdint>
    1 | //
```

Signed-off-by: Sam James <sam@gentoo.org>
2023-01-12 17:52:12 -08:00
michael-west
6a3ab53a2c manifest: Update FPGA images
Update FPGA images for B2xx, E3xx, X3xx, N3xx, and X4xx

Signed-off-by: michael-west <michael.west@ettus.com>
2023-01-11 23:22:06 -08:00
Martin Braun
47be6326c6 docs: Update manual for X3x0 raw UDP streaming 2023-01-11 07:59:19 -08:00
Martin Braun
8c295d8d64 x300: Enable use of advanced transport adapters
This instantiates xport_adapter_ctrl objects in the x300_mb_iface, which
allows the X300 to support the get_chdr_xport_adapters() and
add_remote_ep_route() API calls. Effectively, this enables remote UDP
streaming for X300 devices, provided they have been updated to FPGA
compat number 7.3, which adds those features.

Co-authored-by: Virendra Kakade <virendra.kakade@ni.com>
Co-authored-by: Wade Fife <wade.fife@ni.com>
2023-01-10 14:19:00 -08:00
Martin Braun
e315f0dbc6 usrp: Add xport_adapter_ctrl core
This allows accessing the advanced transport adapter capabilities on
X300, where there is no MPM to aid accessing it. It is functionally
equivalent to xport_adapter_ctrl.py.
Includes unit tests.

Co-authored-by: Virendra Kakade <virendra.kakade@ni.com>
2023-01-10 14:19:00 -08:00
Martin Braun
6d843a2e78 x300: Respect X300_FW_COMMS_FLAGS_ARP_FAIL flag
In firmware version 6.1, this flag was introduced to indicate a failed
ARP lookup.
2023-01-10 14:19:00 -08:00
Martin Braun
89fb75288e x300: Update firmware for TA control
- Bump firmware compat to 6.1
- Remove crossbar counter logic (the FPGA does *not* support crossbar
  counters anymore, so we remove it from the firmware as well)
- Remove crossbar programming control (this is now provided by RFNoC
  management packets)
- Remove UDP framing control (this is also provided by RFNoC management
  packets)
- Remove Ethernet link/activity LED control (this has been handled by
  the FPGA directly for years now)
- Add functionality to program transport adapter. The TA is programmed
  directly on the settings bus, so for the most part, this is already
  possible from the firmware. The only exception is the 'virtual'
  register to program IP address and MAC at the same time. In the
  firmware, it will perform an ARP lookup of the MAC address, and then
  write the "normal" IPv4 address register in the TA, as well as the MAC
  address registers.
- Updated bootram.coe
2023-01-10 14:19:00 -08:00
Wade Fife
2d7c8e0d08 fpga: x300: Bump FPGA compat to 39.1 2023-01-10 14:19:00 -08:00
Wade Fife
adc938c0b6 fpga: x300: Support advanced transport adapter 2023-01-10 14:19:00 -08:00
Wade Fife
100a3f0793 fpga: lib: Add verilog-compatible wrapper for eth_ipv4_chdr_adapter 2023-01-10 14:18:59 -08:00
Wade Fife
105d8d1661 fpga: lib: Add ZPU support to SV transport adapter 2023-01-10 14:18:59 -08:00
Wade Fife
a7050773f2 fpga: lib: Fix indentation in setting_reg.v 2023-01-10 14:18:59 -08:00
Wade Fife
8af3c0e52d fpga: lib: Update header for AXI4S add/remove bytes 2023-01-10 14:18:59 -08:00
Wade Fife
ee36d7fabc fpga: tools: Fix error detection in run_testbenches.py
This fixes recognition of $error and $fatal statements in the output of
XSim when running run_testbenches.py. XSim apparently prints a "shift
in" character (0x15) as part of its error statements, so the regular
expression was not matching.
2023-01-09 15:40:17 -06:00
Steven Koo
b9b53d3945 ci: Update docker repo location
Signed-off-by: Steven Koo <steven.koo@ni.com>
2023-01-06 08:57:38 -06:00
Martin Braun
71d957df29 mpm: x4xx: Remove references to white rabbit
At least in this version of UHD, there is no White Rabbit support on
X410. The references in x4xx.py are vestigial code snippets.
2023-01-05 12:00:27 -08:00
Martin Braun
3e039aadff lib: topo graph: Fix rule-of-3 related compiler warnings
topo_node_t and topo_edge_t explicitly defined a default copy
constructor, but not a default copy assignment operator. Because that
violates the rule of three, requiring an implicit assignment operator
is considered deprecated since C++11, but only newer compilers are
starting to complain about it by emitting warnings.
2023-01-05 11:59:45 -08:00
Wade Fife
4fdcc2af83 fpga: docs: Fix AR76780 dependency
This patch is currently required for all Vivado-based usrp3 devices.
2023-01-04 17:58:05 -06:00
mattprost
be4aaf6cfa devtest: Add multi-spc timed command tests
These tests are designed to validate timed commands operating correctly
at various offsets. This is to support the multiple-samples-per-cycle
logic in the FPGA which enables multi-spc streaming on certain devices.
The tests cover devices with digital code shared in the RFNoC framework,
even if they do not strictly support multi-spc streaming.

Co-authored-by: Grant Meyerhoff <grant.meyerhoff@ni.com>
Co-authored-by: Wade Fife <wade.fife@ettus.com>
Signed-off-by: mattprost <matt.prost@ni.com>
2022-12-21 20:26:51 -06:00
mattprost
d04d386fd6 images: Update manifest - timed sample alignment in RFNoC
This pulls in the FPGA changes that maintain timed sample alignment for
multi-sample-per-cycle streaming on X410 as well as other UHD-4.3 FPGA
changes.

Signed-off-by: mattprost <matt.prost@ni.com>
2022-12-21 20:26:51 -06:00
Martin Braun
e82d56b2a5 docs: rfnoc: Fix Doxygen warnings on chdr_packet::set_metadata()
The doxygen lines for chdr_packet::set_metadata() were incorrect and
caused Doxygen warnings. This fixes the documentation.
2022-12-20 15:37:51 -06:00
Martin Braun
3280ea76b9 lib: Fix warning in ctrlport_endpoint.cpp
This adds additional asserts in peek32() to verify the returned packet
is valid. This is not a failure that was ever observed, but on the off
chance the ACK value is incorrectly returned, peek32() could segfault or
return corrupt data. Now, it would throw an assertion exception.

With gcc 12, this will fix some compiler warnings.
2022-12-20 15:37:51 -06:00
Wade Fife
9afa6be7b2 fpga: rfnoc: Add timed sample alignment to radio
This adds time alignment to the radio, so that the first transmitted or
received sample gets shifted into the position corresponding to its
timestamp. The applies only to configurations in which SPC > 1.

For example, if the radio time is incrementing by 4 samples per cycle
(SPC = 4) starting at time 0, and a packet is supposed to be
transmitted at time 201, then the data must be left-shifted by one
sample (201 % 4 = 1), so that the first sample of the packet correctly
aligns with the radio sample corresponding to time 201. Things get more
complicated if the radio time is not a multiple of the SPC (i.e., the
radio time started at time 1, 2, or 3 instead of 0).
2022-12-19 08:57:18 -06:00
Wade Fife
0a13db4afa fpga: lib: Add align_samples module
This module supports timed sample alignment by shifting radio words
with multiple samples per cycle to put the first sample into the
correct position for the required timestamp.
2022-12-19 08:57:18 -06:00
Wade Fife
684a9879d3 fpga: lib: Support time and data updates in sim_radio_gen 2022-12-19 08:57:18 -06:00
Wade Fife
cadc906649 fpga: sim: Fix typo in clk_wait_f 2022-12-19 08:57:18 -06:00
Lars Amsel
2b50249f4c host: ADC cal: Add ability to set calibration mode explicitly
We currently do not set the calibration mode during ADC self
calbration. The default mode is selected in Vivado configuration.
Nevertheless we have seen issues where not setting the mode
lead to poor results in ADC self calibration.

This commit enable the RPC to call the set_calibration_mode
which was already implemented in our RFDC lib.
2022-12-18 18:28:12 -06:00
Lars Amsel
3a59991b3c host: cal: Rearrange ADC self calibration routine
The current ADC self cal routine is written around the ZBX
daughterboard, which makes a lot of assumptions about abilities
and constants that only applies to ZBX but may not hold true
for future boards.

This commit move ZBX specific code of the self cal into the
ZBX daughterboard class. It also removes constants dedicated to
ZBX from the adc_self_cal_params_t struct.
2022-12-18 18:28:12 -06:00
Martin Braun
dbe8d13d64 ci: Add clang-format 14.0 to the Ubuntu 22.04 container 2022-12-16 14:14:26 -06:00
Adam Vander Pas
4d9b68aa6a examples: rx_samples_to_file: Add disk write speed check
Run 'dd' utility for 1 second to quickly benchmark the
write speed of the file location. A warning is then displayed
to the user if the rate/channel count/data type selection is
likely to cause overflows.
2022-12-13 13:03:07 -06:00
mattprost
d00bc567b2 ci: devtest: Test E320 1G FPGA Image
Test the 1G FPGA image for the E320 devtests in order to accomodate some
shifts in test hardware.

Signed-off-by: mattprost <matt.prost@ni.com>
2022-12-07 16:59:21 -06:00
Adam Vander Pas
d91c86dd33 examples: rx_samples_to_file: Add multichannel option
This modifies the command line parameters of rx_samples_to_file to
allow setting multiple RF channels to recieve from.

Data recieved from each channel is saved in a different file using
ch0_<filename> prefixes.
2022-12-07 15:32:30 -06:00
Wade Fife
7de96848df mpm: rfdc: Add X4xx 125e6 master clock rate 2022-12-06 11:29:15 -06:00
Martin Braun
ddd80a76ef rfnoc: streamers: Fix scaling factor
The scaling factor correction in the RX and TX streamers was inverted.
According to our manual (host/docs/properties.dox):

"""
A scaling value of 0.99 means that a signal that used to be fullscale
(max. amplitude of 1.0) will only have a maximum amplitude of 0.99. For
example, the DDC and DUC blocks use this property to signal how much
they have affected the amplitude. The TX and RX streamer objects can
then apply the inverse of this scaling factor to correct for the scaling
before returning the signal to the user.
"""

We are supposed to be applying the inverse, but we were applying the
scaling factor directly (not the inverse).
2022-12-06 11:27:47 -06:00
Martin Braun
4c390f242d docs: Fix typo in Python API dox file
Thanks to github user f380cedric for pointing it out.
2022-12-06 11:06:47 -06:00
mattprost
e5887d84f7 ci: Replace Rhombus E320
Adding some new test hardware.

Signed-off-by: mattprost <matt.prost@ni.com>
2022-12-05 14:14:12 -06:00
Martin Braun
0624d6c645 fpga: Cosmetic changes to rx_frontend_gen3_tb
- Add different signal types
- Default to real/constant
- Minor cleanup
2022-12-02 11:42:44 -08:00
Martin Braun
8bd982745e fpga: Fix overflows in quarterrate downconverter
The 1/4-rate downconverter naively negated the input signals (y = -x)
which doesn't work when the signal is at full scale. In particular,
signals that are at full negative scale get converted to zeros (even
though 2's complement would be to return the same number, although that
would also be incorrect).

This fix changes it such that the smallest negative value gets converted
to the largest positive value.

This is not a mathematical correction inversion, but a minor amplitude
distortion. However, since we're already at full scale, and thus
probably clipping, this is preferable to the incorrect resolution of the
regular inversion. Put differently, there is no better value in this
case.
2022-12-02 11:42:44 -08:00
Wade Fife
7f13abe9b4 fpga: tools: Detect check_timing issues during build 2022-11-18 14:53:41 -06:00
Wade Fife
4a011e8c90 fpga: lib: Fix inferred latch in ep_autonegotiation 2022-11-18 14:53:41 -06:00
David Raeman
dfccfcefe5 docs: Phase noise consideration when using external clock with E320
Mention that disabling the GPSDO can reduce phase noise when using an
external clock with E320. The language was copied from a similar note
in the N320 docs.

Edit: The original documentation by draeman-synoptic was modified to add
more clarity around how using `enable_gps` in UHD runtime args will
override the value of `enable_gps` in the device's MPM configuration.

Co-authored-by: mattprost <matt.prost@ni.com>
Signed-off-by: mattprost <matt.prost@ni.com>
2022-11-16 09:51:57 -06:00
David Raeman
8cb6699772 e320: Allow internal GPSDO to be powered-down via UHD session args
Currently the E320's integrated GPSDO can be disabled using the
"enable_gps" argment at MPM initialization time (e.g. when the radio
powers on and launches the MPM daemon). However, there is no way for
a UHD application to disable the GPSDO at connection time.

This patch allows the existing "enable_gps" arg to be accepted when
initiating an MPM session from UHD, such that an application can pass
the arg "enable_gps=0" at connection time to disable the GPSDO. The
default power state of the GPSDO is restored when the session ends.

Edit: On top of the original commit by draeman-synoptic, the MPM minor
compat number was also increased to denote new non-breaking feature
support.

Co-authored-by: mattprost <matt.prost@ni.com>
Signed-off-by: mattprost <matt.prost@ni.com>
2022-11-16 09:51:57 -06:00