Commit facc0aa3 authored by Olivier Kaufmann's avatar Olivier Kaufmann
Browse files

Tests graphical output for testing

Showing with 5 additions and 2 deletions
+5 -2
......@@ -53,6 +53,7 @@ class OhmPiHardware:
def _clear_values(self):
self.readings = np.array([])
self._start_time = None
def _inject(self, duration):
self.tx_sync.set()
......
......@@ -22,6 +22,8 @@ print(r)
print(f'length of array: {len(r)}, expected length: {6000./k.rx.sampling_rate}')
print(k.readings)
fig, ax = plt.subplots()
ax.plot(k.readings[:,0], k.readings[:,1], '-r')
ax.plot(k.readings[:,0], k.readings[:,2], '-b')
ax.plot(k.readings[:,0], k.readings[:,1], '-r', label='iab')
ax2 = ax.twinx()
ax2.plot(k.readings[:,0], k.readings[:,2], '-b', label='vmn')
plt.show()
change_config('config_default.py', verbose=False)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment