You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

263 lines
4.9 KiB

<html>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<head>
<title>
Dwingeloo console interface
</title>
</head>
<body background="achtergrond.jpg" >
<p>
<!--
Basic Azimuth & Elevation status
-->
<div id="dt_status"></div>
</p>
<p>
<!--
Authorization
-->
<div id="authorization"></div>
</p>
<p>
<table border="0">
<tr>
<td>
<!--
Sun
Moon
Manual control
Azel
Satellite
-->
<div id="spg_sun"></div>
<div id="spg_moon"></div>
<div id="spg_manual"></div>
<div id="spg_azel"></div>
<div id="spg_j2000"></div>
<div id="spg_sat"></div>
</td>
<!--
Offset
-->
<td>
<div id="offset"></div>
</td>
<!--
DT model
-->
<td>
<div id="model"></div>
<!--
end of box row
-->
</td>
</tr>
</table>
<div id="log"></div>
<p>
<div>
<table width="100%" border="0">
<tr>
<td>
<a href="mech.html" target="_blank">Mechanics</a>
</td>
<td>
<a href="log/" target="_blank">Logs</a>
</td>
<td>
<a href="trace.html" target="_blank">Trace</a>
</td>
<td align="center">
<b>
<a href="help.html" target="_blank">Help</a>
</b>
</td>
<td align="right">
<script type="text/javascript" src="console_version.js"></script>
</td>
</tr>
</table>
</div>
</p>
</body>
<script src="js/load.js" type="application/javascript"></script>
<script type="text/javascript">
/*
Copyright Jeroen Vreeken (pe1rxq@amsat.org), 2008, 2009, 2011, 2012,
2013
Copyright Stichting C.A. Muller Radioastronomiestation, 2008, 2009,
2011, 2012, 2013
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/* 'includes' */
eval(load("js/dt_ui.js"));
eval(load("js/trace.js"));
eval(load("js/azel.js"));
eval(load("js/j2000.js"));
eval(load("js/status.js"));
eval(load("js/manual.js"));
eval(load("js/sun.js"));
eval(load("js/moon.js"));
eval(load("js/sat.js"));
eval(load("js/dt_view.js"));
eval(load("js/authorization.js"));
eval(load("js/utils.js"));
eval(load("js/offset.js"));
eval(load("js/model.js"));
eval(load("js/dt_websocket.js"));
eval(load("js/log.js"));
eval(load("js/dt_status.js"));
new dt_websocket("ws://"+ window.location.host +"/dt");
/*
'constants'
*/
var trace_url = "trace.cgi";
/******************************************************************
*
* Manual, sun and moon, azimuth & elevation
*
******************************************************************/
var status_dt = new dt_status("dt_status");
var manual_spg = new manual("spg_manual");
var sun_spg = new sun("spg_sun");
var moon_spg = new moon("spg_moon");
var azel_spg = new azel("spg_azel");
var j2000_spg = new j2000("spg_j2000");
var sat_spg = new sat("spg_sat");
var auth_win = new authorization("authorization");
var model_win = new model("model");
var offset_win = new offset("offset");
function offset_cb(azimuth_off, elevation_off)
{
offset_win.set_offset(azimuth_off, elevation_off);
}
auth_win.offset_cb = offset_cb;
var log_win = new log("log");
auth_win.tracker_window_set("console/azel", azel_spg);
auth_win.tracker_window_set("console/j2000tracker", j2000_spg);
auth_win.tracker_window_set("console/moontracker", moon_spg);
auth_win.tracker_window_set("console/suntracker", sun_spg);
auth_win.tracker_window_set("console/sattracker", sat_spg);
auth_win.tracker_window_set("console/manual", manual_spg);
/*
Azimuth
*/
var azimuth_enable_command = new controller_command("azimuth_servo_state", "bool");
var elevation_enable_command = new controller_command("elevation_servo_state", "bool");
var elevation_recover_command = new controller_command("elevation_safety", "bool");
status_dt.button_az_enable.onclick = function() {
auth_win.idle();
azimuth_enable_command.send(1);
}
status_dt.button_el_enable.onclick = function() {
auth_win.idle();
elevation_enable_command.send(1);
elevation_recover_command.send(0);
}
status_dt.button_disable.onclick = function() {
auth_win.idle();
azimuth_enable_command.send(0);
elevation_enable_command.send(0);
elevation_recover_command.send(0);
status_dt.fb_enable_command.send(0);
}
/******************************************************************
*
* Azel spg control
*
******************************************************************/
azel_spg.azimuth_position_get = function() { return status_dt.azimuth_position_get(); }
azel_spg.elevation_position_get = function() { return status_dt.elevation_position_get(); }
</script>
</html>