RtssRun Usage

RtssRun can be used to run an RTSS application from a Windows command prompt. It displays all output in the console in which it is executed. If RtssRun is not executed in a console, or from a script executing in a console, a console will be created to display the output.

Note: RtssRun cannot be used to start components of the Subsystem, such as the Network Link Layer (NL2) or TCP/IP Stack.

Note: See RTSS/RTDLL Binary Compatibility with wRTOS Runtime for an overview of the validation workflow that is used to determine whether an RTSS/RTDLL binary is compatible with the wRTOS Runtime version that attempts to run it.

Usage

RtssRun [/a affinity_mask] [/e expand_size] [/i initial_size]  [/r start | firstalloc] [/p ideal_processor] [/s order_id] [/w] filename.rtss [args]

Parameters

/a (1,2,...,63)

Sets the processor affinity mask, as a list of comma-separated processor numbers, for the RTSS application about to run.

Use integers or hexadecimal values to identify the processors. Be sure to use system-wide processor numbers.

Note: The affinity mask can only contain processors associated with RTSS during Subsystem configuration.

Note: If a processor affinity mask is not specified, the Subsystem will use the default ideal processor number for the RTSS process.

/e expand_size

The amount of memory, in kilobytes, by which to expand the process MSpace.

Note: If this parameter is omitted, the process will use the globally configured value.

/i initial_size

The initial amount of memory (allocated at process startup), in kilobytes, within the process external MSpace.

Note: If this parameter is omitted, the process will use the globally configured value.

/p n

Sets the ideal processor for the RTSS application to run. Use an integer or hexadecimal value to identify the processor and be sure to use its system-wide processor number.

Note: If the processor affinity mask is specified by /a, then the ideal processor set by /p must be one of the processors specified in the affinity mask.

Note: If an ideal processor or processor affinity mask is not specified, the Subsystem will use the default ideal processor number for the RTSS process.

/r start | firstalloc

The time of allocation of the process external MSpace. This switch requires one of these valid arguments:

Note: If this parameter is omitted, the process external MSpace will be allocated when the first allocation request which uses that MSpace occurs.

/s order_id

Adds the specified binary as a scheduled task with the specified <order id>. An <order id>of -1 places the scheduled task at the end of the list.

Note: You can obtain the order id of a scheduled task by running the command rtsskill /s.

Note: You must provide the full path name to the binary if it is not located in a folder listed in the wRTOS search path.

Note: If any of the /e, /i, or /r parameters are omitted when parameter /s is specified, the scheduled process will use the globally configured value for the omitted parameter(s).

/w

Causes RtssRun to wait for the RTSS process to complete and display its exit code before exiting (with the same exit code as the process), unless an interruption occurs.

Behaviors for typical scenarios:

Scenario Behavior
Normal termination of the RTSS process

RtssRun displays this message:

Process has exited with the value <exit code>

RtssKill is used, or RtTerminateProcess is called, on the RTSS process

RtssRun displays this message:

Process has exited with the value <exit code>

wRTOS Control Panel or wRTOS Settings attempt to stop the Subsystem while RtssRun is waiting on the RTSS process RtssRun exits without displaying an exit code
RtssRun is terminated RtssRun exits without displaying an exit code

Note: This parameter is ignored when parameter /s is also specified.

filename

A simple file name, relative pathname, or absolute pathname to the RTSS application.

[args]

Parameters to the RTSS application being run.

Return Codes

If RtssRun succeeds, it returns 0. If RtssRun fails, it returns one of the codes listed below.

Return code

Value

Meaning

1

ConfigurationError

The Subsystem could not be started.

2

ParamError

The parameter value is not valid for the current configuration.

3

InvalidPathError

The path to the .rtss file is incorrect or cannot be found.

4

WrongFileType

The binary is invalid.

5

FailedAtLaunch

The program was not able to launch the application.

6

UnexpectedError

An unexpected error occurred while trying to run RTSSRUN.exe.

Examples

Syntax Description

Rtssrun /p 2 srtm.rtss /n 2 /f /h 60

Rtssrun /p 3 srtm.rtss /n 2 /f /h 60

If multiple cores are available, you can run instances of srtm.rtss on each processor to measure their latencies.

Note: /n 2 /f /h 60 are arguments for srtm.rtss. See Using SRTM for more information.

Rtssrun /a (2,3) sample.rtss

Runs sample.rtss and specifies that the process thread will only run on processors 2 and 3.

Rtssrun /a (1,2) /p 2 srtm.rtss

Runs sample.rtss and specifies that the process thread will only run on processors 1 and 2 while setting the ideal processor to 2.

Rtssrun /s 0 srtm.rtss

Adds srtm.rtss as a scheduled task with an order id of 0.

Related topics: