diff options
-rw-r--r-- | python/gui/static/js/odr-home.js | 22 | ||||
-rw-r--r-- | python/gui/templates/home.html | 4 |
2 files changed, 24 insertions, 2 deletions
diff --git a/python/gui/static/js/odr-home.js b/python/gui/static/js/odr-home.js index 11aed8e..9498ae7 100644 --- a/python/gui/static/js/odr-home.js +++ b/python/gui/static/js/odr-home.js @@ -95,7 +95,7 @@ function check_modulating(last_num_frames) { } else { mark_ok('is_modulating', "Number of frames modulated: " + data); - check_dpdce_running(); + check_rate_4x(); } } } @@ -108,10 +108,28 @@ function check_modulating(last_num_frames) { }); } +function check_rate_4x() { + mark_pending('is_rate_4x'); + apiRequestChain("/api/parameter", + {controllable: 'modulator', param: 'rate'}, + function(data) { + if (data == 8192000) { + mark_ok('is_rate_4x', "Samplerate: " + data); + check_dpdce_running(); + } + else { + mark_fail('is_rate_4x', "Samplerate is not 8192ksps: " + data); + } + }, + function(data) { + mark_fail('is_rate_4x', JSON.parse(data)['reason']); + }); +} + function check_dpdce_running() { mark_pending('is_dpdce_running'); apiRequestChain("/api/dpd_results", - {controllable: 'sdr', param: 'frames'}, + {}, function(data) { mark_ok('is_dpdce_running', "State: " + data['state']); mark_ok('overall_state'); diff --git a/python/gui/templates/home.html b/python/gui/templates/home.html index bf802d6..0a0713a 100644 --- a/python/gui/templates/home.html +++ b/python/gui/templates/home.html @@ -27,6 +27,10 @@ <p>Checking predistortion <ul> + <li>Sample rate at 4x native rate: + <span id="is_rate_4x" class="glyphicon glyphicon-question-sign"></span> + <span id="is_rate_4x_comment"><span> + </li> <li>DPDCE running: <span id="is_dpdce_running" class="glyphicon glyphicon-question-sign"></span> <span id="is_dpdce_running_comment"><span> |