RtfwStartSubsystem

RtfwStartSubsystem starts the wRTOS Subsystem.

Syntax

Copy
bool RtfwStartSubsystem(
);

Parameters

This function has no parameters.

Return Value

If the function succeeds, it returns TRUE. If the function fails, it returns FALSE. Call GetLastError to obtain an error code.

Possible error codes:

Error code Meaning

RT_ERROR_NO_STACK_LICENSE

There is no license for the TCP/IP Stack, but the Stack was configured to automatically start with the wRTOS Subsystem.

RT_ERROR_TIMEOUT_STARTING_SUBSYSTEM

Timeout waiting for the Subsystem to start.

RT_ERROR_TIMEOUT_STARTING_NETWORK

Timeout waiting for the TCP/IP Stack to start.

RT_ERROR_SUBSYSTEM_STARTSTOP_LOCK_FAILURE

Failed to obtain the lock to serialize starting/stopping the wRTOS Subsystem.

RT_ERROR_SUBSYSTEM_NOT_STOPPED

The wRTOS Subsystem cannot be started because it is not in the stopped state.

RT_ERROR_SUBSYSTEM_NOT_CONFIGURED

The wRTOS Subsystem is not configured, but an operation was attempted that requires it to be configured.

Remarks

If the Subsystem has not been configured yet, this function fails and sets the last error value to RT_ERROR_SUBSYSTEM_NOT_CONFIGURED.

After this function succeeds, the Subsystem is started. If the TCP/IP Stack is configured to start automatically when the Subsystem starts, then it is also started.

Requirements

Minimum supported version Header Library

wRTOS 1.0 SDK

RtfwApi.h

RtfwApi.lib

See Also: