SPI Programming Manual (G06.24+, H06.03+, J06.03+)

SPI Programming in TACL
SPI Programming Manual427506-006
8-23
#SSGET
Considerations
When token-code is ZSPI^TKN^ENDLIST, the index and count parameters
have no effect. However, if supplied,
index must be equal to zero or 1, and the
count in the expansion is always returned as 1.
Header Tokens and Special Operation for #SSGET and
#SSGETV
The index parameter you supply with these token codes must be 0 or 1.
If you specify ZSPI^TKN^LASTPOSITION or ZSPI^TKN^POSITION, the value
returned is an 8-byte position descriptor that you can later use to reset the position with
the #SSPUT or #SSPUTV special operation ZSPI^TKN^POSITION. For #SSGET, the
position descriptor is returned as a space-separated list of eight 1-byte values. For
#SSGETV, the value is returned in a STRUCT consisting of 8 bytes.
In addition, you can specify the special operation code ZSPI^TKN^DEFAULT^SSID.
This obtains the default subsystem ID at the current position, preceded by the number
of token values returnedwhich in this case is always 1. #SSPUT, #SSPUTV,
#SSGET, and #SSGETV use this value whenever the
ssid parameter is omitted or
null.
Table 8-3. Header Token Values Retrieved by #SSGET and #SSGETV
Token Code Type Value Retrieved
ZSPI^TKN^BUFLEN UINT Buffer length
ZSPI^TKN^CHECKSUM INT Checksum flag
ZSPI^TKN^COMMAND ENUM Command number
ZSPI^TKN^HDRTYPE UINT Header type
ZSPI^TKN^LASTERR ENUM Last nonzero SPI status code
ZSPI^TKN^LASTERRCODE INT2 Token involved in last procedure
error
ZSPI^TKN^LASTPOSITION BYTE:8 Position of last token added with
SSPUT
ZSPI^TKN^MAX^FIELD^VERSION UINT Maximum field version
ZSPI^TKN^MAXRESP INT Maximum response records to
return
ZSPI^TKN^OBJECT^TYPE ENUM Object-type number
ZSPI^TKN^POSITION BYTE:8 Current position for #SSGET
ZSPI^TKN^SERVER^VERSION UINT Server release version
ZSPI^TKN^SSID SSID Subsystem ID used with #SSINIT
ZSPI^TKN^USEDLEN UINT Number of bytes used in the buffer