correct gen18v, and some text
This commit is contained in:
Binary file not shown.
+21
-3
@@ -1,5 +1,7 @@
|
||||
import matplotlib.pyplot as plt
|
||||
import matplotlib.ticker as mpt
|
||||
import matplotlib as mpl
|
||||
import mpl_toolkits.axes_grid1.inset_locator as ins
|
||||
import matplotlib.cm as cm
|
||||
import numpy as np
|
||||
import wafer
|
||||
@@ -119,13 +121,16 @@ def gen_48i_theory():
|
||||
def gen_1v8_theory():
|
||||
rpara = 75000
|
||||
rseri = 2*4700
|
||||
xdata = np.arange(0, 256, 4, dtype=int)
|
||||
xdata = np.arange(0, 256, 1, dtype=int)
|
||||
ydata = (xdata / 256 * 10000)
|
||||
ydata = ydata * rpara / (ydata + rpara) + rseri
|
||||
ydata = 30100 / (ydata + 6490) * .7 + .7
|
||||
|
||||
print(f'vmin: {(ydata[-2]-ydata[-1])*1000} mV')
|
||||
print(f'vmin: {(ydata[0]-ydata[1])*1000} mV')
|
||||
|
||||
plt.clf()
|
||||
plt.plot(xdata, ydata, label="Equation after Datasheet")
|
||||
plt.step(xdata, ydata, label="Equation after Datasheet", where='mid', linewidth=.1)
|
||||
|
||||
vps = vtp.fit(
|
||||
xdata,
|
||||
@@ -145,8 +150,21 @@ def gen_1v8_theory():
|
||||
plt.xlabel("Potentiometer Setting P$_{val}$")
|
||||
plt.ylabel("V$_{MONITOR\_1V8}$ / V")
|
||||
|
||||
plt.savefig('v18.pdf', transparent=True)
|
||||
rect = mpl.patches.Rectangle((48,1.81),32,.08,linewidth=1, edgecolor='gray',facecolor='none')
|
||||
plt.gca().add_patch(rect)
|
||||
|
||||
plt.savefig('v18.pdf', transparent=True)
|
||||
plt.cla()
|
||||
plt.clf()
|
||||
plt.figure(figsize=(4, 2))
|
||||
|
||||
|
||||
plt.step(xdata[48:80], ydata[48:80], label="Equation after Datasheet", where='mid', linewidth=.1)
|
||||
plt.gca().xaxis.set_major_formatter(mpt.FuncFormatter(
|
||||
lambda v, x: '0x{:02x}'.format(int(v))
|
||||
))
|
||||
|
||||
plt.savefig('v18_zoom.pdf', transparent=True)
|
||||
|
||||
if __name__ == "__main__":
|
||||
gen_48v_theory()
|
||||
|
||||
Binary file not shown.
@@ -1,9 +1,9 @@
|
||||
\ExplSyntaxOn
|
||||
\newcommand{\pyval}[1]{%
|
||||
\str_case:nn{#1}{%
|
||||
{ 0 }{ m = \SI{-1.6911+-0.0000}{ }}
|
||||
{ 1 }{ p = \SI{567.6618+-0.0000}{ }}
|
||||
{ 2 }{ a = \SI{-621.1199+-0.0000}{ }}
|
||||
{ 0 }{ m = \SI{-7.2588+-0.0000}{ }}
|
||||
{ 1 }{ p = \SI{2436.5476+-0.0000}{ }}
|
||||
{ 2 }{ a = \SI{-2666.0034+-0.0000}{ }}
|
||||
{ 3 }{ c = \SI{0.9318+-0.0000}{ }}
|
||||
}
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user