diff --git a/dashboard/templates/clasp.html b/dashboard/templates/clasp.html
index ada58e2..9a4c8ec 100644
--- a/dashboard/templates/clasp.html
+++ b/dashboard/templates/clasp.html
@@ -43,7 +43,7 @@
@@ -100,6 +100,10 @@
|
|
+
+ Chiller |
+ |
+
diff --git a/static/rockit-dashboard.js b/static/rockit-dashboard.js
index ac113a7..73a9ed1 100644
--- a/static/rockit-dashboard.js
+++ b/static/rockit-dashboard.js
@@ -357,7 +357,6 @@ function focusState(row, cell, data) {
const current_steps = getData(focuser_data, ['current_steps_' + focuser]);
const moving = getData(focuser_data, ['moving_' + focuser]);
- console.log('powered', powered);
let label, style;
if (powered === 0) {
label = 'POWER OFF';
@@ -661,6 +660,37 @@ function lensTemperature(row, cell, data) {
}
}
+function chillerState(row, cell, data) {
+ const mode = getData(data, ["mode"]);
+ const status = getData(data, ["status"]);
+ const tec_power = getData(data, ["tec_power"]);
+ const water_temp = getData(data, ["water_temp"]);
+
+ let mode_label;
+ if (mode === 1) {
+ mode_label = 'AUTO';
+ } else {
+ mode_label = 'MANUAL';
+ }
+
+ let status_label;
+ if (status === 1) {
+ status_label = 'IDLE';
+ } else if (status === 2) {
+ status_label = 'COOLING (' + tec_power.toFixed(0) + '%)';
+ } else if (status === 3) {
+ status_label = 'HEATING (' + tec_power.toFixed(0) + '%)';
+ } else {
+ status_label = 'OFFLINE';
+ }
+
+ let label = mode_label + ' / ' + status_label;
+ if (water_temp !== undefined)
+ label += ' / ' + water_temp.toFixed(1) + '°C';
+
+ cell.html(label);
+}
+
function roofBattery(row, cell, data) {
if (data != null) {
let display = data.toFixed(2);
diff --git a/update-dashboard-data b/update-dashboard-data
index c0aacad..a295c5c 100644
--- a/update-dashboard-data
+++ b/update-dashboard-data
@@ -314,7 +314,8 @@ def generate_clasp_json(output_path, date, environment, status):
(daemons.clasp_camvirt_1, 'clasp_cam1', lambda d: d.report_camera_status('cam1')),
(daemons.clasp_camera_2, 'clasp_cam2', lambda d: d.report_status()),
(daemons.clasp_power, 'clasp_power', lambda d: d.last_measurement()),
- (daemons.clasp_dehumidifier, 'clasp_dehumidifier', lambda d: d.status())
+ (daemons.clasp_dehumidifier, 'clasp_dehumidifier', lambda d: d.status()),
+ (daemons.clasp_chiller, 'clasp_chiller', lambda d: d.report_status())
], status))
output.update(extract_preview_data({