Jump to content

SENSBLUE ATLAS/Datasheet: Difference between revisions

No edit summary
Line 755: Line 755:
   "task": {
   "task": {
     "taskParams": {
     "taskParams": {
      "CLOCK_SET_MODE": {
        "mode": "timer",
        "alarmSet": "[timestamp epoch ms]",
        "timerSetSeconds": "<INT>"
      }
    }
  }
}
</syntaxhighlight>Req-Topic: clock/config/out<syntaxhighlight lang="json">
{
  "id": "<TIMESTAMP>",
  "origin": "APP",
  "task": {
    "taskResult": {
      "success": true,
       "CLOCK_SET_MODE": {
       "CLOCK_SET_MODE": {
         "mode": "timer",
         "mode": "timer",
Line 764: Line 779:
}
}
</syntaxhighlight>
</syntaxhighlight>
===== 26.1.2 Toggle RTC sync logic (described below) =====
'''tcState:''' State of the synchronization logic of the RTC, this value is '''non-persistent''' so every-time a reboot happens the value return to default (by default the value is '''ON''')
Req-Topic: clock/config/in<syntaxhighlight lang="json">
{
  "id": "<TIMESTAMP>",
  "origin": "APP",
  "task": {
    "action": "TOGGLE"
  }
}
</syntaxhighlight>Req-Topic: clock/config/out<syntaxhighlight lang="json">
{
  "id": "<TIMESTAMP>",
  "origin": "APP",
  "task": {
    "taskResult": {
      "success": true,
      "rtcState": "OFF"
    }
  }
}
</syntaxhighlight>
===== 26.1.3 Read clock configs =====
'''mode:''' Timer, alarm or none.
'''alarmSet:''' Date and time for alarm interruption (No effect if mode is timer or none).
'''timerSetSeconds:''' Period in seconds for timer interruption (No effect if mode is alarm or none).
'''rtcState:''' Current state of the synchronization logic of the RTC.
Req-Topic: clock/config/in<syntaxhighlight lang="json">
{
  "id": "<TIMESTAMP>",
  "origin": "APP",
  "task": {
    "action": "READ"
  }
}
</syntaxhighlight>Reply-Topic: clock/config/out<syntaxhighlight lang="json">
{
  "id": "<TIMESTAMP>",
  "origin": "APP",
  "task": {
    "taskResult": {
      "success": true,
      "CLOCK_CONFIGS": {
        "mode": "timer",
        "alarmSet": "[timestamp epoch ms]",
        "timerSetSeconds": "<INT>",
        "rtcState": "ON"
      }
    }
  }
}
</syntaxhighlight>
===== 26.1.4 Read clock =====
Req-Topic: clock/runtime/in <syntaxhighlight lang="json">
{
  "id": "<TIMESTAMP>",
  "origin": "APP",
  "task": {
    "taskResult": {
      "success": true,
      "timestamp": "[timestamp epoch ms]"
    }
  }
}
</syntaxhighlight>
==== 26.2 Synchronization loop flowchart (every 30 seconds) ====
[[File:RTC Actor Overview.svg|center|frameless|942x942px]]