HP 9835A Programming Manual page 129

35 series desktop computer assembly development rom
Table of Contents

Advertisement

Communication Between BASIC and Assembly Language
111
then this ICALL executes properly -
but these ICALLs result in run-time errors -
Each declaration reserves three words in the object code upon assembly. As a result of the
ICALL execution, these words contain a descriptor of the corresponding argument. These
descriptors are used by the utilities for fetching and storing values. Thus, in the Sort calling
example above, when the ICALL is executed, a descriptor for Test$(*) is stored in the three
words starting at Parameter _1. Similarly, a descriptor for the constant 100 is stored in the three
words starting at Parameter _ 2.
The types discussed here do not apply just to simple variables, arrays, and constants. They also
apply to single elements of arrays and expressions. If you have a STH parameter declaration,
for example, any of the following would be valid as arguments in the ICALL statement -
It is similar for numerical expressions.
The number of arguments passed
9Y
an ICALL statement must be no more than the number of
parameter declarations in the subroutine entry. There may be fewer, however. The actual
number passed is stored in the word reserved by the SUB pseudO-instruction.
Unlike the CALL statement in BASIC, the ICALL statement can be executed from the
keyboard. In doing so, any variables used as arguments pass their current values to the routine,
rather than resetting them to 0 (this is the same contrast as between running a program by
pressing
8
and running it pressing
B).

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the 9835A and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Table of Contents