Commit 9fda9d9b authored by Tristan Renon's avatar Tristan Renon
Browse files

Add into text box + NSamples = 50 + I hope it deleted extracted folders

parent 8d951cd4
......@@ -24,6 +24,17 @@ class Window(Frame):
self.textPhaseShiftMec.delete(0, 'end')
self.textPhaseShiftReg.delete(0, 'end')
def setStrings(self):
self.textPhases.delete(0, 'end')
self.textPhaseAmplitude.delete(0, 'end')
self.textPhaseShiftMec.delete(0, 'end')
self.textPhaseShiftReg.delete(0, 'end')
self.textPhases.insert(0, self.nPhases)
self.textPhaseAmplitude.insert(0, repr(self.phaseAmplitude)[7:-2])
self.textPhaseShiftMec.insert(0, repr(self.phaseShiftMec)[7:-2])
self.textPhaseShiftReg.insert(0, repr(self.phaseShiftReg)[7:-2])
def Plot(self):
self.inputNPhases = int(self.textPhases.get())
self.inputPhaseAmplitude = np.ones(self.inputNPhases)
......@@ -111,6 +122,8 @@ class Window(Frame):
phaseShiftMec=self.inputPhaseShiftMec,
nSamples=self.inputnSamples)
self.setStrings()
self.ax3.cla()
self.ax1.cla()
self.ax2.cla()
......@@ -327,7 +340,7 @@ class Window(Frame):
# -----------------------------------------------------------------------------------
self.inputChange = False
self.inputnSamples = 100
self.inputnSamples = 50
self.inputNPhases = 5
self.inputPhaseAmplitude = (0, 1.382, 1.382, 1.382, 1.382)
self.inputPhaseShiftMec = (0, 72, 144, 216, 288)
......@@ -404,7 +417,7 @@ class Window(Frame):
self.canvas = FigureCanvasTkAgg(self.fig, master=self)
self.canvas.get_tk_widget().grid(row=18, column=0)
self.ani = animation.FuncAnimation(self.fig, self.animate, interval=0.5, frames=self.inputnSamples, blit=False, save_count=self.inputnSamples)
self.ani = animation.FuncAnimation(self.fig, self.animate, interval=1, frames=self.inputnSamples, blit=False, save_count=self.inputnSamples)
root = tk.Tk()
......
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