Changes
A RAM expansion board from Microstyle which behaves like ROM useful for ROM development. Up to 2 units can be used simultaneously allowing the development or use of up to 4 ROMs.<br>
[[Image:Ramrom.jpg|thumb|right|240px|Image of a Microstyle RAMROM]]
== Manual <br> ==
'''32k RAMROM - INSTRUCTIONS'''
The 32k RAMROM's main component is its 32k static ram chip which is capable of being loaded with1 or 2 rom programs of up to 16k each. That's the maximum size that the CPC allows. When loaded,the program(s) remain usable, surviving resets, as long as the computer is on. The RAMROM isquite literally a 2 slot romboard that allows the rom programs to be written to it. What it isnot is a memory expansion like the 64k and 256k memory add-ons. However, it is ram and can beused as such by imaginative programmers. Its main function, though, is to simulate roms forwhatever purpose is required - usually for rom development.
In developing the RAMROM we considered including many features such as battery backup but decidedagainst them in order to keep the price down.
The 464 and 664 can access up to 7 background roms (slots 1 to 7) and 6128, 15 (slots 1 to15). If 2 or more roms occupy the same slot number then they won't work although nothing will beharmed. To avoid such clashes, the RAMROM's slot numbers are flexible, to a degree.
Facilities are incorporated on the board to load 2 different rom programs which can each use adifferent slot (serial) or can both use the same slot (parallel). In the latter case they cannotboth be initialised at the same time, of course.
===SWITCHES & amp; LINKS===
SWITCH ONE - left (write switch):- when set to its left position, the ram can be written to. Whenset right, the ram cannot be written to.
SWITCH TWO - centre (parallel/serial select):- set to its left position = serial; set right =parallel. Serial: two of rom slots 3 to 6 are selectable as shown in the diagrams. Only the fourconfigurations shown are possible. If a link is removed then its associated rom slot can neitherbe written to nor read from. It is ok to leave the links on their pins when not using the RAMROMbut problems (not damage) could occur if an actual rom is occupying the same slot as a linked butunused RAMROM slot. In serial mode the position of switch 3 doesn't matter. Parallel: only 2slots can be used - 3 or 6. In this mode the high and low 16Ks of the total 32k can each hold adifferent rom program in the same slot. Switch 3 is used to switch between the two.
SWITCH THREE - right (high/low):- see switch two. This switch must be set prior to loading aprogram in the parallel mode and is then used to swap between the programs in the high half andlow half of the 32k. After switching from hi to lo, or vice versa, the computer must be resetto initialise the new program.
===USING THE RAMROM===
We are grateful to ROMBO PRODUCTIONS for allowing us to use their loader program which has beenmodified for our needs. It is used to load programs into the RAMROM but will be run only once.After that, its machine code remains in memory (not in the RAMROM) surviving resets. Type it inand save it.
With the computer turned OFF, push the RAMROM onto the CPC's expansion port (disc drive port onthe 464). It doesn't matter if other peripherals are closer to or further away from the computer.
LOADING A ROM PROGRAM: Set the links, switch 2 and, if wanting parallel mode, switch 3 accordingto your choices. Run the typed-in program. Once run, the BASIC part is deleted but the machinecode remains ready for further uses. Type: memory &3fff and press return. Enter your selectedslot number with the following command: poke &be01,x (x = your slot number). Load your programinto memory area &4000 to &7fff with: load"yourprog.rom",&4000
That's your program ready to be loaded into the RAMROM. Set switch 1 to write (left) and type:call &be00
The screen will fill very quickly. When it has done so, switch SWITCH 1 to the right. The Readyprompt will appear after a few seconds and you can then reset the computer by pressing CNTRL,SHIFT and ESC simultaneously. Assuming that your program is written correctly for rom use, it isinitialised and the computer is aware of its presence. To load a second rom, set the links andswitches again but don't alter the existing program's link. Poke the 2nd slot number into &be01,load the 2nd program into &4000 and call &be00.
SWITCH SUMMARY:- Once you've grasped their uses, it will be easy. SWITCH ONE selects write anddon't write (load or don't load). It has no other function. SWITCH TWO selects serial or parallelmode. Serial = 2 different slot numbers; parallel = 2 programs in the same slot number. SWITCHTHREE selects the high or low 16k rom bank when in parallel mode only. It is used when loadingand also to decide which will be initialised.
===ABOUT ROM PROGRAMS===
Contrary to what is often thought, any old machine code program cannot be put into a rom and beexpected to run. The CPC has excellent background rom facilities and, in fact, it looks for andinitialises any that are present at every reset but in order for a rom to be recognised and workproperly, its contents must be layed out in a certain way. Only certain parts of the rom must belayed out correctly and it is beyond the scope of these instructions to teach rom programming.
and finally...
A BASIC program can be put into a rom as long as a machine code program to download it to whereBASIC programs run is also included. Several separate programs can be included in one rom, eachaccessible with a BAR command. The RAMROM does not need to be erased in any way before beingoverwritten with new programs. It is probablt that somebody will attempt to use the RAMROM as astandard romboard by piggybacking a rom chip onto the 32k ram chip. Alas, it won't work. The dataand address buses are not connected to the same pins as an eprom would need.
<br>
===TYPE-IN LOADER PROGRAM (the Os are zeroes and not letter Os)===<pre>10 FOR a=&BE00 TO &BE1F20 READ b$30 POKE a,VAL("&"+b$)40 NEXT50 MODE 260 PRINT"POKE the ROM SLOT NUMBER into &BE0165 PRINT"Slot 6 is selected by default.70 PRINT:PRINT"Disable the RAM after the screen has filled80 PRINT"and before the Ready prompt.90 PRINT"Reset to initialise the ROM.
100 NEW
200 DATA 0E,06,CD,0F,B9,F3,C5,21
220 DATA ED,B0,06,10,1B,7A,B3,20
230 DATA FB,10,F9,C1,CD,18,B9,C9
</pre><pre>------------- ------------- -------------SWITCHES:- | 1 | | 2 | | 3 |------------- ------------- -------------READ/WRITE PARL/SERIAL BANK SELECT
etc. etc. etc.
When the CPC is turned on or reset, it enters the rom at C006/7/8 and runs theINITIALISING ROUTINE that is jumped to from that address. Accessing roms is done via bar (|)commands either at the keyboard or within BASIC programs and each command is listed in theCOMMAND NAME TABLE. C004/5 (low byte first) point to the start address of the COMMAND NAMETABLE which can be anywhere in the rom. The last character of each command name must have bit7 set to 1 and the table must be ended with a 0. When the computer encounters a bar (|)command it searches the command name table for a match. If found, it uses the JUMP TABLE torun the associated program. NAMES and JUMPS must therefore be in the same order. A name mustbe included at the start of the table for the INITIALISING ROUTINE. Sorry I can't explain indepth but, once grasped, it is easy to understand. ------------------------------------------------------------------------------------------------
MicroStyle 28 BELMONT AVENUE, LOW MOOR, BRADFORD, BD12 OPA Telephone: 0274-602180
<br>
== Manual ==
[[Media:Ramrom.txt|Microstyle RAMROM manual as text file]]
[[Category:Peripherals]] [[Category:manualManual]]