diff --git a/libs/core/_locales/core-jsdoc-strings.json b/libs/core/_locales/core-jsdoc-strings.json index df228aaa..52bb7874 100644 --- a/libs/core/_locales/core-jsdoc-strings.json +++ b/libs/core/_locales/core-jsdoc-strings.json @@ -52,11 +52,12 @@ "console.logValue|param|value": "to write", "console.sendToScreen": "Sends the log messages to the brick screen and uses the brick up and down buttons to scroll.", "control": "Program controls and events.", - "control.Timer.millis": "Gets the elapsed time in millis", + "control.Timer": "A timer", + "control.Timer.millis": "Gets the elapsed time in millis since the last reset", "control.Timer.pauseUntil": "Pauses until the timer reaches the given amount of milliseconds", "control.Timer.pauseUntil|param|ms": "how long to pause for, eg: 5, 100, 200, 500, 1000, 2000", "control.Timer.reset": "Resets the timer", - "control.Timer.seconds": "Gets the elapsed time in seconds", + "control.Timer.seconds": "Gets the elapsed time in seconds since the last reset", "control.allocateNotifyEvent": "Allocates the next user notification event", "control.deviceFirmwareVersion": "Determine the version of system software currently running.", "control.dmesg": "Write data to DMESG debugging buffer.", diff --git a/libs/core/timer.ts b/libs/core/timer.ts index b1509e70..31e7dbc9 100644 --- a/libs/core/timer.ts +++ b/libs/core/timer.ts @@ -1,4 +1,7 @@ namespace control { + /** + * A timer + */ //% fixedInstances export class Timer { start: number; @@ -8,7 +11,7 @@ namespace control { } /** - * Gets the elapsed time in millis + * Gets the elapsed time in millis since the last reset */ //% blockId=timerMillis block="%timer|millis" millis(): number { @@ -16,7 +19,7 @@ namespace control { } /** - * Gets the elapsed time in seconds + * Gets the elapsed time in seconds since the last reset */ //% blockId=timerSeconds block="%timer|seconds" seconds(): number {