aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/include/uhdlib/rfnoc/clock_iface.hpp
Commit message (Collapse)AuthorAgeFilesLines
* uhd: Replace include guards with pragma onceLane Kolbly2020-04-081-4/+1
| | | | | Pragma once is the more modern version of include guards, eliminating any potential problems with mistyping include guards. Let's use those.
* uhd: Apply clang-format against all .cpp and .hpp files in host/Martin Braun2020-03-031-1/+1
| | | | | Note: template_lvbitx.{cpp,hpp} need to be excluded from the list of files that clang-format gets applied against.
* rfnoc: Add clock selection to blocksMartin Braun2019-11-261-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | During registration, blocks must now specify which clock they are using for the timebase (i.e., for timed commands) and for the ctrlport (this is used to determine the length of sleeps and polls). For example, the X300 provides bus_clk and radio_clk; typically, the former is used for the control port, and the latter for the timebase clock. Another virtual clock is called "__graph__", and it means the clock is derived from property propagation via the graph. The actual clocks are provided by the mb_iface. It has two new API calls: get_timebase_clock() and get_ctrlport_clock(), which take an argument as to which clock exactly is requested. On block initialization, those clock_iface objects are copied into the block controller. The get_tick_rate() API call for blocks now exclusively checks the timebase clock_iface, and will no longer cache the current tick rate in a separate _tick_rate member variable. Block controllers can't manually modify the clock_iface, unless they also have access to the mb_controller (like the radio block), and that mb_controller has provided said access. This commit also adds the clock selection API changes to the DDC block, the Null block, and the default block.
* rfnoc: clock_iface: Add flag for clock to be (im-)mutableMartin Braun2019-11-261-1/+21
| | | | | An immutable clock means it has a locked frequency, and attempts to change the frequency will cause an exception to be thrown.
* rfnoc: Added clock_iface to convey info about clocksAshish Chaudhari2019-11-261-0/+64
The inteface provides a mechanism for users of clocks to query information such as the running status or rate