pub struct Ticktimer { /* private fields */ }

Implementations

Return the number of milliseconds that have elapsed since boot. The returned value is guaranteed to always be the same or greater than the previous value, even through suspend/resume cycles. During suspend, the counter does not advance, so loops which rely on this value will not perceive any extra time passing through a suspend/resume cycle.

This call is expected to be infalliable, and removing the error handling path makes it a little more efficient in a tight loop.

Returns:
* A `u64` that is the number of milliseconds elapsed since boot.

Sleep for at least ms milliseconds. Blocks until the requested time has passed.

Arguments:
* ms: A `usize` specifying how many milliseconds to sleep for

Ping the watchdog timer. Processes may use this to periodically ping the WDT to prevent the system from resetting itself. Note that every call to sleep_ms() also implicitly pings the WDT, so in more complicated systems an explicit call is not needed.

Query version information embedded in this implementation crate by the build system.

Returns:
* A `String` containing the version information of the latest build

Lock the given Mutex. Blocks until the Mutex is locked.

Note that Mutexes start out in a Locked state and move into an Unlocked state by calling Unlock on their pointer. For example, the following will probably block forever:

`TickTimer.lock_mutex(1)`

In order to create a new Mutex, you must first Unlock it. For example, the following is allowed:

`TickTimer.unlock_mutex(1)`
`TickTimer.lock_mutex(1)`
`TickTimer.unlock_mutex(1)`
Arguments:
* mtx: A `usize` referring to the Mutex. This is probably a pointer, but can be any `usize`

Unlock the given Mutex. Does not block. If the Mutex is not locked, then it will be “doubly-unlocked”. That is, if you Unlock a mutex twice, then you can Lock it twice without blocking.

Arguments:
* mtx: A `usize` referring to the Mutex. This is probably a pointer, but can be any `usize`

Wait for a Condition on the given condvar, with an optional Duration

Arguments:
* condvar: A `usize` referring to the Condvar. This is probably a pointer, but can be any `usize`
* duration: The amount of time to wait for a signal, if any
Returns:
* true: the condition was successfully received
* false: the condition was not received and the operation itmed out

Notify a condition to one or more Waiters

Arguments:
* condvar: A `usize` referring to the Condvar. This is probably a pointer, but can be any `usize`
* count: The number of Waiters to wake up

Trait Implementations

Formats the value using the given formatter. Read more
Executes the destructor for this type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
The archived version of the pointer metadata for this type.
Converts some archived metadata to the pointer metadata for itself.
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type for metadata in pointers and references to Self.
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.