Navigation bar
  Start Previous page
 20 of 158 
Next page End  

14
Option HeapLimit <constant-expression>
Default: n/a
This directive provides a different way of allocating RAM between the string heap and the task stacks. 
The value provided is interpreted as a RAM address and specifies the limit beyond which the heap will
not grow.  This directive is perhaps more useful with ZX devices that support external RAM.  See the
section on setting heap and task stack sizes for more information.
Option MainTaskStackSize <constant-expression>
Default: n/a
This directive provides a different way of allocating RAM between the string heap and the task stacks. 
The value provided is interpreted as the desired size of the task stack for the Main() task and the heap
limit is set at the end of the task stack.  See the section on setting heap and task stack sizes for more
information.
Option TxQueueSize <constant-expression>
Default: 25
Option RxQueueSize <constant-expression>
Default: 50
These directives can be used to modify the sizes of the default transmission and reception queues for
Com1.  They are effective only for native mode devices such as the ZX-24n.
Example
Option TxQueueSize 100
 
Option Com1Speed <constant-expression>
Default: 19200
This directive can be used to modify the default speed of the Com1 serial channel.  It is effective only for
native mode devices such as the ZX-24n.
Example
Option Com1Speed 9600
Option Library "<object-library-filename>"
Default: none
This directive, which can only be used for native mode devices, specifies the name of an object library
that should be linked in when the executable is built.   Typically, this directive will appear in a declarations
file that identifies the public entities contained in the library.  If the specified filename does not have a path
prefix, it is assumed that the specified name is relative to the directory of the module containing the
directive.
Example
Option Library "mylib.a"
2.3.2 The Definitions Section
The definitions section of a ZBasic program may contain constant definitions, variable definitions,
subroutine definitions and function definitions.  There may be any number of each of these types of
definitions and the definitions may occur in any order.  It is a common practice, however, to place
constant and variable definitions at the top of the definitions section followed by subroutine and function
definitions.  On the other hand, some programmers prefer to define the constants and variables closer to
the routine or routines that use them.
Previous page Top Next page