Hi, > How can (or better: *should*) a fully digital signal source have phase noise?
Limited precision arithmetic > Also, for 1Hz at 5MSps I always get either 5005789 or 5005790 samples > (instead of 5000000) ... this is fairly deterministic. That's because the signal source works with phase increments per step. So it computes how much the phase changes per sample. The precision limit of that numbers will then create precision errors. > Example 1: I pipe the output of the signal source into a file: > > https://snipboard.io/xY1JvE.jpg > > Now, I would not care too much about a constant phase shift or similar, but > it can be seen that the frequency slowly drifts (this is also seen if I just > plot them on top of each other). Frequency doesn't drift. Frequency is stable but is not exactly 1 Hz which means the phase slowly drifts. > Example 2: I extend the block diagram with blocks that should never alter the > behaviour as they are only reading samples: > [...] > However, now the saved data is distorted: > > https://snipboard.io/amyn3X.jpg Yeah, that's weird, not sure where that would come from. I looked at the code and can't see anything wrong with it, but then again I might not be looking at the code from the version you're running. Cheers, Sylvain