Add current program cycle/counter status to the api

Issue #21 resolved
Myles Metzler created an issue

This will be added to the endpoint "/api/v1.1/chambers/1/operations" Note that /api/v1.0 remains the same for compatibility. /api/edge/ was added to allow access to the newest api version at all times.

Comments (1)

  1. Myles Metzler reporter

    On /api/v1.1/... or /api/edge/... routes that have the operations parameter now have operations.program.counters parameter:

      ...
      "operations": {
        "datetime": {
          "strftime": "Wed Apr 05 2017 08:36:54", 
          "uts": 1491381414.0
        }, 
        "mode": "Program Running", 
        "program": {
          "counters": [
            {
              "cycles": 99, 
              "end": 3, 
              "name": "A", 
              "remaining": 99, 
              "start": 2
            }, 
            {
              "cycles": 0, 
              "end": 0, 
              "name": "B", 
              "remaining": 0, 
              "start": 0
            }
          ], 
          "editor": "/program/editor?number=1", 
          "name": "CUBIC01", 
          "number": 1, 
          "step": 1, 
          "time_end": "Sun Apr 09 2017 12:56", 
          "time_step": "0:10:00", 
          "time_total": "100:20:00", 
          "uri": "http://webdevscp220/api/v1.1/chambers/1/programs/1"
        }
      },
      ...
    

    On /api/v1.1/... or /api/edge/... routes that have the controllers parameter now have the stoppable parameter:

    ...
    "controllers": [
        {
          "cascade": false, 
          "humidity": true, 
          "indConstant": true, 
          "model": "Espec,SCP220", 
          "stoppable": true
        }
      ],
      ...
    
  2. Log in to comment