-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #577 from visualapproach/development_v4
Development v4
- Loading branch information
Showing
42 changed files
with
1,043 additions
and
494 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<title>Lay-Z-Spa Module | SPA Manual calibration</title> | ||
<meta charset="utf-8"> | ||
<link rel="icon" type="image/png" sizes="48x48" href="favicon.png"> | ||
<link rel="manifest" href="manifest.json"> | ||
<link rel="stylesheet" href="main.css"> | ||
<meta name="theme-color" content="#0066BF"> | ||
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport"> | ||
<script src="function.js" type="text/javascript"></script> | ||
</head> | ||
|
||
<body> | ||
<div id="site"> | ||
<header> | ||
<span>SPA Manual calibration</span> | ||
<a href="javascript:void(0);" class="topnavicon" onclick="topNav()"></a> | ||
</header> | ||
|
||
<div class="topnav" id="topnav"> | ||
<a href="./">Home</a> | ||
<a href="hwconfig.html">Hardware Config</a> | ||
<a href="config.html" class="active">SPA Config</a> | ||
<a href="webconfig.html">Web Config</a> | ||
<a href="wifi.html">Network Config</a> | ||
<a href="mqtt.html">MQTT Config</a> | ||
<a href="/dir/">Directory</a> | ||
<a href="upload.html">File Uploader</a> | ||
<a href="remove.html">File Remover</a> | ||
<a href="chkupdatefw.html">Check firmware update</a> | ||
<a href="/restart/">Restart ESP</a> | ||
<!-- <a href="javascript:void(0);" class="bgred" onclick="sendCommand('restartEsp')">Restart ESP</a> --> | ||
</div> | ||
|
||
<section> | ||
<table> | ||
<tr> | ||
<td><label for="maxtemp">Starting temp:</label></td> | ||
<td><input type="text" id="maxtemp" value="30" maxlength="3" size="4"></td> | ||
</tr> | ||
<tr> | ||
<td><label for="mintemp">Ending temp:</label></td> | ||
<td><input type="text" id="mintemp" value="28" maxlength="3" size="4"></td> | ||
</tr> | ||
<tr> | ||
<td><label for="amb">Avg. ambient temp.:</label></td> | ||
<td><input type="text" id="amb" value="16" maxlength="3" size="4"></td> | ||
</tr> | ||
<tr> | ||
<td><label for="finterval">time (minutes):</label></td> | ||
<td><input type="text" id="minutes" value="120" maxlength="3" size="4"></td> | ||
</tr> | ||
<tr> | ||
<td colspan="2" class="center"><button id="save" class="button" onclick="buttonConfirm(this);saveConfig()">Save</button></td> | ||
</tr> | ||
</table> | ||
</section> | ||
|
||
<script> | ||
|
||
function saveConfig() | ||
{ | ||
var maxtemp = document.getElementById('maxtemp').value; | ||
var mintemp = document.getElementById('mintemp').value; | ||
var amb = document.getElementById('amb').value; | ||
var hours = document.getElementById('minutes').value / 60.0; | ||
var r = hours/Math.log((maxtemp-amb)/(mintemp-amb)); | ||
console.log('r: ', r); | ||
var req = new XMLHttpRequest(); | ||
req.open('POST', '/addcommand/'); | ||
var json = { | ||
'CMD':21, | ||
'VALUE':Math.round(r*1000000), | ||
'XTIME':0, | ||
'INTERVAL':0, | ||
'TXT':'r set' | ||
}; | ||
req.send(JSON.stringify(json)); | ||
console.log(json); | ||
} | ||
|
||
</script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,144 @@ | ||
300 | ||
0.9 | ||
659 | ||
0.5 | ||
622 | ||
0.5 | ||
659 | ||
0.5 | ||
622 | ||
0.5 | ||
659 | ||
0.5 | ||
494 | ||
0.5 | ||
587 | ||
0.5 | ||
523 | ||
0.5 | ||
440 | ||
0.5 | ||
0 | ||
0.5 | ||
262 | ||
0.5 | ||
330 | ||
0.5 | ||
440 | ||
0.5 | ||
494 | ||
0.5 | ||
0 | ||
0.5 | ||
330 | ||
0.5 | ||
415 | ||
0.5 | ||
494 | ||
0.5 | ||
523 | ||
0.5 | ||
0 | ||
0.5 | ||
330 | ||
0.5 | ||
659 | ||
0.5 | ||
622 | ||
0.5 | ||
659 | ||
0.5 | ||
622 | ||
0.5 | ||
659 | ||
0.5 | ||
494 | ||
0.5 | ||
587 | ||
0.5 | ||
523 | ||
0.5 | ||
440 | ||
0.5 | ||
0 | ||
0.5 | ||
262 | ||
0.5 | ||
330 | ||
0.5 | ||
440 | ||
0.5 | ||
494 | ||
0.5 | ||
0 | ||
0.5 | ||
330 | ||
0.5 | ||
523 | ||
0.5 | ||
494 | ||
0.5 | ||
440 | ||
0.5 | ||
0 | ||
0.5 | ||
262 | ||
0.5 | ||
330 | ||
0.5 | ||
440 | ||
0.5 | ||
494 | ||
0.5 | ||
0 | ||
0.5 | ||
330 | ||
0.5 | ||
415 | ||
0.5 | ||
494 | ||
0.5 | ||
523 | ||
0.5 | ||
0 | ||
0.5 | ||
330 | ||
0.5 | ||
659 | ||
0.5 | ||
622 | ||
0.5 | ||
659 | ||
0.5 | ||
622 | ||
0.5 | ||
659 | ||
0.5 | ||
494 | ||
0.5 | ||
587 | ||
0.5 | ||
523 | ||
0.5 | ||
440 | ||
0.5 | ||
0 | ||
0.5 | ||
262 | ||
0.5 | ||
330 | ||
0.5 | ||
440 | ||
0.5 | ||
494 | ||
0.5 | ||
0 | ||
0.5 | ||
330 | ||
0.5 | ||
523 | ||
0.5 | ||
494 | ||
0.5 | ||
440 | ||
0.5 |
Oops, something went wrong.