Commit 98dc99ac authored by Claudio Scafuri's avatar Claudio Scafuri 💬
Browse files

docs added

parent aec2d821
......@@ -7,3 +7,4 @@ Attualmente steps_per_kHz = 6000
e se le proc di reste non funzionano, si semplifi ca tutto e steps_per_kHz diventa una property
letture ADC in Volt, +- 10 V, 16 bit (A. Abrami)
......@@ -6,13 +6,19 @@ import numpy
import matplotlib.pyplot as plt
vlt_min = 50.0
vlt_scale = 0.120412
volt=numpy.arange(0.0, 10.0, 0.2)
vlt_scale_new = 0.1
volt=numpy.arange(0.0, 10.2, 0.2)
vcav=[]
vcavnew=[]
for vlt in volt:
v = vlt_min * pow(10.0, vlt * vlt_scale)
vcav.append(v)
vnew = vlt_min * pow(10.0, vlt * vlt_scale_new)
vcavnew.append(vnew)
plt.plot(volt,vcav)
plt.plot(volt,vcav,volt,vcavnew)
plt.grid()
plt.show()
#!/usr/bin/python3
# plot adc to cavity voltage conversion curve
import numpy
import matplotlib.pyplot as plt
vlt_min = 50.0
vlt_scale = 0.120412
vlt_scale_new = 0.1
volt=numpy.arange(-10.2, 10.2, 0.2)
vcav=[]
vcavnew=[]
for vlt in volt:
vlt += 10
vlt = (vlt/2.0)
if vlt <-11:
vlt = 0
v = vlt_min * pow(10.0, vlt * vlt_scale)
vcav.append(v)
vnew = vlt_min * pow(10.0, vlt * vlt_scale_new)
vcavnew.append(vnew)
plt.plot(volt,vcav,volt,vcavnew)
plt.grid()
plt.show()
Markdown is supported
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