Download Occam 2 User Library Specifications
Transcript
INMOS Limited Confidential occam User Lib Specs PROC so.getkey (CHAN OF SP fs, ts, BYTE key, result) -- As sp.getkey PROC sp.pollkey (CHAN OF SP fs, ts, BYTE key, result) ---------- Purpose: To read a single character from the keyboard, without waiting for one if there is none. Channels: fs - from server ts - to server Out: key - the key that was read Out: result - equals spr.ok if there was a key to read and the read was successful; otherwise >= spr.operation.failed - refer to hostio.inc or iserver documentation for further details Notes: The key is not echoed to the screen. PROC so.pollkey (CHAN OF SP fs, ts, BYTE key, result) -- As sp.pollkey PROC sp.getenv (CHAN OF SP fs, ts, VAL []BYTE name, INT length, []BYTE value, BYTE result) -------------------------- Purpose: To return the contents of an environment variable from whatever host is being used. Channels: fs - from server ts - to server In: name - a string containing the name of the desired environment variable. name should not have more than sp.max.getenvname.size characters in it. Out: length - if result is spr.ok, the number of bytes in value, starting at value[ 0 ]; (SIZE value) if result is spr.buffer.overflow; zero otherwise. Out: value - the contents of the environment variable, if result is spr.ok; truncated environment variable if result is spr.buffer.overflow; undefined otherwise. Out: result - spr.ok if the environment string successfully returned; some other value otherwise, indicating the sort of problem: spr.bad.name the specified name is a null string spr.bad.packet.size (SIZE name) > sp.max.getenvname.size spr.buffer.overflow environment string too large for value; it is truncated to fit >=spr.operation.failed could not read environment string - see hostio.inc or iserver documentation for further details Notes: The largest size the returned contents of an environment variable can be is limited by the functionality of the server, not by this routine. PROC so.getenv (CHAN OF SP fs, ts, VAL []BYTE name, INT length, []BYTE value, BYTE result) APPROVED 5.2.91 15 SW-0114-4