<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.stridewiki.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Andreo</id>
	<title>STRIDE Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://www.stridewiki.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Andreo"/>
	<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Special:Contributions/Andreo"/>
	<updated>2026-04-28T11:31:58Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.10</generator>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=STRIDE_Runtime&amp;diff=8758</id>
		<title>STRIDE Runtime</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=STRIDE_Runtime&amp;diff=8758"/>
		<updated>2009-01-05T19:46:33Z</updated>

		<summary type="html">&lt;p&gt;Andreo: /* Logging Services */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Overview  ==&lt;br /&gt;
&lt;br /&gt;
The STRIDE Runtime routes messages both within and between platform boundaries and manages the conversion of interface data as it crosses from one platform to another. This &amp;quot;transparent messaging&amp;quot; model means that your test cases can be located on one platform (e.g., as a script running off-target) and your code on another (on-target). &lt;br /&gt;
&lt;br /&gt;
The STRIDE Runtime is a combination of processes and libraries that provide services for messaging, remote function calls, and tracing while providing seamless connectivity between the target application and the host operating system. The STRIDE Runtime standardizes how threads and applications communicate with each other, independent of the platform on which they are executing, which eliminates the need to integrate new software on the target hardware. Developers can then incrementally integrate embedded software on a combination of the desktop environment and the target hardware, providing more control over integration and testing. New software functionality under development can be simulated on the desktop environment while the software using this new functionality can run on the target hardware. The tremendous flexibility gained by allowing developers to choose how to integrate different software components and target platforms allows developers to detect integration and testing issues and correct defects much earlier in the development process. &lt;br /&gt;
&lt;br /&gt;
[[Image:Runtime Overview.jpg|600px|center|Overview of the STRIDE Runtime]] &lt;br /&gt;
&lt;br /&gt;
The Runtime components consist of: &lt;br /&gt;
&lt;br /&gt;
*The &#039;&#039;&#039;PAL (Platform Abstraction Layer)&#039;&#039;&#039; - provides a consistent interface for the STRIDE Runtime regardless of the operating system or data transport used. It consists of a small set of functions that provide a virtual link between the target operating system and the STRIDE Runtime. The PAL functionality, defined in the &#039;&#039;pal.h&#039;&#039; header file, allows the STRIDE Runtime to transmit and receive packets of data (called I-blocks) using the platform’s transport mechanism.&lt;br /&gt;
&lt;br /&gt;
*The &#039;&#039;&#039;Host Transport Layer and Object Model&#039;&#039;&#039; - a server process and set of APIs that connects the Transport DLL to the STRIDE Runtime, providing indirect access to the target from host-side scripts and STRIDE applications. The Host Transport Services are defined in the &#039;&#039;transport.h&#039;&#039; header file. The Transport Server process is is accessed through the set of interfaces defined for the &#039;&#039;STRIDE.transport&#039;&#039; COM server.&lt;br /&gt;
&lt;br /&gt;
*The &#039;&#039;&#039;Runtime APIs&#039;&#039;&#039; - a public API set, defined in the &#039;&#039;sr.h&#039;&#039; header file,&amp;amp;nbsp;available for programmers to integrate into their target application code. These APIs support messaging, remote function calls, and tracing between the target application and host operating system.&lt;br /&gt;
&lt;br /&gt;
*The &#039;&#039;&#039;Intercept Module&#039;&#039;&#039; - generated code that facilitates remote function calls between the host and target. The IM code links to the target application; it implements &#039;&#039;&#039;stubs &#039;&#039;&#039;to allow remote function calls from the host to target-resident functions, and &#039;&#039;&#039;proxies &#039;&#039;&#039;that&amp;amp;nbsp;intercept target function calls and remotes them to a host implementation of the function. The IM can contain logic to dynamically switch target-based function calls to either host-resident or target-resident implementations, and capture tracing information, through &#039;&#039;&#039;delegates&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
Additionally, groups of Runtime APIs provide test unit logging and services, and a software development kit is available for creating windows-based target applications. Each is briefly described here, with links provided for more detail.&lt;br /&gt;
&lt;br /&gt;
Refer to [[Target Integration]] on how to integrate the STRIDE Runtime in your environment.&lt;br /&gt;
&lt;br /&gt;
== The Platform Abstraction Layer  ==&lt;br /&gt;
&lt;br /&gt;
The&amp;amp;nbsp;Platform Abstraction Layer, or PAL, defines the set of OS functionality required by the platform to support the STRIDE Runtime. The “pal.h” header file provided with the STRIDE installation defines the PAL functionality. The PAL also defines functionality required by the STRIDE Runtime to transmit and receive packets of data (called I-blocks) using the platform’s transport mechanism. These PAL routines enable the STRIDE Runtime to be installed on diverse environments without changing its internal design. &lt;br /&gt;
&lt;br /&gt;
Refer to the [[Platform Abstraction Layer|Platform Abstraction Layer]] page and the [[Media:s2sPAL.pdf|PAL Specification]] document for a more detailed description of the PAL and its interfaces. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== The Host Transport Services  ==&lt;br /&gt;
&lt;br /&gt;
The Host Transport Services define an interface that enables the STRIDE Runtime on your target to send data to and receive data from the target. The STRIDE Transport Server connects the Transport DLL to the STRIDE Runtime running on the host platform, thus providing indirect access to the target from STRIDE Studio, Autoscript, and other STRIDE applications. Several common transports are already supported within the STRIDE Transport Server, including serial and TCP/IP. &lt;br /&gt;
&lt;br /&gt;
[[Image:Transport diagram.gif|center|Host Transport Services Diagram]] &lt;br /&gt;
&lt;br /&gt;
The Host Transport Services are defined in &amp;quot;transport.h&amp;quot; and each Transport DLL must implement the interfaces derived from the IStrideTransport class. &lt;br /&gt;
&lt;br /&gt;
Refer to the [[Media:s2sTransport.pdf|STRIDE Host Runtime Transport Specification]] document for a more detailed description of the Host Transport Services. &lt;br /&gt;
&lt;br /&gt;
=== The Transport Server Object Model  ===&lt;br /&gt;
&lt;br /&gt;
The Transport Server is an out-of-process COM server that provides connection management, loopback and diagnostic features. It can be accessed by clients through the STRIDE.transport Program ID. The Transport Server API is defined in the [[Transport Server Component|Transport Server Object Model]] page.&lt;br /&gt;
&lt;br /&gt;
== The Runtime Developer&#039;s Guide  ==&lt;br /&gt;
&lt;br /&gt;
Click [[Media:s2sRuntime.pdf|here]] to view the STRIDE Runtime Developer&#039;s Guide PDF document.&lt;br /&gt;
&lt;br /&gt;
=== Runtime Test Services (RTS) ===&lt;br /&gt;
&lt;br /&gt;
The Runtime Test Services (RTS) are a set of APIs in the STRIDE Runtime that facilitate the writing of target based test code. These APIs make up an optional portion of the STRIDE Runtime and can be used to communicate additional information about tests to the host based reporting mechanism. These APIs also allow target test code to create additional test suites and test cases dynamically at runtime.&amp;lt;br&amp;gt;&lt;br /&gt;
A set of C-based APIs work equally well from &#039;&#039;&#039;C Test Functions&#039;&#039;&#039; and &#039;&#039;&#039;C++ Test Classes&#039;&#039;&#039;. Optionally, you can derive your C++ test classes from the &#039;&#039;&#039;STRIDE Test Base Class (srTest)&#039;&#039;&#039; and have access to member objects in the srTest class and its methods that provide the same functionality as the C APIs.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;C Test Functions&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
C test functions enable testing of C code similarily to xUnit-style testing. Test functions can be written by users, captured using the scl_test_flist or scl_test_cclass pragmas, and executed from the host. C-based Runtime Test Services APIs are available for use in test functions.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;C++ Test Classes&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
C++ test classes enable testing of C++ code similarily to xUnit-style testing. Test classes can be written by users, captured using scl_test_class, scl_test_setup and scl_test_teardown pragmas, and executed from the host. C-based Runtime Test Services APIs as well as C++ Runtime Base Class are available for use in test classes.&amp;lt;br&amp;gt; &lt;br /&gt;
&lt;br /&gt;
These services use the &#039;&#039;&#039;&#039;&#039;srtest.h&#039;&#039;&#039;&#039;&#039; header file. Please refer to the &#039;&#039;&#039;[[Test_Units#Runtime_Test_Services|Test Units page]]&#039;&#039;&#039;, or Chapter 4 of the [[Media:s2sRuntime.pdf|STRIDE Runtime Developer&#039;s Guide]] for more information on these APIs.&lt;br /&gt;
&lt;br /&gt;
=== Logging Services ===&lt;br /&gt;
&lt;br /&gt;
The following are the categories available in the Runtime API for logging, that is, collecting and/or displaying, information at the host runtime environment: &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Setup and Shutdown&#039;&#039;&#039; &lt;br /&gt;
**&#039;&#039;&#039;srCreateSTID()&#039;&#039;&#039;: used to allocate resources required to send and receive trace and print messages that implement the following APIs. &lt;br /&gt;
**&#039;&#039;&#039;srDeleteSTID()&#039;&#039;&#039;: used to free STRIDE Runtime resources previously allocated for an STID.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Tracing&#039;&#039;&#039; - Tracing routines are used by target applications for information collection and display by the host runtime environment. &lt;br /&gt;
**&#039;&#039;&#039;srTracePoint()&#039;&#039;&#039;: used to output a data structure to the tracing window on the host. &lt;br /&gt;
**&#039;&#039;&#039;srTraceStr()&#039;&#039;&#039;: used to output a string to the tracing window.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Printing&#039;&#039;&#039; - These routines are used by applications to log or display messages on Trace Views on the host. &lt;br /&gt;
**&#039;&#039;&#039;srPrintInfo()&#039;&#039;&#039;: used to output a formatted string with variable arguments to be displayed at information level filtering. &lt;br /&gt;
**&#039;&#039;&#039;srPrintError()&#039;&#039;&#039;: used to output a formatted string with variable arguments to be displayed at error level filtering.&lt;br /&gt;
*&#039;&#039;&#039;Messaging&#039;&#039;&#039; - These routines can be used to send and receive messages for logging or any other debugging purposes. &lt;br /&gt;
**&#039;&#039;&#039;srBroadcast()&#039;&#039;&#039;: used to “broadcast” information to one or more subscribers. Each subscriber receives its own copy of the message or pointer, depending on the attributes of the payload. If there are multiple subscribers on a remote platform only one copy of the response is transmitted across the link. If there are no subscribers then the routine simply returns.&lt;br /&gt;
**&#039;&#039;&#039;srSubscribe()&#039;&#039;&#039;: used to subscribe to a Broadcast message sent using srBroadcast. There has to be at least one subscriber for a broadcast message to be sent.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These services use the &#039;&#039;&#039;&#039;&#039;sr.h&#039;&#039;&#039;&#039;&#039; header file. Please refer to Chapter 3 of the [[Media:s2sRuntime.pdf|STRIDE Runtime Developer&#039;s Guide]] for more information on these APIs.&lt;br /&gt;
&lt;br /&gt;
== The Intercept Module  ==&lt;br /&gt;
&lt;br /&gt;
The [[Intercept Module]] page provides details of the Intercept Module concept.&amp;lt;br&amp;gt; &lt;br /&gt;
&lt;br /&gt;
The [[Name Mangling]] page provides more background on the use of name mangling when implementing delegates within an Intercept Module. &lt;br /&gt;
&lt;br /&gt;
== Other Runtime components ==&lt;br /&gt;
&lt;br /&gt;
*[[GRS|Generic RTOS Services (GRS)]] &lt;br /&gt;
*[[SLAP|Simplified Link Application Protocol (SLAP)]]&lt;br /&gt;
&lt;br /&gt;
[[Category: Reference]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Category:SDKs&amp;diff=8748</id>
		<title>Category:SDKs</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Category:SDKs&amp;diff=8748"/>
		<updated>2008-12-30T19:48:56Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following topics describe our SDKs. &amp;lt;categorytree style=&amp;quot;background-color: ghostwhite&amp;quot; mode=&amp;quot;pages&amp;quot;&amp;gt;&lt;br /&gt;
SDKs&lt;br /&gt;
&amp;lt;/categorytree&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category: Reference]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Posix_SDK&amp;diff=8746</id>
		<title>Posix SDK</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Posix_SDK&amp;diff=8746"/>
		<updated>2008-12-30T19:47:19Z</updated>

		<summary type="html">&lt;p&gt;Andreo: /* Target Makefile */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction  ==&lt;br /&gt;
&lt;br /&gt;
The Linux SDK is a platform-specific package that contains the STRIDE Runtime source and [[Target_Integration#The_Platform_Abstraction_Layer_.28PAL.29|PAL]] implementation, along with integration tools to build a stride library and a strideDaemon application. It is intended for this article to be used as a reference. &#039;&#039;&#039;For step-by-step instructions on using the contents of this package to create a test application that establishes messaging between the host and target device, please refer to the [[Linux Quickstart]] guide.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Target Makefile==&lt;br /&gt;
&lt;br /&gt;
The SDK makefile provides targets for building the [[Runtime Reference|STRIDE Runtime]] library and two executable applications - a strideDaemon (for a [[#Multiprocess_Application_Integration|multiprocess]] application environment), and an installTestApp (for running the STRIDE installation tests - see [[Verifying_Installation#Using_a_Platform_SDK|Using a Platform SDK]] for more information).&lt;br /&gt;
&lt;br /&gt;
The default make target builds the STRIDE Runtime library and strideDaemon executable. When a single process runtime library is specified (see RTSINGLEPROC below), the strideDaemon is omitted.  To build the installation test application, specify the &#039;&#039;&#039;installtest&#039;&#039;&#039; make target. &lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;installtest&#039;&#039;&#039; target compiles SCL source markup present in the Runtime source and therefore requires that the [[Build Tools]] be installed on your system and in your executable search path. Refer to the [[Linux Quickstart]] guide for an example how to build and run the install tests or the [[Linux_Baseline_Application_Integration|Linux Baseline Application Integration]] on how to integrate the installation test in a current code baseline.&lt;br /&gt;
&lt;br /&gt;
===Configuration===&lt;br /&gt;
&lt;br /&gt;
The behavior of the makefile can be affected by setting certain make variable parameters. For example, the following make invocation will change the value of the TOOLCHAIN and DEBUG variables when making:&lt;br /&gt;
&lt;br /&gt;
  make TOOLCHAIN=arm DEBUG=1&lt;br /&gt;
&lt;br /&gt;
The following variable are intended to be specified or overridden as needed:&lt;br /&gt;
&lt;br /&gt;
====TOOLCHAIN====&lt;br /&gt;
&lt;br /&gt;
The default compiler toolchain when TOOLCHAIN is set to &#039;&#039;&#039;i386&#039;&#039;&#039; is gcc/g++/ar, which are assumed to be in your path.  For any other TOOLCHAIN value, the toolchain tools are $(TOOLCHAIN)-linux-gcc/g++/ar where $(TOOLCHAIN) is replaced by the specified TOOLCHAIN setting.  If your toolchain does not fit this pattern, you will need to modify the makefile or explicitly override values for CC, CPP, and AR.&lt;br /&gt;
&lt;br /&gt;
====LIBRARYTYPE====&lt;br /&gt;
&lt;br /&gt;
The default behavior of the makefile is to build the STRIDE Runtime as a static library. If you prefer a shared library, set this value to &#039;.so&#039;.&lt;br /&gt;
&lt;br /&gt;
====DEBUG====&lt;br /&gt;
&lt;br /&gt;
The default configuration compiles with optimization and NDEBUG defined.  If you prefer debuggable binaries, set this value to 1.&lt;br /&gt;
&lt;br /&gt;
====RTSINGLEPROC====&lt;br /&gt;
&lt;br /&gt;
The default configuration compiles the runtime library with multiprocess support.  If you don&#039;t want (or can&#039;t support) multiprocess functionality, you can disable this by explicitly setting this value to 1.&lt;br /&gt;
&lt;br /&gt;
====STANDALONE_INSTALLTEST====&lt;br /&gt;
&lt;br /&gt;
The default configuration, set to &#039;&#039;&#039;0&#039;&#039;&#039;, builds the installTestApp as a [[#Multiprocess_Application_Integration|multiprocess]] application. When set to &#039;&#039;&#039;1&#039;&#039;&#039; the installTestApp is built as a [[#Standalone_Application_Integration|standalone]] application. &amp;lt;br&amp;gt;&lt;br /&gt;
The STANDALONE_INSTALLTEST variable is affected by the value of RTSINGLEPROC. If RTSINGLEPROC is &#039;&#039;&#039;1&#039;&#039;&#039; and STANDALONE_INSTALLTEST is &#039;&#039;&#039;0&#039;&#039;&#039;, this is an invalid combination and STANDALONE_INSTALLTEST will automatically be set to &#039;&#039;&#039;1&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
====S2SCOPTS====&lt;br /&gt;
&lt;br /&gt;
The STRIDE build process that produces the database and [[Intercept Module]] for the installation tests relies on target settings. These settings are passed as options to the stride compiler and are most conveniently stored in an options file.  We provide a default options file with target settings that are appropriate for x86 Linux targets with GNU compilers -- this file is &#039;&#039;SDK/Linux/settings/stride.s2scompile&#039;&#039; in the SDK distribution. &lt;br /&gt;
&lt;br /&gt;
We recommend that you make a copy of this file and adjust the settings as appropriate for your target. You can then set this variable - &#039;&#039;&#039;S2SCOPTS&#039;&#039;&#039; to the path to your settings file.  This will cause the make process to use the specified target settings options instead of the default one provided in the SDK. This same settings file should ultimately be used for the STRIDE build integration with your application source code.&lt;br /&gt;
&lt;br /&gt;
===S2 Build Flags===&lt;br /&gt;
The target Makefile sets the following Build Tool flags:&lt;br /&gt;
&lt;br /&gt;
  S2_BIND_FLAGS = --starting_suid=7000&lt;br /&gt;
  S2_IM_FLAGS = --disable_access_class&lt;br /&gt;
&lt;br /&gt;
The [[S2sbind#Options|s2sbind]] and [[S2sinstrument#Options|s2sinstrument]] flags are combined so that the test application only registers for test message IDs that are created in a higher range so that it doesn&#039;t conflict with other application processes.&lt;br /&gt;
&lt;br /&gt;
==Target API (stride.h)==&lt;br /&gt;
&lt;br /&gt;
The Linux SDK provides a simplified application interface for initializing the STRIDE subsystem and starting STRIDE messaging and IM threads. The API includes the following routines:&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideInit(const strideIO_t * io)===&lt;br /&gt;
&lt;br /&gt;
This function initializes the STRIDE subsystem.  The IO configuration is passed in as an argument. If this argument is NULL, then the process will attempt to attach to an already running runtime application (daemon) using shared memory for IPC. THis function should only be called once per application.&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideUninit(void)===&lt;br /&gt;
&lt;br /&gt;
Terminates any threads that have been started with this API and uninitializes the STRIDE subsystem.&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideCreateThread(strideThreadFunc_t entry, const srCHAR * name)===&lt;br /&gt;
&lt;br /&gt;
Creates a thread to be managed by the STRIDE subsystem. Threads created using this routine will be sent a palSTOP_EVENT notification (available from palWait) and should respond promptly to this event. The name parameter is used primarily for logging purposes.&lt;br /&gt;
&lt;br /&gt;
===strideCreateIMThread(name)===&lt;br /&gt;
&lt;br /&gt;
This is a macro that wraps the invocation of [[#strideCreateThread|strideCreateThread]] for intercept module entry point functions. Only the IM name must be provided.&lt;br /&gt;
&lt;br /&gt;
===void strideExWaitForExit(void)===&lt;br /&gt;
&lt;br /&gt;
This function can be called by the main application thread to block until a termination signal is received. Internally it uses the pause function to wait for signals to be delivered and then checks if termination has occurred.&lt;br /&gt;
&lt;br /&gt;
===void strideExDaemonize(const char* lockFile, const char* runAs)===&lt;br /&gt;
This function is called by applications to deamonize the process. Both arguments are optional. The first argument specifies a lockfile path/name to use to insure that only one instance of the process is running. The second argument specifies a username to run as (setuid)&lt;br /&gt;
&lt;br /&gt;
This function is optional - if you prefer to run your application as an interactive console application, do not call this function. If you are running as a daemon, we recommend that you have the PAL_LOG_TO_SYSLOG macro defined (in palcfg.h) so that PAL log messages will be sent to the syslog (this is default setting currently).&lt;br /&gt;
&lt;br /&gt;
==Target Integration==&lt;br /&gt;
&lt;br /&gt;
Here are a few examples of how to integrate the stride API into your application.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; the following code assumes that the intercept module was generated with a name of &#039;&#039;myintercept&#039;&#039;.  Change all references to that name in your code to the chosen intercept module name.&lt;br /&gt;
&lt;br /&gt;
===Standalone Application Integration===&lt;br /&gt;
&lt;br /&gt;
The following code demonstrates how to integrate your application with the STRIDE Runtime. Your application might require other logic at startup - you can integrate the following calls according to your needs. Note that this code initializes the STRIDE subsystem and assumes a single standalone process that creates the STRIDE system threads as well as application threads. The call to strideExDaemonize is optional here - remove it if you don&#039;t want you application to run as a daemon. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include &amp;lt;unistd.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stride.h&amp;gt;&lt;br /&gt;
#include &amp;lt;myinterceptIMEntry.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char **argv)&lt;br /&gt;
{&lt;br /&gt;
    strideExDaemonize(NULL, NULL);&lt;br /&gt;
    strideIO_t io = {strideDEFAULT};&lt;br /&gt;
    if (strideInit(&amp;amp;io) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    if (strideCreateIMThread(myintercept) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    strideExWaitForExit();&lt;br /&gt;
    strideUninit();&lt;br /&gt;
    return 0;   &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Multiprocess Application Integration===&lt;br /&gt;
&lt;br /&gt;
This code demonstrates how to integrate your application with the STRIDE Runtime in multiprocess mode. In this mode, the pre-packaged strideDaemon runs simultaneously with the application and provides the STRIDE IO and runtime thread initialization. The host communicates with the application process through the strideDaemon (or another STRIDE IO process). In this sample, the only difference with the preceding sample is the call to strideInit which, in this case, specifies no IO parameters which indicates to the API that the communication and runtime threads should not be started. As before, the call to strideExDaemonize is optional here - remove it if you don&#039;t want your application to run as a daemon. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include &amp;lt;unistd.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stride.h&amp;gt;&lt;br /&gt;
#include &amp;lt;myinterceptIMEntry.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char **argv)&lt;br /&gt;
{&lt;br /&gt;
    strideExDaemonize(NULL, NULL);&lt;br /&gt;
    if (strideInit(NULL) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    if (strideCreateIMThread(myintercept) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    strideExWaitForExit();&lt;br /&gt;
    strideUninit();&lt;br /&gt;
    return 0;   &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Linux PAL==&lt;br /&gt;
&lt;br /&gt;
===PAL Configuration (palcfg.h)===&lt;br /&gt;
The following parameters can be configured in &#039;&#039;palcfg.h&#039;&#039; to effect the behavior of the compiled pal source files.&lt;br /&gt;
&lt;br /&gt;
; PAL_USE_SERIAL_TRANSPORT : if defined, serial communication support is enabled.&lt;br /&gt;
; PAL_USE_TCPIP_TRANSPORT : if defined, sockets-based communication support is enabled.&lt;br /&gt;
; PAL_DEFAULT_DEVICE_NAME : default IO device to use.&lt;br /&gt;
; PAL_DEFAULT_TCP_PORT : default port for TCP communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_PORT : default COM port to use for serial communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_BAUDRATE : default baud rate for serial communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_MODE : default data/parity/stop settings for serial communication.&lt;br /&gt;
; PAL_USE_POSIX_CLOCK_GETTIME or PAL_USE_GETTIMEOFDAY : indicates the time of day clock to use.&lt;br /&gt;
; PAL_TIMER_PERIOD : this is the fire interval for the STRIDE Runtime master timer, in milliseconds.&lt;br /&gt;
; PAL_MAX_THREADS : max STRIDE integrated threads that can be managed by the STRIDE API.&lt;br /&gt;
; PAL_MAX_TIMERS : max STRIDE timers that can be active in the system.&lt;br /&gt;
; PAL_USE_POSIX_TIMER or PAL_USE_INTERVAL_TIMER : indicates the timer type to use.&lt;br /&gt;
; PAL_CLOCKID : indicates the type of POSIX clock to use&lt;br /&gt;
; PAL_DELIVER_TIMER_BY_THREAD or PAL_DELIVER_TIMER_BY_SIGNAL : specify how POSIX timer signals are delivered.&lt;br /&gt;
; PAL_TIMER_SIGNAL_TYPE : define which signal to use for timer delivery.&lt;br /&gt;
; PAL_LOG_TO_SYSLOG : palLog messages will be sent to syslog if this is defined; to stdout/stderr otherwise.&lt;br /&gt;
; PAL_SHM_PATH : the path to use for shared memory files. Only needed if multiprocess support is enabled in srcfg.h.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category: SDKs]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Posix_SDK&amp;diff=8745</id>
		<title>Posix SDK</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Posix_SDK&amp;diff=8745"/>
		<updated>2008-12-30T19:46:32Z</updated>

		<summary type="html">&lt;p&gt;Andreo: /* Target Makefile */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction  ==&lt;br /&gt;
&lt;br /&gt;
The Linux SDK is a platform-specific package that contains the STRIDE Runtime source and [[Target_Integration#The_Platform_Abstraction_Layer_.28PAL.29|PAL]] implementation, along with integration tools to build a stride library and a strideDaemon application. It is intended for this article to be used as a reference. &#039;&#039;&#039;For step-by-step instructions on using the contents of this package to create a test application that establishes messaging between the host and target device, please refer to the [[Linux Quickstart]] guide.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Target Makefile==&lt;br /&gt;
&lt;br /&gt;
The SDK makefile provides targets for building the [[Runtime Reference|STRIDE Runtime]] library and two executable applications - a strideDaemon (for a [[#Multiprocess_Application_Integration|multiprocess]] application environment), and an installTestApp (for running the STRIDE installation tests - see [[Verifying_Installation#Using_a_Platform_SDK|Using a Platform SDK]] for more information).&lt;br /&gt;
&lt;br /&gt;
The default make target builds the STRIDE Runtime library and strideDaemon executable. When a single process runtime library is specified (see RTSINGLEPROC below), the strideDaemon is omitted.  To build the installation test application, specify the &#039;&#039;&#039;installtest&#039;&#039;&#039; make target. &lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;installtest&#039;&#039;&#039; target compiles SCL source markup present in the Runtime source and therefore requires that the [[Build Tools]] be installed on your system and in your executable search path. Refer to the [[Linux Quickstart]] guide for an example how to build and run the install tests or the [[Linux_Baseline_Application_Integration]] on how to integrate the installation test in a current code baseline.&lt;br /&gt;
&lt;br /&gt;
===Configuration===&lt;br /&gt;
&lt;br /&gt;
The behavior of the makefile can be affected by setting certain make variable parameters. For example, the following make invocation will change the value of the TOOLCHAIN and DEBUG variables when making:&lt;br /&gt;
&lt;br /&gt;
  make TOOLCHAIN=arm DEBUG=1&lt;br /&gt;
&lt;br /&gt;
The following variable are intended to be specified or overridden as needed:&lt;br /&gt;
&lt;br /&gt;
====TOOLCHAIN====&lt;br /&gt;
&lt;br /&gt;
The default compiler toolchain when TOOLCHAIN is set to &#039;&#039;&#039;i386&#039;&#039;&#039; is gcc/g++/ar, which are assumed to be in your path.  For any other TOOLCHAIN value, the toolchain tools are $(TOOLCHAIN)-linux-gcc/g++/ar where $(TOOLCHAIN) is replaced by the specified TOOLCHAIN setting.  If your toolchain does not fit this pattern, you will need to modify the makefile or explicitly override values for CC, CPP, and AR.&lt;br /&gt;
&lt;br /&gt;
====LIBRARYTYPE====&lt;br /&gt;
&lt;br /&gt;
The default behavior of the makefile is to build the STRIDE Runtime as a static library. If you prefer a shared library, set this value to &#039;.so&#039;.&lt;br /&gt;
&lt;br /&gt;
====DEBUG====&lt;br /&gt;
&lt;br /&gt;
The default configuration compiles with optimization and NDEBUG defined.  If you prefer debuggable binaries, set this value to 1.&lt;br /&gt;
&lt;br /&gt;
====RTSINGLEPROC====&lt;br /&gt;
&lt;br /&gt;
The default configuration compiles the runtime library with multiprocess support.  If you don&#039;t want (or can&#039;t support) multiprocess functionality, you can disable this by explicitly setting this value to 1.&lt;br /&gt;
&lt;br /&gt;
====STANDALONE_INSTALLTEST====&lt;br /&gt;
&lt;br /&gt;
The default configuration, set to &#039;&#039;&#039;0&#039;&#039;&#039;, builds the installTestApp as a [[#Multiprocess_Application_Integration|multiprocess]] application. When set to &#039;&#039;&#039;1&#039;&#039;&#039; the installTestApp is built as a [[#Standalone_Application_Integration|standalone]] application. &amp;lt;br&amp;gt;&lt;br /&gt;
The STANDALONE_INSTALLTEST variable is affected by the value of RTSINGLEPROC. If RTSINGLEPROC is &#039;&#039;&#039;1&#039;&#039;&#039; and STANDALONE_INSTALLTEST is &#039;&#039;&#039;0&#039;&#039;&#039;, this is an invalid combination and STANDALONE_INSTALLTEST will automatically be set to &#039;&#039;&#039;1&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
====S2SCOPTS====&lt;br /&gt;
&lt;br /&gt;
The STRIDE build process that produces the database and [[Intercept Module]] for the installation tests relies on target settings. These settings are passed as options to the stride compiler and are most conveniently stored in an options file.  We provide a default options file with target settings that are appropriate for x86 Linux targets with GNU compilers -- this file is &#039;&#039;SDK/Linux/settings/stride.s2scompile&#039;&#039; in the SDK distribution. &lt;br /&gt;
&lt;br /&gt;
We recommend that you make a copy of this file and adjust the settings as appropriate for your target. You can then set this variable - &#039;&#039;&#039;S2SCOPTS&#039;&#039;&#039; to the path to your settings file.  This will cause the make process to use the specified target settings options instead of the default one provided in the SDK. This same settings file should ultimately be used for the STRIDE build integration with your application source code.&lt;br /&gt;
&lt;br /&gt;
===S2 Build Flags===&lt;br /&gt;
The target Makefile sets the following Build Tool flags:&lt;br /&gt;
&lt;br /&gt;
  S2_BIND_FLAGS = --starting_suid=7000&lt;br /&gt;
  S2_IM_FLAGS = --disable_access_class&lt;br /&gt;
&lt;br /&gt;
The [[S2sbind#Options|s2sbind]] and [[S2sinstrument#Options|s2sinstrument]] flags are combined so that the test application only registers for test message IDs that are created in a higher range so that it doesn&#039;t conflict with other application processes.&lt;br /&gt;
&lt;br /&gt;
==Target API (stride.h)==&lt;br /&gt;
&lt;br /&gt;
The Linux SDK provides a simplified application interface for initializing the STRIDE subsystem and starting STRIDE messaging and IM threads. The API includes the following routines:&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideInit(const strideIO_t * io)===&lt;br /&gt;
&lt;br /&gt;
This function initializes the STRIDE subsystem.  The IO configuration is passed in as an argument. If this argument is NULL, then the process will attempt to attach to an already running runtime application (daemon) using shared memory for IPC. THis function should only be called once per application.&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideUninit(void)===&lt;br /&gt;
&lt;br /&gt;
Terminates any threads that have been started with this API and uninitializes the STRIDE subsystem.&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideCreateThread(strideThreadFunc_t entry, const srCHAR * name)===&lt;br /&gt;
&lt;br /&gt;
Creates a thread to be managed by the STRIDE subsystem. Threads created using this routine will be sent a palSTOP_EVENT notification (available from palWait) and should respond promptly to this event. The name parameter is used primarily for logging purposes.&lt;br /&gt;
&lt;br /&gt;
===strideCreateIMThread(name)===&lt;br /&gt;
&lt;br /&gt;
This is a macro that wraps the invocation of [[#strideCreateThread|strideCreateThread]] for intercept module entry point functions. Only the IM name must be provided.&lt;br /&gt;
&lt;br /&gt;
===void strideExWaitForExit(void)===&lt;br /&gt;
&lt;br /&gt;
This function can be called by the main application thread to block until a termination signal is received. Internally it uses the pause function to wait for signals to be delivered and then checks if termination has occurred.&lt;br /&gt;
&lt;br /&gt;
===void strideExDaemonize(const char* lockFile, const char* runAs)===&lt;br /&gt;
This function is called by applications to deamonize the process. Both arguments are optional. The first argument specifies a lockfile path/name to use to insure that only one instance of the process is running. The second argument specifies a username to run as (setuid)&lt;br /&gt;
&lt;br /&gt;
This function is optional - if you prefer to run your application as an interactive console application, do not call this function. If you are running as a daemon, we recommend that you have the PAL_LOG_TO_SYSLOG macro defined (in palcfg.h) so that PAL log messages will be sent to the syslog (this is default setting currently).&lt;br /&gt;
&lt;br /&gt;
==Target Integration==&lt;br /&gt;
&lt;br /&gt;
Here are a few examples of how to integrate the stride API into your application.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; the following code assumes that the intercept module was generated with a name of &#039;&#039;myintercept&#039;&#039;.  Change all references to that name in your code to the chosen intercept module name.&lt;br /&gt;
&lt;br /&gt;
===Standalone Application Integration===&lt;br /&gt;
&lt;br /&gt;
The following code demonstrates how to integrate your application with the STRIDE Runtime. Your application might require other logic at startup - you can integrate the following calls according to your needs. Note that this code initializes the STRIDE subsystem and assumes a single standalone process that creates the STRIDE system threads as well as application threads. The call to strideExDaemonize is optional here - remove it if you don&#039;t want you application to run as a daemon. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include &amp;lt;unistd.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stride.h&amp;gt;&lt;br /&gt;
#include &amp;lt;myinterceptIMEntry.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char **argv)&lt;br /&gt;
{&lt;br /&gt;
    strideExDaemonize(NULL, NULL);&lt;br /&gt;
    strideIO_t io = {strideDEFAULT};&lt;br /&gt;
    if (strideInit(&amp;amp;io) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    if (strideCreateIMThread(myintercept) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    strideExWaitForExit();&lt;br /&gt;
    strideUninit();&lt;br /&gt;
    return 0;   &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Multiprocess Application Integration===&lt;br /&gt;
&lt;br /&gt;
This code demonstrates how to integrate your application with the STRIDE Runtime in multiprocess mode. In this mode, the pre-packaged strideDaemon runs simultaneously with the application and provides the STRIDE IO and runtime thread initialization. The host communicates with the application process through the strideDaemon (or another STRIDE IO process). In this sample, the only difference with the preceding sample is the call to strideInit which, in this case, specifies no IO parameters which indicates to the API that the communication and runtime threads should not be started. As before, the call to strideExDaemonize is optional here - remove it if you don&#039;t want your application to run as a daemon. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include &amp;lt;unistd.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stride.h&amp;gt;&lt;br /&gt;
#include &amp;lt;myinterceptIMEntry.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char **argv)&lt;br /&gt;
{&lt;br /&gt;
    strideExDaemonize(NULL, NULL);&lt;br /&gt;
    if (strideInit(NULL) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    if (strideCreateIMThread(myintercept) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    strideExWaitForExit();&lt;br /&gt;
    strideUninit();&lt;br /&gt;
    return 0;   &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Linux PAL==&lt;br /&gt;
&lt;br /&gt;
===PAL Configuration (palcfg.h)===&lt;br /&gt;
The following parameters can be configured in &#039;&#039;palcfg.h&#039;&#039; to effect the behavior of the compiled pal source files.&lt;br /&gt;
&lt;br /&gt;
; PAL_USE_SERIAL_TRANSPORT : if defined, serial communication support is enabled.&lt;br /&gt;
; PAL_USE_TCPIP_TRANSPORT : if defined, sockets-based communication support is enabled.&lt;br /&gt;
; PAL_DEFAULT_DEVICE_NAME : default IO device to use.&lt;br /&gt;
; PAL_DEFAULT_TCP_PORT : default port for TCP communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_PORT : default COM port to use for serial communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_BAUDRATE : default baud rate for serial communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_MODE : default data/parity/stop settings for serial communication.&lt;br /&gt;
; PAL_USE_POSIX_CLOCK_GETTIME or PAL_USE_GETTIMEOFDAY : indicates the time of day clock to use.&lt;br /&gt;
; PAL_TIMER_PERIOD : this is the fire interval for the STRIDE Runtime master timer, in milliseconds.&lt;br /&gt;
; PAL_MAX_THREADS : max STRIDE integrated threads that can be managed by the STRIDE API.&lt;br /&gt;
; PAL_MAX_TIMERS : max STRIDE timers that can be active in the system.&lt;br /&gt;
; PAL_USE_POSIX_TIMER or PAL_USE_INTERVAL_TIMER : indicates the timer type to use.&lt;br /&gt;
; PAL_CLOCKID : indicates the type of POSIX clock to use&lt;br /&gt;
; PAL_DELIVER_TIMER_BY_THREAD or PAL_DELIVER_TIMER_BY_SIGNAL : specify how POSIX timer signals are delivered.&lt;br /&gt;
; PAL_TIMER_SIGNAL_TYPE : define which signal to use for timer delivery.&lt;br /&gt;
; PAL_LOG_TO_SYSLOG : palLog messages will be sent to syslog if this is defined; to stdout/stderr otherwise.&lt;br /&gt;
; PAL_SHM_PATH : the path to use for shared memory files. Only needed if multiprocess support is enabled in srcfg.h.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category: SDKs]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Posix_SDK&amp;diff=8743</id>
		<title>Posix SDK</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Posix_SDK&amp;diff=8743"/>
		<updated>2008-12-30T19:44:32Z</updated>

		<summary type="html">&lt;p&gt;Andreo: /* Introduction */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction  ==&lt;br /&gt;
&lt;br /&gt;
The Linux SDK is a platform-specific package that contains the STRIDE Runtime source and [[Target_Integration#The_Platform_Abstraction_Layer_.28PAL.29|PAL]] implementation, along with integration tools to build a stride library and a strideDaemon application. It is intended for this article to be used as a reference. &#039;&#039;&#039;For step-by-step instructions on using the contents of this package to create a test application that establishes messaging between the host and target device, please refer to the [[Linux Quickstart]] guide.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Target Makefile==&lt;br /&gt;
&lt;br /&gt;
The SDK makefile provides targets for building the [[Runtime Reference|STRIDE Runtime]] library and two executable applications - a strideDaemon (for a [[#Multiprocess_Application_Integration|multiprocess]] application environment), and an installTestApp (for running the STRIDE installation tests - see [[Verifying_Installation#Using_a_Platform_SDK|Using a Platform SDK]] for more information).&lt;br /&gt;
&lt;br /&gt;
The default make target builds the STRIDE Runtime library and strideDaemon executable. When a single process runtime library is specified (see RTSINGLEPROC below), the strideDaemon is omitted.  To build the installation test application, specify the &#039;&#039;&#039;installtest&#039;&#039;&#039; make target. &lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;installtest&#039;&#039;&#039; target compiles SCL source markup present in the Runtime source and therefore requires that the [[Build Tools]] be installed on your system and in your executable search path. Refer to the [[Linux Quickstart]] guide for an example how to build and run the install tests.&lt;br /&gt;
&lt;br /&gt;
===Configuration===&lt;br /&gt;
&lt;br /&gt;
The behavior of the makefile can be affected by setting certain make variable parameters. For example, the following make invocation will change the value of the TOOLCHAIN and DEBUG variables when making:&lt;br /&gt;
&lt;br /&gt;
  make TOOLCHAIN=arm DEBUG=1&lt;br /&gt;
&lt;br /&gt;
The following variable are intended to be specified or overridden as needed:&lt;br /&gt;
&lt;br /&gt;
====TOOLCHAIN====&lt;br /&gt;
&lt;br /&gt;
The default compiler toolchain when TOOLCHAIN is set to &#039;&#039;&#039;i386&#039;&#039;&#039; is gcc/g++/ar, which are assumed to be in your path.  For any other TOOLCHAIN value, the toolchain tools are $(TOOLCHAIN)-linux-gcc/g++/ar where $(TOOLCHAIN) is replaced by the specified TOOLCHAIN setting.  If your toolchain does not fit this pattern, you will need to modify the makefile or explicitly override values for CC, CPP, and AR.&lt;br /&gt;
&lt;br /&gt;
====LIBRARYTYPE====&lt;br /&gt;
&lt;br /&gt;
The default behavior of the makefile is to build the STRIDE Runtime as a static library. If you prefer a shared library, set this value to &#039;.so&#039;.&lt;br /&gt;
&lt;br /&gt;
====DEBUG====&lt;br /&gt;
&lt;br /&gt;
The default configuration compiles with optimization and NDEBUG defined.  If you prefer debuggable binaries, set this value to 1.&lt;br /&gt;
&lt;br /&gt;
====RTSINGLEPROC====&lt;br /&gt;
&lt;br /&gt;
The default configuration compiles the runtime library with multiprocess support.  If you don&#039;t want (or can&#039;t support) multiprocess functionality, you can disable this by explicitly setting this value to 1.&lt;br /&gt;
&lt;br /&gt;
====STANDALONE_INSTALLTEST====&lt;br /&gt;
&lt;br /&gt;
The default configuration, set to &#039;&#039;&#039;0&#039;&#039;&#039;, builds the installTestApp as a [[#Multiprocess_Application_Integration|multiprocess]] application. When set to &#039;&#039;&#039;1&#039;&#039;&#039; the installTestApp is built as a [[#Standalone_Application_Integration|standalone]] application. &amp;lt;br&amp;gt;&lt;br /&gt;
The STANDALONE_INSTALLTEST variable is affected by the value of RTSINGLEPROC. If RTSINGLEPROC is &#039;&#039;&#039;1&#039;&#039;&#039; and STANDALONE_INSTALLTEST is &#039;&#039;&#039;0&#039;&#039;&#039;, this is an invalid combination and STANDALONE_INSTALLTEST will automatically be set to &#039;&#039;&#039;1&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
====S2SCOPTS====&lt;br /&gt;
&lt;br /&gt;
The STRIDE build process that produces the database and [[Intercept Module]] for the installation tests relies on target settings. These settings are passed as options to the stride compiler and are most conveniently stored in an options file.  We provide a default options file with target settings that are appropriate for x86 Linux targets with GNU compilers -- this file is &#039;&#039;SDK/Linux/settings/stride.s2scompile&#039;&#039; in the SDK distribution. &lt;br /&gt;
&lt;br /&gt;
We recommend that you make a copy of this file and adjust the settings as appropriate for your target. You can then set this variable - &#039;&#039;&#039;S2SCOPTS&#039;&#039;&#039; to the path to your settings file.  This will cause the make process to use the specified target settings options instead of the default one provided in the SDK. This same settings file should ultimately be used for the STRIDE build integration with your application source code.&lt;br /&gt;
&lt;br /&gt;
===S2 Build Flags===&lt;br /&gt;
The target Makefile sets the following Build Tool flags:&lt;br /&gt;
&lt;br /&gt;
  S2_BIND_FLAGS = --starting_suid=7000&lt;br /&gt;
  S2_IM_FLAGS = --disable_access_class&lt;br /&gt;
&lt;br /&gt;
The [[S2sbind#Options|s2sbind]] and [[S2sinstrument#Options|s2sinstrument]] flags are combined so that the test application only registers for test message IDs that are created in a higher range so that it doesn&#039;t conflict with other application processes.&lt;br /&gt;
&lt;br /&gt;
==Target API (stride.h)==&lt;br /&gt;
&lt;br /&gt;
The Linux SDK provides a simplified application interface for initializing the STRIDE subsystem and starting STRIDE messaging and IM threads. The API includes the following routines:&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideInit(const strideIO_t * io)===&lt;br /&gt;
&lt;br /&gt;
This function initializes the STRIDE subsystem.  The IO configuration is passed in as an argument. If this argument is NULL, then the process will attempt to attach to an already running runtime application (daemon) using shared memory for IPC. THis function should only be called once per application.&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideUninit(void)===&lt;br /&gt;
&lt;br /&gt;
Terminates any threads that have been started with this API and uninitializes the STRIDE subsystem.&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideCreateThread(strideThreadFunc_t entry, const srCHAR * name)===&lt;br /&gt;
&lt;br /&gt;
Creates a thread to be managed by the STRIDE subsystem. Threads created using this routine will be sent a palSTOP_EVENT notification (available from palWait) and should respond promptly to this event. The name parameter is used primarily for logging purposes.&lt;br /&gt;
&lt;br /&gt;
===strideCreateIMThread(name)===&lt;br /&gt;
&lt;br /&gt;
This is a macro that wraps the invocation of [[#strideCreateThread|strideCreateThread]] for intercept module entry point functions. Only the IM name must be provided.&lt;br /&gt;
&lt;br /&gt;
===void strideExWaitForExit(void)===&lt;br /&gt;
&lt;br /&gt;
This function can be called by the main application thread to block until a termination signal is received. Internally it uses the pause function to wait for signals to be delivered and then checks if termination has occurred.&lt;br /&gt;
&lt;br /&gt;
===void strideExDaemonize(const char* lockFile, const char* runAs)===&lt;br /&gt;
This function is called by applications to deamonize the process. Both arguments are optional. The first argument specifies a lockfile path/name to use to insure that only one instance of the process is running. The second argument specifies a username to run as (setuid)&lt;br /&gt;
&lt;br /&gt;
This function is optional - if you prefer to run your application as an interactive console application, do not call this function. If you are running as a daemon, we recommend that you have the PAL_LOG_TO_SYSLOG macro defined (in palcfg.h) so that PAL log messages will be sent to the syslog (this is default setting currently).&lt;br /&gt;
&lt;br /&gt;
==Target Integration==&lt;br /&gt;
&lt;br /&gt;
Here are a few examples of how to integrate the stride API into your application.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; the following code assumes that the intercept module was generated with a name of &#039;&#039;myintercept&#039;&#039;.  Change all references to that name in your code to the chosen intercept module name.&lt;br /&gt;
&lt;br /&gt;
===Standalone Application Integration===&lt;br /&gt;
&lt;br /&gt;
The following code demonstrates how to integrate your application with the STRIDE Runtime. Your application might require other logic at startup - you can integrate the following calls according to your needs. Note that this code initializes the STRIDE subsystem and assumes a single standalone process that creates the STRIDE system threads as well as application threads. The call to strideExDaemonize is optional here - remove it if you don&#039;t want you application to run as a daemon. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include &amp;lt;unistd.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stride.h&amp;gt;&lt;br /&gt;
#include &amp;lt;myinterceptIMEntry.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char **argv)&lt;br /&gt;
{&lt;br /&gt;
    strideExDaemonize(NULL, NULL);&lt;br /&gt;
    strideIO_t io = {strideDEFAULT};&lt;br /&gt;
    if (strideInit(&amp;amp;io) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    if (strideCreateIMThread(myintercept) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    strideExWaitForExit();&lt;br /&gt;
    strideUninit();&lt;br /&gt;
    return 0;   &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Multiprocess Application Integration===&lt;br /&gt;
&lt;br /&gt;
This code demonstrates how to integrate your application with the STRIDE Runtime in multiprocess mode. In this mode, the pre-packaged strideDaemon runs simultaneously with the application and provides the STRIDE IO and runtime thread initialization. The host communicates with the application process through the strideDaemon (or another STRIDE IO process). In this sample, the only difference with the preceding sample is the call to strideInit which, in this case, specifies no IO parameters which indicates to the API that the communication and runtime threads should not be started. As before, the call to strideExDaemonize is optional here - remove it if you don&#039;t want your application to run as a daemon. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include &amp;lt;unistd.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stride.h&amp;gt;&lt;br /&gt;
#include &amp;lt;myinterceptIMEntry.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char **argv)&lt;br /&gt;
{&lt;br /&gt;
    strideExDaemonize(NULL, NULL);&lt;br /&gt;
    if (strideInit(NULL) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    if (strideCreateIMThread(myintercept) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    strideExWaitForExit();&lt;br /&gt;
    strideUninit();&lt;br /&gt;
    return 0;   &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Linux PAL==&lt;br /&gt;
&lt;br /&gt;
===PAL Configuration (palcfg.h)===&lt;br /&gt;
The following parameters can be configured in &#039;&#039;palcfg.h&#039;&#039; to effect the behavior of the compiled pal source files.&lt;br /&gt;
&lt;br /&gt;
; PAL_USE_SERIAL_TRANSPORT : if defined, serial communication support is enabled.&lt;br /&gt;
; PAL_USE_TCPIP_TRANSPORT : if defined, sockets-based communication support is enabled.&lt;br /&gt;
; PAL_DEFAULT_DEVICE_NAME : default IO device to use.&lt;br /&gt;
; PAL_DEFAULT_TCP_PORT : default port for TCP communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_PORT : default COM port to use for serial communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_BAUDRATE : default baud rate for serial communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_MODE : default data/parity/stop settings for serial communication.&lt;br /&gt;
; PAL_USE_POSIX_CLOCK_GETTIME or PAL_USE_GETTIMEOFDAY : indicates the time of day clock to use.&lt;br /&gt;
; PAL_TIMER_PERIOD : this is the fire interval for the STRIDE Runtime master timer, in milliseconds.&lt;br /&gt;
; PAL_MAX_THREADS : max STRIDE integrated threads that can be managed by the STRIDE API.&lt;br /&gt;
; PAL_MAX_TIMERS : max STRIDE timers that can be active in the system.&lt;br /&gt;
; PAL_USE_POSIX_TIMER or PAL_USE_INTERVAL_TIMER : indicates the timer type to use.&lt;br /&gt;
; PAL_CLOCKID : indicates the type of POSIX clock to use&lt;br /&gt;
; PAL_DELIVER_TIMER_BY_THREAD or PAL_DELIVER_TIMER_BY_SIGNAL : specify how POSIX timer signals are delivered.&lt;br /&gt;
; PAL_TIMER_SIGNAL_TYPE : define which signal to use for timer delivery.&lt;br /&gt;
; PAL_LOG_TO_SYSLOG : palLog messages will be sent to syslog if this is defined; to stdout/stderr otherwise.&lt;br /&gt;
; PAL_SHM_PATH : the path to use for shared memory files. Only needed if multiprocess support is enabled in srcfg.h.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category: SDKs]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Posix_SDK&amp;diff=8742</id>
		<title>Posix SDK</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Posix_SDK&amp;diff=8742"/>
		<updated>2008-12-30T00:39:06Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction  ==&lt;br /&gt;
&lt;br /&gt;
The Linux SDK is a platform-specific package that contains the STRIDE Runtime source and [[Target_Integration#The_Platform_Abstraction_Layer_.28PAL.29|PAL]] implementation, along with integration tools to build a stride library and a strideDaemon application. It is intended for this article to be used as a reference. For step-by-step instructions on using the contents of this package to create a test application that establishes messaging between the host and target device, please refer to the [[Linux Quickstart]] guide.&lt;br /&gt;
&lt;br /&gt;
==Target Makefile==&lt;br /&gt;
&lt;br /&gt;
The SDK makefile provides targets for building the [[Runtime Reference|STRIDE Runtime]] library and two executable applications - a strideDaemon (for a [[#Multiprocess_Application_Integration|multiprocess]] application environment), and an installTestApp (for running the STRIDE installation tests - see [[Verifying_Installation#Using_a_Platform_SDK|Using a Platform SDK]] for more information).&lt;br /&gt;
&lt;br /&gt;
The default make target builds the STRIDE Runtime library and strideDaemon executable. When a single process runtime library is specified (see RTSINGLEPROC below), the strideDaemon is omitted.  To build the installation test application, specify the &#039;&#039;&#039;installtest&#039;&#039;&#039; make target. &lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;installtest&#039;&#039;&#039; target compiles SCL source markup present in the Runtime source and therefore requires that the [[Build Tools]] be installed on your system and in your executable search path. Refer to the [[Linux Quickstart]] guide for an example how to build and run the install tests.&lt;br /&gt;
&lt;br /&gt;
===Configuration===&lt;br /&gt;
&lt;br /&gt;
The behavior of the makefile can be affected by setting certain make variable parameters. For example, the following make invocation will change the value of the TOOLCHAIN and DEBUG variables when making:&lt;br /&gt;
&lt;br /&gt;
  make TOOLCHAIN=arm DEBUG=1&lt;br /&gt;
&lt;br /&gt;
The following variable are intended to be specified or overridden as needed:&lt;br /&gt;
&lt;br /&gt;
====TOOLCHAIN====&lt;br /&gt;
&lt;br /&gt;
The default compiler toolchain when TOOLCHAIN is set to &#039;&#039;&#039;i386&#039;&#039;&#039; is gcc/g++/ar, which are assumed to be in your path.  For any other TOOLCHAIN value, the toolchain tools are $(TOOLCHAIN)-linux-gcc/g++/ar where $(TOOLCHAIN) is replaced by the specified TOOLCHAIN setting.  If your toolchain does not fit this pattern, you will need to modify the makefile or explicitly override values for CC, CPP, and AR.&lt;br /&gt;
&lt;br /&gt;
====LIBRARYTYPE====&lt;br /&gt;
&lt;br /&gt;
The default behavior of the makefile is to build the STRIDE Runtime as a static library. If you prefer a shared library, set this value to &#039;.so&#039;.&lt;br /&gt;
&lt;br /&gt;
====DEBUG====&lt;br /&gt;
&lt;br /&gt;
The default configuration compiles with optimization and NDEBUG defined.  If you prefer debuggable binaries, set this value to 1.&lt;br /&gt;
&lt;br /&gt;
====RTSINGLEPROC====&lt;br /&gt;
&lt;br /&gt;
The default configuration compiles the runtime library with multiprocess support.  If you don&#039;t want (or can&#039;t support) multiprocess functionality, you can disable this by explicitly setting this value to 1.&lt;br /&gt;
&lt;br /&gt;
====STANDALONE_INSTALLTEST====&lt;br /&gt;
&lt;br /&gt;
The default configuration, set to &#039;&#039;&#039;0&#039;&#039;&#039;, builds the installTestApp as a [[#Multiprocess_Application_Integration|multiprocess]] application. When set to &#039;&#039;&#039;1&#039;&#039;&#039; the installTestApp is built as a [[#Standalone_Application_Integration|standalone]] application. &amp;lt;br&amp;gt;&lt;br /&gt;
The STANDALONE_INSTALLTEST variable is affected by the value of RTSINGLEPROC. If RTSINGLEPROC is &#039;&#039;&#039;1&#039;&#039;&#039; and STANDALONE_INSTALLTEST is &#039;&#039;&#039;0&#039;&#039;&#039;, this is an invalid combination and STANDALONE_INSTALLTEST will automatically be set to &#039;&#039;&#039;1&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
====S2SCOPTS====&lt;br /&gt;
&lt;br /&gt;
The STRIDE build process that produces the database and [[Intercept Module]] for the installation tests relies on target settings. These settings are passed as options to the stride compiler and are most conveniently stored in an options file.  We provide a default options file with target settings that are appropriate for x86 Linux targets with GNU compilers -- this file is &#039;&#039;SDK/Linux/settings/stride.s2scompile&#039;&#039; in the SDK distribution. &lt;br /&gt;
&lt;br /&gt;
We recommend that you make a copy of this file and adjust the settings as appropriate for your target. You can then set this variable - &#039;&#039;&#039;S2SCOPTS&#039;&#039;&#039; to the path to your settings file.  This will cause the make process to use the specified target settings options instead of the default one provided in the SDK. This same settings file should ultimately be used for the STRIDE build integration with your application source code.&lt;br /&gt;
&lt;br /&gt;
===S2 Build Flags===&lt;br /&gt;
The target Makefile sets the following Build Tool flags:&lt;br /&gt;
&lt;br /&gt;
  S2_BIND_FLAGS = --starting_suid=7000&lt;br /&gt;
  S2_IM_FLAGS = --disable_access_class&lt;br /&gt;
&lt;br /&gt;
The [[S2sbind#Options|s2sbind]] and [[S2sinstrument#Options|s2sinstrument]] flags are combined so that the test application only registers for test message IDs that are created in a higher range so that it doesn&#039;t conflict with other application processes.&lt;br /&gt;
&lt;br /&gt;
==Target API (stride.h)==&lt;br /&gt;
&lt;br /&gt;
The Linux SDK provides a simplified application interface for initializing the STRIDE subsystem and starting STRIDE messaging and IM threads. The API includes the following routines:&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideInit(const strideIO_t * io)===&lt;br /&gt;
&lt;br /&gt;
This function initializes the STRIDE subsystem.  The IO configuration is passed in as an argument. If this argument is NULL, then the process will attempt to attach to an already running runtime application (daemon) using shared memory for IPC. THis function should only be called once per application.&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideUninit(void)===&lt;br /&gt;
&lt;br /&gt;
Terminates any threads that have been started with this API and uninitializes the STRIDE subsystem.&lt;br /&gt;
&lt;br /&gt;
===srBOOL strideCreateThread(strideThreadFunc_t entry, const srCHAR * name)===&lt;br /&gt;
&lt;br /&gt;
Creates a thread to be managed by the STRIDE subsystem. Threads created using this routine will be sent a palSTOP_EVENT notification (available from palWait) and should respond promptly to this event. The name parameter is used primarily for logging purposes.&lt;br /&gt;
&lt;br /&gt;
===strideCreateIMThread(name)===&lt;br /&gt;
&lt;br /&gt;
This is a macro that wraps the invocation of [[#strideCreateThread|strideCreateThread]] for intercept module entry point functions. Only the IM name must be provided.&lt;br /&gt;
&lt;br /&gt;
===void strideExWaitForExit(void)===&lt;br /&gt;
&lt;br /&gt;
This function can be called by the main application thread to block until a termination signal is received. Internally it uses the pause function to wait for signals to be delivered and then checks if termination has occurred.&lt;br /&gt;
&lt;br /&gt;
===void strideExDaemonize(const char* lockFile, const char* runAs)===&lt;br /&gt;
This function is called by applications to deamonize the process. Both arguments are optional. The first argument specifies a lockfile path/name to use to insure that only one instance of the process is running. The second argument specifies a username to run as (setuid)&lt;br /&gt;
&lt;br /&gt;
This function is optional - if you prefer to run your application as an interactive console application, do not call this function. If you are running as a daemon, we recommend that you have the PAL_LOG_TO_SYSLOG macro defined (in palcfg.h) so that PAL log messages will be sent to the syslog (this is default setting currently).&lt;br /&gt;
&lt;br /&gt;
==Target Integration==&lt;br /&gt;
&lt;br /&gt;
Here are a few examples of how to integrate the stride API into your application.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; the following code assumes that the intercept module was generated with a name of &#039;&#039;myintercept&#039;&#039;.  Change all references to that name in your code to the chosen intercept module name.&lt;br /&gt;
&lt;br /&gt;
===Standalone Application Integration===&lt;br /&gt;
&lt;br /&gt;
The following code demonstrates how to integrate your application with the STRIDE Runtime. Your application might require other logic at startup - you can integrate the following calls according to your needs. Note that this code initializes the STRIDE subsystem and assumes a single standalone process that creates the STRIDE system threads as well as application threads. The call to strideExDaemonize is optional here - remove it if you don&#039;t want you application to run as a daemon. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include &amp;lt;unistd.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stride.h&amp;gt;&lt;br /&gt;
#include &amp;lt;myinterceptIMEntry.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char **argv)&lt;br /&gt;
{&lt;br /&gt;
    strideExDaemonize(NULL, NULL);&lt;br /&gt;
    strideIO_t io = {strideDEFAULT};&lt;br /&gt;
    if (strideInit(&amp;amp;io) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    if (strideCreateIMThread(myintercept) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    strideExWaitForExit();&lt;br /&gt;
    strideUninit();&lt;br /&gt;
    return 0;   &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Multiprocess Application Integration===&lt;br /&gt;
&lt;br /&gt;
This code demonstrates how to integrate your application with the STRIDE Runtime in multiprocess mode. In this mode, the pre-packaged strideDaemon runs simultaneously with the application and provides the STRIDE IO and runtime thread initialization. The host communicates with the application process through the strideDaemon (or another STRIDE IO process). In this sample, the only difference with the preceding sample is the call to strideInit which, in this case, specifies no IO parameters which indicates to the API that the communication and runtime threads should not be started. As before, the call to strideExDaemonize is optional here - remove it if you don&#039;t want your application to run as a daemon. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include &amp;lt;unistd.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stride.h&amp;gt;&lt;br /&gt;
#include &amp;lt;myinterceptIMEntry.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char **argv)&lt;br /&gt;
{&lt;br /&gt;
    strideExDaemonize(NULL, NULL);&lt;br /&gt;
    if (strideInit(NULL) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    if (strideCreateIMThread(myintercept) != srTRUE)&lt;br /&gt;
        return -1;&lt;br /&gt;
&lt;br /&gt;
    strideExWaitForExit();&lt;br /&gt;
    strideUninit();&lt;br /&gt;
    return 0;   &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Linux PAL==&lt;br /&gt;
&lt;br /&gt;
===PAL Configuration (palcfg.h)===&lt;br /&gt;
The following parameters can be configured in &#039;&#039;palcfg.h&#039;&#039; to effect the behavior of the compiled pal source files.&lt;br /&gt;
&lt;br /&gt;
; PAL_USE_SERIAL_TRANSPORT : if defined, serial communication support is enabled.&lt;br /&gt;
; PAL_USE_TCPIP_TRANSPORT : if defined, sockets-based communication support is enabled.&lt;br /&gt;
; PAL_DEFAULT_DEVICE_NAME : default IO device to use.&lt;br /&gt;
; PAL_DEFAULT_TCP_PORT : default port for TCP communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_PORT : default COM port to use for serial communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_BAUDRATE : default baud rate for serial communication.&lt;br /&gt;
; PAL_DEFAULT_SERIAL_MODE : default data/parity/stop settings for serial communication.&lt;br /&gt;
; PAL_USE_POSIX_CLOCK_GETTIME or PAL_USE_GETTIMEOFDAY : indicates the time of day clock to use.&lt;br /&gt;
; PAL_TIMER_PERIOD : this is the fire interval for the STRIDE Runtime master timer, in milliseconds.&lt;br /&gt;
; PAL_MAX_THREADS : max STRIDE integrated threads that can be managed by the STRIDE API.&lt;br /&gt;
; PAL_MAX_TIMERS : max STRIDE timers that can be active in the system.&lt;br /&gt;
; PAL_USE_POSIX_TIMER or PAL_USE_INTERVAL_TIMER : indicates the timer type to use.&lt;br /&gt;
; PAL_CLOCKID : indicates the type of POSIX clock to use&lt;br /&gt;
; PAL_DELIVER_TIMER_BY_THREAD or PAL_DELIVER_TIMER_BY_SIGNAL : specify how POSIX timer signals are delivered.&lt;br /&gt;
; PAL_TIMER_SIGNAL_TYPE : define which signal to use for timer delivery.&lt;br /&gt;
; PAL_LOG_TO_SYSLOG : palLog messages will be sent to syslog if this is defined; to stdout/stderr otherwise.&lt;br /&gt;
; PAL_SHM_PATH : the path to use for shared memory files. Only needed if multiprocess support is enabled in srcfg.h.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category: SDKs]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Scl_string&amp;diff=8156</id>
		<title>Studio:Scl string</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Scl_string&amp;diff=8156"/>
		<updated>2008-10-22T23:56:37Z</updated>

		<summary type="html">&lt;p&gt;Andreo: /* Example 1 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= The scl_string pragma =&lt;br /&gt;
&lt;br /&gt;
The scl_string pragma identifies a particular array type or pointer type as a string. The string type (ASCII or UNICODE) is derived from the element type (1-byte or 2-byte, respectively).&lt;br /&gt;
&lt;br /&gt;
== Syntax ==&lt;br /&gt;
 #pragma scl_string(type-name, max-size)&lt;br /&gt;
 &lt;br /&gt;
 #pragma scl_string(type-name, field-name, max-size)&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;10&amp;quot; style=&amp;quot;align:left;&amp;quot;  &lt;br /&gt;
| &#039;&#039;&#039;Parameters&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;Type&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;Description&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;type-name&#039;&#039;&lt;br /&gt;
| Type&lt;br /&gt;
| Name of the type that contains the array/pointer:&amp;lt;br&amp;gt;&lt;br /&gt;
* structure or union&amp;lt;br&amp;gt;&lt;br /&gt;
* the array/pointer type itself&amp;lt;br&amp;gt;&lt;br /&gt;
* function name&amp;lt;br&amp;gt;&lt;br /&gt;
If the container type is a structure or union and the array/pointer is a member, then field-name must be specified.  &lt;br /&gt;
|- &lt;br /&gt;
| &#039;&#039;field-name [Optional]&#039;&#039;&lt;br /&gt;
| Member&lt;br /&gt;
| Optional name of the array/pointer member contained within a structure/union, or the name of the pointer in the parameter list of a function.&amp;lt;br&amp;gt;&lt;br /&gt;
If type-name is a structure or union and the array/pointer is a member, then field-name must be specified.&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;max-size&#039;&#039;&lt;br /&gt;
| Integer&lt;br /&gt;
| Specifies the maximum length of the string.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&lt;br /&gt;
Two examples using the scl_string pragma are shown below:&lt;br /&gt;
&lt;br /&gt;
=== Example 1 ===&lt;br /&gt;
The first example uses the scl_string pragma to define type definitions as null terminated ASCII strings.&lt;br /&gt;
&amp;lt;source lang=c&amp;gt;&lt;br /&gt;
#define MAX_STR_SIZE 100&lt;br /&gt;
&lt;br /&gt;
typedef char ArrayAsAsciiString_t[MAX_STR_SIZE];&lt;br /&gt;
typedef char* PointerAsAsciiString_t; &lt;br /&gt;
#pragma scl_string( PointerAsAsciiString_t, MAX_STR_SIZE )&lt;br /&gt;
#pragma scl_string( ArrayAsAsciiString_t, MAX_STR_SIZE )&lt;br /&gt;
 &lt;br /&gt;
void GetString(char* pBuf);&lt;br /&gt;
#pragma scl_function(GetString)&lt;br /&gt;
#pragma scl_ptr(GetString, pBuf, &amp;quot;OUT&amp;quot;, &amp;quot;PRIVATE&amp;quot;)&lt;br /&gt;
#pragma scl_string(GetString, pBuf, MAX_STR_SIZE)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example 2 ===&lt;br /&gt;
The second example uses the scl_string pragma to define a structure member and a parameter list member as null terminated ASCII strings.&lt;br /&gt;
&amp;lt;source lang=c&amp;gt;&lt;br /&gt;
#define MAX_STR_SIZE 64  &lt;br /&gt;
 &lt;br /&gt;
/* ASCII string defined as a pointer to char */&lt;br /&gt;
typedef struct {&lt;br /&gt;
  char * pointerToAsciiString;&lt;br /&gt;
  char arrayAsAsciiString[MAX_STR_SIZE];&lt;br /&gt;
} Struct_t;&lt;br /&gt;
 &lt;br /&gt;
/* Function with an input parameter of type ASCII string */&lt;br /&gt;
void SetString( char * parameterAsAsciiString );&lt;br /&gt;
#pragma scl_function(SetString)&lt;br /&gt;
/* Use the scl_string pragma to define the above structure     */&lt;br /&gt;
/* and parameter list members as null-terminated ASCII strings */&lt;br /&gt;
#pragma scl_string( Struct_t, pointerToAsciiString, MAX_STR_SIZE )&lt;br /&gt;
#pragma scl_string( Struct_t, arrayAsAsciiString, MAX_STR_SIZE )&lt;br /&gt;
#pragma scl_string( SetString, parameterAsAsciiString, MAX_STR_SIZE )&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
* For additional information on scl_string, including constraints, refer to the section on scl_string in the [[Media:s2sSCLReferenceGuide.pdf|SCL Reference Guide]].&lt;br /&gt;
&lt;br /&gt;
[[Category: SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Talk:Capturing_Functions&amp;diff=4762</id>
		<title>Talk:Capturing Functions</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Talk:Capturing_Functions&amp;diff=4762"/>
		<updated>2008-04-01T18:20:28Z</updated>

		<summary type="html">&lt;p&gt;Andreo: New page: I would add that the function f1_scl_func_single in the scl_function_capture_one.h file  I could not capture the function after opening the workspace. I got the warning: The database is ou...&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;I would add that the function f1_scl_func_single in the scl_function_capture_one.h file&lt;br /&gt;
&lt;br /&gt;
I could not capture the function after opening the workspace. I got the warning: The database is out of date. SCL Wizard will be disabled until successful compilation. I suggest adding that you have to compile first. &lt;br /&gt;
&lt;br /&gt;
The instructions to perform the exercise tell you what to do but don&#039;t tell where to get help or some hints on how to do it. If this is part of the training where and how would you get help?? What if I can’t remember how to do it or if I make a mistake. How do I undo something I did?&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Talk:Scripting_Multiple_Interfaces&amp;diff=4761</id>
		<title>Talk:Scripting Multiple Interfaces</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Talk:Scripting_Multiple_Interfaces&amp;diff=4761"/>
		<updated>2008-04-01T18:11:00Z</updated>

		<summary type="html">&lt;p&gt;Andreo: New page: The scripts are in Script Files\test\testScripts_InterfaceScripting_MultipleInterfaces and not just Script Files\test as described.  I suggest adding a example of the expected output in st...&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The scripts are in Script Files\test\testScripts_InterfaceScripting_MultipleInterfaces and not just Script Files\test as described.&lt;br /&gt;
&lt;br /&gt;
I suggest adding a example of the expected output in studio&#039;s output tab.&lt;br /&gt;
&lt;br /&gt;
What if the script does not work or the customer has problems writing the script? Where ca the customer get help?&lt;br /&gt;
&lt;br /&gt;
The path or instructions on how to open the html report file should be provided.&lt;br /&gt;
&lt;br /&gt;
The report should be more descriptive. I saw suites with the name f, g, and h which is not very descriptive. There is no description for the suites.&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Is_hyperthreading_supported_in_STRIDE%3F&amp;diff=3057</id>
		<title>Studio:Is hyperthreading supported in STRIDE?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Is_hyperthreading_supported_in_STRIDE%3F&amp;diff=3057"/>
		<updated>2007-12-18T18:23:46Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Yes. The Intel hyperthreading feature, where a single processor chip will run multiple (usually dual) threads of execution, is supported in STRIDE.&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Casting_and_pointers&amp;diff=3055</id>
		<title>Studio:Casting and pointers</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Casting_and_pointers&amp;diff=3055"/>
		<updated>2007-12-18T18:17:54Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;A cast must be applied to a pointer before anything else. In other words, you must apply scl_cast before scl_ptr, as illustrated by the following example:&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;#pragma scl_function(GetUnicodeName)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_cast (GetUnicodeName, name, unsigned short*)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_ptr (GetUnicodeName, name,  OUT,  PRIVATE)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_string (GetUnicodeName, name, 100)&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;br /&gt;
[[Category:Troubleshooting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:After_installing_the_STRIDE_Runtime,_what_are_my_configuration_settings%3F&amp;diff=3053</id>
		<title>Studio:After installing the STRIDE Runtime, what are my configuration settings?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:After_installing_the_STRIDE_Runtime,_what_are_my_configuration_settings%3F&amp;diff=3053"/>
		<updated>2007-12-18T18:14:06Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The Runtime configuration settings are described in the srcfg.h file, located in C:\STRIDE\runtime. Whenever you install a new version of STRIDE, you should avoid overwriting the srcfg.h file.&lt;br /&gt;
&lt;br /&gt;
The correct configuration settings are as follows:&amp;lt;br&amp;gt;&lt;br /&gt;
    &amp;lt;tt&amp;gt;  #define srCFG_TOTAL_STIDS               15               /* number of STRIDE Transact IDs in system  */&lt;br /&gt;
      #define srCFG_TOTAL_SUBCS               20               /* total number of subscribers at one time  */&lt;br /&gt;
      #define srCFG_TOTAL_PTRS                30               /* total number of pointer entries          */&amp;lt;br&amp;gt;&lt;br /&gt;
      #define srCFG_SUID_TABLE_TYPE           0                /* 1 = Search based, 0 = Index based        */&lt;br /&gt;
      #define srCFG_SUID_TABLE_SIZE           225              /* number of SUID Table entries             */&lt;br /&gt;
      #define srCFG_SUID_OVERRIDE             1                /* override (1 = enabled, 0 = disabled)     */&lt;br /&gt;
      #define srCFG_SUID_OVERRIDE_STORAGE     0                /* override registration storage allocation */&amp;lt;br&amp;gt;&lt;br /&gt;
      #define srCFG_TOTAL_SUIDS_QUED          50               /* total number of SUIDS queued at one time */&amp;lt;br&amp;gt;&lt;br /&gt;
      #define srCFG_STID_NAME_SIZE            15               /* max size of a STRIDE Transact ID name    */&lt;br /&gt;
&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Working_with_%22default%22_candidates&amp;diff=3046</id>
		<title>Studio:Working with &quot;default&quot; candidates</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Working_with_%22default%22_candidates&amp;diff=3046"/>
		<updated>2007-12-11T23:09:12Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;scl_ptr_flist() serves as a &amp;quot;shorthand&amp;quot; method of declaring a &amp;quot;default&amp;quot; candidate.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: When using scl_ptr_flist() to define candidates, the function pointer prototypes are defined internally within STRIDE, rather than by the user. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;// function pointer typedef&amp;lt;br&amp;gt;&lt;br /&gt;
 typedef void (*FPtr) (int, char);&amp;lt;br&amp;gt;&lt;br /&gt;
 void foo(FPtr *pFPtr);&amp;lt;br&amp;gt;&lt;br /&gt;
 void foo1(FPtr *pFPtr);&amp;lt;br&amp;gt;&lt;br /&gt;
 void foo2(FPtr *pFPtr);&amp;lt;br&amp;gt;&lt;br /&gt;
 void foo3(FPtr *pFPtr);&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
 // candidate prototypes &amp;lt;br&amp;gt;&lt;br /&gt;
 void C1(int x, char y);&amp;lt;br&amp;gt;&lt;br /&gt;
 void C2(int x, char y);&amp;lt;br&amp;gt;&lt;br /&gt;
 void C3(int x, char y);&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
 // pragmatize candidate prototypes&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_function(C1)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_function(C2)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_function(C3)&amp;lt;br&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;How to declare a &amp;quot;default&amp;quot; candidate using scl_ptr_flist()&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
There are several methods of declaring a &amp;quot;default&amp;quot; candidate using scl_ptr_flist(). Each method is explained below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Method 1: Candidate list declaration using predefined function prototypes&#039;&#039;&#039;&lt;br /&gt;
 &amp;lt;tt&amp;gt;#pragma scl_function(foo)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_ptr_flist(*foo.pFPtr, C1, C2, C3)&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The candidates&#039; (C1, C2, C3) prototypes are defined and pragmatized, and proxies/stubs will be generated. In the parent function (the function that contains the function pointer PFptr) will use a for loop to search through the static table to bind the function pointer with the SMID or vice versa. The command and response payloads of the candidate functions (C1, C2, C3) can be captured via tracing.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Method 2: Candidate list declaration using shorthand method&#039;&#039;&#039;&lt;br /&gt;
 &amp;lt;tt&amp;gt;#pragma scl_function(foo1)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_ptr_flist(*foo1.pFPtr, &amp;quot;cand1&amp;quot;)&amp;lt;br&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;quot;Default&amp;quot; proxies/stubs will be generated for the name in quotes in scl_ptr_flist() &amp;quot;cand1&amp;quot; in the example above. The command and response payloads of the candidate functions (e.g., &amp;quot;cand1&amp;quot;) can be captured via tracing.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Method 3: Candidate list declaration using combination of predefined functions and shorthand method&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;#pragma scl_function(foo2)&lt;br /&gt;
 #pragma scl_ptr_flist(*foo2.pFPtr, &amp;quot;cand4&amp;quot;, C2)&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The candidate &amp;quot;cand4&amp;quot; is interpreted by STRIDE as follows:&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;tt&amp;gt; void cand4(int p1, char p2);&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_function(cand4)&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;quot;Default&amp;quot; proxies/stubs will be generated for the name in quotes in scl_ptr_flist() &amp;quot;cand4&amp;quot; in the example above. The command and response payloads of the candidate functions (e.g., &amp;quot;cand4&amp;quot;) can be captured via tracing.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Method 4: &amp;quot;Default&amp;quot; candidate declaration&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;#pragma scl_function(foo3)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_ptr_flist(*foo3.pFPtr, &amp;quot;def_cand&amp;quot;)&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The candidate &amp;quot;def_cand&amp;quot; is interpreted by STRIDE as follows:&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;void def_cand(int p1, char p2);&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_function(def_cand)&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A &amp;quot;default&amp;quot; proxy/stub will be generated for def_cand. The parent function will not use a for loop and the proxy will replace the existing function pointer in the table with the passed-in function pointer. The command and response payloads of any function prototype with the identical signature to def_cand can be captured via tracing.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Why_am_I_getting_%22unresolved_external_reference%22_errors_during_the_linking_process%3F&amp;diff=3045</id>
		<title>Why am I getting &quot;unresolved external reference&quot; errors during the linking process?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Why_am_I_getting_%22unresolved_external_reference%22_errors_during_the_linking_process%3F&amp;diff=3045"/>
		<updated>2007-12-11T23:05:43Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The srIMON flag in your compiler switches may not be defined. This flag is used to include and exclude source files associated with intercept modules.&lt;br /&gt;
&lt;br /&gt;
Also if you use dynamic delegate make sure that the IM.h files is included in your source file for name mangling.&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:Troubleshooting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:The_communication/messaging_model_I_use_in_my_target_application_is_not_compliant_with_STRIDE&amp;diff=3043</id>
		<title>Studio:The communication/messaging model I use in my target application is not compliant with STRIDE</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:The_communication/messaging_model_I_use_in_my_target_application_is_not_compliant_with_STRIDE&amp;diff=3043"/>
		<updated>2007-12-11T23:00:49Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The STRIDE Communication Model can be used to bridge the differences between it and the messaging model employed in your embedded application. Refer to the &amp;quot;Using a Remote Message Stub Thread&amp;quot; section of the STRIDE Runtime Developer&#039;s Guide, available through STRIDE&#039;s online help, for more information.&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:Troubleshooting]]&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Sending_and_receiving_broadcast_messages_in_the_Runtime&amp;diff=3042</id>
		<title>Studio:Sending and receiving broadcast messages in the Runtime</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Sending_and_receiving_broadcast_messages_in_the_Runtime&amp;diff=3042"/>
		<updated>2007-12-11T23:00:00Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;If broadcast messages are being sent from the target to the host (i.e., there are no subscribers on the target), the data must be marshalled up to the host. However, when both the broadcaster (owner) and a receiver (user) are on the target, it is more efficient to specify srST_RSP_PTR since only a pointer to the message is moved internally. &lt;br /&gt;
&lt;br /&gt;
By contrast, if srST_RSP_VAL is specified, the entire message is copied before being sent.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Is_it_possible_to_change_the_host_trace_buffer_size%3F&amp;diff=3040</id>
		<title>Studio:Is it possible to change the host trace buffer size?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Is_it_possible_to_change_the_host_trace_buffer_size%3F&amp;diff=3040"/>
		<updated>2007-12-11T22:56:57Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Yes. From within STRIDE Studio, click on the Property sheet (or to open it, select &#039;&#039;&#039;Properties&#039;&#039;&#039; from the &#039;&#039;&#039;View&#039;&#039;&#039; menu) and change the value in the &#039;&#039;&#039;Preferences -&amp;gt; Cache Size (KB)&#039;&#039;&#039; field.&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Handling_non-standard_or_unsupported_keywords&amp;diff=3039</id>
		<title>Handling non-standard or unsupported keywords</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Handling_non-standard_or_unsupported_keywords&amp;diff=3039"/>
		<updated>2007-12-11T22:55:52Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;For example if the &amp;lt;tt&amp;gt;__inline__&amp;lt;/tt&amp;gt; keyword is missing or unsupported, you can work around it by adding &amp;lt;tt&amp;gt;&#039;__inline__=&#039;&amp;lt;/tt&amp;gt; to the workspace definitions.&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;br /&gt;
[[Category:Troubleshooting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_to_generate_a_preprocessor_(.i)_file_for_analysis&amp;diff=3038</id>
		<title>Studio:How to generate a preprocessor (.i) file for analysis</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_to_generate_a_preprocessor_(.i)_file_for_analysis&amp;diff=3038"/>
		<updated>2007-12-11T22:55:28Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Preprocessing individual files&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
You can run the preprocessor on one or more header files to generate .i files, which can then be used for analysis. To do this from within Studio, select one or more top-level header files, right-click, and choose &#039;&#039;&#039;Preprocess&#039;&#039;&#039;. &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: You will need to rename the file to have a .h extension.&lt;br /&gt;
&lt;br /&gt;
Only the selected files are compiled, and preprocessed (.i) files are generated for them. During the compilation, the workspace settings for #defines and include paths are in effect. Existing databases are not affected. &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The #include &amp;lt;stdarg.h&amp;gt; will require the workspace to have a valid pointer (usually to the Microsoft C includes directory).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
[[Category:Troubleshooting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_can_I_tell_which_version_of_a_workspace_is_used_when_connected_to_the_target_at_runtime%3F&amp;diff=3035</id>
		<title>Studio:How can I tell which version of a workspace is used when connected to the target at runtime?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_can_I_tell_which_version_of_a_workspace_is_used_when_connected_to_the_target_at_runtime%3F&amp;diff=3035"/>
		<updated>2007-12-11T22:53:06Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;When working with multiple targets, you may want to determine which version of a workspace is being used at runtime. To determine the target to which you are connected, add a helper function to the Intercept Module which can return something from the target (e.g., a string whose value is a target compile-time setting) that will tell the script the kind of target to which it is connected.&lt;br /&gt;
&lt;br /&gt;
You can also add a preprocessor define with a version number as part of the workspace build (not the target build). The define is not used for compilation. A script will check which preprocessor define is set and act accordingly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Handling_non-standard_or_unsupported_keywords&amp;diff=3033</id>
		<title>Handling non-standard or unsupported keywords</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Handling_non-standard_or_unsupported_keywords&amp;diff=3033"/>
		<updated>2007-12-11T22:50:20Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;For example if the &amp;lt;tt&amp;gt;__inline__&amp;lt;/tt&amp;gt; keyword is missing or unsupported, you can work around it by adding &amp;lt;tt&amp;gt;&#039;__inline__=&#039;&amp;lt;/tt&amp;gt; to the workspace definitions.&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_does_the_STRIDE_compiler_handle_zero-length_arrays%3F&amp;diff=3032</id>
		<title>Studio:How does the STRIDE compiler handle zero-length arrays?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_does_the_STRIDE_compiler_handle_zero-length_arrays%3F&amp;diff=3032"/>
		<updated>2007-12-11T22:49:45Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;A zero-length array embedded in the middle of a struct is treated as if it was not there (i.e., as if it was commented out). It will not allocate storage or affect alignment in the structure in any way. It will not be addressable from ascript and will not be visible in the interface or workspace view.&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Casting_and_pointers&amp;diff=3031</id>
		<title>Studio:Casting and pointers</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Casting_and_pointers&amp;diff=3031"/>
		<updated>2007-12-11T22:48:20Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;A cast must be applied to a pointer before anything else. In other words, you must apply scl_cast before scl_ptr, as illustrated by the following example:&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;#pragma scl_function(GetUnicodeName)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_cast (GetUnicodeName, name, unsigned short*)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_ptr (GetUnicodeName, name,  OUT,  PRIVATE)&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_string (GetUnicodeName, name, 100)&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Auxiliary_data&amp;diff=3029</id>
		<title>Studio:Auxiliary data</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Auxiliary_data&amp;diff=3029"/>
		<updated>2007-12-11T22:45:07Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;If auxiliary data is enabled (srCFG_AUXDATA is set to 1 in srcfg.h), auxiliary data is transmitted with each message. The data you set using srSetAuxData for the particular STID is transferred with each message. Once the value is set, the same value will be transmitted with each message until you change the value.&lt;br /&gt;
&lt;br /&gt;
With srGetAuxData, you can read the data. The value returned will be the one that was received with the most recent message on that STID. The auxiliary data is bidirectional, which means that there is a set of data which is sent in each direction. srSetAuxData sets the transmit auxiliary data and srGetAuxData reads the received auxiliary data. Transmit auxiliary data is accessible in a write-only manner through srSetAuxData, and receiving auxiliary data is accessible in a read-only manner through srGetAuxData.&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Stride_System_Error_Logging&amp;diff=3028</id>
		<title>Studio:Stride System Error Logging</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Stride_System_Error_Logging&amp;diff=3028"/>
		<updated>2007-12-11T22:44:31Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Acceptable error log level values are &#039;&#039;all, trace, debug, info, warn, error, fatal,&#039;&#039; and &#039;&#039;off&#039;&#039;. The default is &#039;&#039;error&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Advantages_and_disadvantages_of_%22default%22_candidates&amp;diff=3026</id>
		<title>Studio:Advantages and disadvantages of &quot;default&quot; candidates</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Advantages_and_disadvantages_of_%22default%22_candidates&amp;diff=3026"/>
		<updated>2007-12-11T22:42:52Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following table describes the advantages and disadvantages associated with the &amp;quot;default&amp;quot; candidate method vs. the candidate method.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;, cellpadding=&amp;quot;5&amp;quot;&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
! &lt;br /&gt;
&lt;br /&gt;
! &#039;&#039;&#039;&amp;quot;Default&amp;quot; candidate method&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
! &#039;&#039;&#039;Candidate method&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| &#039;&#039;&#039;Define and pragmatize each function prototype&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
| Not needed.&lt;br /&gt;
&lt;br /&gt;
| Cumbersome if there are hundreds of candidate functions. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| &#039;&#039;&#039;Code footprint of the generated code&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
| Only the proxy/stub of the &amp;quot;default&amp;quot; candidate is generated; thus, the code footprint is much smaller. &lt;br /&gt;
&lt;br /&gt;
| The code footprint is dependent upon how many candidates are defined using the scl_ptr_flist() pragma, since a proxy/stub is generated for each candidate defined in the list.&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| &#039;&#039;&#039;Capturing of function callback command/response payloads via the trace module&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
| Any function callback command/response payloads with the identical signature can be captured.  &lt;br /&gt;
&lt;br /&gt;
| Only those candidate functions defined in the scl_ptr_flist() pragma can be captured.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| &#039;&#039;&#039; Visibility of function callbacks via the trace module&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
| The function callback being called is unknown. All of the function callbacks with the identical signature will be displayed with the &amp;quot;default&amp;quot; candidate name and SMID. &lt;br /&gt;
&lt;br /&gt;
| All of the function callbacks being called are known, as long as the candidate functions were declared in the scl_ptr_flist() pragma.&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
One disadvantage of using the shorthand method to define candidates in scl_ptr_flist(), as shown in Method 3 of the [[Working with &amp;quot;default&amp;quot; candidates]] topic, is that the function pointer prototypes are not defined by the user/customer, but rather by STRIDE. So, for example, if the user wants to create a proxy for foo2() with stub candidate functions C2 and &amp;quot;cand4&amp;quot; on the target, the generated IM code will give &amp;quot;undefined&amp;quot; compiler errors for &amp;quot;cand4&amp;quot;. The following procedure using the header file MyHeader.h (the file containing the SCL pragmas or function prototypes) resolves this issue:&lt;br /&gt;
 &amp;lt;tt&amp;gt;#ifdef srIMON&amp;lt;br&amp;gt;&lt;br /&gt;
 void cand4(int x, char y);&amp;lt;br&amp;gt;&lt;br /&gt;
 #endif &amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The use of the srIMON preprocessor directive allows the SDAC to compile the file without any name conflicts for &amp;quot;cand4&amp;quot;, since these are already defined within STRIDE. It also allows the generated IM code to compile successfully.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;MyFunctions.c&#039;&#039;&#039;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
MyFunctions.c is an example of a user-created file containing the actual code for the candidate &amp;quot;cand4&amp;quot;:&lt;br /&gt;
 &amp;lt;tt&amp;gt;void cand4(int x, char y)&amp;lt;br&amp;gt;&lt;br /&gt;
 { &amp;lt;br&amp;gt;&lt;br /&gt;
 } &amp;lt;br&amp;gt; &amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;MyTest.c&#039;&#039;&#039;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
MyTest.c is an example of a user-created file containing a test thread that makes the call to foo2() with the appropriate function pointer callback:&lt;br /&gt;
 &amp;lt;tt&amp;gt;#include “MyHeader.h”&amp;lt;br&amp;gt;&lt;br /&gt;
 FPtr funcPtr;&amp;lt;br&amp;gt;&lt;br /&gt;
 // set to cand4&amp;lt;br&amp;gt;&lt;br /&gt;
 funcPtr = cand4;&amp;lt;br&amp;gt;&lt;br /&gt;
 foo2(&amp;amp;funcPtr);&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
In some instances, the candidates on the target are not known to the implementer of foo2() and the candidates may be static, so the above solution isn’t applicable. Using the “default” candidate mechanism is the perfect solution to this problem. The following example demonstrates how to do this (refer to Method 3 above):&lt;br /&gt;
&lt;br /&gt;
In MyHeader.h (the file that contains the SCL pragma’s or the function prototypes), replace the following:&lt;br /&gt;
 &amp;lt;tt&amp;gt;#pragma scl_ptr_flist(*foo2.pFPtr, “cand4”, C2)&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
with:&lt;br /&gt;
 &amp;lt;tt&amp;gt;#pragma scl_ptr_flist(*foo2.pFPtr, “default_cand”) // default candidate&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;MyFunctions.c&#039;&#039;&#039;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
MyFunctions.c is an example of a user-created file containing the actual code for the candidates (unknown_cand1, unknown_cand2):&lt;br /&gt;
 &amp;lt;tt&amp;gt;static void unknown_cand1(int x, char y)&amp;lt;br&amp;gt;&lt;br /&gt;
 {&amp;lt;br&amp;gt;&lt;br /&gt;
 }&amp;lt;br&amp;gt;&lt;br /&gt;
 static void unknown_cand2(int x, char y)&amp;lt;br&amp;gt;&lt;br /&gt;
 {&amp;lt;br&amp;gt;&lt;br /&gt;
 }&amp;lt;br&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;MyTest.c&#039;&#039;&#039;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
MyTest.c is an example of a user-created file containing a test thread that makes the call to foo2() with the appropriate function pointer callback.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;tt&amp;gt;#include “MyHeader.h”&amp;lt;br&amp;gt;&lt;br /&gt;
 FPtr funcPtr;&amp;lt;br&amp;gt;&lt;br /&gt;
 // set to unknown_cand1&amp;lt;br&amp;gt;&lt;br /&gt;
 funcPtr = unknown_cand1;&amp;lt;br&amp;gt;&lt;br /&gt;
 foo2(&amp;amp;funcPtr);&amp;lt;br&amp;gt;&lt;br /&gt;
 // set to unknown_cand2&amp;lt;br&amp;gt;&lt;br /&gt;
 funcPtr = unknown_cand2;&amp;lt;br&amp;gt;&lt;br /&gt;
 foo2(&amp;amp;funcPtr);&amp;lt;br&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:What_to_do_when_the_Perl_tag_file_is_corrupted&amp;diff=3025</id>
		<title>Studio:What to do when the Perl tag file is corrupted</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:What_to_do_when_the_Perl_tag_file_is_corrupted&amp;diff=3025"/>
		<updated>2007-12-11T22:36:26Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;If the tag file (C:\STRIDE\bin\vslick\S2Custom\StridePL.vtg) becomes corrupted, delete it.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;br /&gt;
[[Category:Troubleshootng]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Referring_to_global_stride_objects&amp;diff=3014</id>
		<title>Studio:Referring to global stride objects</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Referring_to_global_stride_objects&amp;diff=3014"/>
		<updated>2007-12-11T21:48:02Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following variables are automatically injected when scripts are run in Studio, and must be referred to:&lt;br /&gt;
&lt;br /&gt;
$ascript&lt;br /&gt;
&lt;br /&gt;
$studio&lt;br /&gt;
&lt;br /&gt;
$reporter&lt;br /&gt;
&lt;br /&gt;
$panel&lt;br /&gt;
&lt;br /&gt;
$testSuite&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In Perl, these variables must be qualified with the namespace (main::) in order for the script to run under strictures (invoked by including use strict in your script): &lt;br /&gt;
&lt;br /&gt;
{| &lt;br /&gt;
| &#039;&#039;&#039;Automatic variable&#039;&#039;&#039;  || &#039;&#039;&#039;Refer to as&#039;&#039;&#039;&lt;br /&gt;
|- &lt;br /&gt;
| width=&amp;quot;200pt&amp;quot; | $ascript ||  $main::ascript&lt;br /&gt;
|-&lt;br /&gt;
| $studio  ||  $main::reporter&lt;br /&gt;
|- &lt;br /&gt;
| $reporter || $main::studio&lt;br /&gt;
|-&lt;br /&gt;
| $panel || $main::panel&lt;br /&gt;
|-&lt;br /&gt;
| $testSuite || $main::testSuite&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Using use strict in scripts is recommended, as it catches a number of potential errors that might otherwise go undetected.  However, if strictures are not used, these global variables may be referred to without the main:: qualification.&lt;br /&gt;
&lt;br /&gt;
For additional information on global variables on the target, click [[Accessing global variables|here]].&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_access_global_variables%3F&amp;diff=3013</id>
		<title>Studio:How do I access global variables?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_access_global_variables%3F&amp;diff=3013"/>
		<updated>2007-12-11T21:38:39Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;STRIDE allows you to call functions and send messages on the target, which is in most cases all you need for validation. However, in some cases it might be necessary to read or modify global variables or certain memory locations. If there are API functions available to access the global variables or read memory, those APIs could be exposed to STRIDE and used. If no such API calls are available, they can be added; this requires changes to the target code. Although STRIDE doesn’t directly support accessing target memory with simple helper functions, you can easily access target information without changing the target code by adding code to a header file containing SCL pragmas.&lt;br /&gt;
&lt;br /&gt;
This header file would then be included in the STRIDE workspace, and therefore included in the intercept module. It would not be required to include the header file in any of the customer target code, nor would modifications to the customer code be required. Since the function is known to the intercept module and the intercept module is the only one calling the function, it could be static and therefore have no impact on the rest of the code. The following demonstrates a header file which is included in the STRIDE workspace and subsequently in the intercept module; the function is defined as static, since its scope is limited to the intercept module.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example: Reading a number of bytes from the target&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;static __inline__ void SCL_get_num_bytes ( void *ptr, unsigned char* data, int num_bytes)&amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;{ &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;    memcpy ( data, ptr, num_bytes ); &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;} &amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reading and writing global data&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Another application is to read and write global data. For example, we could have a global state variable. Either the header file which defines the global state variable could be included, or an external definition could be added to the header file. The first option is preferred; in some cases the global state variable definition could be in a .c file.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example: STRIDE header file&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;/* extern definition for global */&amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;extern int global_state&amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;/* helper function to set the state */&amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;static __inline__ void SCL_set_state(int state)&amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt; { &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt; global_state = state; &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt; } &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt; /* helper function to get (read) the state */ &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt; static __inline__ int SCL_get_state(void) &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt; { &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt; return global_state;&amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt; } &amp;lt;/code&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:KB]]&lt;br /&gt;
[[Category:Scripting]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Perl_and_COM&amp;diff=3012</id>
		<title>Studio:Perl and COM</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Perl_and_COM&amp;diff=3012"/>
		<updated>2007-12-11T21:37:18Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Because of its multiplatform heritage, Perl is not a COM-aware language by default. The Win32::OLE package integrates COM with Perl, however there are some &amp;quot;features&amp;quot; of this library that might not be intuitive to Perl programmers. The most important ones are the options the library provides for error reporting (warning level). For more information see [http://search.cpan.org/~jdb/libwin32-0.26/OLE/lib/Win32/OLE.pm Win32::OLE description].&lt;br /&gt;
&lt;br /&gt;
* We always recommend setting a warn level of 3. If you don&#039;t do this, COM errors won&#039;t be passed back to the script. In JScript, you always receive COM errors, so warn level 3 brings Perl in line with that behavior.&lt;br /&gt;
* When working with unicode the code page has to be set in order to get Perl/COM to properly pass the pchar value as a unicode character. For example Win32::OLE-&amp;gt;Option(CP =&amp;gt; Win32::OLE::CP_UTF8);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_to_define_message_structures&amp;diff=3011</id>
		<title>Studio:How to define message structures</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_to_define_message_structures&amp;diff=3011"/>
		<updated>2007-12-11T21:28:27Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following rules make it easier to process unions and select the active member(s) within a union or nested unions, as well as making it easier to transfer data between tasks.&lt;br /&gt;
* Have a one-to-one correlation between disciminants and union members.&lt;br /&gt;
* The order of enums for discriminants matches with the order of members within the union.&lt;br /&gt;
* In the case of nested unions, each union should have its own discriminant.&lt;br /&gt;
* Use inline data instead of pointers.&lt;br /&gt;
&lt;br /&gt;
Below is an example:&lt;br /&gt;
 &amp;lt;tt&amp;gt;typedef struct&amp;lt;br&amp;gt;&lt;br /&gt;
   {&amp;lt;br&amp;gt;&lt;br /&gt;
    DEVICE_NAME,&amp;lt;br&amp;gt;&lt;br /&gt;
    INQUIRY,&amp;lt;br&amp;gt;&lt;br /&gt;
    SD,&amp;lt;br&amp;gt;&lt;br /&gt;
    SECURITY,&amp;lt;br&amp;gt;&lt;br /&gt;
    CONN, &amp;lt;br&amp;gt;&lt;br /&gt;
   } app_opcodes_t;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The corresponding message structure is as follows:&lt;br /&gt;
 &amp;lt;tt&amp;gt;typedef struct&amp;lt;br&amp;gt;&lt;br /&gt;
   {&amp;lt;br&amp;gt;&lt;br /&gt;
    ros_hdr_t  ros_hdr;&amp;lt;br&amp;gt;&lt;br /&gt;
    vris_hdr_t  vris_hdr;&amp;lt;br&amp;gt;&lt;br /&gt;
    app_hdr_t  app_hdr;&amp;lt;br&amp;gt;&lt;br /&gt;
 union&amp;lt;br&amp;gt;&lt;br /&gt;
      { &amp;lt;br&amp;gt;&lt;br /&gt;
        app_name_msg_t   app_name_msg;&amp;lt;br&amp;gt;&lt;br /&gt;
        app_inquiry_msg_t   app_inquiry_msg;&amp;lt;br&amp;gt;&lt;br /&gt;
        app_sd_msg_t   app_sd_msg;&amp;lt;br&amp;gt;&lt;br /&gt;
        app_sec_msg_t   app_sec_msg;&amp;lt;br&amp;gt;&lt;br /&gt;
        app_conn_msg_t   app_conn_msg;&amp;lt;br&amp;gt;&lt;br /&gt;
      } ros_msg&amp;lt;br&amp;gt;&lt;br /&gt;
   } app_msg_t;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The first element of the union app_name_msg matches with the first enum value of DEVICE_NAME (discriminant within ros_hdr). The number and order of the discriminant values (app_opcodes_t) are the same as the union members.&lt;br /&gt;
&lt;br /&gt;
If the union within the message contains other unions (nested unions), the same rule would apply. The following example demonstrates app_sec_msg_t within ros_msg:&lt;br /&gt;
 &amp;lt;tt&amp;gt;typedef enum&amp;lt;br&amp;gt;&lt;br /&gt;
   {&amp;lt;br&amp;gt;&lt;br /&gt;
        DISCOVERABLE_CFM,&amp;lt;br&amp;gt;&lt;br /&gt;
        CONNECTABLE_CFM,&amp;lt;br&amp;gt;&lt;br /&gt;
        SEC_AUTHORIZE_CFM,&amp;lt;br&amp;gt;&lt;br /&gt;
        SEC_AUTHENTICATE_CFM,&amp;lt;br&amp;gt;&lt;br /&gt;
        SEC_BOND_CFM,&amp;lt;br&amp;gt;&lt;br /&gt;
   } app_prim_sec_t;&amp;lt;br&amp;gt;&lt;br /&gt;
 typedef struct&amp;lt;br&amp;gt;&lt;br /&gt;
 {&amp;lt;br&amp;gt;&lt;br /&gt;
    app_prim_sec_t sec_msg_rsp;&amp;lt;br&amp;gt;&lt;br /&gt;
 union&amp;lt;br&amp;gt;&lt;br /&gt;
 { &amp;lt;br&amp;gt;&lt;br /&gt;
        discoverable_mode   discoverable_info;&amp;lt;br&amp;gt;&lt;br /&gt;
        connectable_info_t   connectable_info;&amp;lt;br&amp;gt;&lt;br /&gt;
        authorize_info_t   authorize_info;&amp;lt;br&amp;gt;&lt;br /&gt;
        authenticate_info_t   authenticate_info;&amp;lt;br&amp;gt;&lt;br /&gt;
        user_info_input_t   user_input_info;&amp;lt;br&amp;gt;&lt;br /&gt;
        bond_info_t   bond_info;&amp;lt;br&amp;gt;&lt;br /&gt;
        } sec_msg;&amp;lt;br&amp;gt;&lt;br /&gt;
 } app_sec_msg_t;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The above examples have the same number of discriminant values and union members. There is a one-to-one correlation between discriminant and union member. Having a discriminant for each union within nested unions decouples the unions and makes it more scalable and easier to maintain. The unions become independent of each other and can easily be extended.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_start_non-blocking_scripts_which_do_not_use_the_Reporter_from_a_Perl_script%3F&amp;diff=3010</id>
		<title>Studio:How do I start non-blocking scripts which do not use the Reporter from a Perl script?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_start_non-blocking_scripts_which_do_not_use_the_Reporter_from_a_Perl_script%3F&amp;diff=3010"/>
		<updated>2007-12-11T21:26:00Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The reporter object is automatically instantiated when a script is started in studio. If none of the STRIDE objects need to be instantiated you can start a script extern to stride.  &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;tt&amp;gt;use Win32;&amp;lt;br&amp;gt;&lt;br /&gt;
 use Win32::API;&amp;lt;br&amp;gt;&lt;br /&gt;
 use Win32::Process;&amp;lt;br&amp;gt;&lt;br /&gt;
 use constant WIN32_STILL_RUNNING =&amp;gt; 259;&amp;lt;br&amp;gt;&lt;br /&gt;
 my $processObject;&amp;lt;br&amp;gt;&lt;br /&gt;
 my $retValue = Win32::Process::Create(&amp;lt;br&amp;gt;&lt;br /&gt;
  $processObject,&lt;br /&gt;
  $^X,&lt;br /&gt;
  &amp;quot;perl PATH_TO_MY_SCRIPT ARGUMENTS&amp;quot;,&lt;br /&gt;
  0,&lt;br /&gt;
  NORMAL_PRIORITY_CLASS,&lt;br /&gt;
  &amp;quot;.&amp;quot;) || die Win32::FormatMessage(Win32::GetLastError());&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Once you have started the process this way, you can use GetExitCode to check if it is still running, as shown in the following example:&lt;br /&gt;
 &amp;lt;tt&amp;gt;$processObject-&amp;gt;GetExitCode($exitCode);&amp;lt;br&amp;gt;&lt;br /&gt;
 if ($exitCode == Win32_STILL_RUNNING) {&amp;lt;br&amp;gt;&lt;br /&gt;
 ## it is still running&amp;lt;br&amp;gt;&lt;br /&gt;
 }&amp;lt;br&amp;gt;&lt;br /&gt;
 else  {&amp;lt;br&amp;gt;&lt;br /&gt;
 ## it has finished&amp;lt;br&amp;gt;&lt;br /&gt;
 }&amp;lt;br&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can kill the process by using&lt;br /&gt;
 &amp;lt;tt&amp;gt;$processObject-&amp;gt;Kill(255);&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Using the above statement forces a kill and is not a graceful way to force the process to exit. If your script is a daemon-like process, it is recommended that you use some sort of IPC mechanism (such as Win32::Event or sockets, pipes, semaphores, etc.) to force a more graceful shutdown.&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_start_non-blocking_scripts_which_do_not_use_the_Reporter_from_a_Perl_script%3F&amp;diff=3009</id>
		<title>Studio:How do I start non-blocking scripts which do not use the Reporter from a Perl script?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_start_non-blocking_scripts_which_do_not_use_the_Reporter_from_a_Perl_script%3F&amp;diff=3009"/>
		<updated>2007-12-11T21:25:29Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The reporter object is automatically instantiated when a script is started in studio. If none of the STRIDE objects need to be instantiated you can start a script extern to stride.  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;use Win32;&amp;lt;br&amp;gt;&lt;br /&gt;
 use Win32::API;&amp;lt;br&amp;gt;&lt;br /&gt;
 use Win32::Process;&amp;lt;br&amp;gt;&lt;br /&gt;
 use constant WIN32_STILL_RUNNING =&amp;gt; 259;&amp;lt;br&amp;gt;&lt;br /&gt;
 my $processObject;&amp;lt;br&amp;gt;&lt;br /&gt;
 my $retValue = Win32::Process::Create(&amp;lt;br&amp;gt;&lt;br /&gt;
  $processObject,&lt;br /&gt;
  $^X,&lt;br /&gt;
  &amp;quot;perl PATH_TO_MY_SCRIPT ARGUMENTS&amp;quot;,&lt;br /&gt;
  0,&lt;br /&gt;
  NORMAL_PRIORITY_CLASS,&lt;br /&gt;
  &amp;quot;.&amp;quot;) || die Win32::FormatMessage(Win32::GetLastError());&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Once you have started the process this way, you can use GetExitCode to check if it is still running, as shown in the following example:&lt;br /&gt;
 &amp;lt;tt&amp;gt;$processObject-&amp;gt;GetExitCode($exitCode);&amp;lt;br&amp;gt;&lt;br /&gt;
 if ($exitCode == Win32_STILL_RUNNING) {&amp;lt;br&amp;gt;&lt;br /&gt;
 ## it is still running&amp;lt;br&amp;gt;&lt;br /&gt;
 }&amp;lt;br&amp;gt;&lt;br /&gt;
 else  {&amp;lt;br&amp;gt;&lt;br /&gt;
 ## it has finished&amp;lt;br&amp;gt;&lt;br /&gt;
 }&amp;lt;br&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can kill the process by using&lt;br /&gt;
 &amp;lt;tt&amp;gt;$processObject-&amp;gt;Kill(255);&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Using the above statement forces a kill and is not a graceful way to force the process to exit. If your script is a daemon-like process, it is recommended that you use some sort of IPC mechanism (such as Win32::Event or sockets, pipes, semaphores, etc.) to force a more graceful shutdown.&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_speed_up_scripts_by_caching_an_intermediate_collection/object%3F&amp;diff=3008</id>
		<title>Studio:How do I speed up scripts by caching an intermediate collection/object?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_speed_up_scripts_by_caching_an_intermediate_collection/object%3F&amp;diff=3008"/>
		<updated>2007-12-11T21:15:17Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following example re-accesses the ascript object for each node of the Files and Item() collection. This is slow and expensive:&lt;br /&gt;
 &amp;lt;tt&amp;gt;#enable the &amp;quot;makereport&amp;quot; property for the item we just added&amp;lt;br&amp;gt;&lt;br /&gt;
 $subFolder-&amp;gt;Files-&amp;gt;Item($script_name)-&amp;gt;{MakeReport} = &amp;quot;true&amp;quot;;&amp;lt;br&amp;gt;&lt;br /&gt;
 #mark the script as executable or not&amp;lt;br&amp;gt;&lt;br /&gt;
 $subFolder-&amp;gt;Files-&amp;gt;Item($script_name)-&amp;gt;{Execute} = $entry-&amp;gt;{executable} || &#039;false&#039;;&amp;lt;br&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A faster and better way is to reuse the object returned by the Add() method (which is the same one returned by the Item() method later). The change shown in the example below improved performance by over 50%:&lt;br /&gt;
 &amp;lt;tt&amp;gt;my $file = $subFolder-&amp;gt;Files-&amp;gt;Add($script);&amp;lt;br&amp;gt;&lt;br /&gt;
 #enable the &amp;quot;makereport&amp;quot; property for the item we just added&amp;lt;br&amp;gt;&lt;br /&gt;
 $file-&amp;gt;{MakeReport} = &amp;quot;true&amp;quot;;&amp;lt;br&amp;gt;&lt;br /&gt;
 #mark the script as executable or not &amp;lt;br&amp;gt;&lt;br /&gt;
 $file-&amp;gt;{Execute} = $entry-&amp;gt;{executable} || &#039;false&#039;;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;br /&gt;
[[Category:Troubleshooting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_kill_a_task_if_the_window_is_owned_by_a_non-killable_system_task%3F&amp;diff=3006</id>
		<title>Studio:How do I kill a task if the window is owned by a non-killable system task?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_kill_a_task_if_the_window_is_owned_by_a_non-killable_system_task%3F&amp;diff=3006"/>
		<updated>2007-12-11T21:07:49Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following Perl script demonstrates how to &amp;quot;kill&amp;quot; a specific task:&lt;br /&gt;
 #!c:/perl/bin/perl -w&lt;br /&gt;
 use Win32::OLE;&lt;br /&gt;
 use strict;&lt;br /&gt;
 my $wshShell = Win32::OLE-&amp;gt;new(&#039;WScript.shell&#039;);&lt;br /&gt;
 while ($wshShell-&amp;gt;AppActivate(&amp;quot;Application.exe - Application Error&amp;quot;))&lt;br /&gt;
 {&lt;br /&gt;
  $wshShell-&amp;gt;SendKeys(&amp;quot;%{F4}&amp;quot;);&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
Check TestUtils Perl library in C:\Stride\lib\perl\S2S for additional information on how to dismiss pop-up windows.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;br /&gt;
[[Category:Troubleshooting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_get_Perl_scripts_to_emit_fatal_errors_when_a_COM_error_occurs%3F&amp;diff=3005</id>
		<title>Studio:How do I get Perl scripts to emit fatal errors when a COM error occurs?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_get_Perl_scripts_to_emit_fatal_errors_when_a_COM_error_occurs%3F&amp;diff=3005"/>
		<updated>2007-12-11T21:03:30Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;By default, the Win32::OLE package in Perl, which allows Perl scripts to interact with COM objects, does not emit fatal errors when a COM error occurs. In order to get Perl scripts to emit fatal errors when a COM error occurs, include the following statement in your script:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;tt&amp;gt;Win32::OLE::Option(Warn =&amp;gt; 3);&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This would typically be placed near the top of the script. It is our recommendation that you always use Warn Level 3.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;br /&gt;
[[Category:Troubleshooting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_extract_the_drive_letter_and_use_it_to_define_the_location_of_the_Perl_module%3F&amp;diff=3004</id>
		<title>Studio:How do I extract the drive letter and use it to define the location of the Perl module?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_extract_the_drive_letter_and_use_it_to_define_the_location_of_the_Perl_module%3F&amp;diff=3004"/>
		<updated>2007-12-11T20:59:51Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following code will extract the drive letter and use it to define the location of the Perl module: &amp;lt;br&amp;gt;&lt;br /&gt;
 use strict;&lt;br /&gt;
 use File::Spec;&lt;br /&gt;
 use vars qw($modulePath);&lt;br /&gt;
 BEGIN&lt;br /&gt;
 {&lt;br /&gt;
  my($vol, undef, undef) =&lt;br /&gt;
  File::Spec-&amp;gt;splitpath($main::ascript-&amp;gt;Database-&amp;gt;Path);&lt;br /&gt;
  $modulePath = File::Spec-&amp;gt;catpath($vol, File::Spec-&amp;gt;catdir(&#039;&#039;,&#039;Stride&#039;,&#039;lib&#039;, &#039;perl&#039;, &#039;S2S&#039;));&lt;br /&gt;
 }&lt;br /&gt;
 use lib qq($modulePath);&lt;br /&gt;
 use TestUtils;&lt;br /&gt;
&lt;br /&gt;
A BEGIN block is evaluated as soon as it is encountered, so the $modulePath value will have a value by the time the &#039;use lib&#039; statement is encountered.&lt;br /&gt;
&lt;br /&gt;
If libraries are always installed on the system drive, $ENV{&#039;SystemDrive&#039;} can be used to determine the volume. Alternately, a registry setting or environment variable can be used.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_access_an_array_in_the_parameter_list_through_Perl%3F&amp;diff=3003</id>
		<title>Studio:How do I access an array in the parameter list through Perl?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_access_an_array_in_the_parameter_list_through_Perl%3F&amp;diff=3003"/>
		<updated>2007-12-11T20:53:05Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;By using a simple interface such as:&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;void test1(char s[10]);&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_function(test1)&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The following Perl script example illustrates how to access an array in the parameter list. The following example sets element 0 of s to 15.&lt;br /&gt;
  my $test = $ascript-&amp;gt;Functions-&amp;gt;Item(&amp;quot;test1&amp;quot;)-&amp;gt;User;&lt;br /&gt;
  my $data = $test-&amp;gt;ParameterList;&lt;br /&gt;
  $data-&amp;gt;SetProperty(&amp;quot;s&amp;quot;, 0, 15);&lt;br /&gt;
  $test-&amp;gt;Call();&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Another option is to use safearray to directky copy a Perl array into an array of the parameter list. Here is an example:&lt;br /&gt;
 my @a = (11, 12, 13, 14, 15, 16, 17, 18, 19, 20);&lt;br /&gt;
 $user-&amp;gt;ParameterList-&amp;gt;a-&amp;gt;seq_num-&amp;gt;{SafeArray} = \@a;&lt;br /&gt;
 $user-&amp;gt;Call(); &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_do_I_access_an_array_in_the_parameter_list_through_Perl%3F&amp;diff=3002</id>
		<title>Studio:How do I access an array in the parameter list through Perl?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_do_I_access_an_array_in_the_parameter_list_through_Perl%3F&amp;diff=3002"/>
		<updated>2007-12-11T20:52:02Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;By using a simple interface such as:&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;void test1(char s[10]);&amp;lt;br&amp;gt;&lt;br /&gt;
 #pragma scl_function(test1)&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following Perl script example illustrates how to access an array in the parameter list. The following example sets element 0 of s to 15.&lt;br /&gt;
  &amp;lt;tt&amp;gt;my $test = $ascript-&amp;gt;Functions-&amp;gt;Item(&amp;quot;test1&amp;quot;)-&amp;gt;User;&amp;lt;br&amp;gt;&lt;br /&gt;
  my $data = $test-&amp;gt;ParameterList;&amp;lt;br&amp;gt;&lt;br /&gt;
  $data-&amp;gt;SetProperty(&amp;quot;s&amp;quot;, 0, 15);&amp;lt;br&amp;gt;&lt;br /&gt;
  $test-&amp;gt;Call(); &amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Another option is to use safearray to directky copy a Perl array into an array of the parameter list. Here is an example:&lt;br /&gt;
&lt;br /&gt;
 my @a = (11, 12, 13, 14, 15, 16, 17, 18, 19, 20);&lt;br /&gt;
 $user-&amp;gt;ParameterList-&amp;gt;a-&amp;gt;seq_num-&amp;gt;{SafeArray} = \@a;&lt;br /&gt;
 $user-&amp;gt;Call(); &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_can_I_check_which_version_of_STRIDE_I_am_using_from_a_script%3F&amp;diff=3000</id>
		<title>Studio:How can I check which version of STRIDE I am using from a script?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_can_I_check_which_version_of_STRIDE_I_am_using_from_a_script%3F&amp;diff=3000"/>
		<updated>2007-12-11T20:45:48Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The only way to check the STRIDE version number is to read the version information from the Windows registry.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;tt&amp;gt;use strict;&amp;lt;br&amp;gt;&lt;br /&gt;
 use Carp;&amp;lt;br&amp;gt;&lt;br /&gt;
 use Win32::TieRegistry(Delimiter =&amp;gt; &#039;/&#039;);&amp;lt;br&amp;gt;&lt;br /&gt;
 my $stride_version = $Registry-&amp;gt;{&amp;quot;LMachine/Software/S2 Technologies/STRIDE/Version&amp;quot;};&amp;lt;br&amp;gt;&lt;br /&gt;
 print &amp;quot;STRIDE VERSION: $stride_version\n&amp;quot;;&amp;lt;br&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The last three digits of the version string indicate the STRIDE build number (e.g, STRIDE VERSION 2.0.0602.326 indicates a build number of 326).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Can_STRIDE_marshal_both_data_and_pointers%3F&amp;diff=2999</id>
		<title>Studio:Can STRIDE marshal both data and pointers?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Can_STRIDE_marshal_both_data_and_pointers%3F&amp;diff=2999"/>
		<updated>2007-12-11T20:41:40Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;STRIDE does not marshal both the pointer value and the data. You have to pick on of the two. If a pointer is defined as void or the scl_ptr_opaque pragma is applied the pointer value is marshaled otherwise the data the pointer points to is marshaled. Opaque pointers can be passed to other functions or helper function to retrieve the data to which it points.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Can_STRIDE_marshal_both_data_and_pointers%3F&amp;diff=2998</id>
		<title>Studio:Can STRIDE marshal both data and pointers?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Can_STRIDE_marshal_both_data_and_pointers%3F&amp;diff=2998"/>
		<updated>2007-12-11T20:40:52Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;STRIDE does not marshal both the pointer value and the data. You have to pick on of the two. If a pointer is defined as void or the scl_ptr_opaque pragma is applied the pointer value is marshaled otherwise the data the pointer points to is marshaled. Opaque pointers can be passed to other functions or helper function to retrieve the data to which it points.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;br /&gt;
[[Category:Scl]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Can_I_use_Perl%27s_Tk_package_in_STRIDE%3F&amp;diff=2997</id>
		<title>Studio:Can I use Perl&#039;s Tk package in STRIDE?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Can_I_use_Perl%27s_Tk_package_in_STRIDE%3F&amp;diff=2997"/>
		<updated>2007-12-11T20:35:43Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;We recommend running the script which uses the Tk package as a separate script outside of STRIDE Studio, as there is an incompatibility with the Tk package that causes errors during execution. You should not get an error the first time you run the script, but you will get errors during every subsequent execution until you shut down Studio. This is due to a problem with initialization and the Perl engine failing to fully clean up; the Tk engine relies on the cleanup code, but since this only occurs when the engine unloads (i.e., Studio is closed), errors occur during execution.&lt;br /&gt;
&lt;br /&gt;
To run the script using Tk outside of Studio, you can launch it from a script in Studio using the system command. You can also pass arguments between the scripts. Below is an example.&lt;br /&gt;
&lt;br /&gt;
Script to launch the Tk script. (Note: The Tk script has to be included in the workspace script files).&lt;br /&gt;
&lt;br /&gt;
 use strict;&lt;br /&gt;
 use File::Spec;&lt;br /&gt;
 &lt;br /&gt;
 #Get path and name of perl exectuable          &lt;br /&gt;
 my $perlExe = $^X;&lt;br /&gt;
 if ($perlExe =~ /\.dll$/i) &lt;br /&gt;
 {&lt;br /&gt;
     my ($vol, $dir, $file) = File::Spec-&amp;gt;splitpath($perlExe);&lt;br /&gt;
     $perlExe = File::Spec-&amp;gt;catpath($vol, $dir, &#039;perl.exe&#039;); &lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 # get the name and path of the script with the Tk library&lt;br /&gt;
 my $tkScript= $main::studio-&amp;gt;Workspace-&amp;gt;Files-&amp;gt;Item(&amp;quot;tk.pl&amp;quot;);&lt;br /&gt;
 my $tkFullPath = File::Spec-&amp;gt;catfile($tkScript-&amp;gt;Path, $tkScript-&amp;gt;Name); &lt;br /&gt;
 &lt;br /&gt;
 #List of arguments for Tk script&lt;br /&gt;
 my @options = (&#039;&amp;quot;option 1&amp;quot;&#039;, &#039;&amp;quot;option 2&amp;quot;&#039;, &#039;&amp;quot;option 3&amp;quot;&#039;, &#039;&amp;quot;option 4&amp;quot;&#039;);&lt;br /&gt;
 &lt;br /&gt;
 #Start the script &lt;br /&gt;
 my @data = `$perlExe \&amp;quot;$tkFullPath\&amp;quot; @options`; &lt;br /&gt;
 &lt;br /&gt;
 #@data is the array with the return values (through STDOUT)&lt;br /&gt;
 for (my $i=0; $i &amp;lt;= $#data; $i++)&lt;br /&gt;
 {&lt;br /&gt;
   $main::ascript-&amp;gt;MessageBox(&amp;quot;$data[$i]&amp;quot;, &amp;quot;Element $i&amp;quot;);&lt;br /&gt;
 }&lt;br /&gt;
           &lt;br /&gt;
And here is the Tk script &lt;br /&gt;
&lt;br /&gt;
 #!c:/perl/bin/perl -w&lt;br /&gt;
 use strict;&lt;br /&gt;
 use Tk;&lt;br /&gt;
 my $mw = MainWindow-&amp;gt;new;&lt;br /&gt;
 my $fileName;&lt;br /&gt;
 FillWindow($mw, &#039;Choose Script to Run:&#039;,@ARGV);&lt;br /&gt;
 &lt;br /&gt;
 MainLoop;&lt;br /&gt;
 &lt;br /&gt;
 sub FillWindow &lt;br /&gt;
 {&lt;br /&gt;
    my ($window, $header,@List) = @_;&lt;br /&gt;
    my @selected;&lt;br /&gt;
    my $i;&lt;br /&gt;
    $window-&amp;gt;Label(-text =&amp;gt; &amp;quot;$header&amp;quot;)-&amp;gt;pack;&lt;br /&gt;
    foreach (@List)&lt;br /&gt;
    {&lt;br /&gt;
      push @selected, 0;&lt;br /&gt;
      $mw-&amp;gt;Checkbutton(-text=&amp;gt;&amp;quot;$_&amp;quot;,-variable=&amp;gt;\$selected[$i])-&amp;gt;pack;&lt;br /&gt;
      $i++;&lt;br /&gt;
    }&lt;br /&gt;
    $mw -&amp;gt; Button(-text=&amp;gt;&amp;quot;Select&amp;quot;, -command =&amp;gt;sub&lt;br /&gt;
                 {&lt;br /&gt;
                    my @selectedOptions;&lt;br /&gt;
                    for (my $i=0; $i &amp;lt;= $#List; $i++)&lt;br /&gt;
                    {&lt;br /&gt;
                        if ($selected[$i])&lt;br /&gt;
                        {&lt;br /&gt;
                            push @selectedOptions, $List[$i];&lt;br /&gt;
                        }&lt;br /&gt;
                     }&lt;br /&gt;
                     print STDOUT join(&amp;quot; \n &amp;quot;, @selectedOptions);&lt;br /&gt;
                     $mw -&amp;gt; destroy;&lt;br /&gt;
 	         })-&amp;gt;pack;	&lt;br /&gt;
   &lt;br /&gt;
 }    &lt;br /&gt;
           &lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Are_multiple_callbacks_possible%3F&amp;diff=2996</id>
		<title>Studio:Are multiple callbacks possible?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Are_multiple_callbacks_possible%3F&amp;diff=2996"/>
		<updated>2007-12-11T19:59:14Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Due to the single-threaded nature of most applications, once an off-target owner function is called, the owner may not call back into it. However, multiple callbacks may be done by using a short-term local timer which may continue processing after returning control back to the application and unblocking it. If callbacks are called from different threads it is possible that multiple callbacks are called at the same time.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Can_I_use_STRIDE_if_my_embedded_code_has_real-time_constraints%3F&amp;diff=2921</id>
		<title>Studio:Can I use STRIDE if my embedded code has real-time constraints?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Can_I_use_STRIDE_if_my_embedded_code_has_real-time_constraints%3F&amp;diff=2921"/>
		<updated>2007-11-29T00:11:55Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The STRIDE components and architecture are tailored specifically to embedded applications, so overhead and intrusiveness are minimal. STRIDE’s target components consume very little memory and can be configured to run at lower priorities. Similarly, tracing overhead is minimized by collecting raw data on the target, and uploading tracing information at a very low priority task to the host for processing.&lt;br /&gt;
&lt;br /&gt;
If tight real-time constraints are a concern, STRIDE also supports target-resident test code, which minimizes transactions or overhead over the transport. In this case, STRIDE provides a framework for automating and managing the execution of the on-target test code, and publishing the test results.&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:What_up-front_integration_is_required_to_begin_using_STRIDE%3F&amp;diff=2920</id>
		<title>Studio:What up-front integration is required to begin using STRIDE?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:What_up-front_integration_is_required_to_begin_using_STRIDE%3F&amp;diff=2920"/>
		<updated>2007-11-29T00:10:05Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To support remotely accessing function calls, the STRIDE Runtime and Platform Abstraction Layer (PAL) components must be integrated into the target environment, including support for the available transport. S2 already has pre-ported or reference PALs available for many popular embedded RTOSes. In this case, there is only a few days of integration and verification work.  &lt;br /&gt;
&lt;br /&gt;
For custom or new OSes, implementing a PAL takes only a few extra days. A new PAL involves implementing 10 – 12 well-defined primitive interfaces, based on common OS services. In either case, S2 is generally involved with this process in order to ensure proper integration.&lt;br /&gt;
&lt;br /&gt;
If the software architecture includes a messaging subsystem, then a custom remote message server (RMS) component is also required. S2 generally undertakes this work and delivers, integrates, and verifies the RMS with the customer. The scope of the RMS varies depending on the complexity of the messaging subsystem.&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
[[Category:Getting Started]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:What_other_techniques_does_STRIDE_support_to_generate_test_cases%3F&amp;diff=2919</id>
		<title>Studio:What other techniques does STRIDE support to generate test cases?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:What_other_techniques_does_STRIDE_support_to_generate_test_cases%3F&amp;diff=2919"/>
		<updated>2007-11-29T00:07:18Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;STRIDE’s built-in tracing provides record-and-playback capabilities, which can be leveraged to record a sequence of transactions across application interfaces, then reproduce or replay a certain scenario. This technique can also be used in conjunction with test equipment or to capture certain field conditions.&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:Why_use_a_scripting_language%3F&amp;diff=2918</id>
		<title>Studio:Why use a scripting language?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:Why_use_a_scripting_language%3F&amp;diff=2918"/>
		<updated>2007-11-29T00:05:43Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Due to their interpretive nature, scripting languages are very dynamic and flexible. Test applications can be quickly implemented through scripts, and these tests can be modified, added, or deleted without requiring time-consuming target software builds. Also, for regression and continuous integration, scripts can be easily automated and executed without constantly requiring new test code to be downloaded or unloaded from the target, which in many cases is impractical or impossible.&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:How_does_STRIDE_know_about_my_APIs_and_messaging_interfaces%3F&amp;diff=2917</id>
		<title>Studio:How does STRIDE know about my APIs and messaging interfaces?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:How_does_STRIDE_know_about_my_APIs_and_messaging_interfaces%3F&amp;diff=2917"/>
		<updated>2007-11-29T00:02:53Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;STRIDE learns about APIs and messaging interfaces through the header files of embedded applications. To clarify ambiguities in complex interfaces, developers add pragma statements (SCL) to further specify the characteristics of interfaces and data types. STRIDE compiles through these header files and builds an XML database of the application interface signatures.  These application interfaces are now remotely available to the developer through STRIDE.&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
[[Category:SCL]]&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
	<entry>
		<id>https://www.stridewiki.com/index.php?title=Studio:What_software_development_challenges_result_from_increased_complexity%3F&amp;diff=2915</id>
		<title>Studio:What software development challenges result from increased complexity?</title>
		<link rel="alternate" type="text/html" href="https://www.stridewiki.com/index.php?title=Studio:What_software_development_challenges_result_from_increased_complexity%3F&amp;diff=2915"/>
		<updated>2007-11-28T23:59:58Z</updated>

		<summary type="html">&lt;p&gt;Andreo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In working with large embedded software engineering organizations, S2 has observed that &#039;&#039;&#039;verifying and integrating embedded software components&#039;&#039;&#039; becomes a serious challenge as software complexity increases. As more features and functionality are designed into a product, more software components need to be integrated and verified. Common software strategies, such as distributed development, outsourcing, leveraging expert contractors, and third-party software, further contribute to complexity.  The difficulty of integrating so many different software components, developed by so many different people, across various geographies and time zones, have a severe impact on the development process. &lt;br /&gt;
&lt;br /&gt;
Ad hoc or manual approaches to software testing have become tedious and ineffective. Likewise, traditional test harness-based approaches are too difficult and limiting to apply across-the-board to embedded development. As a result, the Product Test or System Test organization is often the first to extensively exercise and vet the software as an integrated whole, and thus they detect a disproportionately high volume of defects. This wreaks havoc on the development process, leaving software engineers to face the daunting challenge of fixing an overwhelming number of defects to meet their deadline. This scenario typically results in:&lt;br /&gt;
&lt;br /&gt;
* Extra test cycles and resources, adding unplanned development time and costs&lt;br /&gt;
* Missing or dropped features, as a tradeoff to meeting tight deadlines&lt;br /&gt;
* Compromised quality, hurting reputation and revenues&lt;br /&gt;
* Delayed product releases, resulting in competitive losses&lt;/div&gt;</summary>
		<author><name>Andreo</name></author>
	</entry>
</feed>