80Bus News 
May–June 1983, Volume 2, Issue 3 



Page 35 of 59 




The workings of NASCOM ROM BASIC Ver 4.7  PAGE 16  

LOG  F6C7 
LOG(X) routine. Get LOG of FPREG.  
MULT  F706  Multiply FPREG by value on stack.  
FPMULT  F708  MULTIPLY FPREG by value in BCDE.  
DIV  F767  Divide the value on stack by FPREG and leave the result in FPREG.  
DVBCDE  F768  Divide the value in BCDE by FPREG and leave the result in FPREG.  
TSTSGN  F813  Test sign of number in FPREG.  
SGN  F822  SGN(X) routine.  
ABS  F838  ABS(X) routine.  
STAKFP  F844  Move value in FPREG to stack.  
PHLTFP  F851  Move value at HL to FPREG.  
FPBCDE  F854  Move value in BCDE to FPREG.  
BCDEFP  F85F  Move FPREG to BCDE.  
LOADFP  F862  Move value at HL to BCDE.  
FPTHL  F86B  Move Value in FPREG to HL.  
SIGNS  F879  Set sign of result depending on signs of operands.  
CMPNUM  F88E  Compare numbers.  
FPINT  F8BB  Get integer of FP value.  
INT  F8E6  INT(X) routine.  
ASCTFP  F91A  Convert ASCII floating point number into binary.  
NUMASC  F9B8  Convert floating point binary into ASCII.  
SQR  FAAC  SQR(X) routine. Uses SQR(X) = X ^ 0.5  
POWER  FAB5 
Raise base BCDE to the power FPREG. 
The workings of NASCOM ROM BASIC Ver 4.7  PAGE 17  

EXP  FAFA 
EXP(X) routine.  
SUMSER  FB5B 
Sum the series using table of coefficients at HL.  
SUMSER1  FB6A 
Sum the series using table of coefficients at HL.  
RND  FB8B  RND(X) routine.  
COS  FC00  COS(X) routine. Uses COS(X) = SIN(X+PI/2).  
SIN  FC03 
SIN(X) routine.  
TAN  FC67  TAN(X) routine. TAN(X) = SIN(X) / COS(X).  
ATN  F67C 
ATN(X) routine.  
WIDTH  FDA5  WIDTH routine. Set terminal width but NOT commas width.  
LINES  FDAD  LINES routine.  
DEEK  FDBC  DEEK(X) routine.  
DOKE  FDC7  DOKE A,V routine.  
SCREEN  FDE6  SCREEN X,Y routine.  
SCRADR  FE11  Get screen address from row and column in DE and BC.  
INLINE  FEE8  Get an input line from NASSYS.  
GETXYA  FF15 
Get (X,Y) for SET,RESET and POINT.  
SETB  FF40  SET(X,Y) routine.  
RESETB  FF55  RESET(X,Y) routine.  
POINTB  FF79  POINT(X,Y) routine.  
XYPOS  FF96  Convert (X,Y) to a row and column on screen. 
NASCOM ROM BASIC source code is available in ASM and LST file format.



Page 35 of 59 



