Hi all,

I'm using GR3.9 with UHD4.1.0.1.
I have a flowgraph containing a UHD_USRP Source block, with Sync property set 
to "PC Clock on Next PPS" so that the device time is synced to PC system time 
on the next PPS.

I want to then, somewhat frequently, access the usrp time from within 
downstream custom C++ blocks.

Options that I've considered:
1. From the custom c++ block - make another UHD USRP device instance (though I 
don't think this is possible, as the device has already been allocated to the 
source block):
    uhd::device_addr_t deviceAddress("");
    uhd::usrp::multi_usrp::sptr usrp = 
uhd::usrp::multi_usrp::make(deviceAddress);

2. From the custom c++ block - Just retrieve clock info from the device a bit 
like this (but it's too slow):
    uhd::device_addr_t dev;
    dev["addr"] = "192.168.XXX.XXX";
    uhd::usrp_clock::multi_usrp_clock::sptr clock = 
uhd::usrp_clock::multi_usrp_clock::make(dev);
    std::cout << clock->get_time()

3. From the custom c++ block - Somehow access the already discovered usrp 
device from the UHD_USRP source block (not sure how to do this)

4. Copy and modify the usrp source code to send time as a stream tag along with 
each packet (seems like a lot of work!)
a. perhaps this could be achieved using the UHD_USRP Source block stream args 
property - though would require mods to the .yml?

Thanks for your help!
Mike
_______________________________________________
USRP-users mailing list -- usrp-users@lists.ettus.com
To unsubscribe send an email to usrp-users-le...@lists.ettus.com

Reply via email to