Loading…

Method Name: refresh_echo_history_graph_method

Method ID: 0x471A

Method Label: Atualizar Gráfico Histórico Eco

Method Help: Clique para atualizar a Curva de Eco.


  • {
  • char status[3];
  • int temp_array_index;
  • int cscratch;
  • int max_pos_value;
  • int max_neg_value;
  • long i;
  • long array_index;
  • long received_index;
  • long block;
  • long num_blocks;
  • long success;
  • long datapoint;
  • long datapointvalue;
  • float conv_to_units;
  • float ref_offset;
  • float echodeltaX;
  • float fscratch;
  • float fscratch1;
  • int point_interval;
  • int total_graphed_points;
  • int last_index;
  • float first_x_location;
  • float last_x_location;
  • float threshold_slope;
  • float lvl_threshold_slope;
  • float ifc_threshold_slope;
  • _set_device_status(0xFF,0);
  • _set_all_resp_code(0);
  • _set_xmtr_device_status(0xFF,0);
  • _set_xmtr_all_resp_code(0);
  • curve_selection = history1_select;
  • requested_runtime = echo_runtimes[curve_selection];
  • save_values();
  • send_trans(224,0,status);
  • if (status[0] == 2)
  • {
  • ACKNOWLEDGE(literal_string(1577));
  • process_abort();
  • }
  • DELAY_TIME(1);
  • success = 0;
  • for (i = 1; i <= 3; i++)
  • {
  • send(225,status);
  • if (status[0] == 0)
  • {
  • save_values();
  • success = 1;
  • i = 4;
  • }
  • DELAY_TIME(1);
  • }
  • if (!success)
  • {
  • if (status[0] == 10)
  • {
  • ACKNOWLEDGE(literal_string(1578));
  • _add_abort_method(18205);
  • }
  • else
  • {
  • ACKNOWLEDGE(literal_string(1579));
  • }
  • clear_curve1_method();
  • clear_curve2_method();
  • process_abort();
  • }
  • if (CurveEndIndex == 0)
  • {
  • ACKNOWLEDGE(literal_string(1580));
  • clear_curve1_method();
  • clear_curve2_method();
  • process_abort();
  • }
  • if (CurveEndIndex > 1750 - 1)
  • {
  • CurveEndIndex = 1750 - 1;
  • }
  • switch (level_units)
  • {
  • case 47:
  • conv_to_units = 0.03937;
  • break;
  • case 48:
  • conv_to_units = 0.1;
  • break;
  • case 45:
  • conv_to_units = 0.001;
  • break;
  • case 44:
  • conv_to_units = 0.00328083;
  • break;
  • default:
  • conv_to_units = 1;
  • break;
  • }


Please login for more