Commit 38d9872b authored by Jeroen Vreeken's avatar Jeroen Vreeken
Browse files

Only one disable button in the console

parent cbeb4fd3
......@@ -44,11 +44,8 @@
<td>
<span id="azimuth_enable"></span>
</td>
<td>
<span id="azimuth_disable"></span>
</td>
<td>
<span id="azimuth_emergency"></span>
<td rowspan="2">
<span id="azimuth_elevation_disable"></span>
</td>
<td>
Status:
......@@ -85,12 +82,6 @@
<td>
<span id="elevation_enable"></span>
</td>
<td>
<span id="elevation_disable"></span>
</td>
<td>
<span id="elevation_emergency"></span>
</td>
<td>
Status:
</td>
......@@ -812,18 +803,12 @@ function check_floatval(element)
*/
var azimuth_enable_param = 'controller \'params { { "azimuth_servo_state", "enabled", (int)1 } } \' ';
var azimuth_disable_param = 'controller \'params { { "azimuth_servo_state", "enabled", (int)0 } } \' ';
var azimuth_emergency_param = 'controller \'params { { "azimuth_servo_state", "emergency", (int)1 } } \' ';
var azimuth_elevation_disable_param = 'controller \'params { { "azimuth_servo_state", "enabled", (int)0 } { "elevation_servo_state", "enabled", (int)0 } { "elevation_safety", "recover", (int)0 } } \' ';
var azimuth_disable = new dt_button("azimuth_disable");
var azimuth_disable = new dt_button("azimuth_elevation_disable");
azimuth_disable.background("red");
azimuth_disable.value("Disable");
azimuth_disable.click(function() { do_auth('console/idle'); do_shell(azimuth_disable_param); } );
var azimuth_emergency = new dt_button("azimuth_emergency");
azimuth_emergency.background("red");
azimuth_emergency.value("Emergency");
azimuth_emergency.click(function() { do_auth('console/idle'); do_shell(azimuth_emergency_param); } );
azimuth_disable.click(function() { do_auth('console/idle'); do_shell(azimuth_elevation_disable_param); } );
var azimuth_enable = new dt_button("azimuth_enable");
azimuth_enable.background("springgreen");
......@@ -991,18 +976,6 @@ var el_setpoint_value = 0;
var el_setpoint_value_last = -30;
var elevation_enable_param = 'controller \'params { { "elevation_servo_state", "enabled", (int)1 } { "elevation_safety", "recover", (int)0 } } \' ';
var elevation_disable_param = 'controller \'params { { "elevation_servo_state", "enabled", (int)0 } { "elevation_safety", "recover", (int)0 } } \' ';
var elevation_emergency_param = 'controller \'params { { "elevation_servo_state", "emergency", (int)1 } { "elevation_safety", "recover", (int)0 } } \' ';
var elevation_disable = new dt_button("elevation_disable");
elevation_disable.background("red");
elevation_disable.value("Disable");
elevation_disable.click(function() { do_shell(elevation_disable_param); do_auth('console/idle'); } );
var elevation_emergency = new dt_button("elevation_emergency");
elevation_emergency.background("red");
elevation_emergency.value("Emergency");
elevation_emergency.click(function() { do_shell(elevation_emergency_param); do_auth('console/idle'); } );
var elevation_enable = new dt_button("elevation_enable");
elevation_enable.background("springgreen");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment