|
@@ -21,12 +21,13 @@ class Main(tk.Tk, Table):
|
|
|
self.adc = MCP3008(0,0)
|
|
|
self.pressureSensors = Spd610Array()
|
|
|
self.forceSensors = LoadCells()
|
|
|
+ self.forceSensors.start()
|
|
|
self.motorController = None
|
|
|
|
|
|
Table.__init__(self,
|
|
|
["time", "windspeed", "motor_pwm"] +
|
|
|
[f"pressure_{i}" for i in range(8)] +
|
|
|
- [f"adc_{i}" for i in range(8)] +
|
|
|
+ [f"adc_{i}" for i in range(1)] +
|
|
|
[f"force_X_1", f"force_Y_1", f"force_Z_1"] +
|
|
|
[f"force_X_2", f"force_Y_2", f"force_Z_2"] +
|
|
|
[f"force_X_3", f"force_Y_3", f"force_Z_3"])
|
|
@@ -96,7 +97,14 @@ class Main(tk.Tk, Table):
|
|
|
def interval(self):
|
|
|
adcValues = self.adc.read()
|
|
|
|
|
|
- self.addRow([time.time()] + adcValues)
|
|
|
+ self.addRow(
|
|
|
+ [time.time(), 0, 0] +
|
|
|
+ self.pressureSensors.getValues() +
|
|
|
+ [self.adc.getVoltage(0)] +
|
|
|
+ self.forceSensors.getForces(0) +
|
|
|
+ self.forceSensors.getForces(1) +
|
|
|
+ self.forceSensors.getForces(2)
|
|
|
+ )
|
|
|
for frame in self.frames:
|
|
|
frame.update()
|
|
|
|