Which version of UHD? Sent from my iPhone
> On Jun 10, 2021, at 7:39 AM, Skyvalakis Konstantinos <[email protected]> > wrote: > > > Yes, I know that about GNURadio and the timed commands. I just described the > flowchart here. > > > > After I generated that flowchart in GNURadio I edited the timed commands in > the generated python file, according to the code I included in my very first > message in this thread. > > > > So the timing is definitely done properly. > > > > I also switched to QT GUI time sink, as you proposed, and I still observe a > different phase offset at every experiment. > > > > I am using 3.7.12.0 version of GNURadio. > > > > Thanks for your help. > > From: Marcus D. Leech <[email protected]> > Sent: Thursday, June 10, 2021 2:26 PM > To: Skyvalakis Konstantinos > Cc: [email protected] > Subject: Re: Phase Synchronize 2 USRP N200 w/ SBX cards > >> On 06/10/2021 04:50 AM, Skyvalakis Konstantinos wrote: >> I set up the following flowchart: >> >> >> >> Multi_usrp_source -----> complex_to_real -------> WX GUI Scope Sink >> >> >> >> I repeated the phase identical test tone experiment multiple times and I >> could clearly see that the phase offset between the 2 channels was different >> almost every time. >> >> >> >> Phase offsets were ranging from almost 0 degrees up to 90 degrees. >> >> >> >> Thanks. >> > Gnu Radio does NOT emit code that wraps the tuning requests in timed > commands, so the synthesizers won't be properly > tuned for phase synchronization. ALSO the WX GUI Scope sink had (as I > recall) a bug that caused things to appear out > of phase even if they weren't. You should probably use the QT GUI time > sink instead--what version of GR are you using? > The WX GUI widgets have been deprecated for several years now, and don't > even appear in later versions of GR. > > You'd have to modify the generated code to have it wrap the tuning requests > in timed commands. > > >> >> From: Marcus D Leech <[email protected]> >> Sent: Wednesday, June 9, 2021 10:53 PM >> To: Skyvalakis Konstantinos >> Cc: [email protected] >> Subject: Re: Phase Synchronize 2 USRP N200 w/ SBX cards >> >> >> >> Sent from my iPhone >> >>> On Jun 9, 2021, at 3:52 PM, Skyvalakis Konstantinos >>> <[email protected]> wrote: >>> >>> >>> Οk, I know the way of the atan2 method you are proposing. I will try it >>> tomorrow when I will have access to the equipment again. >>> >>> >>> >>> When you said injecting a phase identical test tone earlier you meant, >>> driving the signal from the generator to the RX2 port of each one of the >>> SBX daughterboards (using a splitter), with equal length cables and then >>> checking the phase offset between the 2 channels? >>> >>> >>> >> Exactly this, yes. You want to measure the phase offset that is dominated by >> the receivers and not external path length differences. >>> Thanks. >>> >>> >>> >>> From: Marcus D Leech <[email protected]> >>> Sent: Wednesday, June 9, 2021 9:05 PM >>> To: Skyvalakis Konstantinos >>> Cc: [email protected] >>> Subject: Re: Phase Synchronize 2 USRP N200 w/ SBX cards >>> >>> Your generated tone should be OK as long as the path lengths are the same >>> during phase calibration. >>> >>> Measuring mutual phase offset can be done in a number of ways like taking >>> the atan2 of the two channels and averaging. >>> >>> Sent from my iPhone >>> >>>> On Jun 9, 2021, at 1:50 PM, Skyvalakis Konstantinos >>>> <[email protected]> wrote: >>>> >>>> >>>> You assumed correctly. I am doing this in a single multi_usrp object, so >>>> it is ok. I will also remove that sleep command. >>>> >>>> I don't know how I can measure the phase difference between the two RX >>>> channels. In my DoA experiment I am just transmitting a tone @ 868MHz from >>>> an RF generator and I'm receiving it from the 2 RX channels. >>>> >>>> Also could you elaborate more on the last thing you mentioned, the one >>>> about the phase identical test tone.... >>>> >>>> On Jun 9, 2021 19:51, "Marcus D. Leech" <[email protected]> wrote: >>>> On 06/09/2021 10:11 AM, Skyvalakis Konstantinos wrote: >>>> I have 2 USRP N200 devices, each one equipped with an SBX daughterboard. >>>> >>>> >>>> >>>> I am providing 10MHz ref clock and 1 PPS input on both devices with equal >>>> length cables, from an external signal generator. >>>> >>>> >>>> >>>> My application is DoA. Is it possible to do it, with 2 USRP N200 and the >>>> SBX daughterboards? >>>> >>>> >>>> >>>> 1) Is the following timed commands code snippet correct for frequency and >>>> phase synchronization of both SBX cards? >>>> >>>> >>>> >>>> self.source = uhd.usrp_source( >>>> >>>> ",".join(("addr0=192.168.10.2, addr1=192.168.10.3", "")), >>>> >>>> uhd.stream_args( >>>> >>>> cpu_format="fc32", >>>> >>>> channels=range(2), >>>> >>>> ), >>>> ) >>>> self.source.set_clock_source('external', 0) >>>> self.source.set_time_source('external', 0) >>>> self.source.set_clock_source('external', 1) >>>> self.source.set_time_source('external', 1) >>>> self.source.set_samp_rate(2e6) >>>> self.source.set_time_unknown_pps(uhd.time_spec()) >>>> self.source.set_gain(50, 0) >>>> self.source.set_antenna('RX2', 0) >>>> self.source.set_gain(10, 1) >>>> self.source.set_antenna('RX2', 1) >>>> >>>> time.sleep(1) >>>> >>>> self.source.clear_command_time() >>>> self.source.set_command_time(self.source.get_time_now() + >>>> uhd.time_spec_t(0.1)); >>>> self.source.set_center_freq(uhd.tune_request(868e6,0), 0) >>>> self.source.set_center_freq(uhd.tune_request(868e6,0), 1) >>>> >>>> time.sleep(0.11) >>>> >>>> self.source.clear_command_time() >>>> >>>> >>>> >>>> >>>> >>>> 2) Is there anyway to measure and compensate the offset between the 2 SBX >>>> daughterboards? >>>> >>>> >>>> >>>> 3) Can this synchronization problem be tackled easier with a MIMO cable >>>> (since I do have one) ? >>>> >>>> >>>> >>>> Thank you in advance. >>>> >>>> >>>> >>>> Konstantinos >>>> >>>> Assuming that you're streaming two channels in a single multi_usrp object, >>>> then this looks OK, except there's no reason for that >>>> time.sleep(0.11) *before* the self.source.clear_command_time(). >>>> >>>> What magnitude of residual phase-offset are you seeing, and how are you >>>> measuring it? >>>> >>>> A MIMO cable won't help with residual phase offset. >>>> >>>> The usual way of calibrating this out is to inject a phase-identical test >>>> tone into each channel, and measure the phase offset when >>>> starting up. >>>> >>>> >>>> >>>> >>>> >>>> >
