Skip to content

3.14.0

Choose a tag to compare

@jboulton jboulton released this 11 Nov 10:58
· 4 commits to master since this release

Setting the clock from the Dash app

set_clock_callback(callback) now lets the user set the device's clock from the Dash app. It adds CLK to the layout's deviceSetup, so the app offers it in the device's provisioning menu. See Provisioning from the app.

  • Breaking: the callback gets the time, not the message. It's called with an int, whole seconds since 1970 UTC, whether the time comes from the app or from the Dash server's reply to request_clock(). Before, it got the raw message.
  • Return True if the clock was set. The device then sends the app the CLK reply it waits for. The server's reply gets no answer, because a CLK sent to the server asks it for the time again.
  • unset_clock_callback() stops offering the setting.

Fixes

  • set_ota_callback() set the clock callback, and unset_clock_callback() cleared the OTA callback. Each now sets or clears its own.

Full changes: 3.13.0...3.14.0