Discussion and technical support related to USRP, UHD, RFNoC
View all threadsHi
I bought 2 B210s for testing direction of arrival estimation, like below.
======================= Configuration =============================
Ch0 <--> | USRP0 Rx 0 |
| | <-- USB3.0 --> | PC |
Ch1 <--> | USRP0 Rx 1 | | Ubuntu 14.04 |
| GNU Radio Companion 3.7.11.1 |
Ch2 <--> | USRP1 Rx 0 | | UHD_003.010.001.001-79-g7ac01c7f|
| | <-- USB3.0 --> | |
Ch3 <--> | USRP1 Rx 1 |
In GRC
I generated python code by GRC and then I added custom timing adjustment
code.
self.uhd_usrp_source_0.set_time_next_pps(uhd.time_spec(0))
self.uhd_usrp_source_1.set_time_next_pps(uhd.time_spec(0))
time.sleep(1.0)
start_time = uhd.time_spec(5.0)
self.uhd_usrp_source_0.set_start_time(start_time)
self.uhd_usrp_source_1.set_start_time(start_time)
---=========
I believe that I am following all the instructions what I found in web.
but, when I tried to check that sampling timing is exactly matched or not
by dumping all the samples(connect File Sink), I found sampling gaps
between 2 B210.
While testing, I confirmed that
I observed that
Please let me know what I am missing.
Thanks,
Matsu
Hi Hideyuki,
Our students were working (with my help) on synchronizing two USRPs B210
with use of Octoclock-G.
To make your code work without any race-conditions I would add a loop
that waits for pps edge before your adjustment code, like this:
time_last_pps = self.uhd_usrp_source_0.get_time_last_pps()
while(self.uhd_usrp_source_0.get_time_last_pps() == time_last_pps):
time.sleep(0.01)
Code like this will work perfectly on devices like USRP X3x0. But sadly
not on B210 - with them there is always
always some time-offset between the devices. It changes randomly every
time we run the program. The values we observed are in range of few
hundreds of us. We still need to check again with different USRP B210s
and different Octoclock-G, but my theory is currently following:
I haven't seen anyone admitting publicly that he/she in fact
synchronized B210 in time (I exclude from 'synchronized' doing the
synchronization in signal post processing).
So unless someone will come out, say is openly that he synchronized
USRPs B210, how he did it and what time offsets were observed, issue of
synchronizing B210s is still open and not solved.
--
Best Regards,
Piotr Krysik
W dniu 25.10.2017 o 08:59, Hideyuki Matsunaga via USRP-users pisze:
I bought 2 B210s for testing direction of arrival estimation, like below.
======================= Configuration =============================
Ch0 <--> | USRP0 Rx 0 |
| | <-- USB3.0 --> | PC |
Ch1 <--> | USRP0 Rx 1 | | Ubuntu 14.04
|
| GNU Radio Companion 3.7.11.1
|
Ch2 <--> | USRP1 Rx 0 | | UHD_003.010.001.001-79-g7ac01c7f|
| | <-- USB3.0 --> | |
Ch3 <--> | USRP1 Rx 1 |
In GRC
I generated python code by GRC and then I added custom timing
adjustment code.
self.uhd_usrp_source_0.set_time_next_pps(uhd.time_spec(0))
self.uhd_usrp_source_1.set_time_next_pps(uhd.time_spec(0))
time.sleep(1.0)
start_time = uhd.time_spec(5.0)
self.uhd_usrp_source_0.set_start_time(start_time)
self.uhd_usrp_source_1.set_start_time(start_time)
---=========
I believe that I am following all the instructions what I found in web.
but, when I tried to check that sampling timing is exactly matched or not
by dumping all the samples(connect File Sink), I found sampling gaps
between 2 B210.
While testing, I confirmed that
I observed that
Please let me know what I am missing.
On Thu, Jan 18, 2018 at 10:34:14AM +0100, Piotr Krysik via USRP-users wrote:
Hi Hideyuki,
Our students were working (with my help) on synchronizing two USRPs B210
with use of Octoclock-G.
To make your code work without any race-conditions I would add a loop
that waits for pps edge before your adjustment code, like this:
time_last_pps = self.uhd_usrp_source_0.get_time_last_pps()
while(self.uhd_usrp_source_0.get_time_last_pps() == time_last_pps):
time.sleep(0.01)
This is good advice. You can go to multi_usrp.cpp and take a look at
set_time_unknown_pps() for a reference on how to do that.
-- Martin
dniu 23.01.2018 o 19:11, Martin Braun via USRP-users pisze:
On Thu, Jan 18, 2018 at 10:34:14AM +0100, Piotr Krysik via USRP-users wrote:
Hi Hideyuki,
Our students were working (with my help) on synchronizing two USRPs B210
with use of Octoclock-G.
To make your code work without any race-conditions I would add a loop
that waits for pps edge before your adjustment code, like this:
time_last_pps = self.uhd_usrp_source_0.get_time_last_pps()
while(self.uhd_usrp_source_0.get_time_last_pps() == time_last_pps):
time.sleep(0.01)
This is good advice. You can go to multi_usrp.cpp and take a look at
set_time_unknown_pps() for a reference on how to do that.
Hi Martin,
The problem is that even when I replicated exactly the
set_time_unknown_pps() function in Python it doesn't work with USRPs B210.
It works perfectly well with X310s but somehow with B210s there is some
time offset (few hundreds us) that changes from one program execution to
another. I still have to check on different B210s and different
Octoclocks but it requires some time and in the end I don't expect a
surprise (probably I will just be more sure that it is fault of the B210).
So even to get information from someone like: "I checked and it works
for me" would help me and others a lot.
--
Best Regards,
Piotr Krysik
Hi Hideyuki,
For the solution look at the end of "Is it possible to time synchronize
multiple USRPs B210?" thread.
I attached there a working example for two USRPs B210.
--
Best Regards,
Piotr Krysik