NEW RUN
This commit is contained in:
@@ -24,4 +24,6 @@
|
|||||||
ETHANOL_DRAIN_OPEN,
|
ETHANOL_DRAIN_OPEN,
|
||||||
LOX_DRAIN_OPEN,
|
LOX_DRAIN_OPEN,
|
||||||
ETHANOL_DRAIN_CLOSED,
|
ETHANOL_DRAIN_CLOSED,
|
||||||
LOX_DRAIN_CLOSED
|
LOX_DRAIN_CLOSED,
|
||||||
|
ENTER_ABORT,
|
||||||
|
EXIT_ABORT
|
||||||
@@ -7,7 +7,7 @@ from datetime import datetime
|
|||||||
import queue
|
import queue
|
||||||
import re
|
import re
|
||||||
|
|
||||||
PORT = "COM7"
|
PORT = "COM9"
|
||||||
|
|
||||||
SerialPort = serial.Serial(port=PORT,baudrate=250000)
|
SerialPort = serial.Serial(port=PORT,baudrate=250000)
|
||||||
input_queue = queue.SimpleQueue()
|
input_queue = queue.SimpleQueue()
|
||||||
|
|||||||
@@ -72,7 +72,7 @@ lbl.grid(row=4, column=0, columnspan=2)
|
|||||||
labels.append(lbl) # index 16
|
labels.append(lbl) # index 16
|
||||||
|
|
||||||
lbl = tk.Label(root, text="Delta Tick:0", width=20, height=3, borderwidth=2, relief="groove", font=("Arial", 14))
|
lbl = tk.Label(root, text="Delta Tick:0", width=20, height=3, borderwidth=2, relief="groove", font=("Arial", 14))
|
||||||
lbl.grid(row=4, column=2, columnspan=2)
|
lbl.grid(row=4, column=1, columnspan=2)
|
||||||
labels.append(lbl) # index 17
|
labels.append(lbl) # index 17
|
||||||
|
|
||||||
# Checkboxes to select plotted (derived) channels
|
# Checkboxes to select plotted (derived) channels
|
||||||
@@ -232,7 +232,7 @@ def update_SI(value: SD.ReturnDecoder):
|
|||||||
# NOTE: mode should be "a" or "a+", not "+a"
|
# NOTE: mode should be "a" or "a+", not "+a"
|
||||||
with open(f"{FILENAME}_SI.csv", "a") as file:
|
with open(f"{FILENAME}_SI.csv", "a") as file:
|
||||||
file.write(f"{value.timestamp},{value.log_message}\n")
|
file.write(f"{value.timestamp},{value.log_message}\n")
|
||||||
print(f"\033[F\033[2Ktime:{value.timestamp}, SI:{value.log_message}", end="\n")
|
print(f"Time:{value.timestamp}, SI:{value.log_message}", end="\n")
|
||||||
|
|
||||||
|
|
||||||
Last_history_call: int = 0
|
Last_history_call: int = 0
|
||||||
@@ -262,6 +262,10 @@ def append_history(adc_values: list, timestamp: int):
|
|||||||
|
|
||||||
# 7-14: Pressures from channels 8..15
|
# 7-14: Pressures from channels 8..15
|
||||||
for i in range(8, 16): # eight pressure sensors
|
for i in range(8, 16): # eight pressure sensors
|
||||||
|
if i == 12:
|
||||||
|
pres = 0.0000153522 * (adc_values[i] / 2) - 6.5652036917
|
||||||
|
history_y[i - 1].append(pres) # 8→7, 15→14
|
||||||
|
else:
|
||||||
pres = 0.0000153522 * adc_values[i] - 6.5652036917
|
pres = 0.0000153522 * adc_values[i] - 6.5652036917
|
||||||
history_y[i - 1].append(pres) # 8→7, 15→14
|
history_y[i - 1].append(pres) # 8→7, 15→14
|
||||||
|
|
||||||
|
|||||||
14
run1.m
14
run1.m
@@ -1,7 +1,8 @@
|
|||||||
close all
|
close all
|
||||||
|
|
||||||
result = readmatrix("3NitrogenTest2_ADC_data.csv");
|
result = readmatrix("SaveData/2025_12_03_16_23_RUN1_ADC.csv");
|
||||||
|
%result = result(14430:end, : );
|
||||||
|
result(:,14) = result(:,14)./2;
|
||||||
time = result(:,1);
|
time = result(:,1);
|
||||||
|
|
||||||
temp = 0.000111 .* result(:,4:9) + 2.31991;
|
temp = 0.000111 .* result(:,4:9) + 2.31991;
|
||||||
@@ -12,23 +13,26 @@ load_cell = result(:,2:3);
|
|||||||
weight = -1.166759307845543e-04 .* 0.5.*(load_cell(:,1) + load_cell(:,2)) + 4.971416323340051e+02;
|
weight = -1.166759307845543e-04 .* 0.5.*(load_cell(:,1) + load_cell(:,2)) + 4.971416323340051e+02;
|
||||||
|
|
||||||
figure()
|
figure()
|
||||||
plot(time,weight)
|
scatter(time,weight,10)
|
||||||
title("load cell in Kg")
|
title("load cell in Kg")
|
||||||
xlabel("Time in ms")
|
xlabel("Time in ms")
|
||||||
ylabel("KG")
|
ylabel("KG")
|
||||||
|
xlim([1101179 1134450+5000])
|
||||||
|
|
||||||
for x = 1:7
|
for x = 1:7
|
||||||
figure()
|
figure()
|
||||||
plot(time,pressure(:,x))
|
scatter(time,pressure(:,x),10)
|
||||||
title(sprintf("Pressure channel %d",x))
|
title(sprintf("Pressure channel %d",x))
|
||||||
xlabel("Time in ms")
|
xlabel("Time in ms")
|
||||||
ylabel("Pressure")
|
ylabel("Pressure")
|
||||||
|
xlim([1101179 1134450+5000])
|
||||||
end
|
end
|
||||||
|
|
||||||
for x = 1:6
|
for x = 1:6
|
||||||
figure()
|
figure()
|
||||||
plot(time,temp(:,x))
|
scatter(time,temp(:,x),10)
|
||||||
title(sprintf("temperature channel %d",x))
|
title(sprintf("temperature channel %d",x))
|
||||||
xlabel("Time in ms")
|
xlabel("Time in ms")
|
||||||
ylabel("Temprature in C")
|
ylabel("Temprature in C")
|
||||||
|
xlim([1101179 1134450+5000])
|
||||||
end
|
end
|
||||||
|
|||||||
38
run2.m
Normal file
38
run2.m
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
close all
|
||||||
|
|
||||||
|
result = readmatrix("SaveData/2025_12_03_13_26_COLD_FIRE_ADC.csv");
|
||||||
|
%result = result(14430:end, : );
|
||||||
|
result(:,14) = result(:,14)./2;
|
||||||
|
time = result(:,1);
|
||||||
|
|
||||||
|
temp = 0.000111 .* result(:,4:9) + 2.31991;
|
||||||
|
|
||||||
|
pressure = result(:,10:17).*(0.000015)-6.565;
|
||||||
|
|
||||||
|
load_cell = result(:,2:3);
|
||||||
|
weight = -1.166759307845543e-04 .* 0.5.*(load_cell(:,1) + load_cell(:,2)) + 4.971416323340051e+02;
|
||||||
|
|
||||||
|
figure()
|
||||||
|
scatter(time,weight,10)
|
||||||
|
title("load cell in Kg")
|
||||||
|
xlabel("Time in ms")
|
||||||
|
ylabel("KG")
|
||||||
|
xlim([1038760 1082100+5000])
|
||||||
|
|
||||||
|
for x = 1:7
|
||||||
|
figure()
|
||||||
|
scatter(time,pressure(:,x),10)
|
||||||
|
title(sprintf("Pressure channel %d",x))
|
||||||
|
xlabel("Time in ms")
|
||||||
|
ylabel("Pressure")
|
||||||
|
xlim([1038760 1082100+5000])
|
||||||
|
end
|
||||||
|
|
||||||
|
for x = 1:6
|
||||||
|
figure()
|
||||||
|
scatter(time,temp(:,x),10)
|
||||||
|
title(sprintf("temperature channel %d",x))
|
||||||
|
xlabel("Time in ms")
|
||||||
|
ylabel("Temprature in C")
|
||||||
|
xlim([1038760 1082100+5000])
|
||||||
|
end
|
||||||
Reference in New Issue
Block a user