Program Entry
- A Line without a program number executes immediately
- A line with a number is inserted in order in the program
- Line numbers must be from 0 to 32767
- No blanks in keywords (LET, IF, THEN, GOTO, GOSUB, GO, TO, SUB,
RETURN, INPUT, PRINT, LIST, CLEAR, RUN)
- Blanks outside keywords are optional
- SHIFT/O (Back-arrow) deletes last character typed
- CONTROL/H (Backspace) has the same function as SHIFT/O (for use with CRT's)
- CONTROL/U Deletes the entire current line
Program Control
- CLEAR clears all variables (A-Z) and all stacks
- NEW deletes the program in PAGE 2 (normal page)
- NEW n (n is from 2-7) deletes the program in page n
- LIST lists the program starting at the lowets line number
or the line number given
- RUN starts the program at the lowest line number
NOTE
Repeated pressing of the BREAK key interrupts execution and returns the
system to programming mode.
Expressions
- All expresions are 16-bit, twos-complement values
- 26 variable names: A through Z.
- Relational Operators: <, >, =, <=, >=, <>
- Arithmatic operators: +, -, *, /
- Logical Operators: AND, OR, NOT
- Decimal Contstants in the range -32767 to 32767
- Hexadecimal Constants denoted by '#' followed by Hex digits
- Expresions can be on individual lines or several can be inserted
on the same line if they are seperated with a colon (e.g., 100 PRINT
"HOW MANY";:INPUT X)
Functions
- RND(a,b) returns the random number in the range a through b
- MOD(a,b) returns the remainder of a/b
- STAT returns the value of the INS8060 Status Register
- PAGE returns the number of the current page
- TOP returns the highest address of the NIBL program in the
current page
Input/Output Statements
- INPUT X
- INPUT X,Y,Z
- PRINT "A STRING"
- PRINT "F=",M*A
- PRINT "TAKE",X,"PILLS BEFORE";
NOTE
The semicolon suppresses an otherwise automatic carriage return after
any PRINT statement.
Assignment Statements
- LET X=7
- E=I*R
- STAT=#70
- PAGE=PAGE+1
- LET @A=255
- @(T+36)=#FF
- B=@(TOP+5)
Control Statements
- GO TO 15 or GOTO 15
- GOTO X+5
- GO SUB 100 or BOSUB 100
- RETURN
- IF X+Y>=#1A GOTO 15
- IF A=B LET A=B-C
- FOR I=10 to 0 STEP -2
- NEXT I
- FOR K=1 TO 5
- DO: X=X+1: UNTIL (X=10)OR(@X=13)
Indirect Operator
- If the value of V is #2000, then "LET @V=100" stores 100(dec)
at memory location 2000(hex) and "LET W=@V"sets W to the contents
of the location specified by V.
NOTE
The values that can be stored at any one specified memory location range from 0 to 255(dec)
String Handling
- $T="THIS IS A STRING"
- PRINT $T, $(TOP+72)
- INPUT $(U+20)
- $U=$(TOP+2*36)
Additional Statements
- LINK "address" causes control to be transferred to the SC/MP
Machine Language Routine starting at "address" wich is a
decial number
- REM - This statement is used to insert comments into the NIBL
program
- END - this statement is useful for inserting breakpoints into the
NIBL program while it is being debugged. When NIBL encounters
an END statement, it prints a break message and the current line
number, and returns to edit mode
Message |
Description |
CHAR |
Character after logical end of statement |
DIV0 |
Division by zero |
END" |
No ending quote on string |
FOR |
For without next |
NEST |
Nesting limit exceeded in expression, FORs, GOSUBs, etc |
NEXT |
NEXT without FOR |
NOGO |
No line number corresponding to GOTO or GOSUB |
RTRN |
RETURN without GOSUB |
SNTX |
Syntax error |
STMT |
Statement type used improperly |
UNTL |
UNTIL without DO |
VALU |
Constant format or value error |
AREA |
No more room left in current page for program |
|