!!!!    6    0    1  986858828  V7884                                         

! Device           : idt7198
! Function         : Static RAM 16k x 4
! revision         : B.01.00
! safeguard        : high_out_cmos
! Modifications    : Modified for AwareTest xi
!
  warning           "This library has not been verified with hardware."

sequential

vector cycle   500n
receive delay  400n

!+++++++++++++ Power ++++++++++++++!
assign VCC to pins 24
assign GND to pins 12

!+++++++ Address/Data Bus +++++++++!
assign Address     to pins 23,22,21,20,19,9,8,7,6,5,4,3,2,1

assign Data        to pins 17,16,15,14
assign Data_D0     to pins 14   !AT Added for minimum pin test.
assign Data_D1     to pins 15   !AT Added for minimum pin test.
assign Data_D2     to pins 16   !AT Added for minimum pin test.
assign Data_D3     to pins 17   !AT Added for minimum pin test.

!++++++++++++ Control Pins ++++++++++++!
assign CS1_bar     to pins 10
assign CS2_bar     to pins 18

assign WE_bar      to pins 13
assign OE_bar      to pins 11

family TTL

power  VCC,GND

inputs        Address,CS1_bar,CS2_bar,WE_bar,OE_bar

bidirectional Data
bidirectional Data_D0, Data_D1, Data_D2, Data_D3 !AT Added for min. pin test.

!
!  Disable Information
!

disable Data                          with OE_bar     to "1"
disable Data                          with CS1_bar    to "1"
disable Data                          with CS2_bar    to "1"

!
!  Trace information
!

when WE_bar        is "0"             inputs  Data
when WE_bar        is "1"             outputs Data

when CS1_bar       is "1"             inactive Data
when CS2_bar       is "1"             inactive Data

!*****************************************************************************!
!**********************Vector Definition Section******************************!
!*****************************************************************************!

vector Initial_Inputs
  set CS1_bar     to "1"
  set CS2_bar     to "1"
  set OE_bar      to "1"
  set WE_bar      to "1"
end vector

vector Keep_Control
  set CS1_bar     to "k"
  set CS2_bar     to "k"
  set OE_bar      to "k"
  set WE_bar      to "k"
end vector

vector Keep_Address
  initialize  to  Keep_Control
  set Address     to "kkkkkkkkkkkkkk"
end vector

vector Chip_enable1_true
  initialize  to  Keep_Control
  set CS1_bar     to "0"
end vector

vector Chip_enable2_true
  initialize  to  Keep_Control
  set CS2_bar     to "0"
end vector

vector Chip_enable1_false
  initialize  to  Keep_Control
  set CS1_bar     to "1"
end vector

vector Chip_enable2_false
  initialize  to  Keep_Control
  set CS2_bar     to "1"
end vector

vector Chip_disable1
  initialize  to  Keep_Control
  set CS1_bar     to "1"
  set CS2_bar     to "0"
end vector

vector Chip_disable2
  initialize  to  Keep_Control
  set CS1_bar     to "0"
  set CS2_bar     to "1"
end vector

vector Chip_enable
  initialize  to  Keep_Address
  set CS1_bar     to "0"
  set CS2_bar     to "0"
end vector

vector Write_enable
  initialize  to  Keep_Address
  set WE_bar      to "0"
end vector

vector Write_disable
  initialize  to  Keep_Control
  set WE_bar      to "1"
end vector

vector Output_enable
  initialize  to  Keep_Address
  set OE_bar      to "0"
end vector

vector Output_disable
  initialize  to  Keep_Control
  set OE_bar      to "1"
end vector

vector Write_end
  initialize  to  Keep_Control
  set CS1_bar     to "1"
  set CS2_bar     to "1"
  set WE_bar      to "1"
end vector

vector Read_end
  initialize  to  Keep_Control
  set CS1_bar     to "1"
  set CS2_bar     to "1"
  set OE_bar      to "1"
end vector

vector Address_00000000000000
  initialize  to  Keep_Control
  set Address     to "00000000000000"
end vector

vector Address_01010101010101
  initialize  to  Keep_Control
  set Address     to "01010101010101"
end vector

vector Address_10101010101010
  initialize  to  Keep_Control
  set Address     to "10101010101010"
end vector

vector Address_10010010010010
  initialize  to  Keep_Control
  set Address     to "10010010010010"
end vector

vector Address_01001001001001
  initialize  to  Keep_Control
  set Address     to "01001001001001"
end vector

vector Address_00110011001100
  initialize  to  Keep_Control
  set Address     to "00110011001100"
end vector

vector Address_11001100110011
  initialize  to  Keep_Control
  set Address     to "11001100110011"
end vector

vector Address_10001000100010
  initialize  to  Keep_Control
  set Address     to "10001000100010"
end vector

vector Address_01000100010001
  initialize  to  Keep_Control
  set Address     to "01000100010001"
end vector


vector Dataw_1010
  initialize  to  Keep_Address
  drive Data
  set Data        to "1010"
end vector

vector Dataw_0101
  initialize  to  Keep_Address
  drive Data
  set Data        to "0101"
end vector

vector Dataw_1001
  initialize  to  Keep_Address
  drive Data
  set Data        to "1001"
end vector

vector Dataw_0100
  initialize  to  Keep_Address
  drive Data
  set Data        to "0100"
end vector

vector Dataw_0010
  initialize  to  Keep_Address
  drive Data
  set Data        to "1001"
end vector

vector Dataw_1100
  initialize  to  Keep_Address
  drive Data
  set Data        to "1100"
end vector

vector Dataw_0011
  initialize  to  Keep_Address
  drive Data
  set Data        to "0011"
end vector

vector Dataw_1000
  initialize  to  Keep_Address
  drive Data
  set Data        to "1000"
end vector

vector Dataw_0000
  initialize  to  Keep_Address
  drive Data
  set Data        to "0000"
end vector

vector Datar_1010
  initialize  to  Keep_Address
  receive Data
  set Data        to "1010"
end vector

vector Datar_0101
  initialize  to  Keep_Address
  receive Data
  set Data        to "0101"
end vector

vector Datar_1001
  initialize  to  Keep_Address
  receive Data
  set Data        to "1001"
end vector

vector Datar_0100
  initialize  to  Keep_Address
  receive Data
  set Data        to "0100"
end vector

vector Datar_0010
  initialize  to  Keep_Address
  receive Data
  set Data        to "1001"
end vector

vector Datar_1100
  initialize  to  Keep_Address
  receive Data
  set Data        to "1100"
end vector

vector Datar_0011
  initialize  to  Keep_Address
  receive Data
  set Data        to "0011"
end vector

vector Datar_1000
  initialize  to  Keep_Address
  receive Data
  set Data        to "1000"
end vector

vector Datar_0000
  initialize  to  Keep_Address
  receive Data
  set Data        to "0000"
end vector

vector Datar_1111
  initialize  to  Keep_Address
  receive Data
  set Data        to "1111"
end vector

!AT The following vectors have been added for a minimum pins test. Any
!AT vectors that references the data bus was copied and modified to reference
!AT only a single pin of the data bus.

vector Dataw_D0_0
  initialize  to  Keep_Address
  drive Data_D0
  set Data_D0     to "0"
end vector

vector Dataw_D0_1
  initialize  to  Keep_Address
  drive Data_D0
  set Data_D0     to "1"
end vector

vector Dataw_D1_0
  initialize  to  Keep_Address
  drive Data_D1
  set Data_D1     to "0"
end vector

vector Dataw_D1_1
  initialize  to  Keep_Address
  drive Data_D1
  set Data_D1     to "1"
end vector

vector Dataw_D2_0
  initialize  to  Keep_Address
  drive Data_D2
  set Data_D2     to "0"
end vector

vector Dataw_D2_1
  initialize  to  Keep_Address
  drive Data_D2
  set Data_D2     to "1"
end vector

vector Dataw_D3_0
  initialize  to  Keep_Address
  drive Data_D3
  set Data_D3     to "0"
end vector

vector Dataw_D3_1
  initialize  to  Keep_Address
  drive Data_D3
  set Data_D3     to "1"
end vector

vector Datar_D0_0
  initialize  to  Keep_Address
  receive Data_D0
  set Data_D0     to "0"
end vector

vector Datar_D0_1
  initialize  to  Keep_Address
  receive Data_D0
  set Data_D0     to "1"
end vector

vector Datar_D1_0
  initialize  to  Keep_Address
  receive Data_D1
  set Data_D1     to "0"
end vector

vector Datar_D1_1
  initialize  to  Keep_Address
  receive Data_D1
  set Data_D1     to "1"
end vector

vector Datar_D2_0
  initialize  to  Keep_Address
  receive Data_D2
  set Data_D2     to "0"
end vector

vector Datar_D2_1
  initialize  to  Keep_Address
  receive Data_D2
  set Data_D2     to "1"
end vector

vector Datar_D3_0
  initialize  to  Keep_Address
  receive Data_D3
  set Data_D3     to "0"
end vector

vector Datar_D3_1
  initialize  to  Keep_Address
  receive Data_D3
  set Data_D3     to "1"
end vector

!++++++++++++++++ Subroutines +++++++++++++++++!
!

!  Subroutine: Write
sub Write(Address,Data)
  execute Address
  execute Chip_enable
  execute Write_enable
  execute Data
  execute Write_end
end sub

!  Subroutine: Read
sub Read(Address,Data)
  execute Address
  execute Chip_enable
  execute Output_enable
  execute Data
  execute Read_end
end sub

!  Subroutine: Read_disabled
sub Read_disabled(Address,Data,Chip_disable)
  execute Address
  execute Chip_disable
  execute Output_enable
  execute Data
  execute Read_end
end sub

!*****************************************************************************!
!************************ Vector Execution Section ***************************!
!*****************************************************************************!

!AT The following AwareTest units have been added for minimum pins tests. Each
!AT unit tests a separate data pin starting with D0.

unit   "awaretest D0 Test"

  execute Initial_Inputs
  call Write(Address_00000000000000,Dataw_D0_0)
  call Read(Address_00000000000000,Datar_D0_0)

  call Write(Address_00000000000000,Dataw_D0_1)
  call Read(Address_00000000000000,Datar_D0_1)

end unit

unit   "awaretest D1 Test"

  execute Initial_Inputs
  call Write(Address_00000000000000,Dataw_D1_0)
  call Read(Address_00000000000000,Datar_D1_0)

  call Write(Address_00000000000000,Dataw_D1_1)
  call Read(Address_00000000000000,Datar_D1_1)

end unit

unit   "awaretest D2 Test"

  execute Initial_Inputs
  call Write(Address_00000000000000,Dataw_D2_0)
  call Read(Address_00000000000000,Datar_D2_0)

  call Write(Address_00000000000000,Dataw_D2_1)
  call Read(Address_00000000000000,Datar_D2_1)

end unit

unit   "awaretest D3 Test"

  execute Initial_Inputs
  call Write(Address_00000000000000,Dataw_D3_0)
  call Read(Address_00000000000000,Datar_D3_0)

  call Write(Address_00000000000000,Dataw_D3_1)
  call Read(Address_00000000000000,Datar_D3_1)

end unit

unit "Test All"
  execute Initial_Inputs
  call Write(Address_10101010101010,Dataw_0011)
  call Write(Address_01010101010101,Dataw_1100)
  call Write(Address_10010010010010,Dataw_0010)
  call Write(Address_01001001001001,Dataw_0100)
  call Write(Address_00110011001100,Dataw_1001)
  call Write(Address_11001100110011,Dataw_1000)
  call Write(Address_10001000100010,Dataw_1010)
  call Write(Address_01000100010001,Dataw_0101)

  call Read(Address_10101010101010,Datar_0011)
  call Read(Address_01010101010101,Datar_1100)
  call Read(Address_10010010010010,Datar_0010)
  call Read(Address_01001001001001,Datar_0100)
  call Read(Address_00110011001100,Datar_1001)
  call Read(Address_11001100110011,Datar_1000)
  call Read(Address_10001000100010,Datar_1010)
  call Read(Address_01000100010001,Datar_0101)
end unit

!****************************************************************************!
!The following unit "Test Chip Enables" tests the pins CS1_bar and CS2_bar.  !
!This unit is primarily for testing these pins on the 3065 test system as    !
!the "unit disable tests" test these pins on the 3070 test system. In order  !
!to use the unit "Test Chip Enables", the user must connect pull-ups to the  !
!bidirectional data pins.                                                    !
!****************************************************************************!
!!unit "Test Chip Enables"
!!  execute Initial_Inputs
!!  call Write(Address_10101010101010,Dataw_0000)
!!  call Read(Address_10101010101010,Datar_0000)
!!  call Read_disabled(Address_10101010101010,Datar_1111,Chip_disable1)
!!  call Read(Address_10101010101010,Datar_0000)
!!  call Read_disabled(Address_10101010101010,Datar_1111,Chip_disable1)
!!
!!  call Read(Address_10101010101010,Datar_0000)
!!  call Read_disabled(Address_10101010101010,Datar_1111,Chip_disable2)
!!  call Read(Address_10101010101010,Datar_0000)
!!  call Read_disabled(Address_10101010101010,Datar_1111,Chip_disable2)
!!end unit

!****************************************************************************!
!If this test is to be used on the 3065 test system then the following two   !
!"unit disable tests" must be commented out.                                  !
!****************************************************************************!
unit disable test
  execute Initial_Inputs
  call Write(Address_10101010101010,Dataw_0011)
  call Read_disabled(Address_10101010101010,Datar_0011,Chip_disable1)
  call Write(Address_10101010101010,Dataw_1100)
  call Read_disabled(Address_10101010101010,Datar_1100,Chip_disable1)
end unit

unit disable test
  execute Initial_Inputs
  call Write(Address_10101010101010,Dataw_0011)
  call Read_disabled(Address_10101010101010,Datar_0011,Chip_disable2)
  call Write(Address_10101010101010,Dataw_1100)
  call Read_disabled(Address_10101010101010,Datar_1100,Chip_disable2)
end unit

