IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jan 24, 2011, 2:43:37 PM (15 years ago)
Author:
watersc1
Message:

added -updatepzexp mode to pztool so the state can be set for bad exposures

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTools/src/pztool.c

    r30227 r30353  
    4747static bool advanceMode(pxConfig *config);
    4848
     49static bool updatepzexpMode(pxConfig *config);
    4950static bool updatenewexpMode(pxConfig *config);
    5051
     
    8586        MODECASE(PZTOOL_MODE_TOADVANCE, toadvanceMode);
    8687        MODECASE(PZTOOL_MODE_ADVANCE, advanceMode);
     88        MODECASE(PZTOOL_MODE_UPDATEPZEXP, updatepzexpMode);
    8789        MODECASE(PZTOOL_MODE_UPDATENEWEXP, updatenewexpMode);
    8890        default:
     
    894896            || (strncmp(state, "stop", 5) == 0)
    895897            || (strncmp(state, "reg", 4) == 0)
     898            || (strncmp(state, "drop", 5) == 0)
    896899        )
    897900    ) {
     
    910913}
    911914
     915static bool updatepzexpMode(pxConfig *config)
     916{
     917  PS_ASSERT_PTR_NON_NULL(config, false);
     918  PXOPT_LOOKUP_STR(exp_name, config->args, "-exp_name", true, false);
     919  PXOPT_LOOKUP_STR(camera,   config->args, "-camera",   true, false);
     920  PXOPT_LOOKUP_STR(telescope,config->args, "-telescope",true, false);
     921  PXOPT_LOOKUP_STR(state,    config->args, "-set_state",true, false);
     922
     923  if (!pzDownloadExpSetState(config,exp_name,camera,telescope,state)) {
     924    psError(PS_ERR_UNKNOWN, false, "failed to change state for %s:%s:%s", exp_name, camera, telescope);
     925    return false;
     926  }
     927  return true;
     928}
     929 
     930 
    912931static bool updatenewexpMode(pxConfig *config)
    913932{
     
    952971
    953972
     973
     974
    954975#if 0
    955976static psArray *pzArrayAddArray(psArray *array, psArray *input)
Note: See TracChangeset for help on using the changeset viewer.