Loading…
Loading…
Method Name: mth_measure_echo_profile
Method ID: 0x44E4
Method Label: Measure
Method Help:
- {
- char status[3];
- int transNumber;
- int number_of_tries;
- float progress;
- float factor;
- int nStart_y_axis;
- int nConf_long;
- int nWindow_sill;
- int result;
- float fX_axis_value;
- float fEcho_lock_window;
- float fX_axis_end;
- float fX_axis_start;
- send_command(150);
- DELAY_TIME(3);
- send_command(150);
- progress = 0;
- PUT_MESSAGE(literal_string(582));
- result = SELECT_FROM_LIST(literal_string(583),literal_string(584));
- if (result == 0)
- {
- progress = 5;
- }
- else
- {
- progress = 0.13;
- }
- PUT_MESSAGE(literal_string(582));
- _set_resp_code(32,0);
- number_of_tries = 0;
- do {
- send(150,status);
- DELAY_TIME(5);
- }
- while (status[0] == 32 && number_of_tries++ < 10);
- if (result == 0)
- {
- progress = 10;
- }
- else
- {
- progress = 0.22;
- }
- PUT_MESSAGE(literal_string(582));
- if (result == 0)
- {
- progress = -0.3;
- }
- else
- {
- progress = -1.77;
- }
- if (result == 0)
- {
- for (transNumber = 129; transNumber < 135; transNumber++)
- {
- send_trans(151,transNumber,status);
- progress = progress + 16.6;
- PUT_MESSAGE(literal_string(582));
- if (status[0] == 6)
- {
- process_abort();
- }
- }
- }
- else
- {
- for (transNumber = 1; transNumber < 34; transNumber++)
- {
- send_trans(151,transNumber,status);
- progress = progress + 2.5;
- PUT_MESSAGE(literal_string(582));
- if (status[0] == 6)
- {
- process_abort();
- }
- }
- }
- DELAY_TIME(2);
- send_command(170);
- send_command(206);
- send_command(218);
- send_command(210);
- send_command(1);
- switch (_ivar_value(16437))
- {
- case 44:
- factor = 0.3048;
- break;
- case 45:
- factor = 1.0;
- break;
- case 47:
- factor = 0.0254;
- break;
- case 48:
- factor = 0.01;
- break;
- case 49:
- factor = 0.001;
- break;
- case 57:
- factor = 1.0;
- break;
- }
- nStart_y_axis = _ivar_value(16847);
- nConf_long = _ivar_value(16590);
- nWindow_sill = _ivar_value(17635);
- fX_axis_value = _fvar_value(16853);
- fX_axis_end = _fvar_value(16851);
- fX_axis_start = _fvar_value(16850);
- fEcho_lock_window = _fvar_value(16434) * factor;
- _fassign(16856,nStart_y_axis + nConf_long);
- _iassign(16859,nWindow_sill);
- _iassign(16858,nWindow_sill + 2);
- if (fEcho_lock_window != 0)
- {
- _fassign(16860,fX_axis_value - fEcho_lock_window / 2.0);
- _fassign(16861,fX_axis_value + fEcho_lock_window / 2.0);
- }
- else
- {
- _fassign(16860,fX_axis_value - (fX_axis_end - fX_axis_start) / 40.0);
- _fassign(16861,fX_axis_value + (fX_axis_end - fX_axis_start) / 40.0);
- }
- if (result == 0)
- {
- _vassign(16862,17502);
- _vassign(16863,17502);
- _vassign(16864,17502);
- _vassign(16865,17502);
- _vassign(16866,17502);
- _vassign(16867,17502);
- _vassign(16868,17502);
- _vassign(16869,17502);
- _vassign(16870,17503);
- _vassign(16871,17503);
- _vassign(16872,17503);
- _vassign(16873,17503);
- _vassign(16874,17503);
- _vassign(16875,17503);
- _vassign(16876,17503);
Please login for more