Yes, transmissions within the same session are consistent. If I destroy the
MultiUSRP object and recreate it (restart my transmit script), the timing
will change. If I repeat hundreds of transmissions without restarting the
timing is stable to the expected accuracy of my TOA measurements.

On Mon, Jun 15, 2020, 4:47 PM Marcus D. Leech <patchvonbr...@gmail.com>
wrote:

> On 06/15/2020 06:45 PM, Aaron Smith wrote:
>
> I am using a master clock rate of 48 MHz and a sample rate of 8 MHz.
>
> When do you notice the timing inconsistency?  For example, if you do a
> number of timed transmits during the same session, are they
>   self-consistent?  Where "session" is defined as "that stuff you do after
> you've set the clock with 1PPS, etc".
>
>
>
> On Mon, Jun 15, 2020, 4:41 PM Marcus D. Leech <patchvonbr...@gmail.com>
> wrote:
>
>> On 06/15/2020 03:42 PM, Aaron Smith wrote:
>> > I am using the python api.
>> >
>> > usrp = uhd.usrp.MultiUSRP()
>> >
>> > # Set gain, clock rate, sample rate etc...
>> >
>> > usrp.set_clock_source('external')
>> > usrp.set_time_source('external')
>> >
>> > ts_reset = uhd.types.TimeSpec(0.0)
>> > usrp.set_time_next_pps(ts_reset)
>> > time.sleep(1.0)
>> > last_pps = usrp.get_time_last_pps().to_ticks(1e9)
>> > if last_pps % int(1e9) != 0:
>> >     print("Error failed to align clock")
>> >
>> > # The signal is complex float data, scaled to a max amplitude of 0.9
>> > approx 0.1 secs in duration
>> > signal_data = numpy.fromfile('signal.dat',dtype=numpy.complex64)
>> >
>> > wirefmt = 'sc16'
>> >
>> > sa = uhd.usrp.StramArgs('fc32',wirefmt)
>> > sa.channels = [0]
>> > stream = usrp.get_tx_stream(sa)
>> >
>> > # Send 3 seconds in future
>> > send_time = usrp.get_time_last_pps().get_real_secs() + 3.0
>> > metadata = uhd.type.TXMetadata()
>> > metadata.has_time_spec = True
>> > metadata.time_spec = uhd.types.TimeSpec(send_time)
>> >
>> > stream.send(signal_data, metadata)
>> >
>> > # Ensure the transmission is complete before returning
>> > time.sleep(4.0)
>> >
>> > sys.exit(0)
>> >
>> >
>> This probably has to do with uncertainty in the way the 1PPS signal is
>> flopped into the device.    What sample rate are you using, and what
>>    master clock rate?
>>
>>
>>
>
_______________________________________________
USRP-users mailing list
USRP-users@lists.ettus.com
http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com

Reply via email to