Hi, I just wanted to follow up on the question below. I am currently (ab)using the "Function Probe" to execute the tuning code at the "Poll Rate". But I'd like to avoid this because it does not seem reliable.
My main concerns are (a) setting integer-N mode via the messages port and (b) obtaining the current USRP time (get_time_now) for the timed commands when using the message port. If this is something that's just not possible, that would be a valuable answer as well. Thanks, Luke > Gesendet: Freitag, 13. Dezember 2019 um 22:50 Uhr > Von: "Lukas Haase" <lukasha...@gmx.at> > An: usrp-users@lists.ettus.com > Betreff: Config USRP Source/Sink integer-N mode and timed commans via messages > > Hi, > > The UHD interface supports messages to change center frequency etc [1]. > I would want to send the following commands via messages to the USRP Sink and > USRP Source, respectively: > > now = self.uhd_usrp_sink_0.get_time_now() > timeStamp = now + uhd.time_spec(0.1) > > tune_req_tx = uhd.tune_request(fcenter-1e6, 1e6) > tune_req_tx.args=uhd.device_addr(','.join(["mode_n=integer", > "int_n_step=1000e3",])) > self.uhd_usrp_sink_0.set_command_time(timeStamp) > res1 = self.uhd_usrp_sink_0.set_center_freq( tune_req_tx, 0) > self.uhd_usrp_sink_0.clear_command_time() > > tune_req_rx = uhd.tune_request(2*fcenter) > tune_req_rx.args=uhd.device_addr(','.join(["mode_n=integer", > "int_n_step=1000e3",])) > now = self.uhd_usrp_sink_0.get_time_now() > self.uhd_usrp_source_0.set_command_time(timeStamp) > res2 = self.uhd_usrp_source_0.set_center_freq(tune_req_rx, 0) > self.uhd_usrp_source_0.clear_command_time() > > The first issue is that the "tune_request" described in [1] is a simple pair. > However, the real uhd::tune_request_t is more comprehensive and includes the > "args" element that I need to set to "mode_n=integer", "int_n_step=1000e3" > for integer N PLL. > > The second issue is the timed command. It seems usrp_block::set_command_time > translates into "time" with "timestamp" and usrp_block::clear_command_time > translates into "time" with PMT_NIL. However, how to I obtain the current UHD > time (uhd_usrp_sink_0.get_time_now)? > > Thanks, > Luke > > > [1] https://www.gnuradio.org/doc/doxygen/page_uhd.html _______________________________________________ USRP-users mailing list USRP-users@lists.ettus.com http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com