Add status indicators for ign/exh

This commit is contained in:
Skylar Grant 2023-11-17 10:18:40 -05:00
parent 78a502e959
commit 1919a9c518

View File

@ -22,7 +22,9 @@
<div id="status" class="row"> <div id="status" class="row">
<!-- <!--
| Auger | rows[0].cells[1] | Auger | rows[0].cells[1]
| Feed Rate | rows[1].cells[1] | Igniter | rows[1].cells[1]
| Exhaust | rows[2].cells[1]
| Feed Rate | rows[3].cells[1]
--> -->
<table id="status-table" class="table table-bordered col-sm-12 col-md-6"> <table id="status-table" class="table table-bordered col-sm-12 col-md-6">
@ -30,6 +32,14 @@
<td>Auger</td> <td>Auger</td>
<td></td> <td></td>
</tr> </tr>
<tr>
<td>Igniter</td>
<td></td>
</tr>
<tr>
<td>Exhaust</td>
<td></td>
</tr>
<tr> <tr>
<td>Feed Rate</td> <td>Feed Rate</td>
<td></td> <td></td>
@ -116,12 +126,16 @@
// Get the elements we need to update // Get the elements we need to update
const statusTable = document.getElementById('status-table'); const statusTable = document.getElementById('status-table');
const augerStatus = statusTable.rows[0].cells[1]; const augerStatus = statusTable.rows[0].cells[1];
const feedRate = statusTable.rows[1].cells[1]; const igniterStatus = statusTable.rows[1].cells[1];
const exhaustStatus = statusTable.rows[2].cells[1]
const feedRate = statusTable.rows[3].cells[1];
const feedRateSelect = document.getElementById('feed-rate-select'); const feedRateSelect = document.getElementById('feed-rate-select');
// console.log(config); // console.log(config);
augerStatus.innerHTML = parseStatus(config.status.auger); augerStatus.innerHTML = parseStatus(config.status.auger);
igniterStatus.innerHTML = parseStatus(config.status.igniter);
exhaustStatus.innerHTML = parseStatus(config.status.exhaust);
switch (config.intervals.augerOn) { switch (config.intervals.augerOn) {
case '500': case '500':