Kontron VM162 User Manual
Page 76
VM162/VM172
Chapter 4 Programming
Page 4- 6
© PEP Modular Computers
July 19, 1997
• CS5: size to 8 kByte, port size external, tcyc 1
0x1FFFE006.L -> OR5
• CS5: CXC to 0xBF70000
0xBF70001.L -> BR5
• CS6: size to 2 kByte, port size external, tcyc 1
0x1FFFF806.L -> OR6
• CS6: RTC to 0xC000000
0xC000001.L -> BR6
• CS7: size to 16 MByte, port size external, tcyc 1
0x1F000006.L -> OR7
• CS7: on-board control to 0xD000000
0xD000001.L -> BR7
Note
CS1 and CS4
It is important that the values of these Select Lines are changed later (after RAM search) to the actual
configuration of the on-board memory. For example:
•
A board with 16 MByte DRAM --> OR1: 0xF000001.L
•
A board with 256 kByte SRAM --> OR4: 0xFFC00006.L
12)The system software normally determines the real sizes of the DRAM and SRAM installed and
re-programs the CS lines accordingly. The simplest way to achieve this is to write a pattern to the
first location and then search for that pattern at meaningful distances (e.g. 256kB, 512 kB, 1 MB,
2 MB, 4 MB, 8 MB, 16 MB). If the pattern is found at such an address, the original pattern must be
altered and then checked to see if the mirrored pattern changes in the same way. If not, the search
must be continued or, if yes, the memory size is found.
Note: The MC68040 normally operates in non-serialized mode, meaning that read accesses can occur
before write accesses, even if they are programmed in the opposite way. It is therefore recommended
that especially when changing the patterns, a ‘nop’ instruction should be inserted, as this forces all pen-
ding cycles to be completed.
13)Set vector and IRQ level for internal IRQ requester
• vector base = 0x40
• level = 4
0x8040.L -> CICR
14)Set SDMA configuration register
0x770.W -> SDCR
15)If the card is in the first slot, enable the VMEbus monitor
If bit 4 in VCSR is set then set bit 5 in VCSR
16)Enable on-board I/O bus error timer
Set bit 2 in BCSR