Execution Sequence of Operations within a gp_test mode

The Test Manager (gp_test) uses a unique language for specifying actions within a test mode for setting control targets, requesting fuel readings, setting variable values, and so on.  The gp_test language is not a scripting language where the sequence of operation is based on the sequence in which the operations are specified.  Instead, there is a hard-coded sequence of operation.  The following describes the sequence of actions when a test mode is started.  This sequence is unrelated to the order in which the corresponding keywords are entered in the gp_test procedure file.

  1. Perform conditional tests to see if the mode is to be skipped.  The conditional test are @IF_TRUE, @IF_FALSE, and @SWITCH.  If the tests indicate that a new mode or test procedure should be started, then the mode is exited and none of the other actions are executed except those which have a start_code of “AT_END”.
  2. Any @PARAMETERS or @SET_DISPLAY_STATUS values will be set.
  3. Any control loop operations are executed. (@SPEED, @TORQUE, @DYNO, @THROTTLE, @USER_LOOP, @PID_GAINS, @ENGINE_CONTROL_MODE, @PID_GAINS, @FEED_FORWARD, @GET_PID_GAINS, @GET_FF_GAIN, @CONTROL_TOLERANCE)
  4. Send any events specified by @SET_EVENTS.
  5. Configure any limits specifications specified by @LIMIT_SPECS.
  6. Configure any ramping operations specified by @RAMP or @RAMP_DYNAMIC
  7. Configure fuel reading operations specified by @FUEL_READING, @PAM_DATAPOINT, @FUEL_READING_SYNC, and @FUEL_READING_STATS
  8. Communicate with any applications launched by @AUXILIARY_TASK or @TEST_TABLE
  9. Configure any stability operations specified by @STABILITY_SPECS
  10. Perform communications specified by @ASC
  11. Perform all ECM communications specified the @ASAM3…. Keywords
  12. Perform any file writing operations specified by @WRITE_VALUES
  13. Launch background scripts specified by @BACKGROUND and @BACKGROUND_TASKS
  14. Perform AK and DEVCOM communications
  15. Perform an CYBER related configuration commands
  16. Send any specified emails specified by @EMAIL
  17. Perform UNICO related communications with the dyno controller
  18. Configure operations specified for multi-filter changers (@MFC_CMD)
  19. Configure operations specified by @CHAIN_EVENTS (cyflex.6.3.0 and later)
  20. Configure state machine operations specified by @STATE_MON_ACTIONS and related STATE_MON keywords.

As an example, if you use@AUXILIARY_TASK to read a value from a file, you specify the index in the file (often using the ‘count’ integer variable ).  In the gp_test procedure file you could do the following:

########################################################

@AUXILIARY_TASK
AT_START                                          MODE_TERMINATE                           99
/cyflex/bin/vrbl_to_file   “specs/gp/myfile READ count”

@PARAMETERS
AT_START                           count                   100

This would cause vrbl_to_file to read index 100 from “myfile”, because @PARAMETERS are executed BEFORE @AUXILIARY_TASK operations.  So, it really doesn’t matter where the @PARAMETERS keyword is positioned within the mode, that operation happens before the value of the ‘count’ variable is sent to vrbl_to_file.