The RAMM Computer
Introduction
History
Organization of RAMM
RAMM Instructions
RAMM Assembly Language
 
 Using RAMM for Windows
Machine Language Programming
Assembly Language Programming
Download exe
Download zip
 
 Using RAMM for DOS
Download exe
 
 Sample Exercises
Simple
Index Looping
Trailer Value Looping
Header Value Looping




Index Looping 1

Flowchart a procedure to read in and echo print 10 values and stop. Echo printing is printing immediately after the read is accomplished, similar to a voice echo. It is frequently used to ascertain whether the data being used is the data expected.

Flowchart      RAMM Machine Language Program     RAMM Assembly Language Program
    

Flowchart:



RAMM Machine Language Program:

0000  00  K                        
0000  01  A                                                     
0000  02  K0                                                    
0001  03  K1                                                    
0010  04  K10                                                   
5000  05  STRT  No operation                                                      
1202  06        Load (A-Reg) with (K0)                                                    
2000  07        Store (A-Reg) at K                                                     
1200  08  LOOP  Load (A-Reg) with (K)                                                     
1504  09        Subtract (K10) from (A-Reg)                                                   
3713  10        Jump if (A-Reg) is negative to RDIA                                                  
3619  11        Jump if (A-Reg) is zero to EXIT                                                  
7519  12        Unconditional Jump to EXIT                                                  
6501  13  RDIA  Read A                                                     
6601  14        Print A                                                     
1200  15        Load (A-Reg) with (K)                                                     
1403  16        Add (K1) to (A-Reg)                                                     
2000  17        Store (A-Reg) at K                                                     
7508  18        Unconditional Jump to LOOP                                                  
0000  19  EXIT  Halt                                                       
9905  20        End and begin program execution at STRT                                                                                                                                                                                           


RAMM Assembly Language Program:

K     BSS 0001  
A     BSS 0001
K0    DEC 0000
K1    DEC 0001
K10   DEC 0010
STRT  NOP
      LDA K0
      STA K
LOOP  LDA K
      ISB K10
      AMJ RDIA
      AZJ EXIT
      UNJ EXIT
RDIA  RDI A
      PRI A
      LDA K
      IAD K1
      STA K
      UNJ LOOP
EXIT  HLT
      END STRT