Perhaps you need to define the full address range:
FIELD ADDRESS = [A15..0];
and specify "h" for hex addresses
RAM = ADDRESS:['h'0000..7FFF];
Below is what I used for a single glue chip on a recent project:
Code:
Name Glue3 ;
PartNo 01 ;
Date 10/31/2017 ;
Revision 01 ;
Designer KM ;
Company Analogue Technologies ;
Assembly SBC2 ;
Location ;
Device g22v10 ;
/* *************** INPUT PINS *********************/
PIN 1 = CLK ; /* */
PIN 2 = A15 ; /* */
PIN 3 = A14 ; /* */
PIN 4 = A13 ; /* */
PIN 5 = A12 ; /* */
PIN 6 = A11 ; /* */
PIN 7 = A10 ; /* */
PIN 8 = A9 ; /* */
PIN 9 = A8 ; /* */
PIN 10 = A7 ; /* */
PIN 11 = A6 ; /* */
PIN 13 = A5 ; /* */
PIN 23 = RW ; /* */
/* *************** OUTPUT PINS *********************/
PIN 14 = !IO1 ; /* */
PIN 15 = !IO2 ; /* */
PIN 16 = !IO3 ; /* */
PIN 17 = !IO4 ; /* */
PIN 18 = !IO5 ; /* */
PIN 19 = !ROM ; /* */
PIN 20 = !RAM ; /* */
PIN 21 = !MWR ; /* */
PIN 22 = !MRD ; /* */
/** Declarations and Intermediate Variable Definitions **/
FIELD ADDRESS = [A15..0];
RAM = ADDRESS:['h'0000..7FFF];
IO1 = ADDRESS:['h'FE00..FE1F];
IO2 = ADDRESS:['h'FE20..FE3F];
IO3 = ADDRESS:['h'FE40..FE5F];
IO4 = ADDRESS:['h'FE60..FE7F];
IO5 = ADDRESS:['h'FE80..FE9F];
ROM = ADDRESS:['h'8000..FDFF]
# ADDRESS:['h'FEA0..FFFF];
/** Logic Equations **/
MWR = (CLK & !RW);
MRD = (CLK & RW);