Skip to content

Commit 834b570

Browse files
author
Amanda Butler
authored
Merge pull request #1170 from ARMmbed/AnotherButler-patch-2
Deprecate Wait.md
2 parents b805af9 + c9a5157 commit 834b570

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

docs/api/platform/Wait.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# Wait
22

3+
<span class="warnings">**Warning:** `wait` is deprecated in favor of explicit sleep functions. To sleep, replace `wait` with `ThisThread::sleep_for` (C++) or `thread_sleep_for` (C). To wait (without sleeping), call `wait_us`. `wait_us` is safe to call from ISR context.</span>
4+
35
Wait functions provide simple wait capabilities. The OS scheduler puts the current thread in `waiting state`, allowing another thread to execute. Even better: If there are no other threads in `ready state`, it can put the whole microcontroller to `sleep`, saving energy.
46

57
## Avoiding OS delay

0 commit comments

Comments
 (0)