Please enable JavaScript to view this site.

winIDEA Help

Version: 9.21.241

SLO Text Format Specification

SLO format (file extension: SIT) is a specification of a text type symbol table that can be read in by winIDEA. You can use an additional download file of SIT format to define custom symbols that are otherwise not available in the main download files, or you can write a SIT format converter to load symbols from a file of an unsupported type.

 

Warning_orange

If you are using this SLO format it should be listed under Applications / Symbol Files.

 

 

File Extension

The file must carry a '.SIT' extension.

 

File Header

The first line must contain the following string to allow type recognition: 260691SLO

 

File Tags

MODULE tag

Defines a program module generated from a source file or a precompiled object module or library.

 

MODULE <module name> [,module source]

<module name> is a mandatory field, up to 8 characters

[module source] is an optional field specifying the path to the source file from which the module was generated.

 

 

LINE tag

Defines a high level or assembler statement association between a line in source code of the preceding MODULE definition and a target location.

 

LINE <address>,<line> {,column {,last ln. {,last col.}}}

<address> is the address of the code associated with the line symbol

<number> defines the position of the line in the source file

{column} is optional, defining the column in which the line starts

{last ln.} is optional, defining the last line of the line symbol

{last col.} is optional, defining the last column of the line symbol

 

 

GLOBAL tag

Defines a global variable, defined in the preceding MODULE definition. If there was no preceding MODULE definition it is associated to a predefined global module with blank name.

 

GLOBAL <name>,<address> {,type}

<name> is name of the variable

<address> is the address of the variable

{type} is optional, defining the type of variable

 

 

LABEL tag

Defines a code label (usually generated by assembler), defined in the preceding MODULE definition. If there was no preceding MODULE definition it is associated to a predefined global module with blank name.

LABEL <name>,<address>

<name> is name of the label

<address> is address of the label

 

 

CONSTANT tag

Defines an association between a name and a value, typically defined by an EQU statement or a C const definition.

CONSTANT <name>,<value>

<name> is name of the constant

<value> is a decimal (if not explicitly specified hex with the 0x prefix) value of the constant

 

 

FUNCTION tag

Defines a high level procedure or a nested block. A function will have a nonblank name and is assumed to be defined in the preceding MODULE definition. A nested block caries a blank name. Its scope definition does not necessary refer to the preceding FUNCTION declaration, but is calculated from its address. Blocks that can not be fitted in a function are not allowed.

 

FUNCTION <name>,<address>,<exit address 1>,…<exit address n>

<name> is name of the function. If blank, than this is a block definition

<address> is the first address of the function/block.

<exit address 1>,..,<exit address n> are exit addresses from the function/block. At least one exit (higher most) must be specified.

 

 

LOCAL tag

Defines a local variable. It is assumed to be defined in the preceding FUNCTION definition (true function or a block)

LOCAL <name>,<address> {,type}

<variable name> is name of the variable

<address> is address of the variable

{type} is optional, defining the type of variable

 

 

FORMULA tag

Defines a way to calculate a physical location. A formula must be defined prior to its usage in any address definition.

FORMULA <number>,<definition>

<number> is the index number of the formula by which it will be referred to in address definitions (1-255)

<definition> is a string, defining the way a physical address is calculated. See CPU appendix for information on defined formulas.

 

 

Address Specification

<address> of an object is a decimal value, or hexadecimal if prefixed with a '0x' prefix.

10 address 10 (0Ah)

0x10 address 16 (10h)

 

Optionally the address value can be preceded by a number and a colon sign, thus overriding the default physical linear address mapping.

2:10 value 10 applied on formula 2.

 

If formula 2 was defined as '(SP+ADDRESS)' then the 10 specifies a 10-byte offset from the SP register.

Example:

FORMULA 1 (IO)(ADDRESS)

GLOBAL port 1:0x40

 

 

Type Specification

<type> of a variable can be one of the types below.

 

Type

Type description

void

void type

bit

a single bit

s8

signed 8 bit entity (char)

u8

unsigned 8 bit entity (unsigned char)

s16

signed 16 bit entity (short)

u16

unsigned 16 bit entity (unsigned short)

s32

signed 32 bit entity (long)

u32

unsigned 32 bit entity (unsigned long)

f32

32 bit float number (float)

f64

64 bit float number (double)

f80

80 bit float number (long double)

 

 

Pointer Specification

A type can be prefixed by a 'p' thus specifying a pointer to the type:

ps8 pointer to s8

                 *char

 

Size of a pointer can be specified by a decimal digit following the 'p'. If no size is specified a value 2 is assumed.

p2s8 2 byte pointer to s8

                 *char

 

The memory area to which the pointer is pointing can be specified by a decimal number following the 'p<size>' where <size> is a mandatory single digit pointer size specifier. The number that follows specifies the index of a linear formula that points to the memory area. If no number is specified the default formula (ADDRESS) is assumed (CODE area on 8031 CPU family).

p24s8 2 byte pointer to s8, the object pointed to, is accessed by 4-th formula

 

If the 4-th formula was defined (XDATA)(ADDRESS), then this is a pointer to a

char variable located in XDATA memory area.

                 *xdata char

 

 

Array Specification

A type can be prefixed by an 'a' followed by a number, thus specifying an array of the type:

a40s8 array of 40 s8 elements

                 char[40]

a10pu16 array of 10 pointers to u16 elements

                 unsigned int *[40]

 

 

Examples

A SIT file can contain just simple user extensions to the symbol table, thusdefining additional symbols:

260691SLO

GLOBAL HeapOrigin,0x4000

LABEL start,0

 

The above file defines an untyped global symbol 'HeapOrigin', located on address 4000h and program label 'start' on address 0h.

 

If you write your own translator from your linker output or listing file the SIT file might look something like this:

260691SLO

FORMULA 1,(IX+ADDRESS)

MODULE STARTUP,C:\LUKNA\STARTUP.ASM

LABEL start,0

GLOBAL StackTop,0xFFFF

CONSTANT StackSize,0x1000

MODULE MAIN,C:\LUKNA\MAIN.C

LINE 0x1000,10

LINE 0x1008,12

LINE 0x1010,13

LINE 0x103C,17

LINE 0x106A,18

LINE 0x1070,20

GLOBAL c,0x4000,s8

FUNCTION main,0x1000,0x1080

LOCAL i,1:-2,s16

FUNCTION ,0x1010,0x106A

LOCAL i,1:-6,f32

 

If you decide to write your own translator, this is the order in which to do it, write:

260691SLO header

all required formulas

global variables and labels that are not defined in any of modules

module by module with its lines, globals, labels and functions

 

 

Accepted Formulas

The list below shows formulas that are accepted:

 

Formula string

Description

(ADDRESS)

default linear addressing mode

<register>

variable stored in a CPU register.

Example: R0

(<register>+ADDRESS)

offset from a CPU register.

Example: (SP+ADDRESS)

(<variable>)+ADDRESS)

offset from a variable.

'<variable>' is a simple type variable.

Example: ((?C_XBP)+ADDRESS).

 

All above formulas can be preceded by a memory area specifier, thus defining the CPU memory area. If none is specified the default program area is assumed.

(<memory area>)<formula>

 

Example:

(XDATA)(ADDRESS)

linear addressing in the XDATA area

Copyright © 2024 TASKING Germany GmbH