Skip to main content

IAR Embedded Workbench for RH850 3.20.x

Summary of C-SPY system macros

In this section:

This table summarizes the pre-defined system macros:

Macro

Description

__abortLaunch

Aborts the launch of the debugger

__cancelAllInterrupts

Cancels all ordered interrupts

__cancelInterrupt

Cancels an interrupt

__clearBreak

Clears a breakpoint

__closeFile

Closes a file that was opened by __openFile

__delay

Delays execution

__disableInterrupts

Disables generation of interrupts

__driverType

Verifies the driver type

__enableInterrupts

Enables generation of interrupts

__evaluate

Interprets the input string as an expression and evaluates it

__expandVar

Expands all argument variables in a string

__fillMemory8

Fills a specified memory area with a byte value

__fillMemory16

Fills a specified memory area with a 2-byte value

__fillMemory32

Fills a specified memory area with a 4-byte value

__getNumberOfCores

Gets the number local cores being debugged.

__getSelectedCore

Gets the number of the current core.

__isBatchMode

Checks if C-SPY is running in batch mode or not.

__isMacroSymbolDefined

Checks if a C-SPY macro symbol is defined.

__loadImage

Loads a debug image

__memoryRestore

Restores the contents of a file to a specified memory zone

__memorySave

Saves the contents of a specified memory area to a file

__messageBoxYesCancel

Displays a Yes/Cancel dialog box for user interaction

__messageBoxYesNo

Displays a Yes/No dialog box for user interaction

__openFile

Opens a file for I/O operations

__orderInterrupt

Generates an interrupt

__popSimulatorInterruptExecutingStack

Informs the interrupt simulation system that an interrupt handler has finished executing

__readFile

Reads from the specified file

__readFileByte

Reads one byte from the specified file

__readMemory8, __readMemoryByte

Reads one byte from the specified memory location

__readMemory16

Reads two bytes from the specified memory location

__readMemory32

Reads four bytes from the specified memory location

__registerMacroFile

Registers macros from the specified file

__resetFile

Rewinds a file opened by __openFile

__selectCore

Switches focus from the current core to the specified core.

__setCodeBreak

Sets a code breakpoint

__setDataBreak

Sets a data breakpoint

__setDataLogBreak

Sets a data log breakpoint

__setLogBreak

Sets a log breakpoint

__setSimBreak

Sets a simulation breakpoint

__setSystemMaxData

Sets the number of bytes to collect from an application started with __system2 or __system3.

__setSystemTimeout

Sets the timeout for an application started with __system1, __system2, or __system3.

__setTimerStartBreak

Sets a timer start breakpoint

__setTimerStopBreak

Sets a timer stop breakpoint

__setTraceStartBreak

Sets a trace start trigger breakpoint

__setTraceStopBreak

Sets a trace stop trigger breakpoint

__sourcePosition

Returns the file name and source location if the current execution location corresponds to a source location

__strFind

Searches a given string for the occurrence of another string

__subString

Extracts a substring from another string

__system1

Starts an external application

__system2

Starts an external application with stdout and stderr collected in one variable

__system3

Starts an external application with stdout and stderr collected in separate variables

__targetDebuggerVersion

Returns the version of the target debugger

__toLower

Returns a copy of the parameter string where all the characters have been converted to lower case

__toString

Prints strings

__toUpper

Returns a copy of the parameter string where all the characters have been converted to upper case

__unloadImage

Unloads a debug image

__wallTime_ms

Returns the current host computer CPU time in milliseconds

__writeFile

Writes to the specified file

__writeFileByte

Writes one byte to the specified file

__writeMemory8, __writeMemoryByte

Writes one byte to the specified memory location

__writeMemory16

Writes a two-byte word to the specified memory location

__writeMemory32

Writes a four-byte word to the specified memory location

Table 25. Summary of system macros