How precise is the timing?

Applications, development tools, FPGA, C, WEB
Post Reply
majtom
Posts: 3
Joined: Thu Nov 08, 2018 10:29 am

How precise is the timing?

Post by majtom » Thu Nov 08, 2018 10:40 am

Hi everybody,

I am planning to use the Red Pitaya for scientific purposes and so far I am very impressed with its abilities.

I am interested in any experience with the board in regards to precise time stamping of data.

1)As far as I understand it is not possible to timestamp individual samples, but only the entire buffer. Is this correct?

2) I can see that the board has a lightweight version of NTP. This way I can synchronize it with my PC which is connected to a GPS. But, how precise will the timestamp on my data package be, if I simply use a time function i c to add a timestamp to my data?

I am looking for ms precision.

I hope someone has experience with this and can give me some advise.

Cheers!

pavel
Posts: 524
Joined: Sat May 23, 2015 5:22 pm

Re: How precise is the timing?

Post by pavel » Thu Nov 08, 2018 11:38 am

I think that a time stamp with a precision of around a few microseconds is relatively easy to implement.

It's possible to connect Red Pitaya to a GPS module with a PPS output. The Linux kernel and the FPGA configuration should be slightly modified to forward the PPS signal to the programs running under Linux. Then gpsd and chrony can be configured to use the GPS module for the time synchronization.

I'm using this kind of configuration for my multiband WSPR transceiver project:

http://pavel-demin.github.io/red-pitaya ... -interface

majtom
Posts: 3
Joined: Thu Nov 08, 2018 10:29 am

Re: How precise is the timing?

Post by majtom » Thu Nov 08, 2018 1:29 pm

Dear Pavel,

Thank you very much for the fast answer.

Do you add one timestamp to your output file or do you timestamp each data point in the buffer?
And have you ever tested the system time offset from the pps signal?

Also, from the documentation I thought there would only be a limited version of NTP on the RP? Not one including ntpd and chrony.

I am sorry for the many questions, but it would be amazing if we could achieve a few microseconds precision with the RP.

Cheers!

pavel
Posts: 524
Joined: Sat May 23, 2015 5:22 pm

Re: How precise is the timing?

Post by pavel » Thu Nov 08, 2018 3:10 pm

The SD card images provided by the Red Pitaya developers are based on the Ubuntu Linux distribution that provides several NTP implementations. It's also possible to build from the source codes any version of any open source NTP implementation.

For my projects, I use the Alpine Linux distribution. This distribution also provides several NTP implementations.

You can find some plots of the time offset and jitter at the following link:

http://www.satsignal.eu/ntp/Raspberry-Pi-NTP.html

The only time measurement that I did was to check the time offset and jitter reported by chrony. The results were similar to the results from the above link.

In my projects, I use the PPS signal mainly for the frequency calibration and it works well.

I think that the following C code should be enough to read the time for a time stamp:

Code: Select all

struct timespec t;
clock_gettime(CLOCK_REALTIME, &t);

majtom
Posts: 3
Joined: Thu Nov 08, 2018 10:29 am

Re: How precise is the timing?

Post by majtom » Tue Nov 13, 2018 11:49 am

Dear Pavel,

Thank you very much for the info.
I just ordered a RP and I am looking forward to playing around with it.

- Maja

Post Reply
jadalnie klasyczne ekskluzywne meble wypoczynkowe do salonu ekskluzywne meble tapicerowane ekskluzywne meble do sypialni ekskluzywne meble włoskie

Who is online

Users browsing this forum: No registered users and 11 guests