Loading…

Method Name: api_setup

Method ID: 0x42C0

Method Label: Petroleum Measurement Set Up

Method Help: This method will step the user through setting up the API parameters.


  • {
  • char status[3];
  • int numberChoice;
  • int letterChoice;
  • int enableApi;
  • long var_id[1];
  • char disp_string[100];
  • char disp_string1[100];
  • int slen;
  • int slen1;
  • int deviceChoice;
  • int loop_choice;
  • deviceChoice = 0;
  • slen1 = 100;
  • slen = 100;
  • _set_xmtr_device_status(0xFF,0);
  • _set_xmtr_all_resp_code(0);
  • _set_device_status(0xFF,0);
  • _set_all_resp_code(0);
  • _iassign(17338,1);
  • _iassign(17339,237);
  • send(162,status);
  • if (varMODBUS_Data_Type_Code == 1 && varCoil_Value == 0x01)
  • {
  • ACKNOWLEDGE(literal_string(1078));
  • process_abort();
  • }
  • ACKNOWLEDGE(literal_string(1121));
  • do {
  • deviceChoice = SELECT_FROM_LIST(literal_string(1122),literal_string(1123));
  • switch (deviceChoice)
  • {
  • case 0:
  • loop_choice = 1;
  • break;
  • case 1:


Please login for more