diff options
Diffstat (limited to 'dpd/src')
-rw-r--r-- | dpd/src/Measure.py | 13 | ||||
-rwxr-xr-x | dpd/src/subsample_align.py | 2 |
2 files changed, 14 insertions, 1 deletions
diff --git a/dpd/src/Measure.py b/dpd/src/Measure.py index 0f90a44..ba71917 100644 --- a/dpd/src/Measure.py +++ b/dpd/src/Measure.py @@ -130,11 +130,24 @@ class Measure: tx_rx_frame_path = ('/tmp/tx_rx_sync1_' + datetime.datetime.now().isoformat() + '.pdf') + plt.subplot(311) plt.plot(np.abs(rxframe_aligned[:128]), label="rxframe") plt.plot(np.abs(txframe_aligned[:128]), label="txframe") plt.xlabel("Samples") + plt.ylabel("Absolute Value") + plt.legend() + plt.subplot(312) + plt.plot(np.real(rxframe_aligned[:128]), label="rxframe_real", alpha=0.5, linestyle=":") + plt.plot(np.real(txframe_aligned[:128]), label="txframe_real", alpha=0.5, linestyle=":") + plt.xlabel("Samples") plt.ylabel("Real Part") plt.legend() + plt.subplot(313) + plt.plot(np.imag(rxframe_aligned[:128]), label="rxframe_imag", alpha=0.5, linestyle="--") + plt.plot(np.imag(txframe_aligned[:128]), label="txframe_imag", alpha=0.5, linestyle="--") + plt.xlabel("Samples") + plt.ylabel("Imaginary Part") + plt.legend() plt.savefig(tx_rx_frame_path) plt.clf() diff --git a/dpd/src/subsample_align.py b/dpd/src/subsample_align.py index d90d018..992aa03 100755 --- a/dpd/src/subsample_align.py +++ b/dpd/src/subsample_align.py @@ -61,7 +61,7 @@ def subsample_align(sig, ref_sig): #print("Found subsample delay = {}".format(best_tau)) - if 0: + if 1: corr = np.vectorize(correlate_for_delay) ixs = np.linspace(-1, 1, 100) taus = corr(ixs) |