skysafe / gr-sigmf

GNURadio blocks to read, write, and modify SigMF datasets
Other
30 stars 11 forks source link

GPS Message Source affects previously-initialized USRP connections #24

Open eklai opened 5 years ago

eklai commented 5 years ago

GPS message source block initializes a new multi-USRP object, which can affect any previously-initialized multi-USRP or RFNoC-API connections to the same USRP.

For example, if a Tx or Rx streamer has been set up and connected to a specific RFNoC block, that same streamer will still work after initialization of the GPS message source, but attempting to disconnect it will result in an error. (Error message: "Attempting to disconnect output port 0, which is not registered as connected.")

The reverse does not currently hold true; if the USRP GPS message source is initialized before any other USRP blocks, its functionality is not affected since it only queries the underlying GPS object for certain parameters.

Possible fixes include:

  1. Passing into the message source block a reference to an existing USRP object.
  2. Providing callbacks into the GPS message source block for accessing the three relevant properties in the USRP property tree: gps_time, gps_locked, and gps_gpgga.
pwicks86 commented 5 years ago

Adding a way to accept a usrp_ptr object probably makes the most sense.

pwicks86 commented 5 years ago

@eklai 5de25f83a74ce047a4a4264c162acda6ce8c0534 adds a second constructor that should fix your issues, lemme know if that works for you.