Commit graph

13 commits

Author SHA1 Message Date
Martin Braun
88d284816e mpm: Demote WARNING on minor compat mismatch to DEBUG
When the minor FPGA compat number on the device is ahead of what MPM
expects, we no longer print a warning. That's because by definition, the
FPGA is still compatible with the software in this case.

If UHD or MPM require a certain minor compat number to enable a feature,
the appropriate behaviour would be to print a warning only for that
case.
2022-01-14 14:36:19 -06:00
Lars Amsel
2a575bf9b5 uhd: Add support for the USRP X410
Co-authored-by: Lars Amsel <lars.amsel@ni.com>
Co-authored-by: Michael Auchter <michael.auchter@ni.com>
Co-authored-by: Martin Braun <martin.braun@ettus.com>
Co-authored-by: Paul Butler <paul.butler@ni.com>
Co-authored-by: Cristina Fuentes <cristina.fuentes-curiel@ni.com>
Co-authored-by: Humberto Jimenez <humberto.jimenez@ni.com>
Co-authored-by: Virendra Kakade <virendra.kakade@ni.com>
Co-authored-by: Lane Kolbly <lane.kolbly@ni.com>
Co-authored-by: Max Köhler <max.koehler@ni.com>
Co-authored-by: Andrew Lynch <andrew.lynch@ni.com>
Co-authored-by: Grant Meyerhoff <grant.meyerhoff@ni.com>
Co-authored-by: Ciro Nishiguchi <ciro.nishiguchi@ni.com>
Co-authored-by: Thomas Vogel <thomas.vogel@ni.com>
2021-06-10 12:01:53 -05:00
Joerg Hofrichter
b252771600 mpm: utils: print error on minor compat number mismatch conditionally
If the minor compat number does not match (older than expected), then
generate an error message only if argument fail_on_old_minor is True;
generate a warning otherwise.
2020-07-13 15:22:59 -05:00
Lane Kolbly
11bc3fa3a8 mpm: Make contextmanagers exception-safe
When making context managers in Python, the yield statement has to be wrapped in a try/finally clause in order to properly clean up after exceptions happen.
2020-03-03 15:16:06 -06:00
Martin Braun
f23c8cd140 mpm: Add lock_guard() function
This allows sharing mutexes between C++ and Python, and uses the with
statement to provide a locked-out context.
2018-10-23 10:13:00 -07:00
Trung N Tran
546aa04355 mpm: replace long execution function with async call
- Replace mykonos finish_initialization with async version
- Replace myknonos setup_cal with async version
- Remove disable_timeout on rpc_server init()
2018-04-30 14:36:29 -07:00
Martin Braun
e9288a439c mpm: Update all license headers
- Fix typo in company name (missing 'a')
- Updated SPDX license identifier to version 3.0
2018-02-19 16:55:08 -08:00
Martin Braun
88ab35529b fixup! mpm: Fixup for argument parsing in N310 2018-02-07 13:59:23 -08:00
Brent Stapleton
d9366ba7d4 mpm: Fixup for argument parsing in N310
Adding helper function to parse strings to a boolean value. We can
then use that function to parse MPM's default_args, and set enable_gps
and enable_fp_gpio. This replaces the usages of the Python builtin
bool(), which returns True for any non-empty string.
2018-02-07 17:21:43 +01:00
Martin Braun
cdc9d60e73 mpm: utils: Fix to_native_str for non-string types
Before, you couldn't use to_native_str for objects such as integers
(i.e., anything that was not a bytes-like object).
2018-01-11 14:50:12 -08:00
Martin Braun
877f833983 mpm: utils: Add assert_compat_number function
Reviewed-by: Brent Stapleton <brent.stapleton@ettus.com>
2018-01-08 16:33:10 -08:00
Martin Braun
06f6156f85 mpm: utils: Add string conversion utilities
Adds conversions for:
- Any-to-binary
- Any-to-UTF8
- Any-to-native
2017-12-22 15:05:57 -08:00
Martin Braun
99c5b6fff8 mpm: Add mpmutils module, includes poll_with_timeout
This is a convenience function for polling with sleeps and timeouts.
2017-12-22 15:04:02 -08:00