File:  [Coherent Logic Development] / freem / doc / ssv_support.md
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Sun Jan 19 02:04:04 2025 UTC (6 months, 1 week ago) by snw
Branches: MAIN, CoherentLogicDevelopment
CVS tags: v0-63-1-rc1, v0-63-0-rc1, v0-63-0, v0-62-3, v0-62-2, v0-62-1, v0-62-0, start, HEAD
FreeM

    1: ^$GLOBAL(<global>,"BLOCK",<block-number>,"TYPE") => "POINTER", "ROOT", or "DATA"
    2: ^$GLOBAL(<global>,"BLOCK",<block-number>,"BLOCKCOUNT") => number (root block only) 
    3: ^$GLOBAL(<global>,"BLOCK",<block-number>,"KEYLEN") => number (data blocks only)
    4: ^$GLOBAL(<global>,"BLOCK",<block-number>,"RLPTR") => right-link pointer (data blocks only)
    5: ^$GLOBAL(<global>,"BLOCK",<block-number>,"LLPTR") => left-link pointer (data blocks only)
    6: ^$GLOBAL(<global>,"BLOCK",<block-number>,"OFFS") => offset to first free byte in block data area
    7: ^$GLOBAL(<global>,"BLOCK",<block-number>,"CHARACTER") => "M" or "ASCII"
    8: ^$GLOBAL(<global>,"BLOCK",<block-number>,"COLLATE") => "M" or "ASCII"
    9: ^$GLOBAL(<global>,"NAMESPACE") => namespace where <global> resides
   10: ^$GLOBAL(<global>,"FILE") => full path to <global> data file
   11: ^$GLOBAL(<global>,"BLOCKSIZE") => block size for <global>
   12: ^$GLOBAL(<global>,"BLOCKS") => block count for <global>
   13: ^$GLOBAL(<global>,"BYTES") => size of global in blocks
   14: 
   15: ^$DEVICE(<channel>,"EOF") => 1 if <channel> in EOF state, 0 otherwise
   16: ^$DEVICE(<channel>,"LENGTH") => length of <channel> in bytes
   17: ^$DEVICE(<channel>,"MNEMONICSPACE") => current mnemonic space of <channel>, only for channel 0, always "X364"
   18: ^$DEVICE(<channel>,"DSW") => device status word for <channel>
   19: ^$DEVICE(<channel>,"TERMINATOR") => read terminator for <channel>
   20: ^$DEVICE(<channel>,"TERMID") => terminal model (only for channel 0), ex. "vt100"
   21: ^$DEVICE(<channel>,"ECHOON") => 0 if local echo off, 1 otherwise 
   22: ^$DEVICE(<channel>,"DELMODE") => 1 | 0
   23: ^$DEVICE(<channel>,"ESCSEQPROC") => 1 | 0
   24: ^$DEVICE(<channel>,"CONVUPPER") => 1 | 0
   25: ^$DEVICE(<channel>,"DELEMPTY") => 1 | 0
   26: ^$DEVICE(<channel>,"NOCTRLS") => 1 | 0
   27: ^$DEVICE(<channel>,"CTRLOPROC") => 1 | 0
   28: ^$DEVICE(<channel>,"NOTYPEAHEAD") => 1 | 0
   29: 
   30: ^$DEVICE(<chan>)             => currently open I/O channels
   31: ^$DEVICE(<chan>,"$X")        => current value of $x on open I/O device channel
   32: ^$DEVICE(<chan>,"$Y")        => current value of $y on open I/O device channel
   33: ^$DEVICE(<chan>,"CHARACTER") => "M" - same as standard
   34: ^$DEVICE(<chan>,"FD")        => operating system file descriptor for file/device
   35: ^$DEVICE(<chan>,"MODE")      => device's current mode; one of 
   36:                                 WRITE|READ|APPEND|IO|TCPIP|SERVER|NOFORK|FORKED|PIPE|NEWPIPE|DEVICE
   37: ^$DEVICE(<chan>,"NAME")      => file/device name in the operating system
   38: ^$DEVICE(<chan>,"NAMESPACE") => current mnemonic namespace (if set); user-defined M routine
   39: ^$DEVICE(<chan>,"TYPE")      => type of device in channel; one of 1,FILE|2,SOCKET|3,PIPE|4,TERMINAL
   40:                                 the numbers match the second comma-delimited number in $device, and
   41:                                 therefore can be looked up for the type name from this node
   42: ^$DEVICE(<chan>,"OPTIONS","DELETE")     => keys which generate a delete; one of NONE|BACK|DELETE|BOTH
   43:                                            BACK is the Backspace key, DELETE is the Delete key
   44: ^$DEVICE(<chan>,"OPTIONS","ECHO")       => whether device echoing is enabled; one of 1|0
   45: ^$DEVICE(<chan>,"OPTIONS","ESCAPE")     => whether device escape processing is enabled; one of 1|0
   46: ^$DEVICE(<chan>,"OPTIONS","OUTPUT")     => the sequence of 0 to 6 characters that are generated from 
   47:                                            a newline in M code with (write !)
   48: ^$DEVICE(<chan>,"OPTIONS","TERMINATOR") => the comma-separated list of key codes that terminate a read 
   49:                                            or other input
   50: 
   51: ^$SYSTEM("NAME_LENGTH") => number (max length of names)
   52: ^$SYSTEM("STRING_MAX") => number (max length of strings)
   53: ^$SYSTEM("$NEXTOK") => 1 ($NEXT enabled)
   54: ^$SYSTEM("EOK") => 1 (exponent notation enabled)
   55: ^$SYSTEM("OFFOK") => 1 (DO and GOTO offsets enabled)
   56: ^$SYSTEM("BIG_ENDIAN") => 1 if host system is big-endian, 0 otherwise
   57: 
   58: ^$DISPLAY(<display>,"CLIPBOARD") => X11 clipboard contents
   59: ^$DISPLAY(<display>,"PLATFORM") => window system platform
   60: ^$DISPLAY(<display>,"SIZE") => "<width>,<height>" of <display>
   61: ^$DISPLAY(<display>,"SPECTRUM") => color depth of <display>
   62: ^$DISPLAY(<display>,"COLORTYPE") => "COLOR"
   63: ^$DISPLAY(<display>,"UNITS") => "PIXEL"
   64: ^$DISPLAY(<display>,"TYPEFACE",<typeface-name>,0) => empty string for each <typeface-name> on system
   65: 
   66: ^$JOB(<pid>,"CHARACTER") => "M"
   67: ^$JOB(<pid>,"CWD") => current working directory of <pid>
   68: ^$JOB(<pid>,"GLOBAL") => empty string
   69: ^$JOB(<pid>,"LOCK") => empty string
   70: ^$JOB(<pid>,"IOPATH") => OPEN, USE, CLOSE path for sequential I/O
   71: ^$JOB(<pid>,"PRIORITY") => process priority for <pid>
   72: ^$JOB(<pid>,"ROUTINE") => routine name of routine currently being executed by <pid>
   73: ^$JOB(<pid>,"$PRINCIPAL") => current value of $PRINCIPAL for <pid>
   74: ^$JOB(<pid>,"$TLEVEL") => current value of $TLEVEL for <pid>
   75: ^$JOB(<pid>,"$IO") => current value of $IO for <pid>
   76: ^$JOB(<pid>,"USER") => UID of <pid>'s process owner
   77: ^$JOB(<pid>,"GROUP") => GID of <pid>'s process owner
   78: ^$JOB(<pid>,"NAMESPACE") => namespace of <pid>
   79: ^$JOB(<pid>,"SYMTAB") => 0 | 1 (currently-active symbol table)
   80: ^$JOB(<pid>,"PID") => <pid>
   81: ^$JOB(<pid>,"MATH") => "IEEE754" or "FIXED"
   82: ^$JOB(<pid>,"REVSTR") => 1 if reverse string function forms enabled, 0 otherwise
   83: 
   84: ^$ZPROCESS(<pid>,"EXISTS") => 1 if <pid> is a PID for a valid process
   85: ^$ZPROCESS(<pid>,"ATTRIBUTE",<attribute-name>) => contents of /proc/<pid>/<attribute-name>
   86: ^$ZPROCESS(<pid>,"SIGNAL")=<numexpr> => sends signal <numexpr> to <pid>
   87: 
   88: ^$ZRPI("INITIALIZE") => initializes Raspberry Pi GPIO subsystem
   89: ^$ZRPI("GPIO",<pin>,"MODE") => "INPUT", "OUTPUT", "PWM_OUTPUT", or "GPIO_CLOCK"
   90: ^$ZRPI("GPIO",<pin>,"DIGITAL") => digital read/write of <pin>
   91: ^$ZRPI("GPIO",<pin>,"ANALOG") => analog read/write of <pin>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>