Share via


WaitForIdleCPU Method

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Waits for the system to enter an idle state (no active threads).

Namespace:  Microsoft.SPOT.Hardware
Assembly:  Microsoft.SPOT.Hardware (in Microsoft.SPOT.Hardware.dll)

Syntax

'Declaration
Public Shared Function WaitForIdleCPU ( _
    expectedWorkItemDuration As Integer, _
    timeout As Integer _
) As Boolean
public static bool WaitForIdleCPU(
    int expectedWorkItemDuration,
    int timeout
)
public:
static bool WaitForIdleCPU(
    int expectedWorkItemDuration, 
    int timeout
)
static member WaitForIdleCPU : 
        expectedWorkItemDuration:int * 
        timeout:int -> bool 
public static function WaitForIdleCPU(
    expectedWorkItemDuration : int, 
    timeout : int
) : boolean

Parameters

  • timeout
    Type: System. . :: . .Int32
    The timeout in milliseconds for the system to wait for the appropriate idle time.

Return Value

Type: System. . :: . .Boolean
true if the current idle time is greater than or equal to the time indicated by exeConstraintTimeout_ms; otherwise, false.

Remarks

This method waits for the system to enter an idle state (no active threads). The call will return either when the timeout has expired, or when the current idle time is greater than or equal to the expectedWorkItemDuration parameter (in milliseconds).

.NET Framework Security

See Also

Reference

PowerState Class

Microsoft.SPOT.Hardware Namespace