RtfwStopSubsystemForce
RtfwStopSubsystemForce forces the wRTOS Subsystem to stop, even if RTSS processes or Windows processes linked to wRTOS are still running.
Syntax
bool RtfwStopSubsystemForce(
);
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_SUBSYSTEM_NOT_STARTED |
The wRTOS Subsystem is not started. |
|
RT_ERROR_SUBSYSTEM_STARTSTOP_LOCK_FAILURE |
Failed to obtain the lock to serialize starting/stopping the wRTOS Subsystem. |
|
RT_ERROR_TIMEOUT_STOPPING_SUBSYSTEM |
A timeout occurred waiting for the Subsystem to shut down. |
Remarks
IMPORTANT: When this API is called, no other threads in the process can be executing a call to any function in RtApi.dll, otherwise they will malfunction.
IMPORTANT: If the function returns error RT_ERROR_TIMEOUT_STOPPING_SUBSYSTEM, the Subsystem will likely be left in an error state as parts of the Subsystem shut down. This is most likely to occur if there are real-time applications running that have shutdown handlers attached, and whose shutdown handler threads may take more than 60 seconds to finish executing. While in this state, additional calls to this function can be made, but they will continue to fail with the same error if the shutdown handler threads are still running. If this condition persists longer than expected, the only recovery option is a full Windows restart.
Requirements
| Minimum supported version | Header | Library |
|---|---|---|
|
wRTOS 1.0 SDK |
RtfwApi.h |
RtfwApi.lib |
See Also: