MFAX and DragonBall are trademarks of Motorola, Inc.
This document contains information on a new product. Specifications and information herein are subject to change
without notice.
Motorola reserves the right to make changes without further notice to any products herein. Motorola makes no warranty,
representation or guarantee regarding the suitability of its products for any particular purpose, nor does Motorola assume any liability
arising out of the application or use of any product or circuit, and specifically disclaims any and all liability, including without limitation
consequential or incidental damages. “Typical” parameters which may be provided in Motorola data sheets and/or specifications can
and do vary in different applications and actual performance may vary over time. All operating parameters, including “Typicals” must
be validated for each customer application by customer’s technical experts. Motorola does not convey any license under its patent
rights nor the rights of others. Motorola products are not designed, intended, or authorized for use as components in systems
intended for surgical implant into the body, or other applications intended to support life, or for any other application in which the
failure of the Motorola product could create a situation where personal injury or death may occur. Should Buyer purchase or use
Motorola products for any such unintended or unauthorize d application, Buyer shall indemnify and hold Motorola and its officers,
employees, subsidiaries, affiliates, and distributors harmless against all claims, costs, damages, and expenses, and reasonable
attorney fees arising out of, directly or indirectly, any claim of personal injury or death associated with such unintended or
unauthorized use, even if such claim alleges that Motorola was negligent regarding the design or manufacture of the part.
Motorola and are registered trademarks of Motorola, Inc. Motorola, Inc. is an Equal Opportunity/Affirmative Action Employer.
All other tradenames, trademarks, and registered trademarks are the property of their respective owners.
How to reach us:
USA/EUROPE/Locations Not Listed: Motorola Literature Distribution; P.O. Box 5405, Denver, Colorado, 80217
1-303-675-2140 or 1-800-441-2447
JAPAN: Motorola Japan, Ltd.; SPS, Technical Information Center, 3-20-1, Minami-Azabu, Minato-ku,
Tokyo 106-8573 Japan. 81-3-3440-3569
ASIA/PACIFIC: Motorola Semiconductors H.K. Ltd., Silicon Harbour Centre, 2 Dai King Street,
Tai Po Industrial Estate, 2 Tai Po, N.T., Hong Kong. 852-26668334
This user’s manual describes the features and operation of the MC68VZ328 (DragonBall™ VZ)
microprocessor, t he thi rd ge neration of t he Dr agonBal l
initialize, configure, and program the MC68VZ328. The manual presumes basic knowledge of 68000
architecture.
family of products. It prov ides t he det ails of how to
Audience
The MC68VZ328 user’s manual is intended to provide a design engineer with the necessary data to
successfully in tegrate the MC68 VZ328 into a wide vari ety of appl icatio ns. It is assumed that the reader ha s
a good working knowledge of the 68000 CPU. For programming information about the 68000, see the
documents listed in the Suggested Reading section of this preface.
Organization
The MC68VZ328 user’s manua l is o rganized into 20 chapter s that cover t he oper ation an d progra mming of
the DragonBall VZ device. Summaries of the chapters follow.
Chapter 1Introduction: This chapter contains a device overview, system block diagrams,
and an operational overview of 68000 CPU operation.
Chapter 2Signal Descriptions: Thi s chapter contains lis tings of the MC68VZ328 input an d
output signals, organized into functional groups.
Chapter 3Memory Map: This chapter summarizes the memory organization,
programming information, and registers’ addresses and reset values.
Chapter 4Clock Generation Module and Power Contr ol Module: Thi s chapter pro vides
detailed information about the operation and programming of the clock
generation module as well as the recommended circuit schematics for external
clock circuits. It als o describes and provide s programming in formation ab out the
operation of the power control module and the system power states.
Chapter 5System Control: This chapter describes the operation of and programming
models for the system control, peripheral control, ID, an d I/O drive control
registers.
Chapter 6Chip-Select Logic: This chapter describes the operation and programming of the
chip-select logic. It includes information related to the operation of the DRAM
controller and other memory-related applications.
Chapter 7DRAM Controller: The operati on and progr amming of the DRAM cont roller is
described in this chapter. This module p rovides a glueles s interface to 8-b it or
16-bit DRAM supporting EDO RAM, F ast Page Mo de, and synchronous DRAM.
Chapter 8LCD Controller: This chapter describes the operation and programming of the
LCD controller, which provides display data for external LCD drivers or for an
LCD panel.
About This Bookxxvii
Chapter 9Interrupt Controller: This chapter provides a description and operational
considerations for interrupt controller operation. It includes a description of the
vector generator and pen and keyboard interrupts.
Chapter 10I/O Ports: This chapter covers all 76 GPIO lines found in the MC68VZ328.
Because each pin is individually configurable, a detailed description of the
operation of and programming information for each pin is provided.
Chapter 11Real-Time Clock: This chap ter describes th e operation of the real-time clock
(R TC) module, which is composed of a prescal er, ti me-of-day (TOD) clock, TOD
alarm, programmable real-ti me interrup t, w atchdog timer, and min ute stopw atch
as well as co ntrol registers and bus interface hardware.
Chapter 12General-Purpose T i mers : This chapter describes the two 16-bit timers that can
be used as both watchdogs and alarms. It also describes how the timers can be
combined into a single 32-bit timer.
Chapter 13Serial Peripheral Interface 1 and 2: This chapter describes the features of the
DragonBall VZ’s two serial peripheral interfaces and how they are used to
communicate with external devices.
Chapter 14Universal Asynchronous Receiver/Transmitter 1 and 2: The tw o universal
asynchronous recei ver/ transmitter (U AR T) por ts allo w the incor poration of se rial
communication in existing and new designs. This section describes how data is
transported in character blocks using the standard “start-stop” format. It also
discusses how to configure and program the UART modules.
Chapter 15Pulse-Width Modulat or 1 and 2: This chapter describes both pulse-width
modulators. Programming information is also provided.
Chapter 16In-Circuit Emulation: This cha pter describes the in-circui t emulation (ICE)
module and how it is used to support low-cost emulator designs for the
MC68VZ328 microprocessor.
Chapter 17Bootstrap Mode: The operation of bootstrap models is described in detail in this
chapter. This chapter describes programming information necessary to allow a
system to initialize a target system and download a program or data to the target
system’s RAM using the UART 1 or UART 2 controller.
Chapter 18Application Guide: This chapter c ontains info rmation that will assist dur ing the
integration of the MC68VZ328 into an existing or a new design. It includes a
design checklist and instructions for using the MC68VZ328 Application
Development System (ADS) board to get started with the design process.
Chapter 19Electrical Characteristics: This chapter describes the electrical characteristics
of the MC68VZ328 integrated processor.
Chapter 20Mechanical Data and Ordering Information: This chapter provides
mechanical data, including illustrations, and ordering information.
xxviiiMC68VZ328 User’s Manual
Suggested Reading
The following documents are re quire d for a compl ete desc ript ion of the MC68 VZ328 and ar e necessa ry to
design properly with the part. Especially for those not familiar with the 68000 CPU, the following
documents will be helpful when used in conjunction with this manual.
M68000 Family Programmer’s Reference Manual (order number M68000PM/AD)
M68000 User’s Manual (order number M68000UM/D)
M68000 User’s Manual Addendum (order number M68000UMAD/AD)
MC68EZ328 User’s Manual (order number MC68EZ328UM/D)
MC68EZ328 User’s Manual Addendum (order number MC68EZ328UMA/D)
MC68VZ328 Product Brief (order number MC68VZ328P/D)
The manuals may be found at the Motorola Web site at http://www.Motorola.com/DragonBall. These
documents may be downloaded fr om the Web site, or a printed vers ion may be obtained from a local s ale s
office. The Web site also may have useful application notes.
Conventions
This user’s manual uses the following conventions:
•OVERBAR
•Logic level one is a voltage that corresponds to Boolean true (1) state.
is used to indicate a signal that is active when pulled low: for example, RESET.
•Logic level zero is a voltage that corresponds to Boolean false (0) state.
•To set a bit or bits means to establish logic level one.
•To clear a bit or bits means to establish logic level zero.
•A signal is an electronic construct whose state conveys or changes in state convey information.
•A pin is an external physical connection. The sa me pin can be used to connect a number of signal s.
•Asserted means that a discrete signal is in active logic state.
— Active low signals change from logic level one to logic level zero.
— Active high signals change from logic level zero to logic level one.
•Negated means that an asserted discrete signal changes logic state.
— Active low signals change from logic level zero to logic level one.
— Active high signals change from logic level one to logic level zero.
•LSB means least significant bit or bi ts, and MSB means most significant bit or bits. References to
low and high bytes or words are spelled out.
•Numbers preceded by a percent sign (%) are binary. Numbers preceded by a dollar sign ($) or 0x
are hexadecimal.
About This Bookxxix
Definitions, Acronyms, and Abbreviations
The following list defines the acronyms and abbreviations used in this document.
BCDbinary coded decimal
CGMclock generation module
DRAMdynamic RAM
FIFOfirst in first out
ICEin-circuit emulation
MAPmold array process
MAPBGAmold array process ball grid array
MIPSmillion instructions per second
PWMpulse-width modulator
RTCreal-time clock
SIMsystem integration module
SPIserial peripheral interface
SRAMstatic RAM
TQFPthin quad flat pack
UARTuniversal asynchronous receiver/transmitter
XTALcrystal
xxxMC68VZ328 User’s Manual
Chapter 1
Introduction
This chapter describes the overall system architecture of the MC68VZ328 (DragonBall™ VZ) integrated
processor. It provides an overview of the 68000 CPU and the operational blocks of the MC68VZ328 at a
system level.
The MC68VZ328 builds on the success of the earlier DragonBall processors and features a synthesizable
68000 core that utilizes an advanced process technology. Thus, the DragonBall VZ can provide system
designers with more perf orma nce— th e capability of running at hi ghe r speed while achieving lowe r powe r
consumption using a true static core. Additionally, the new DragonBall VZ integrates the logic needed to
support color LCD panels on-chip. The DragonBall VZ is the integrated processor of choice for some of
the most popular PDA designs, and it can be used in a wide variety of other applicat ions inclu ding exerci se
monitors, games, smart toys, depth finders, navigation systems, and smart phones.
All these features combine to make the MC68VZ328 microprocessor attractive to many system designers.
Its functionality and glue logic are all optimally connected and timed with the same clock. Also, only the
essential signals are brought out to the pins, allowing the MC68VZ328’s primary packages (TQFP and
MAPBGA) to occupy the smallest possible footprint on the circuit board.
To improve total system throughput and reduce component count, board size, and the cost of system
implementation, the MC68VZ328 combines a powerful FLX68000 processor with intelligent peripheral
modules and typical system interface logic. The architecture of the MC68VZ328, shown in Figure 1-1 on
page 1-2, consists of the following blocks:
•FLX68000 CPU
•Chip-select logic and 8-/16-bit bus interface
•Clock generation module (CGM) and power control
•Interrupt controller
•76 GPIO lines grouped into 10 ports
•Two pulse-width modulators (PWM 1 and PWM 2)
•Two general-purpose timers
•Two serial peripheral interfaces (SPI 1 and SPI 2)
•Two UARTs (UART 1 and UART 2) and infrared communication support
•LCD controller
•Real-time clock
•DRAM controller that supports EDO RAM, Fast Page Mode, and SDRAM
•In-circuit emulation module
•Bootstrap mode
Introduction1-1
Features of the MC68VZ328
CGM &
Power
Control
Interrupt
Controller
FLX68000
Static
CPU
16-Bit
GPIO Ports
Timers (2)
16-Bit
PWM 2
8-Bit
PWM 1
Real-Time
Clock
Memory
Controller
8/16-Bit 68000
Bus Interface
68000 Internal Bus
In-Circuit
Emulation
Bootstrap
Mode
LCD
Controller
SPI 1
SPI 2
GPIO Ports
UART 1 with
IrDA1.0
UART 2 with
IrDA1.0
Figure 1-1. MC68VZ328 Block Diagram
1.1 Features of the MC68VZ328
The features of the DragonBall VZ include the following:
•Static FLX68000 CPU—identical to the MC68EC000 microprocessor
— Full compatibility with MC68000 and MC68EC000
— 32-bit internal address bus
— Static design that allows processor clock to be stopped to provide power savings
— 5.4 MIPS performance at 33 MHz processor clock
— External M68000 bus interface with selectable bus sizing for 8-bit and 16-bit data ports
•System integration module (SIM) that incorporates many functions typically related to external
array logic, reducing parts counts in design, with functions that include the following:
— System configuration and programmable address mapping
— Glueless interface to SRAM, DRAM, SDRAM, EPROM, and flash memory
— Eight prog r ammable chip-selects with wait-state generation logic
— Four programmable interrupt I/Os, with keyboard interrupt capability
1-2MC68VZ328 User’s Manual
Features of the MC68VZ328
— Five general-purpose, programmable edge/level/polarity interrupt IRQs
— Other programmable I/O, multiplexed with peripheral functions of up to 76 GPIO lines
— Programmable interrupt vector response for on-chip peripheral modules
— Low-power mode control
•DRAM controller
— Support for CAS
— Support for 8-bit and 16-bit port DRAM and synchronous DRAM
— EDO RAM or automatic Fast Pa ge Mode for LCD access
— Programmable refresh rate
— Support for up to two banks of DRAM and EDO RAM
— Programmable column address size
•76 GPIO lines grouped into 10 ports
•Two UART ports
•Two serial peripheral interface (SPI) p orts
•Two 16-bit general-purpose counters/timers
— Automatic interrupt generation
— 30 ns resolution at 33 M Hz system clock
— Timer input/output pin
•Real-time clock/sampling timer
— Separate power supply for the RTC
— One programmable alarm
— Capability of counting up to 512 days
-before-RAS refresh cycles and self-refresh mode DRAM
— Sampling timer with selectable frequency (4 Hz, 8 Hz, 16 Hz, 32 Hz, 64 Hz, 256 Hz, 512 Hz,
1kHz)
— Interrupt generation for digitizer sampling or keyboard debouncing
•LCD controller
— Software-progr ammable screen size (up to 640
and color STN panels
— Capability of dire ctly driving popul ar LCD drive rs and modules from Motorola, Shar p, Hitachi,
Toshiba, and numerous other manufacturers
— Support for up to 16 gray levels out of a palette of 16 density levels
— Utilization of system memory as display memory
— LCD contrast control using 8-bit PWM
•Two pulse-width modulator (PWM) modules
— Audio effects support
— 16- and 8-bit resolution
— 5-byte FIFO that provides more fl exibility on perfo rmance
— Sound and melody generation
× 512) to support single ( nonsplit) monochrome
Introduction1-3
CPU
•Built-in emulation function
— Dedicated memory space for emulator debug monitor with chip-select
— Dedicated interrupt (interrupt level 7) for in-circuit emulation (ICE)
— One address-signal comparator and one control-signal comparator, with masking to support
single or multiple hardware execution
— Breakpoint
— One breakpoint instruction insertion unit
•Bootstrap mode function
— Capability to initialize system and download programs and data to system memory through
UART
— Acceptance of execution command to run program stored in system memory
— 8-byte-long instruction buffer for 68000 instruction storage and execution
•Power management
— Fully static HCMOS technology
— Programmable clock synthesizer using 32.768 kHz or 38.4 kHz external crystal for full
frequency control
— Low-power stop capabilities
— Modules that can be individually shut down
— Operation from DC to 33 MHz (processor clock)
— Operating voltage of 2.7 V to 3.3 V
— Compact 144-lead thin quad flat pack (TQFP) and MAPBGA
1.2 CPU
The FLX68000 CPU in the MC68VZ328 is an update d implementation of t he 68000 32-bit micr oprocessor
architecture. The main features of the CPU are the following:
•Low-power, fully static HCMOS implementation
•32-bit address bus and 16-bit data bus
•Sixteen 32-bit data and address registers
•56 powerful instruction types that support high-level development languages
•14 addressing modes and 5 main data types
•Seven priority levels for interrupt control
The CPU is completely code compatible with other members of the M68000 families, which means it has
access to a broad base of established real-time kernels, operating systems, languages, applications, and
development tools.
1-4MC68VZ328 User’s Manual
CPU
1.2.1 CPU Programming Model
The CPU has 32-bit registers and a 32-bit program counter, which are shown in Figure 1-2. The first eight
registers (D7–D0) are data registers that are used for byte (8-bit), word (16-bit), and long-word (32-bit)
operations. When being used to manipulate data, the data re gis te rs a ff ect the sta tus reg is ter (SR) . The next
seven registers ( A6–A0) and the user stack poin ter (USP) can function as software stack pointers a nd bas e
address registers. The se registe rs can be used for wor d and long-word operations , but they do not affe ct the
status register. The D7–D0 and A6–A0 registers can be used as index registers.
3116 15
3116150
310
7
8
7
Figure 1-2. User Programming Model
0
D0
D1
D2
D3
D4
D5
D6
D7
0151631
A0
A1
A2
A3
A4
A5
A6
PCProgram Counter
0
Data Registers
Address Registers
User Stack PointerA7 (USP)
Status RegisterSR
In supervisor mode, t he upper byte of the status register and the s upervisor stack poin te r ( SSP) can also be
programmed, as shown in Figure 1-3.
3116150
8
15
7
0
SRStatus Register
Figure 1-3. Supervisor Programming Model Supplement
Supervisor StackA7 (SSP)
Pointer
The status register contains the interrupt mask with seven available levels, as well as an extend (X),
negative (N), zero (Z), overflow (V), and carry (C) condition code. The T bit in dic at es when the processor
is in trace mode, and the S bit indicates when it is in supervisor o r user mode.
Introduction1-5
CPU
1.2.2 Data and Address Mode Types
The CPU supports five types of data and six main types of address modes. The five types of data are bits,
binary-coded decimal (BCD) digits, bytes, words, and long words. The six types of address modes are
shown in Table 1-1.
Table 1-1. Address Modes
Address ModeSyntax
Register direct address
•Data register direct
•Address register direct
Absolute data address
•Absolute short
•Absolute long
Program counter relative address
•Relative with offset
•Relative with index offset
Register indirect address
•Register indirect
•Postincrement register indirect
•Predecrement register indirect
•Register indirect with offset
•Indexed register indirect with offset
Dn
An
xxx.W
xxx.L
d
16
d
(PC, Xn)
8
(An)
(An)+
–(An)
d
16
d
(An, Xn)
8
(PC)
(An)
Immediate data address
•Immediate
•Quick immediate
Implied address
•Implied registerSR/USP/SP/PC
Note:
Dn = Data register
An = Address register
Xn = Address or data register used as index register
SR = Status register
PC = Program counter
SP = Stack pointer
USP = User stack pointer
( ) = Effective address
= 8-bit offset (displacement)
d
8
= 16-bit offset (displacement)
d
16
#xxx = Immediate data
#xxx
#1–#8
1.2.3 FLX68000 Instruction Set
The FLX68000 CPU instruction set supports high-level languages that facilitate programming. Almost
every instruction o perates o n bytes, word s, and long wor ds, and mo st of them can us e any of th e 14 addres s
modes. Combining instruct ion typ es, dat a types , and addres s modes pr ovides acces s to ove r 1,000 po ssibl e
instructions. Thes e instr uctions, shown in Table 1-2 on page 1-7, include signed and unsi gned multipl y and
divide, quick arithmetic operations, binary-coded decimal (BCD) arithmetic, and expanded operations
(through traps).
1-6MC68VZ328 User’s Manual
Table 1-2. Instruction Set
MnemonicDescriptionMnemonicDescription
ABCDAdd decimal with extendMOVEMMove multiple registers
ADDAdd MOVEPMove peripheral data
ADDAAdd addressMOVEQMove quick
ADDQAdd quickMOVE from SRMove from status register
ADDIAdd immediateMOVE to SRMove to status register
ADDXAdd with extendMOVE to CCRMove to condition codes
ANDLogical ANDMOVE USPMove user stack pointer
ANDIAND immediateMULSSigned multiply
ANDI to CCRAND immediate to condition codesMULUUnsigned multiply
ANDI to SRAND immediate to status registerNBCDNegate decimal with extend
ASLArithmetic shift leftNEGNegate
CPU
ASRArithmetic shift rightNEGXNegate with extend
BccBranch conditionallyNOPNo operation
BCHGBit test and changeNOTOne’s-complement
BCLRBit test and clearORLogical OR
BRABranch alwaysORIOR immediate
BSETBit test and setORI to CCROR immediate to co ndi tio n code s
BSRBranch to subroutineORI to SROR immediate to status register
BTSTBit testPEAPush effective address
CHKCheck register against boundsRESETReset external devices
CLRClear operandROLRotate left without extend
CMPCompareRORRotate right without extend
CMPACompare addressROXLRotate left with extend
CMPMCompare memoryROXRRotate right with extend
CMPICompare immediateRTEReturn from exception
DBccTest conditionally, decrement, and branchRTRReturn and restore
DIVSSigned divideRTSReturn from subroutine
DIVUUnsigned divideSBCDSubtract decimal with extend
EORExclusive ORSccSet conditional
Introduction1-7
Modules of the MC68VZ328
Table 1-2. Instruction Set (Continued)
MnemonicDescriptionMnemonicDescription
EORIEx clusive OR immediateSTOPStop
EORI to CCRExclusive OR immediate to condition codesSUBSubtract
EORI to SRExclusive OR immediate to status registerSUBASubtract address
EXGExchange registersSUBISubtract immediate
EXTSign extendSUBQSubtract quick
JMPJumpSUBXSubtract with extend
JSRJump to subroutineSWAPSwap data register halves
LEALoad effective addressTASTest and set operand
LINKLink stackTRAPTrap
LSLLogical shift leftTRAPVTrap on overflow
LSRLogical shift rightTSTTest
MOVEMoveUNLKUnlink
MOVEAMove address
1.3 Modules of the MC68VZ328
In addition to the powerful 68000 processor, the DragonBall VZ contains a wide variety of peripheral
interface and control modules. The following subsections provide brief descriptions of these modules and
how they operate.
1.3.1 Memory Controller
The memory controller provide s a glueless int erface to most memory chips on the market. It suppor ts flash,
ROM, SRAM, different DRAM types (EDO RAM and Fast Page Mode ), a nd synchronous DRAM. Either
one or two banks of DRAM may be used, and each bank can be a maximum of 32 Mbyte. For a more
complete explanation of how memory is configured and controlled, see Chapter 3, “Memory Map.”
1.3.2 Clock Generation Module and Power Control Module
The module containing the clock synthesizer operates with either an external crystal or an external
oscillator to provide a stable clock source for the internal clock generation module (CGM). The output
frequency can be adjusted by writing to the CGM frequency select register. The CGM can be disabled to
shut down the system clo ck divider chain fo r maximum power s aving, whil e the real- time cloc k (RTC) and
DRAM controller remain act ive. The po wer control module can be conf igured to control the CPU cycles t o
optimize power consumption. The power control module offers three power-saving modes: normal, doze,
1-8MC68VZ328 User’s Manual
Modules of the MC68VZ328
and sleep. When in sleep mode, the CGM wakes up aut omaticall y when any un maske d exter nal or inte rnal
interrupt occurs. Se e Chapter 4, “Clock Generation Module and Power Control Module,” for more detaile d
information.
1.3.3 System Control
The primary function of the system control module is to provide configuration control of several other
modules in the DragonBall VZ. These registers grant permission for access to many of the internal
peripheral registers. In addition, the module controls address space of the internal peripheral registers and
the bus time-out control and status (bus error generator). System control also is used to program the drive
current of the GPIO lines. See Chapter 5, “S ystem Control,” for more infor mation.
1.3.4 Chip-Select Logic
The MC68VZ328 provides eight programmable general-purpose chip-select signals to allow the selection
of a wide variety of memory or external peripherals. Each chip-select signal provides a write-protect
option, internal and external DTACK generation, and 8-bit and 16-bit data port size selection. For more
detailed information about using the chip-select logic, see Chapter 6, “Chip-Select Logic.”
1.3.5 DRAM Controller
The DRAM controller provides a glueless interface for either 8-bit or 16-bit DRAM. It supports EDO
RAM, Fast Page Mode, and synchronous DRAM. The DRAM controller provides row address strobe
) and column address strobe (CAS ) sig nals fo r up to a maxi mum of two ba nks of DRAM. In addi tion
(RAS
to controlling DRAM, the DRAM controller supports access for LCD controller burst accesses. See
Chapter 7, “DRAM Controller,” for more information about this module.
1.3.6 LCD Controller
The LCD controller provides display data for exte rnal LCD drivers or for an LCD panel. The LCD
controller fetches display data directly from system memory through periodic DMA transfer cycles. For
this reason, an understandi ng of the DRAM controller is recommended. For more information, ple ase refer
to Chapter 7, “DRAM Controller,” as well as Chapter 8, “LCD Controller.”
1.3.7 Interrupt Controller
The interrupt controller prioritizes internal and external interrupt requests and generates a vector number
during the CPU inter ru pt-acknowledge cycle. I nterrupt nesting is al so provided so that an i nterrupt service
routine of a lower-priority interrupt may be su spended by a higher-priority interrupt request. The o n-chip
interrupt controller features prioritized interrupts, a fully nested interrupt environment, programmable
vector generatio n, and unique vector number generati on for each inte rrupt lev el. For addit ional infor mation
about this module, see Chapter 9, “Interrupt Controller.”
Introduction1-9
Modules of the MC68VZ328
1.3.8 General-Purpose I/O (GPIO) Lines
The MC68VZ328 supports a maximum of 76 GPIO lines grouped together in ports A–G, J, K, and M.
These ports can be configured as GPIO pins or dedicated peripheral interface pins. Each pin can be
independently progr ammed as a GPIO pin ev en when other pins rela te d to that on- chip per iphera l are u sed
as dedicated pins. For detailed information about programming these GPIO lines, see Chapter 10, “I/O
Ports.”
1.3.9 Real-Time Clock
A real-time clock provides the time of day with 1-second resolution. Using an external crystal (either
32.768 kHz or 38.4 kHz) as a clock source, it keeps time as long as power i s applied t o the chip, e ven when
it is in sleep or doze mode. The watchdog clock timer protects against system failures by providing a way
of escape from unexpected input conditions, external events, or programming errors. Once started, this
timer must be cleared by software on a regular basis so that it never reaches its time-out value. When it
does reach its time-out value, the watchdog timer assumes that a system failure has occurred and the
software watchdog logic resets or interrupts the CPU. For detailed information about configuring and
programming this module, refer to Chapter 11, “Real-Time Clock.”
1.3.10 General-Purpose Timer
The MC68VZ328 has two 16-bit timers that can be used in various modes to capture the timer value with
an external event, to trigger an external event or interrupt when the timer reaches a set value, or to count
external events. Each timer has an 8-bit prescaler to allow a programmable clock input frequency to be
derived from the system clock. The two timers can also be cascaded together as one 32-bit timer. This
module is described in detail in Chapter 12, “General-Purpose Timers.”
1.3.11 Serial Peripheral Interfaces (SPI)
The MC68VZ328 contains two serial peripheral interface (SPI) modules, SPI 1 and SPI 2. The serial
peripheral interfaces are mainly used for controlling external peripherals. The passed data is synchronized
with the SPI clock, and it is transmitted and received with the same SPI clock. One SPI module (SPI 2)
only operates in master mode, which initiates SPI transfers from the MC68VZ328 to the peripheral. The
other SPI (SPI 1) may be configured as either master or slave. Chapter 13, “Serial Peripheral Interface 1
and 2,” provides detailed information about the configuration and operation of the SPIs.
The two UART ports in the MC68VZ328 may be used to communicate with external serial devices.
UART 1 is identical to the UART i n the Drag onBal l EZ processor, while UART 2 represen ts an enh anc ed
version of UART 1. One of the enhancements to the UART 2 design consists of an enlarged RxFIFO and
TxFIFO to reduce the number of software interr upt s. An improv ement to bot h UARTs is the sys te m clock
input frequency, which is 33.16 MHz, doubling the 16.58 MHz frequency of the MC68EZ328. For a
33.16 MHz system clock, software written for the MC68EZ328 version of the chip is not compatible
unless the divider and prescaler are adjusted to compensate for the increased clock speed. For more
information about the programming and configuration of these two modules, see Chapter 14, “Universal
Asynchronous Receiver/Transmitter 1 and 2.”
1-10MC68VZ328 User’s Manual
Modules of the MC68VZ328
1.3.13 Pulse-Width Modulators (PWM)
The MC68VZ328 has two pulse-width modulator s (PWMs). Each of the pul se-wid th modulat ors has thr ee
modes of operation— playba ck, t one, a nd digital -to- analog (D/A) conve rsion . Us ing t hese three modes, the
PWM can be used to play back high-quality digital sounds, produce simple tones, or convert digital data
into analog waveforms. The 8-bit PWM contains a 5-byte FIFO that enhances the system performance by
reducing the numb er of int errupt s to the CPU. The 16-bit PWM provi des h igher reso lutio n for bett er s ound
quality. Users can enable both PWMs at the sa me time to genera te a mixed PWMO signa l. See Chapter 15,
“Pulse-Width Modulator 1 and 2,” for more detailed information about the configuration and operation of
these devices.
1.3.14 In-Circuit Emulation Module
The in-circuit emulati on module is designed fo r low-cost emulat or development pu rposes. System me mory
space, which is 0xFFFC0000 t o 0xFFFCFFFF, is covered by the EMUCS
the emulator debug monitor. However, the EMUCS
system I/O port. Keep in mind that if the monitor ROM is selected, the system must boot up in emulator
mode. Refer to Chapter 16, “In-Circuit Emulation,” for more details.
signal can be used to select the monitor ROM or
signal and primar ily dedi cated to
1.3.15 Bootstrap Mode
The bootstra p mode is design ed to allow the initialization of a target syst em and the ability to downloa d
programs or data to the target system RAM using either the UART 1 or UART 2 controller. See
Chapter 14, “Universal Asynchronous Receiver/Transmitter 1 and 2,” for information on operating and
programming the UART controllers. Once a program is downloaded to the MC68VZ328, it can be
executed, providin g a simple debugging env ironment for fail ure analys is and a chan nel to up date progr ams
stored in flash memory. Simple hardware debug func tions may be performed on the t arget s ystem using the
bootstrap utility program BBUGV.EXE, which is available on the following World Wide Web site:
http://www.Motorola.com/DragonBall. See Chapter 17, “Bootstrap Mode,” for more information about
this mode.
Introduction1-11
Modules of the MC68VZ328
1-12MC68VZ328 User’s Manual
Chapter 2
Signal Descriptions
This chapter describes the MC68VZ328’s input and output signals, which are organized into functional
groups, as illustrated in Figure 2-1 on page 2-2. The MC68VZ328 uses a standard M68000 bus to
communicate with on-chip and external peripherals. This single continuous bus exists both on and off the
chip. CPU read cycles to internal memory- ma pped r egi st er s of the device ar e i nvi si bl e on the external bus,
but write cycles to internal or external memory-mapped locations are visible.
The MC68VZ328 microprocessor has three types of power pins. They are VDD, VSS, and LVDD.
•V
—External power supply to drive all I/O pins and for the internal voltage regulator. It is
DD
recommended to place a 0.1 µF bypass capacitor close to each of these pins.
•V
•LV
—Signal return pin for both digital and analog circuits.
SS
—Internal v oltage regu lator output s ignal that is used b y the internal circuitry. The L VDD pins
DD
should not be used as an external circuit power supply due to current supply limitations. Each
package has unique bypass capacitor requirements. The TQFP package requires that an external
bypass capacito r circuit of 0.01
µF and 0.0001 µF (in parallel) be placed clo se to each of the LV
pins, except pin 35, which requires a 270 nF and a 0.0001 µFbypass capacitor. The PBGA has a
single LV
pin (M1) requiring only a 270 nF and a 0.0001 µFbypass capacitor.
DD
NOTE:
For maximum noise immunity, ensure that external bypass capacitors are
placed as close to the pins as possible.
2.3 Clock and System Control Signals
There are four clock and system control signals.
•EXT AL—External Clock/Crys tal. This i nput signal con nects to th e e xternal lo w freq uency c rystal.
The MC68VZ328 microprocessor supports both a 32.768 kHz and a 38.4 kHz crystal frequency.
For a 32.768 kHz input, the internal phase-locked loop generates a PLLCLK signal that passes
through two prescalers, and the resulting output (DMACLK and SYSCLK) clock is 16.58 MHz.
Figure 2-2 illustrates how a crystal is usually connected to the MC68VZ328. For specific circuit
design values, see Figure 4-2 on page 4-4.
DD
32.768 kHz or 38.4 kHz
EXTAL
C1
Figure 2-2. Typical Crystal Connection
XTAL
C2
•XTAL—Crystal. This output signal connects the on-chip oscillator output to an external crystal.
•CLKO/PF2—Clock Out or bit 2 of Port F . This output clock signal is derive d from the on-chip clock
oscillator and is internally connected to the clock output of the internal CGM. This signal is
provided for external reference. The outp ut can be disa bled in the PLL control regis ter to reduce
power consumption and electromagnetic emission. See Section 4.4.1, “PLL Control Register,” on
page 4-8 for more information. The CLKO/PF2 signal defaults t o t he Port F pin 2 in put sig nal . Fo r
detailed information, refer to Section 10.4.7.3, “Port F Dedicated I/O Functions,” on page 10-26.
ESET—Reset. This active low, Schmitt trigger input signal resets the entire MC68VZ328
•R
processor (CPU and peripherals). The threshold of this Schmitt trigger device is 1.2 V high and
0.8 V low. Af ter the MC68VZ328 po wers up, this re set input signa l should be dri ven lo w for at le ast
2-4MC68VZ328 User’s Manual
Data Bus Signals
1.2 s before its voltage is higher than 1.2 V to ensure that the crystal oscill ator star ts and stabil izes.
See Section 4.3.1, “CLK32 Clock Signal,” on page 4-4 for details about selecting circuit values.
This signal is inactive while the CPU is executing the RESET instruction.
NOTE:
When an R/C circuit is being used to generate the RESET signal to the
MC68VZ328, the R/C circuit must be placed as close to the chip as
possible.
2.4 Address Bus Signals
The address bus pins A[23:0] are the address lines driven by the CPU or LCD controller for panel refresh
DMA. In sleep mode, all address signals are in an active state of the last bus cycle. Refer to
Section 4.5.1.4, “Sleep Mode,” on page 4-12 for more detailed information.
•A0/PG1—Address 0 or Port G bit 1. After system reset, this signal defaults to A0.
•MA[15:0]/A[16:1]—Multiplexed DRAM bits 15–0 or Address bits 16–1. These address output
lines are multiplexed with the DRAM row and column address signals. The MA signal is selected
on DRAM access cycles.
•A[19:17]—Address lines 19–17.
•A[23:20]/PF[6:3]—Address bit s 23–20 or Po rt F bits 6 –3. These a ddress lines are mult iplex ed with
Port F. These signals default to address functions after reset.
2.5 Data Bus Signals
The flexible data bus interface design of the MC68VZ328 microprocessor allows programming of the
lower byte of the data bus (in an 8-bit-only system) to operate as general-purpose I/O signals. In sleep
mode, all of the data bus pins (D15–D0) are individually pulled up with 1-megaohm resistors. Refer to
Section 4.5.1.4, “Sleep Mode,” on page 4-12 for more detailed information.
•D[15:8]—Data bits 15–8. The upper byte of the data bus is not multiplexed with any other signal.
In pure 8-bit systems, this is the data bus. In mixed 8- and 16-bit systems, 8-bit memory blocks or
peripherals should be connected to this bus.
•D[7:0]/P A[7:0]—Data bits 7–0 or Port A bits 7–0. This bu s is the lower data by te or general-purpose
I/O. In pure 8-bit systems, th is b us can serv e as a general -purpose I /O. The WDTH8 bit in the SCR
register (0xFFF000) should be set to 1 by software before the port can be used. See Section 5.2.1,
“System Control Register,” on page 5-2 for details on setting this bit. In 16-bit or mixed 8- and
16-bit systems, these pins must function as the lower data byte.
Signal Descriptions2-5
Interrupt Controller Signals
2.6 Bus Control Signals
The bus control signals are used for both the configuration and operation of the MC68VZ328 bus. The
following descriptions provide detailed information about programming the signals and their use.
WE/LB, UWE/UB—Lower Byte Write-Enable and Uppe r Byte Write-Enable , or Lower Byte and
•L
Upper Byte data strobe s. For all chip-select cycles excep t CSB
WE. They are used as lower and upper write-enable signals to a 16-bit port. If the chip-select is
U
set to 8-bit port (the BSW bit is clea r), use only the UWE
be used as a DRAM write-enab le if DRAM refresh does not re quire that UWE
should be used. For CSB [1:0] cycles, if the SR16 bit is clear in the CSCTRL1 register, these
DWE
two pins are LWE
pins are UB
of the 16-bit memory chip.
WE/UCLK/PE3—DRAM Write-Enable, UA R T Cl ock, or Port E bit 3. Use the D WE signal with
•D
DRAM, which requires an independent write-enable signal rather than one that is shared with
. This signal stays high during re fresh cycles . This pin defaults to a PE3 inp ut signal. T o se lect
UWE
the DWE
bit of the DRAMC register, which is described in Section 7.3.2, “DRAM Control Register,” on
page 7-14. If this bit is not enabled, the UCLK signal function is selected, which is an input clock
to the UART module. For a description of the UCLK signal, refer to Section 14.2.3, “Serial
Interface Signals,” on page 14-3. This pin defaults to GPIO input pulled high.
function, program Port E to DWE and enable the DWE signal by wr itin g a 1 to th e DWE
and UWE and function as previo usl y d escribed. If the SR16 bit is set, these two
and LB. These two data strobe signa ls ar e nor mal ly us ed to connect to UDS and LDS
[1:0], these two pins are LWE and
signal for wri te-enabl e contro l. UWE can
stay high. Otherwise,
•BUSW/DTACK
default bus width for the CSA0
signal. The MC68VZ328 microprocessor will latch the BUSW signal at the rising edge of the
RESET
of BUSW on reset means t hat CSA0
on reset means that CSA0
DTACK
If it is input, only those chip-select cycles using external DTACK
cycles of internal DTACK
system reset. For a 16-bit CSA0
pulled up, externally.
•O
microprocessor, which enables the output of either ROM or SRAM.
•U
These pins default to GPIO input pulled high.
•RW
GPIO input pulled high.
signal. Its mode will determine the defa ult bus width for CSA0. For example, a logic low
input signal. DTACK can be conf igured as output b y programming the Port G DIR regis ter .
E—Output Enable. This active low signal is asserted during a read cycle of the MC68VZ328
DS/PK3, LDS/PK2—Data strobes or GPIO. UDS and LDS are 68000 CPU data strobe signals.
/PK1—Read/Write or Port K bit 1. R W is the 68000 CPU read/wri te signal. Th is pin def aults to
/PG0—Bus Width, Data Transfer Acknowledge, or Port G bit 0. BUSW is the
signal. The DTACK signal is the external input data acknowledge
connects to an 8-bit memory de vice, and a logic hi gh of BUSW
connects to a 16-bit memory device. After reset, this pin defaults to the
will ignore the input status. This pin can be configured to GPIO after
-selected memory device, it is recommended that this signal be
2.7 Interrupt Controller Signals
will be affected. Chip-select
This section describes signals that are used by the MC68VZ328 interrupt controller.
NT[3:0], IRQ[3:1 ], IRQ6/PD[7:0]—Interrupt bits 3–0, Interrupt Request bits 3-1, or Port D bits
•I
NT[3:0], IRQ[3:1], and IRQ6 can be configured as edge or level trigger interrupt signals. To
7–0. I
support keyboard applications, the I/O function can be used with interrupt capabilities, which are
described in Chapter 9, “Interrupt Controller.” These pins default to GPIO input pulled high.
2-6MC68VZ328 User’s Manual
LCD Controller Signals
•IRQ5/PF1—Interrupt Request 5 or Port F bit 1. This signal can be programmed as GPIO or as an
interrupt input. When conf igured as an inter rupt input, the signal may be pro grammed as a leve l high
or level low trigger interrupt. This pin defaults to GPIO input pulled high.
•EMIQ—Emulator Interrupt Status
EMUIRQ
sources—two br eak point interrupts fr om the in-circuit emul ation module and an external interrupt
from EMUIRQ
ICEMSR register to identify the interrupt source and write a 1 to the corresponding bit in the
ICEMSR. See Section 9.6.4, “Interrupt Status Register,” on page 9-12 for more information.
pin is reque sting a level 7 interrupt. This bit can be generated from three interrupt
, which is an active low, edge-sensitive interrupt. To clear this interrupt, read the
. This bit indicates that the in-circuit emulation module or
2.8 LCD Controller Signals
The MC68VZ328 contains all necessary circuitry to support an external LCD display panel. This section
describes the signals used by the LCD controller. It also provides some programming information about
the use of these signals.
•LD[3:0]/PC[3:0], LD[7:4]/PK[7:4]—LCD Data Bus bits 7–0, or Port C bits 3–0 and Port K bits
7–4. LD signals output bus transfers of pixel data to the LCD panel to which it will be displayed.
The pixel data is arranged to accommodate the programmable panel mode data width selection.
Panel interfaces of 1, 2, 4, or 8 bits are supported.
NOTE:
The MC68VZ328’ s LCD inte rface data b us uses th e LSB (LD0) to display
pixel 0,0. Some LCD panel manufacturers program their LCD panel data
bus so that the MSB of the panel displays pixel 0,0. For these panels, the
connection between the MC68VZ328’ s LCD data b us and the LCD p anel’ s
data bus ma y hav e a re ver sed bit signi fica nce. F or a 4-bit LCD panel of t his
type, connect the MC68VZ328’s LD0 signal to the LCD panel’s data bit 3,
and then connect LD1 to LCD data 2, LD2 to LCD data 1, and LD3 to LCD
data 0. The four pins can also be programmed as I/O ports from Port C.
These signals default as GPIO input with Port C being pulled low and Port
K pulled high.
•LFLM/PC4—First Line Marker or Port C bit 4. This signal indicates the start of a new display
frame. LFLM becomes act iv e af ter the firs t line pulse of the f rame and r emains active until the next
line pulse, at which point it deasserts and remains inactive until the next frame. LFLM can be
programmed to be an active high or an activ e low signal. It can also be programmed as an I /O port .
This pin defaults to GPIO input pulled low.
•LLP/PC5—LCD Line Pulse or Port C bit 5. The LLP signal is used to latch a line of shifted data
onto an LCD panel. The LLP can be programmed to be an active high or active low signal in
software. See Section 8.3.10, “LCD Polarity Configuration Register,” on page 8-16 for more
information.
•LCLK/PC6—LCD Shift Clock or Port C bit 6. This is t he clock output to which th e out put dat a t o
the LCD panel is synchronized. LCLK can be programmed to be either an active high or an active
low signal. This pin can a lso b e prog rammed as an I /O port. This pin d efa ults to GPI O input pull ed
low .
•LACD/PC7 —LCD Alternate Crystal Direction or Port C bit 7. This output is toggled to alte rnate
the crystal polarization on the panel. This signal can be programmed to toggle at a period of 1 to
128 frames or lines. Th is pin also can also be pr ogrammed as an I/O por t. This pin d efaults to GPIO
input pulled low.
Signal Descriptions2-7
Timer Signals
•LCONTRAST/PF0—LCD Contrast and Port F bit 0. This output is generated by the pulse-width
modulator (PWM) inside the LCD controller to adjust the supply voltage to the LCD panel. This
pin can also be programmed as an I/O port. This pin defaults to GPIO input pulled high.
2.9 UART 1 and UART 2 Controller Signals
There are two Universal Asynchronous Receive Transmit (UART) modules in the MC68VZ328. This
section describes the signals that are used to interface with external serial devices.
•RXD1/PE4, RXD2/PJ4—UART 1 and UAR T 2 Receive Data or Port E bit 4 and Port J bit 4. RXD
is the receiver serial input. During normal operation, NRZ data is expected, but in IrDA mode, a
narrow pulse of 1.6 µs minimum is expected for each zero bit received. External circuitry must be
used to con vert the IrD A sign al to an elec trical signa l. RS-232 applica tions need an externa l RS-232
receiver to convert voltage levels. These pin s default to GPIO input pulle d high.
•TXD1/PE5, TXD2/PJ5—UART 1 and UAR T 2 Transmit Data or Port E bit 5 and Port J bit 5. TXD
is the transmitter serial output. During normal operation, they output NRZ data signals. In IrDA
mode, they output a selectable pulse width of three-sixteenths bit period or 1.6 µs minimum bit
period for each zero bit transmitted. For RS-232 applications, this pin must be connected to an
RS-232 transmitter. For IrDA applications, this pin can directly drive an IrDA LED. These pins
default to GPIO input pulled high.
TS1/PE6, R TS2/PJ6—UART 1 and U ART 2 Request to Send or Port E bit 6 and Port J bit 6. RTS
•R
indicates that i t is ready to receive data by as ser ti ng this pin (low). This pin would be connected to
the far-end transmitter’s CTS
These pins default to GPIO input pulled high.
TS1/PE7, CTS2/PJ7—UART 1 and UART 2 Clear to Send or Port E bit 7 and Port J bit 7. CTS
•C
controls th e transmitte r. Normally, the transmitter waits until this sign al is active (low) before a
character is transmitted. If the NOCTSx bit is set in the UTX register, the transmitter sends a
character whenever a character is ready to transmit. These pins default to GPIO input pulled high.
pin. When the recei ver detects a pending overrun, it negates th is pi n.
2.10 Timer Signals
There are several external timer and clock signal functions available using the MC68VZ328. This section
describes the signals and how they are programmed.
•TOUT/TIN/PB6—Timer 1 Output, Timer 1 Input, or Port B bit 6. TOUT can be programmed to
toggle or generate a pulse of 1-system-clock duration when the timer/counter reaches a reference
value. TIN is used as the external clock source of Timer 1 or used as a capture function. This pin
defaults to GPIO input pulled high.
•UCLK/DWE
function is selected when DWE
controlled by the UCLKDIR bit of UART 1 and UART 2. For UCLK output, the UCLK bit of
peripheral control register selects the clock output signal from UART 1 or UART 2. This pin
defaults to GPIO input pulled high.
/PE3—UART Clock input/output, DRAM Write-Enable, or Port E bit 3. The UCLK
is disabled and PESEL3 is written 0. The direction of UCLK is
2-8MC68VZ328 User’s Manual
Serial Peripheral Interface 2 Signals
2.11 Pulse-Width Modulator Signals
There are two pulse-width modulator (PWM) modules in the MC68VZ328. This section describes the
signals available to communicate with these PWM modules.
•PWMO1/PB7—Pulse-Width Modula tor Output 1 or Port B bit 7. PWMO1 is an output signal from
the logical operation (AND or OR) of both the PWM 1 and PWM 2 modules. This pin defaults to
GPIO input pulled high.
•PWMO2/DATA_READY
PWMO2 is an output signal from the PWM 2 module. If this pin is configured for dedicated I/O
function and PKDIR0 is 1, the PWMO2 signal is selected. If PKDIR0 is 0, SPI Data Ready
(DATA_READY
) is selected. This pin defaults to GPIO input pulled high.
/PK0—Pulse-W idth Modulator Output 2, SPI Data Ready , or Port K bit 0.
2.12 Serial Peripheral Interface 1 Signals
There are two serial peripheral interface (SPI) modules in the MC68VZ328. This section describes the
signals that are used with SPI 1 to interface with external devices.
•MOSI/PJ0—SPI Transmi t Data or Port J bit 0. MOSI is the maste r outpu t/sla ve input signa l for t he
SPI shift register. This pin defaults to GPIO input pulled high.
•MISO/PJ1—SPI Receive Data or Por t J bi t 1. MISO is the maste r in put/s lave output sig nal for the
SPI shift register. This pin defaults to GPIO input pulled high.
•SPICLK1/PJ2—SPI Clock or Port J bit 2. SPICLK1 is the master clock output/slave clock input
signal for SPI. In polarity = 0 mode, this signal is low while the serial peripheral interface master is
idle. In polarity = 1 mode, this signal is high during idle. This pin defaults to GPIO input pulled
high.
S/PJ3—SPI Slav e Select or Port J bit 3. SS is the master out put/sla ve input chip- select signal. Thi s
•S
pin defaults to GPIO input pulled high.
•DATA_READY
master mode to signal the SPI master to clock out data. To select the DATA_READY
PKDIR0 and PKSEL0 bits are written 0. This pin defaults to GPIO input pulled high.
/PWMO2/PK0—SPI Data Ready or Port K bit 0. DATA_READY can be used in
function, the
2.13 Serial Peripheral Interface 2 Signals
This section describes the signals that are used with SPI 2, the second serial peripheral interface (SPI)
module in the MC68VZ328, to interface with external devices.
•SPITXD/PE0—SPI Master Transmit Data or Port E bit 0. SPITXD is the master SPI shift register
output signal. This pin defaults to GPIO input pulled high.
•SPIRXD/PE1—SPI Master Receive Data or Port E bit 1. SPIRXD is the input to the master SPI shift
register. This pin defaults to GPIO input pulled high.
•SPICLK2/PE2—SPI Master Clock or Port E bit 2. SPICLK2 is the clock output when the serial
peripheral interface master is enabled. In polarity = 0 mode, this signal is low while the serial
peripheral interface master is idle. In polarity = 1 mode, this signal is high during idle. This pin
defaults to GPIO input pulled high.
Signal Descriptions2-9
SDRAM Interface Signals
2.14 Chip-Select and EDO RAM Interface Signals
Chip-select logic is used to provide maximum compatibility with a wide variety of memory logic. This
section and Section 2.15, “SDRAM Interface Signals,” describe the signals used to interface with RAM,
SDRAM, and EDO RAM.
SA0—Chip-Select A bit 0. CSA0 is a defau lt chip-sel ect signal aft er reset. It i s set to 6 wait st ates
•C
and decodes all a ddress ranges, e xcept internal register add ress space, emulat or space, and bootstrap
space (0xFFFC0000–0xFFFFFFFF). It can be reprogrammed during the boot sequence to another
address range or dif ferent wait states. The default data bus width f or CSA0
of the BUSW signal.
•C
Chip-Select A, B, C, and D bits 0 and 1, Port F bit 7, Port B bits 5–0, or row and column select
signals. These pins comprise the remainder of the Group A, B, C, and D chip-selects and are
individually programmable. Pins that are not needed as chip-selects can be programmed as
general-purpose I/O. In addition, CSC
and RAS
signals. These pins default to GPIO input pulled high.
[1:0] and CSD [1:0] are designed to support DRAM as CAS
is determined by the s tate
•PM5/DMOE
the OE
memory read c ycles. In continuous p age mode, RAS
or RAS
and if OE
contention. Therefore, a dedicated output enable, DMOE
continuous page mode is enable d. Using th is mode will minimize t he number of clocks p er DRAM
access. This pin defaults to GPIO input pulled high.
—Port M bit 5 or DRAM Continuous P age Mode Out put Ena ble. DMOE is si mila r to
signal. However , DMOE onl y goes act i v e on DRAM read cy cle s, while OE is active for all
is held low until a page-miss, refresh required,
duration time out. During an RAS low period there may be other memory access cycles,
is used to enable the DRAM data output, DRAM will drive data, producing bus
, is required, connecting to DRAM if
2.15 SDRAM Interface Signals
•CSD0, CSD1—These two signals are multiplexed with SDRAM CS0 and CS1. When SDRAM is
enabled, CSD0
“Chip-Select Logic,” for more details.
•CSC0
•CSC1
•SDWE
—This signal is multiplexed with SDRAM RAS. When SDRAM is enabled, this signal
becomes an SDRAM RAS
“Chip-Select Logic.”
—This signal is multiplexed with SDRAM CAS. When SDRAM is enabled, this signal
becomes an SDRAM RAS
—SDRAM WE. When SDRAM is enabled, this signal becomes an SDRAM Write-Enable
signal. There is additi ona l pr ogr amming information about this sub je ct i n Chap ter 6, “Chip-Select
Logic.”
and CSD1 are SDRAM bank 1 and bank 2 chi p- sel ec t sign als . Als o s ee Ch apt er 6,
signal. For additional information about this subject, see Chapter 6,
signal. For mo re details, see Chapter 6, “Chip-Select Logic.”
•PM0/SDCLK—Port M bit 0 or SDRAM Clock. This pin defaults to GPIO input pulled low.
•PM1/SDCE—Port M bit 1 or SDRAM Clock Enable. This pin defaults to GPIO pulled low.
•PM2/DQMH, PM3/DQML—Port M bits 2–3 or SDRAM input/output mask. The se pi ns def ault to
GPIO pulled low.
•PM4/SDA10—Port M bit 4 or SDRAM Address A10. This pin defaults to GPIO input pulled low.
2-10MC68VZ328 User’s Manual
In-Circuit Emulation (ICE) Signals
2.16 In-Circuit Emulation (ICE) Signals
The ICE module is designed to sup port lo w-cost emula tor design s using t he MC68VZ328 mi cropr ocesso r.
There are four interface signals that are extended to external pins.
IZ/P/D/PG3—High Impedance, Program/Data, or Port G bit 3. During system reset, a logic low
•H
of this input signal will put the MC68VZ328 into Hi-Z mode, in which all MC68VZ328 pins are
three-stated after reset release. For normal operation, this pin must be pulled high during system
reset or left unconnected. This pin defaults to GPIO input pulled high, but can be programmed as
the P/D
or in data space during emulation mode.
•E
input signal will put the MC68VZ328 into emulation mode, which is described in Chapter 16,
“In-Circuit Emulation.” For normal operation, this pin must be pulled high during system reset or
left unconnected. After system reset, this pin defaults to an EMUIRQ
emulation mode. EMUIRQ
•E
input signal will put the MC68VZ328 into bootstrap mode, which is described in Chapter 17,
“Bootstrap Mode.” For normal operation, this pin must be pulled high during system reset or left
unconnected. After system reset , this pin def aults to the EMUBRK
used in emulation mode for breakpoint control.
function. P/D is a status signal tha t sho ws whether the curren t b us cycl e is in pr ogram space
MUIRQ/PG2—Emulator Interr upt Request or Port G b it 2. During syste m reset, a logic low of this
function in normal or
is an active low, level 7 interrupt input signal.
MUBRK/PG5—Emulator Breakpoint or Port G bit 5. During system reset, a logic low of this
function, which is an I/O signal
MUCS/PG4—Emulator Chip-Sel ect or Port G bit 4. EMUCS is an 8-bit data b us width chip-sel ect
•E
signal that selects the dedicated memory space from 0xFFFC0000 to 0xFFFDFFFF. It cannot be
used to select 16-bit data bus memory devices. EMUCS
but in normal and bootstrap modes as well. See Chapter 16, “In-Circuit Emulation,” for more
information about EMUCS
operation. This pin defaults to an EMUCS signal.
is not only activated in emulation mode,
Signal Descriptions2-11
In-Circuit Emulation (ICE) Signals
2-12MC68VZ328 User’s Manual
Chapter 3
Memory Map
The memory map is a guide to all on-chip resources. When you configure your chip, refer to Figure 3-1
and either Table 3-1 on page 3-2, which is sorted by address, or Table 3-2 on page 3-8, which is sorted
alphabetically by register name.
Monitor Program
(Defined by User)
0x1FFFFFFF
0xFFFC0000
0xFFFDFFFF
0xFFFFF000
0xFFFFFDff
0xFFFFFF00
0xFFFFFfff
Supervisor Memory Map
System Memory
Emulator
MC68VZ328
Monitor
Register
Bootstrap
User’s Memory Map
512 Mbyte
Program / Data
Memory
Reserved
Figure 3-1. MC68VZ328 System Memory Map
Memory Map3-1
Programmer’s Memory Map
3.1 Programmer’s Memory Map
On reset the base address used in the ta ble is 0xFFFFF000 (or 0xXXF FF000, where XX is “don’t car e”). If
a double-mapped bit is cleared in the system control register, then the base address is 0xFFFFF000 only.
Unpredictable result s occur if you write to any 4K regist er space not documented in Ta ble 3-1 or Table 3-2
on page 3-8.
Table 3-1. Programmer’s Memory Map (Sorted by Address)
AddressNameWidthDescriptionReset Value
0xFFFFF000SCR8System control register0x1C5-2
0xFFFFF003PCR8Peripheral control register0x005-4
0xFFFFF004IDR32Silicon ID register0x560000005-5
0xFFFFF008IODCR16I/O drive control register0x1FFF5-6
0xFFFFF100CSGBA16Chip-select group A base register0x00006-4
0xFFFFF102CSGBB16Chip-select group B base register0x00006-4
0xFFFFF104CSGBC16Chip-select group C base register0x00006-4
0xFFFFF106CSGBD16Chip-select group D base register0x00006-4
0xFFFFF108CSUGBA16Chip-select upper group address
register
0xFFFFF10ACSCR16Chip-select control register0x00006-16
0xFFFFF110CSA16Group A chip-select register0x00B06-8
0xFFFFF112CSB16Group B chip-select register0x00006-8
0x00006-6
Page
Number
0xFFFFF114CSC16Group C chip-select register0x00006-8
0xFFFFF116CSD16Group D chip-select register0x02006-8
0xFFFFF118EMUCS16Emulation chip-select register0x00606-16
0xFFFFF200PLLCR16PLL control register0x24B34-8
0xFFFFF202PLLFSR16PLL frequency select register0x03474-10
0xFFFFF204RES—Reserved——
0xFFFFF207PCTLR8Power control register0x1F4-14
0xFFFFF300IVR8Interrupt vector register0x009-7
0xFFFFF302ICR16Interrupt control register0x00009-8
0xFFFFF304IMR32Interrupt mask register0x00FFFFFF9-10
0xFFFFF308RES32Reserved——
0xFFFFF30CISR32Interrupt status register0x000000009-12
3-2MC68VZ328 User’s Manual
Programmer’s Memory Map
Table 3-1. Programmer’s Memory Map (Sorted by Address) (Continued)
AddressNameWidthDescriptionReset Value
0xFFFFF310IPR32Interrupt pending register0x000000009-16
0xFFFFF314ILCR16Interrupt level control regi ste r0x65339 -19
0xFFFFF400PADIR8Port A direction register 0x0010-6
0xFFFFF401PADATA8Port A data register0xFF10-6
0xFFFFF402PAPUEN8Port A pull-up enable register0xFF10-6
0xFFFFF403RES8Reserved ——
0xFFFFF408PBDIR8Port B direction register 0x0010-8
0xFFFFF409PBDATA8Port B data register 0xFF10-8
0xFFFFF40APBPUEN8Port B pull-up enable register0xFF10-8
0xFFFFF40BPBSEL8Port B select register0xFF10-8
0xFFFFF410PCDIR8Port C direction register 0x0010-11
0xFFFFF411PCDATA8Port C data register 0x0010-11
0xFFFFF412PCPDEN8Port C pull-down enable register0xFF10-11
Page
Number
0xFFFFF413PCSEL8Port C select register0xFF10-11
0xFFFFF418PDDIR8Port D direction register 0x0010-16
0xFFFFF419PDDATA8Port D data register 0xFF10-16
0xFFFFF41APDPUEN8Port D pull-up enable register0xFF10-16
0xFFFFF41BPDSEL8Port D select register0xF010-16
0xFFFFF41CPDPOL8Port D polarity register0x0010-16
0xFFFFF41DPDIRQEN8Port D interrupt request enable
register
0xFFFFF41EPDKBEN8Port D keyboard enable register0x0010-16
0xFFFFF41FPDIRQEG8Port D interrupt request edge register0x0010-16
0xFFFFF420PEDIR8Port E direction register 0x0010-21
0xFFFFF421PEDATA8Port E data register0xFF10-21
0xFFFFF422PEPUEN8Port E pull-up enable register0xFF10-21
0xFFFFF423PESEL8Port E select register 0xFF10-21
0xFFFFF428PFDIR8Port F direction register 0x0010-24
0x0010-16
0xFFFFF429PFDATA8Port F data register0xFF10-25
Memory Map3-3
Programmer’s Memory Map
Table 3-1. Programmer’s Memory Map (Sorted by Address) (Continued)
AddressNameWidthDescriptionReset Value
0xFFFFF42APFPUEN8Port F pull-up/pull-down enable
register
0xFFFFF42BPFSEL8Port F select register 0x8710-27
0xFFFFF430PGDIR8Port G direction register 0x0010-28
0xFFFFF431PGDATA8Port G data register0x3F10-28
0xFFFFF432PGPUEN8Port G pull-up enable register0x3D10-30
0xFFFFF433PGSEL8Port G select register 0x0810-31
0xFFFFF438PJDIR8Port J direction register 0x0010-31
0xFFFFF439PJDATA8Port J data register0xFF10-32
0xFFFFF440PKDIR8Port K direction register 0x0010-34
0xFFFFF441PKDATA8Port K data register0x0F10-35
0xFF10-27
Page
Number
0xFFFFF442PKPUEN8Port K pull-up/pull-down enable
register
0xFFFFF443PKSEL8Port K select register 0xFF10-36
0xFFFFF448PMDIR8Port M direction register 0x0010-37
0xFFFFF449PMDATA8Port M data register0x2010-38
0xFFFFF44APMPUEN8Port M pull-up/pull-down enable regis-
ter
0xFFFFF44BPMSEL8Port M select register 0x3F10-40
0xFFFFF500PWMC116PWM unit 1 control register0x002015-4
0xFFFFF502PWMS116PWM unit 1 sample register 0xxxxx15-6
0xFFFFF504PWMP18PWM unit 1 period register 0xFE15-7
0xFFFFF505PWMCNT18PWM unit 1 counter register 0x0015-7
0xFFFFF506RES16Reserved ——
0xFFFFF510PWMC216PWM unit 2 control register0x000015-8
0xFFFFF512PWMP216PWM unit 2 period register 0x000015-9
0xFF10-36
0x3F10-39
0xFFFFF514PWMW216PWM unit 2 width register 0x000015-10
0xFFFFF516PWMCNT216PWM unit 2 counter register 0x000015-10
3-4MC68VZ328 User’s Manual
Programmer’s Memory Map
Table 3-1. Programmer’s Memory Map (Sorted by Address) (Continued)
AddressNameWidthDescriptionReset Value
0xFFFFF600TCTL116Timer unit 1 control register 0x000012-6
0xFFFFF602TPRER116Timer unit 1 prescaler register 0x000012-8
0xFFFFF604TCMP116Timer unit 1 compare register 0xFFFF12-9
0xFFFFF606TCR116Timer unit 1 capture register 0x000012-10
0xFFFFF608TCN116Timer unit 1 counter register0x000012-11
0xFFFFF60ATSTAT116Timer unit 1 status register0x000012-12
0xFFFFF610TCTL216Timer unit 2 control register 0x000012-6
0xFFFFF612TPRER216Timer unit 2 prescaler register 0x000012-8
0xFFFFF614TCMP216Timer unit 2 compare register 0xFFFF12-9
0xFFFFF616TCR216Timer unit 2 capture register 0x000012-10
0xFFFFF618TCN216Timer unit 2 counter register0x000012-10
0xFFFFF61ATSTAT216Timer unit 2 status register0x000012-12
0xFFFFF700SPIRXD16SPI unit 1 receive data register0x000013-4
Page
Number
0xFFFFF702SPITXD16SPI unit 1 transmit data register0x000013-5
0xFFFFF704SPICONT116SPI unit 1 control/status register0x000013-6
0xFFFFF706SPIINTCS16SPI unit 1 interrupt control/status
register
0xFFFFF708SPITEST16SPI unit 1 test register0x000013-10
0xFFFFF70ASPISPC16SPI unit 1 sample period control
register
0xFFFFF800SPIDATA216SPI unit 2 data register0x000013-14
0xFFFFF802SPICONT216SPI unit 2 control/status register0x000013-15
0xFFFFF900USTCNT116UART unit 1 status/control register0x000014-10
0xFFFFF902UBAUD116UART unit 1 baud control register0x003F14-12
0xFFFFF904URX116UART unit 1 receiver register0x000014-13
0xFFFFF906UTX116UART unit 1 transmitter register0x000014-14
0xFFFFF908UMISC116UART unit 1 miscellaneous register0x000014-16
0xFFFFF90ANIPR116UART unit 1 non-integer prescaler
register
0x000013-8
0x000013-11
0x000014-18
0xFFFFF910USTCNT216UART unit 2 status/control register0x000014-10
Memory Map3-5
Programmer’s Memory Map
Table 3-1. Programmer’s Memory Map (Sorted by Address) (Continued)
AddressNameWidthDescriptionReset Value
0xFFFFF912UBAUD216UART unit 2 baud control register0x003F14-12
0xFFFFF914URX216UART unit 2 receiver register0x000014-13
0xFFFFF916UTX216UART unit 2 transmitter register0x000014-14
0xFFFFF918UMISC216UART unit 2 miscellaneous register0x000014-16
0xFFFFF91ANIPR216UART unit 2 non-integer prescaler
register
0xFFFFF91CHMARK16UART unit 2 FIFO half mark register0x010214-29
0xFFFFFA00LSSA32LCD screen starting address register0x000000008-10
0xFFFFFA05LVPW8LCD virtual page width register0xFF8-11
0xFFFFFA08LXMAX16LCD screen width register0x03F08-12
0xFFFFFA0ALYMAX16LCD screen height register0x01FF8-12
0xFFFFFA18LCXP16LCD cursor X position register0x00008-12
0xFFFFFA1ALCYP16LCD cursor Y position register0x00008-13
0x000014-18
Page
Number
0xFFFFFA1CLCWCH16LCD cursor width and height register0x01018-14
0xFFFFFA1FLBLKC8LCD blink control register0 x7F8-14
0xFFFFFA20LPICF8LCD panel interface configuration
0xFFFFFA2DLPOSR8LCD panning offset register0x008-19
0xFFFFFA31LFRCM8LCD frame rate control modulation
register
0xFFFFFA33LGPMR8LCD gray palette mapping register0x848-20
0xFFFFFA36PWMR16PWM contrast control register0x00008-20
0x008-15
0x008-19
0xFFFFFA38RMCR8Refresh mode control register0x008-21
0xFFFFFA39DMACR8DMA control register0x628-22
3-6MC68VZ328 User’s Manual
Programmer’s Memory Map
Table 3-1. Programmer’s Memory Map (Sorted by Address) (Continued)
AddressNameWidthDescriptionReset Value
0xFFFFFB00RTCTIME32RTC time of day register0xXXXX00XX11-3
0xFFFFFB04RTCALRM32RTC alarm register0x0000000011-3
0xFFFFFB0AW ATCHDOG16Watchdog tim er registe r0x00 0111-4
0xFFFFFB0CRTCCTL8RTC control register0x008011-10
0xFFFFFB0ERTCISR16RTC interrupt status register 0x 00 0011-10
0xFFFFFB10RTCIENR16RTC interrupt enable register0x000011-12
0xFFFFFB12STPWCH8Stopwatch minutes register0x003F11-14
0xFFFFFB1ADAYR16RTC day count registe r0x0xxx11-6
0xFFFFFB1CDAYALARM16RTC day alarm register0x000011-8
0xFFFFFC00DRAMMC16DRAM memory configuration register0x00007-12
0xFFFFFC02DRAMC16DRAM control register0x00007-14
0xFFFFFC04SDCTRL16SDRAM control register0x003C7-16
0xFFFFFC06SDPWDN16SDRAM power down register0x00007-18
0xFFFFFD0AICEMCMR16ICEM control mask register0x000016-6
0xFFFFFD0CICEMCR16ICEM control register0x000016-8
0xFFFFFD0EICEMSR16ICEM status r eg ister0x000016-10
Table 3-2. Programmer’s Memory Map (Sorted by Register Name)
NameAddressWidthDescriptionReset Value
Bootloader0xFFFFFExx—Bootloader micro cod e s pa ce——
CSA0xFFFFF11016Group A chip-select register0x00B06-8
CSB0xFFFFF11216Group B chip-select register0x00006-8
CSC0xFFFFF11416Group C chip-select register0x00006-8
CSCR0xFFFFF10A16Chip-select control register0x00006-16
CSD0xFFFFF11616Group D chip-select register0x02006-8
CSGBA0xFFFFF10016Chip-select group A base register0x00006-4
CSGBB0xFFFFF10216Chip-select group B base register0x00006-4
CSGBC0xFFFFF10416Chip-select group C base register0x00006-4
CSGBD0xFFFFF10616Chip-select group D base register0x00006-4
CSUGBA0xFFFFF10816Chip-select upper group address
register
DAYALARM0xFFFFFB1C16RTC day alarm register0x000011-8
0x00006-6
Page
Number
DAYR0xFFFFFB1A16RTC day count regis te r0x0xxx11-6
DMACR0xFFFFFA398DMA control register0x628-22
DRAMC0xFFFFFC0216DRAM control register0x00007-14
NIPR10xFFFFF90A16UART unit 1 non-integer prescaler
register
NIPR20xFFFFF91A16UART unit 2 non-integer prescaler
register
PADATA0xFFFFF4018Port A data register0xFF10-6
PADIR0xFFFFF4008Port A direction register 0x0010-6
0x008-15
0x000014-18
0x000014-18
PAPUEN0xFFFFF4028Port A pull-up enable register0xFF10-6
PBDATA0xFFFFF4098Port B data register 0xFF10-8
Memory Map3-9
Programmer’s Memory Map
Table 3-2. Programmer’s Memory Map (Sorted by Register Name) (Continued)
NameAddressWidthDescriptionReset Value
PBDIR0xFFFFF4088Port B direction register 0x0010-8
PBPUEN0xFFFFF40A8Port B pull-up enable register0xFF10-8
PBSEL0xFFFFF40B8Port B select register0xFF10-8
PCDATA0xFFFFF4118Port C data register 0x0010-11
PCDIR0xFFFFF4108Port C direction register 0x0010-11
PCPDEN0xFFFFF4128Port C pull-down enable register0xFF10-11
PCR0xFFFFF0038Peripheral control register0x005-4
PCSEL0xFFFFF4138Port C select register0xFF10-11
PCTLR0xFFFFF2078Power control register0x1F4-14
PDDATA0xFFFFF4198Port D data register 0xFF10-16
PDDIR0xFFFFF4188Port D direction register 0x0010-16
PDIRQEG0xFFFFF41F8Port D interrupt request edge register0x0010-16
PDIRQEN0xFFFFF41D8Port D interrupt request enable
register
0x0010-16
Page
Number
PDKBEN0xFFFFF41E8Port D keyboard enable register0x0010-16
PDPOL0xFFFFF41C8Port D polarity register0x0010-16
PDPUEN0xFFFFF41A8Port D pull-up enable register0xFF10-16
PDSEL0xFFFFF41B8Port D select register0xF010-16
PEDATA0xFFFFF4218Port E data register0xFF10-21
PEDIR0xFFFFF4208Port E direction register 0x0010-21
PEPUEN0xFFFFF4228Port E pull-up enable register0xFF10-21
PESEL0xFFFFF4238Port E select register 0xFF10-21
PFDATA0xFFFFF4298Port F data register0xFF10-25
PFDIR0xFFFFF4288Port F direction register 0x0010-24
PFPUEN0xFFFFF42A8Port F pull-up/pull-down enable
register
PFSEL0xFFFFF42B8Port F select register 0x8710-27
PGDATA0xFFFFF4318Port G data register0x3F10-28
PGDIR0xFFFFF4308Port G direction register 0x0010-28
0xFF10-27
PGPUEN0xFFFFF4328Port G pull-up enable register0x3D10-30
3-10MC68VZ328 User’s Manual
Programmer’s Memory Map
Table 3-2. Programmer’s Memory Map (Sorted by Register Name) (Continued)
NameAddressWidthDescriptionReset Value
PGSEL0xFFFFF4338Port G select register 0x0810-31
PJDATA0xFFFFF4398Port J data register0xFF10-32
PJDIR0xFFFFF4388Port J direction register 0x0010-31
PKDIR0xFFFFF4408Port K direction register 0x0010-34
PKPUEN0xFFFFF4428Port K pull-up/pull-down enable
register
PKSEL0xFFFFF4438Port K select register 0xFF10-36
PLLCR0xFFFFF20016PLL control register0x24B34-8
PLLFSR0xFFFFF20216PLL frequency select register0x03474-10
PMDATA0xFFFFF4 498Port M data register0x2010-38
0xFF10-36
Page
Number
PMDIR0xFFFFF4488Port M direction register 0x0010-37
PMPUEN0xFFFFF44A8Port M pull-up/pull-down enable
register
PMSEL0xFFFFF44B8Port M select register 0x3F10-40
PWMC10xFFFFF50016PWM unit 1 control register0x002015-4
PWMC20xFFFFF51016PWM unit 2 control register0x000015-8
PWMCNT10xFFFFF5058PWM unit 1 counter register 0x0015-7
PWMCNT20xFFFFF51616PWM unit 2 counter regist er 0x000015-10
PWMP10xFFFFF5048PWM unit 1 period register 0xFE15-7
PWMP20xFFFFF51216PWM unit 2 period register 0x000015-9
PWMR0xFFFFFA3616PWM contrast control register0x00008-20
PWMS10xFFFFF50216PWM unit 1 sample register 0xxxxx15-6
PWMW20xFFFFF51416PWM unit 2 width register 0x000015-10
RTCIENR0xFFFFFB1016RTC interrupt enable regi st er0x000011-12
RTCISR0xFFFFFB0E16RTC interrupt status register 0x000011-10
RTCTIME0xFFFFFB0032RTC time of day register0xXXXX00XX11-3
SCR0xFFFFF0008System control register0x1C5-2
SDCTRL0xFFFFFC041 6SDRAM control register0x003C7-16
SDPWDN0xFFFFFC0616SDRAM power down register0x00007-18
SPICONT10xFFFFF70416SPI unit 1 control/status register0x000013-6
SPICONT20xFFFFF80216SPI unit 2 control/status register0x000013-15
Page
Number
SPIDATA20xFFFFF80016SPI unit 2 data register0x000013-14
SPIINTCS0xFFFFF70616SPI unit 1 interrupt control/status
register
SPIRXD0xFFFFF70016SPI unit 1 receive data register0x000013-4
SPISPC0xFFFFF70A16SPI unit 1 sample period control
register
SPITEST0xFFFFF70816SPI unit 1 test register0x000013-10
SPITXD0xFFFFF70216SPI unit 1 transmit data register0x000013-5
TCMP10xFFFFF60416Timer unit 1 compare register 0xFFFF12-9
TCMP20xFFFFF61416Timer unit 2 compare register 0xFFFF12-9
TCN10xFFFFF60816Timer unit 1 counter register0x000012-11
TCN20xFFFFF61816Timer unit 2 counter register0x000012-10
TCR10xFFFFF60616Timer unit 1 capture register 0x000012-10
TCR20xFFFFF61616Timer unit 2 capture register 0x000012-10
0x000013-8
0x000013-11
TCTL10xFFFFF60016Timer unit 1 control register 0x000012-6
TCTL20xFFFFF61016Timer unit 2 control register 0x000012-6
3-12MC68VZ328 User’s Manual
Programmer’s Memory Map
Table 3-2. Programmer’s Memory Map (Sorted by Register Name) (Continued)
NameAddressWidthDescriptionReset Value
TPRER10xFFFFF60216Timer unit 1 prescaler register 0x000012-8
TPRER20xFFFFF61216Timer unit 2 prescaler register 0x000012-8
TSTAT10xFFFFF60A16Timer unit 1 status register0x000012-12
TSTAT20xFFFFF61A16Timer unit 2 status register0x000012-12
UBAUD10xFFFFF90216UART unit 1 baud control register0x003F14-12
UBAUD20xFFFFF91216UART unit 2 baud control register0x003F14-12
UMISC10xFFFFF90816UART unit 1 miscellaneous register0x000014-16
UMISC20xFFFFF91816UART unit 2 miscellaneous register0x000014-16
URX10xFFFFF90416UART unit 1 receiver register0x000014-13
URX20xFFFFF91416UART unit 2 receiver register0x000014-13
USTCNT10xFFFFF90016UART unit 1 status/control register0x000014-10
USTCNT20xFFFFF91016UART unit 2 status/control register0x000014-10
UTX10xFFFFF90616UART unit 1 transmitter register0x000014-14
Page
Number
UTX20xFFFFF91616UART unit 2 transmitter register0x000014-14
This chapter describes the clock generation module (CGM) and power control module (PCM). The
description of both modules comprises a single chapter because their operation is so closely integrated.
The programmability of the individual clock signals makes the CGM a flexible clock source for the
MC68VZ328 and its associated peripherals.
The CGM uses a low-frequency oscillator in conjunction with a multiplier/divider chain to produce the
clock signals used throughout the MC68VZ328 integrated processor. The frequency of all clock signals
(except the low-frequency reference) are individually selectable through software control. The
MC68VZ328 has four different power modes to provide optimum power efficiency.
The PCM controls the power consumption of the CPU by applying clock signals to the CPU at reduced
burst widths. For maximum power savings, the MC68VZ328 can be placed in sleep mode in which all
clocks (except for the low-frequency clock) are disabled.
NOTE:
The CGM module is designated as the PLL module in earlier versions of
the DragonBa ll family. The nomenclatu re change d from PLL to CGM to
be consistent with Motorola naming and standards conventions. The term
PLL is used only to describe the actual PLL circuit within the CGM.
Clock Generation Module and Power Control Module4-1
Introduction to the Clock Generation Module
4.1 Introduction to the Clock Generation Module
The CGM produces four clock signals:
•CLK32—A low-frequency reference clock used by almost every module
•DMACLK—Used to create the remaining two clocks, and serves as DMA clock for the LCD
controller
•SYSCLK—Used by most modules, including the CPU
•LCDCLK—Used as reference by the LCD
The distribution of the clock signals generated by the CGM is shown in Table 4-1. With the exception of
the CLK32 signal, the frequency of the clock signals can be individually programmed.
The CGM consists of six major parts, as shown in the simplified block diagram in Figure 4-1. The clock
source for the CGM is a crystal oscillator that is comprised of an external crys tal connected to the internal
XTAL oscillator circuit. The output of the XTAL oscillator is the CLK32 signal, whose frequency is
determined by the frequency of the external crystal. The CLK32 clock signal serves as a source for the
PLL and many other modules within the MC68VZ328.
The output frequency of the PLL (PLLCLK) is determined by the frequency of CLK32 and by the values
of the PC and QC fields of the PLL frequency select register (PLLFSR). The output of the PLL is applied
to a divider chain comp osed of two pr escal ers. The PLLCLK cl ock is fi rst in put i nto pres caler 1. Its output
frequency is selected by the prescaler select 1 (PRESC1) bit in the PLLCR. The output of the prescaler 1
(PR1CLK) is applied to prescaler 2, whose output frequency (DMACLK) is controlled by the prescaler
select 2 (PRESC2) bit in the PLLCR. The DMACLK signal is applied to the LCD controller in the
MC68VZ328 and also serves as the clock source for the LCD clock divider and the SYSCLK divider.
The output of the LCD clock divider is LCDCLK, whose frequency is controlled by the LCD clock
selection (LCDCLK) field in the PLLCR. The LCDCLK signal is only used by the LCD controller. The
SYSCLK divider produces a SYSCLK clock signal that is used throughout the MC68VZ328. SYSCLK is
also used as the CPU clock signal (CPUCLK) by the internal FLX68000 CPU. SYSCLK is the only
CGM-generated clock signal that can be made available to external devices via the buffered output of the
clock out/Port F bit 2 pin (CLKO/PF2). See Section 10.4.7.3, “Port F Dedicated I/O Functions,” on
page 10-26 for more information. The output is available when the clock enable bit of the PLLCR is
enabled and bit 2 in the Port F select register (PFSEL) is cleared.
Clock Generation Module and Power Control Module4-3
Detailed CGM Clock Descriptions
4.3 Detailed CGM Clock Descriptions
Section 4.3.1, “CLK32 Clock Signal,” and Section 4.3.2, “PLLCLK Clock Signal,” describe in detail the
operation of each clock signal produced by the CGM.
4.3.1 CLK32 Clock Signal
The low-frequency output of th e XTAL oscil lato r (CLK32) i s avai lable withi n a few hun dred mil lise conds
after initial power is applied to the circuit. The frequency of the CLK32 signal is determined by the
frequency of the external crystal. The CGM supports either a 32.768 kHz or a 38.4 kHz crystal.
NOTE:
Regardless of the crystal frequency used, the output is always labeled
CLK32.
Figure 4-2 represents a suggestion of how a crystal may be connected to the MC68VZ328. The values of
C1 and C2 in Figure 4-2 are determined by using the crystal load capaci tance (CL) , PCB stray capacit ance,
Cstray (measured or a ppr oxi mate d), and DragonBall input capa ci tan ce ( C dbvz << 1.0 pf) according to the
following fo rmula:
CL = Cstray + Cdbvz + (C1 * C2) / (C1 + C2)
Eqn. 4-1
Typical design values are C1 = C2 = 20 pf. The user should consult the crystal manufacturer for
appropriate circuit layout and circuit values.
The CLK32 clock signal is uni que in t hat whil e the o ther clock sources are dis abled whe n the MC68VZ328
is placed in sleep mode, the CLK32 clock is available as long as power is applied. See Section 4.5.1.4,
“Sleep Mode,” for detailed information on sleep mode.
MC68VZ328
EXTAL
Crystal
32.768 kHz or
38.4 kHz
XTAL
C1*
Figure 4-2. Example of External Crystal Connection
C2*
*See Equation 4-1 for design values.
4.3.2 PLLCLK Clock Signal
The PLL output frequency, PLL clock (PLLCLK), is determined by a combination of the CLK32 signal’s
input frequency and the values in the PC and QC fields of the PLLFSR. Section 4.3.2.2, “PLL Frequency
Selection,” describes the procedure for frequency selection.
4-4MC68VZ328 User’s Manual
Detailed CGM Clock Descriptions
4.3.2.1 PLLCLK Initial Power-up Sequence
Refer to Figure 4-3 for a graphical representation of the following power-up sequence description. When
power is init ially applied to the MC68VZ328, the XTAL oscillator begins to oscillate. Due to the
low-power design on the oscillator pads, the RESET
ensure that the cryst al oscil lato r st arts and stabil izes. Thi s is a signifi cant cha nge from the 250 ms required
with the previous DragonBall and DragonBall EZ processors. The length of the delay (1.2 s) is an
approximate value and should only be used as a starting point. The RESET
device with a threshold of 1.4 V high and 1.0 V low.
On power up, the RESET signal should be deasserted after the crystal has
energized and its output has stabil ized, as sh own in Figure 4-3. While most
crystal oscillators typically operate with a value of 1.2 seconds, the
optimum value will be determined experimentally. Due to the inherent
nature of crystals, refer to manufacturers documentation for optimum
circuit design information.
signal must be asserted (low) for at least 1.2 s to
pin (input) is a Schmitt trigger
NOTE:
After RESET
is deasserted, the PLLCLK signal is available to the divider chain, resulting in the
availability of DMACLK from prescaler 2.
V
DD
XTAL OSC
RESET
DMACLK
Figure 4-3. Initial Power-up Sequence Timing
1.2 s
Clock Generation Module and Power Control Module4-5
Detailed CGM Clock Descriptions
4.3.2.2 PLL Frequency Selection
Using the default settings for the PC and QC fields of the PLLFSR and a CLK32 input frequency of
32.768 kHz produces a PLLCLK output of 66.322 MHz. For a 38.400 kHz crystal, the same default
settings produce a 77.722 M Hz PLLCLK. The PLLCLK clock is phase locked to the CLK32 clock input
signal.
WARNING:
The value of prescaler 1 must always be set to divide-by-two to prevent
DMACLK and SYSCLK from operating beyond their design limits.
The PLL uses a dual-modulus counter to multiply the CLK32 frequency before it is input to the prescaler
and the rest of t he divider chain. Du al -modul us counters opera te di ff erently from other c ounters in that the
overall multiplication ratio depends on two separate values, PC and QC.
In the follow ing equation, the value of Q is defined as 1 <
Q+1.
P>
Multiplier2 14 P1+
For example, if Q = 3 and P = 71, then the following equations obtain:
The default multiplier value is 2024. Using any multiplier equal to or greater than 794 (decimal) allows
changing the PLLCLK in 32.768 kHz or 38.4 kHz steps. The minimum PC and QC values are P = 0x1B
and Q = 0x04 (which produce a multiplier of 794 decimal
=
()
()
Q<14, and the value of P is defined as
Q1++
).
Eqn. 4-2
4.3.2.3 PLLCLK Frequency Selection Programming Example
Example 4-1 on page 4-7 demonstrates the recommended sequence of events to change the PLLCLK
frequency. The assumptions are:
•All peripherals have been disabled using chip-select. See Chapter 6, “Chip-Select Logic,” for
details.
•SYSCLK is operating at the highest possible frequency (SYSCLK SEL = 100).
In Example 4-1, the variable NEWFREQ is the new frequency value (P and Q values) to be programmed.
The MC68VZ328 is placed in sleep mode before the stop command. See Section 4.5.1.4, “Sleep Mode,”
for detailed information about sleep modes. This routine enables the timer to wake up the PLL after 96
CLK32 periods. When the P LL wake s up, it will be at the new frequency. The inte rr upt se rvi ce routine for
the temporary timer interrupt should clear the timer interrupt and then return. In addition, the PLLCLK
should only be changed during an early phase of the boot-up sequence.
NOTE:
Example 4-1 is designed for clarity, and is not necessarily efficient.
4-6MC68VZ328 User’s Manual
Detailed CGM Clock Descriptions
Example 4-1. Configuring the PLLCLK Frequency
NEWFREQ equ somevalue;P and Q value of new f requency
PLLCONTROL equ $FFFFF200;PLL Control Register
PLLFREQ equ $FFFFF202;P LL Frequency Control Register
TCOMPARE equ $FFFFF604;Timer Compare Value Register
TCONTROL equ $FFFFF600;Timer Control Register
IMR equ $FFFFF304;Interrupt Mask Register
move.l IMR,-(SP);save the Interrupt Mask register
move.l #$fffffffd,IMR;enable ONLY Timer interrupt
move.w #$0001,TCOMPARE;set compare value to 2
move.w #$0119,TCONTROL;enable Timer 2 with CLK32 s ource
SYNC1btst.b #$7,PLLFREQ;synchronize to CLK32 high level
SYNC2btst.b #$7,PLLFREQ;synchronize to CLK32 low level
; the PLL shuts down here an d waits for the Timer interrupt
; interrupt service for Time r occurs here
; The PLL has reacquired loc k and SYSCLK is stabl e
beq.s SYNC 1;CLK32 is still not high, go back
bne.s SYNC2;CLK32 is still not low, go back
move.w #NEWFREQ,PLLFREQ;load the new frequency
ori.b #$8,PLLCONTROL+1;disable the PLL (in 30 cloc ks)-sleep mode
stop #$2000;stop, enable all interrupts
move.w (SP)+,IMR ;restore the Interrupt Mask Register
rts ;PLL is now at the new frequency
4.3.2.4 Programming Considerations When Changing Frequencies
The following information is provided to assist the user in programming the MC68VZ328.
•When programming the SYSCLK frequenc y, ensure that it does not e xceed 33.161 216 MHz at any
time.
•Since the PRESC1 and PRESC2 bits are set to %1 by default, the DMACLK output is
approximately 16 MHz.
•Because most of the modules—such as the U AR T , SPI, gene ral-purpose timers, and PWM—use t he
SYSCLK for bit-rate generation, changi ng the PLLCLK fr equenc y will also cha nge SYSCLK and
overall system timing (except for CLK32). Therefore, once a PLLCLK frequency is selected, it
should not be changed during system operation.
•To reduce power consumption, the output of the PLL can be disabled using the DISPLL bit in the
PLL control register, which places the chip in sleep mode. See Section 4.5.1.4, “Sleep Mode,” for
more details. When the MC68VZ328 is awakened from sleep mode by a wake-up event, the PLL
output (PLLCLK) is available after a delay determined by the setting in the WKSEL field of
PLLCR. Unlike the initial power-up sequence, the crystal oscillator is already on, so the crystal
startup time is not a factor.
Clock Generation Module and Power Control Module4-7
CGM Programming Model
4.4 CGM Programming Model
This section describes the two registers that enable and control the frequency of the CGM clocks.
4.4.1 PLL Control Register
The PLL control register (PLLCR) controls the frequency selection of the LCDCLK, SYSCLK, and
DMACLK. It also enables the output of the PLL and clock out/Port F pin 2 (CLKO/PF2). The settings for
each bit and field in the register are described in Table 4-2.
PLLCRPLL Control Register0xFFFFF200
BIT
1413121110987654321
15
LCDCLK SELSYSCLK SELPRESC1PRESC2CLKENDISPLLWKSEL
TYPE
RESET
0 01001001 0 110 011
rwrwrwrwrwrwrwrwrwrwrwrw
0x24B3
Table 4-2. PLL Control Register Description
Name Description Setting
Reserved
Bits 15–14
LCDCLK SEL
Bits 13–11
SYSCLK SEL
Bits 10–8
ReservedThese bits are reserved and should be set to
0.
LCD Clock Select—This field controls the
divide ratio used by the LCD clock divider to
convert DMACLK to LCDCLK. This field can
be changed at any time.
System Clock Select—This field controls the
divide ratio used by the SYSCLK divider to
convert DMACLK to SYSCLK. This field can
be changed at any time.
Prescaler 1 Select—T his bit sel ects the di vide
ratio of the prescaler 1.
ReservedThis bit is reserved and should be set to 0.
Prescaler 2 Select—T his bit sel ects the di vide
ratio used by the prescaler 2 to divide the output of prescaler 1, producing DMACLK. This
field can be changed at any time.
Clock Enable—This bit enable s the buf fered
output of the SYSCLK at the CLKO/PF2 pin
when bit 2 of the PFSEL register is als o
cleared.
0 = PLLCLK ÷ 1.
1 = PLLCLK ÷ 2 (default).
0 = PR1CLK ÷ 1.
1 = PR1CLK ÷ 2 (default).
0 = CLKO enabled.
1 = CLKO disabled (defaul t).
4-8MC68VZ328 User’s Manual
CGM Programming Model
Table 4-2. PLL Control Register Description (Continued)
Name Description Setting
DISPLL
Bit 3
Reserved
Bit 2
WKSEL
Bits 1–0
Disable PLL—This bit, when set , disables the
output of the PLL, placing the chip in sleep
mode, its low est power state.
ReservedThis bit is reserved and should be set to 0.
Wake-up Clock Select — Thi s field se lects the
delay of the PLL output from the initiation of
the wake up until an output is available. Since
the delay time is calc ulated by coun ting CLK32
cycles, the frequency of the crystal oscillator
will determine the amount of delay that each
setting produces.
Clock Generation Module and Power Control Module4-9
Introduction to the Power Control Module
4.4.2 PLL Frequency Select Register
The PLL frequency select regis ter (PLLFSR) cont rols the two di viders of th e dual-modulus counter. It also
contains the write-protect bit for the QC and PC counters and the CLK32 status bit. Although PLLFSR
register can be acc essed in byt es, it should al ways be writt en as a 16- bit wor d. T he set tings for each bit an d
field in the register is described in Table 4-4.
PLLFSRPLL Frequency Select Register0x(FF)FFF202
BIT 15 14 13 12 11 10 987654321BIT 0
CLK32PROT
TYPErrw*
RESET
000 0 0 0 110100011 1
*This bit can be set by software but is cleared only by reset.
rwrwrwrwrwrwrwrwrwrwrwrw
Table 4-4. PLL Frequency Select Register Settings
Name Description Setting
QCPC
0x0347
CLK32
Bit 15
PROT
Bit 14
Reserved
Bits 13–12
QC
Bits 11–8
PC
Bits 7–0
Clock32 Status—This read-only bit indicates
the status of the CLK32 clock signal. The bit
switches with each cycle of the CLK32 clock.
Protect Bit—This bit write protects the QC
and PC fields of the PLLFSR. After this bit is
set by software, the register is write protected
until a reset clears this bit.
ReservedThese bits are reserved and must remain at
Q Counter—This field contains the Q value
that is used by the PLL to produce the
PLLCLK.
P Counter—This field contains the P value
that is used by the PLL to produce the
PLLCLK.
0 = CLK32 low.
1 = CLK32 high.
0 = PLLFSR is not protect ed.
1 = PLLFSR is write protected.
their default value.
Field value range is 1 <
Field value range is P >
Q<14.
Q+1.
4.5 Introduction to the Power Control Module
The purpose of the power control module (PCM) is to optimize the power consumption of the FLX68000
CPU by turning the CPU off for a programmed number of clock pulses. The CPU consumes more power
than any comp onent in the MC68VZ328, so to conserve power while the CPU is relatively idle, the PCM
can disable the CPU clock or apply the clock in bursts. When the MC68VZ328 is in one of these
reduced-power modes, it is restored to normal operation by a wake-up eve nt. When this occ urs, the clock is
immediately enabled, allowing the CPU to service the request. The DMA controller is not affected by the
PCM having full access to the bus while the CPU is idle, keeping the LCD screen refreshed.
4-10MC68VZ328 User’s Manual
Introduction to the Power Control Module
4.5.1 Operating the PCM
The power control mod ule has f our modes of operation: normal, burst, d oze and sl eep. In nor mal mode, the
PCM is off. The MC68VZ328 enters burst mode when the PCM is enabled. In burst mode, the PCM
controls the burst width of the CPUCLK signal to the CPU. If the burst width of the CPU clock is reduced
to zero, CPUCLK is disabled and the MC68VZ328 is in doze mode. The lowest power mode setting is
sleep mode. It is entered by setting the disable PLL (DISPLL) bit in the PLLCR, which disables the PLL
and thus disables ev ery clo ck si gnal i n the CGM ex cep t CLK32. Section 4.5.1.1, “Normal Mode,” through
Section 4.5.1.4, “Sleep Mode,” give detailed information about each of the four power modes.
4.5.1.1 Normal Mode
After reset, the PCM is disabled, the CPU clock runs continuously, and the MC68VZ328 consumes
maximum power. This is normal mode.
4.5.1.2 Burst Mode
Setting the PCEN bit in the power control register (PCTRL) enables the PCM, causing the clock burst
width of the CPU clock to be under the control of the PCTLR WIDTH settings in increments of 3 percent
(one thirty-first of a cycle). Initially, the burst width is set to 100 percent. Software can then change the
burst width to a lower value, and the clock is applied t o th e CPU in bur st s. The burs t-width register can be
programmed for burst widths of any value between zero thirty-firsts and thirty-one thirty-firsts. This
effectively produce s a sys te m clock with a variable burst width (an d power dis si pation) between 3 percent
and 100 pe rcent in incremental steps of 3 percent.
When the PCM is enabled, if a wake-up event is received, the PCM is immediately disabled, restoring the
continuous CPU clock. It is the responsibility of the wake-up service routine to reenable the PCM.
4.5.1.3 Doze Mode
Setting the width fiel d of PCTLR to %00000 reduces the burs t width of the CPU clock to zer o, causi ng the
MC68VZ328 to enter doze mode. As with burst mode, the CPUCLK is immediately enabled when it
receives a wake-up event. At the end of the service routine, the PCM can be reenabled with a width of
%00000, putting the CPU back into doze mode. Once the CPU is placed in doze mode, only a wake-up
event or h ardware reset will reenab le it.
NOTE:
The most effective power-control strategy is to run the CPU in normal
mode until CPU action is not needed and then to enter doze mode by
writing 0x80 into the PCTLR. This disables the CPU clock at the earliest
possible moment, but allows the CPU to immediately respond to wake-up
events. The peripheral devices, including the LCD controller, are not
affected by the PCM.
Clock Generation Module and Power Control Module4-11
Introduction to the Power Control Module
4.5.1.4 Sleep Mode
Unlike burst or do ze mode, sleep mode disables all of th e clocks in the MC68VZ328 wit h the exception of
the CLK32. The output of the PLL in th e CGM is disab led in slee p mode through sett ing the DISPLL b it in
the PLLCR register. Only the 32 kHz clock works to keep the real-time clock operational. Wake-up events
activate the PLL, and the system clock starts operating after a delay determined by the WKSEL setting in
the PLLCR.
Other events that occur during sleep mode include:
•All Address Bus signals are in the active state of the last bus cycle.
•All data bus pins (D15–D0) are individually pulled up with 1-megaohm resistors.
•If CLK32 is selected as the c loc k sour ce, the gener al-pu rpo se ti mer oper ates even while the PLL is
in sleep mode.
•The RTC interru pt status register ca n post interrupts while the system clock is in doze or sl eep mode.
4.5.2 CGM Operation During Sleep Mode
Shutting down the PLL to place the system in sleep mode is similar to the process used to change the
frequency. The difference is that the system can be awakened only by a wake-up event or reset. Before
shutting the PLL down, make sure that all peripheral devices are prepared for shutdown. The PLL shuts
down 30 clock cycles of SYSCLK after the DISPLL bit is set in the PLLCR, allowing sufficient time to
execute the stop instruction. When a wake-up event occurs, the PLL is enabled, and after a delay
determined by the WKSEL set ting in th e PLLCR, the PLLCLK begin s, as do as th e rest of the c locks in t he
divider chain of the CGM. The CPU executes an interrupt service routine for the level of the wake-up
event.
After the rte instruction in the wake-up service routine, the CPU returns and starts execution on the
instruction fo ll owing the stop ins tr uct ion. Example 4-2 illustrates a typi cal s hutdown sequence. It assumes
that all peripherals have been shut down before the PLL is stopped.
Example 4-2. Shutdown Example
IRQMASK equ wake-up_mask_lev el
ori.b #$8,PLLCONTROL+1;disable the PLL (in 30 clocks)
stop #IRQMASK ;stop, enable wake-up events
;the PLL shuts down here
;The PLL has reacquired lock and SYSCLK is stable
;interrupt service occurs he re
rts;the system is operating
4.5.3 Burst Mode Operation
Figure 4-4 on page 4-13 shows a simplified block dia gram of the PCM. When operat ing at 100 perc ent, the
SYSCLK input is unaf fecte d by burs t-widt h contr ol appear ing a s CPUCLK fr om the clock control . When a
value has been placed in the width field of the PCTLR, the burst-width control allows the SYSCLK signal
through to the clock control until the CPU clock’s time slot has expired and is to be disabled. At that time
the clock control requests the bus from the CPU. After the bus is granted, the CPUCLK stops. A bus grant
to the DMA controller is asserted, allowing the DMA controller complete access to the bus.
4-12MC68VZ328 User’s Manual
Introduction to the Power Control Module
CLK32
SYSCLK
CPU Bus
Request
Burst-Width
Control
Width
PCTLR
CPU Bus
Grant
CPU Interface
Wake-up
CPU Bus
Control
DMA Bus
Request
Clock
DMA Bus
CPUCLK
Grant
Figure 4-4. Power Control Module Block Diagram
If a wake-up event occurs while CPUCLK is disabled, the PCM is disabled and CPUCLK is immediately
restored, allowing the CPU to process the event. The DMA controller always has priority, so if a DMA
access is in progre ss , the CPU will wait u ntil the DMA cont ro ller has complet ed it s acces s bef ore s erv icing
the wake-up routine. Note that the LCD DMA contro ller has access to the bus at all times and the SYSCLK
(master clock to all peripherals) is continuously active.
Figure 4-5 illustrates how the PCM operates. As described previously, a width setting of %11111
represents 31 peri ods of CLK32, o r approxi mately 1 ms. In this example, th e width se tting i n the PCTLR is
00011. The clock bur sts are a pplie d a t a bu rst widt h of three th irty -fir sts, o r appr oximat ely at 1 0 perc ent on
time, making the CPU active about 10 percent of the time. The remainder of the time, the CPU is in doze
mode. When a wake-up event occurs, CPUCLK immediate ly returns to 100 perce nt so the CPU can service
the wake-up event interrupt.
31 cycles
1 ms
CLK32
PCEN
SYSCLK
Clock Burst Width = %00011
CPUCLK
CPU ActiveCPU In activ eCPU ActiveWake-up EventCPU Inactive
Figure 4-5. Power Control Operation in Burst Mode
EnabledDisabled
CPU Active
Clock Generation Module and Power Control Module4-13
Introduction to the Power Control Module
4.5.4 Power Control Register
The power control register (PCTLR) enabl es the p ower contr ol module and deter mines when t he CPUCLK
signal is applied to the CPU. The settings for each bit and field in the register are described in Table 4-5.
PCTLRPower Control Register0x(FF)FFF207
BIT 7654321BIT 0
PCEN
TYPErw
RESET
00011111
rwrwrwrwrw
0x1F
Table 4-5. Power Control Register Description
Name Description Setting
WIDTH
PCEN
Bit 7
Reserved
Bits 6–5
WIDTH
Bits 4–0
Power Control Enable—This bit controls the
operation of the power control module. While
this bit is low, the CPU clock is on continuously. When this bit is high, the pulse-width
comparator presents the clock to the CPU in
bursts or disables it. When this bit is high, a
masked interrupt can disable the power control
module.
ReservedThese bits are reserve d and s hould rem ain se t
Width—This field controls the width of the
CPU clock bursts in increments of one
thirty-first. While this bit is set to 1 and the
PCM is enabled, the clock is applied to the
CPU in burst widths of one thirty-fir st (3 percent). When the width fi eld is 0x1 F, the cloc k is
always on, and when it is 0, th e clock is always
off. You can immediatel y wake it up ag ain without waiting for the PLL to reacquire lock. The
contents of this field are not affected by the
PCEN bit. When an interrupt disables the
power control module, these bits are not
changed.
0 = Power control is disabled (default).
1 = Power control is enabled.
This chapter descr ibe s the system control r egi st er of t he MC68VZ328 microprocess or. The system control
register enables system software to control and customize the following functions:
•Access permission from the internal peripheral registers
•Address space of the internal peripheral registers
•Bus time-out control and status (bus error generator)
5.1 System Control Operation
The on-chip resources use a reserved 4,096-byte block of address space for their registers. This block is
mapped beginning a t location 0xFFFFF000 ( 32-bit) or 0xXXFFF00 0 (24-bi t, where XX i s “don’t care ”) on
reset. The DMAP bit in the syst em control regis ter disab les double mapp ing in a 32-bi t system. If t his bit is
cleared, the on-chip peripheral registers appear only at the top of the 4 Gbyte address range starting at
0xFFFFF000.
The system control register provides control of system operation functions such as bus interface and
watchdog protection. The system control register contains status bits that allow exception handler code to
interrogate the cause of both exceptions and resets. The bus time-out monitor and the watchdog timer
provide system protection. The bus time-out monitor generates a bus error when a bus cycle is not
terminated b y the DTACK
signal after 128 clock cycles have elapsed.
5.1.1 Bus Monitors and Watchdog Timers
The bus error time-out logic consists of a bus time-out monitor that, when enabled, begins to count clock
cycles as the internal AS
normally terminates the count, but if the count reaches terminal count before AS
asserted until AS
system control register. The BETO bit in the system control register is set after a bus time out, which may
indicate a write-protect violation or privilege.
The watchdog timer resets the MC68VZ328 if it is enabled and not cleared or disabled before reaching
terminal count. The watchdog timer is enabled at reset.
is deasserted. The bus error time-out logic consists of 1 control bit and 1 status bit in the
System Control5-1
pin is asserted for internal or external bus accesses. The deassertion of AS
is deasserted, BERR is
Programming Model
5.2 Programming Model
The following sections provide detailed programming information about the system control register and
the other registers associated with its operation.
5.2.1 System Control Register
The 8-bit read/write system control register (SCR) resides at the address 0xFFFFF000 or 0xXXFFF000
(where XX is “don’t care”) after reset. The SCR and all other internal registers cannot be accessed in the
68000’s user mode if the SO bit is set to 1. The bit ass ign me nts for the re gis te r are shown in the fol lo w ing
register display. The settings for the bits in the register are listed in Table 5-1.
SCRSystem Control Register0x(FF)FFF000
BIT 7654321BIT 0
BETOWPVPRVBETENSODMAP
TYPErwrwrwrwrwrw
RESET
00011100
0x1C
WDTH8
rw
Table 5-1. System Control Register Description
NameDescriptionSetting
BETO
Bit 7
WPV
Bit 6
PRV
Bit 5
Bus Error Time Out—This status bit indicates
whether or not a bus-error-timer time out has
occurred. When a bus cycle is not terminated by
the DTACK
elapsed, the BETO bit is set. However, the
BETEN bit must be set for a bu s e rror time out to
occur. This bit is cleared by writing a 1 (writing a
0 has no effect).
Write-Protect Violation—This status bit indicates that a write-protect violation has occurred.
If a write-protec t v iolation occurs and the BETEN
bit is not set, the current bus cycle will not terminate. The BETEN bit must be set for a bus error
exception to occur during a write-protect violation. This bit is cleared by writing a 1 (writing a 0
has no effect).
Privilege Violation—This status bit indicates
that if a privilege vi olatio n occ urs and the BETEN
bit is not set, the cycle will not terminate. The
BETEN bit must be set for a bus error exception
to occur during a privilege violation. This bit is
cleared by writing a 1 (writing a 0 has no effect).
signal after 128 clock cycles have
0 = A bus-error-timer time out did not occur.
1 = A bus-error-timer time out has occurred
because an undecoded address space has
been accessed or b ecause a write-pr otect or
privilege violation has occurred.
0 = A write-protect violation did not occur.
1 = A write-protect violation has occurred.
0 = A privilege violation did not occur.
1 = A privilege violation has occurred.
BETEN
Bit 4
SO
Bit 3
Bus Error Time-Out Enable—This control bit
enables the bus error timer.
Supervisor Only—This control bit limits on-chip
registers to supervisor accesses only.
0 = Disable the bus error timer.
1 = Enable the bus error timer.
0 = User and supervisor mode.
1 = Supervisor-only mode.
5-2MC68VZ328 User’s Manual
Table 5-1. System Control Register Description (Continued)
NameDescriptionSetting
Programming Model
DMAP
Bit 2
Reserved
Bit 1
WDTH8
Bit 0
Double Map—This control bit controls the
double-mapping fun cti on.
ReservedThis bit is reserved and reads 0.
8-Bit Width Select—This control bit allows the
D[7:0] pins to be used for Port A input/output.
0 = The on-chip registers are mapped at
0xFFFFF000–0xFFFFFFFF.
1 = The on-chip registers are mapped at
0xFFFFF000–0xFFFFFFFF and
0xXXFFF000–0xXXFFFFF (XX = “don’t
care”).
0 = Not an 8-bit system.
1 = 8-bit system.
System Control5-3
Programming Model
5.2.2 Peripheral Control Register
This register controls the PWM logical block operation, timer TIN/TOUT signal, and UART UCLK
signal. The bit assignments for t he register are shown in the followin g r egister display. The settings for the
bits in the register are listed in Table 5-2.
PCRPeripheral Control Register0x(FF)FFF003
BIT 7654321BIT 0
UCLKP[1:0]T[1:0]
TYPE
00000000
RESET
Table 5-2. Peripheral Control Register Description
NameDescriptionSetting
rwrwrwrwrw
0x00
Reserved
Bits 7–5
UCLK
Bit 4
P[1:0]
Bits 3–2
T[1:0]
Bits 1–0
ReservedDo not use these bits.
UART Clock Pin Configuration—When UCLK
of UART 1 and UART 2 is configured to output
signal, this bit selects UART 1’s or UART 2’s
UCLK for UCLK pin output. When UCLK of
UART 1 and UART 2 is configured as input, this
bit is “don’t care,” and UC LK pin is an input si gnal.
PWM Outputs Logic Operation—These bits
select the logical combination for final PWM pin
output.
TIN/TOUT Signal Configuration—These 2 bits
are used to configure the external TIN/TOUT signal when pin PB6/TIN/TOUT is selected as
TIN/TOUT function. For detailed information on
using this function, see Section 12.1.4,
“TOUT/TIN/PB6 Pin,” on page 12-3.
0 = UCLK pin is connected to UART 1.
1 = UCLK pin is connected to UART 2.
00 = 8-bit PWM out only (default).
01 = 16-bit PWM out only.
10 = Logic OR of both PWM outputs.
11 = Logic AND of both PWM outputs.
00 = TIN/TOUT is connected to Timer 1.
01 = TIN/TOUT is connected to Timer 2.
10 = Timer 2 OUT -> Timer 1 IN; TIN -> Timer 2
(DIR6 = 0), or TOUT -> Timer 1 (DIR6 = 1).
11 = Timer 1 OUT -> Timer 2 IN; TIN -> Timer 1
(DIR6 = 0), or TOUT -> Timer 2 (DIR6 = 1).
5-4MC68VZ328 User’s Manual
Programming Model
5.2.3 ID Register
This 32-bit read- only register shows the chip identifica ti on. Th e bit assignments for the register are shown
in the follow ing register display. The se ttings for the bits in the register are listed in Table 5-3.
IDR ID Register0x(FF)FFF004
BIT 313029282726252423222120191817 BIT 16
CHIPIDMASKID
TYPEr r r r r r rrrrrrrrr r
RESET
TYPE r r r r r r rrrrrrrrr r
RESET
0 1 0 1 0 1 100000000 0
0x5600
BIT 1514 13 12 11 10 987654321BIT 0
SWID
0 0 0 0 0 0 000000000 0
0x0000
Table 5-3. ID Register Description
NameDescriptionSetting
CHIPID
Bits 31–24
MASKID
Bits 23–16
SWID
Bits 15–0
Chip ID Field—This field contains the chip identification number for the
DragonBall series MPU.
Maskset ID Field—This field contains the maskset number for the silicon.See description
Software ID—This field contains the custom software ID. It is normally “0000.”See description
See description
System Control5-5
Programming Model
5.2.4 I/O Drive Control Register
This register controls the driving strength of all I/O signals. By default, all pins are defaulted to 4 mA
driving current. After reset, system software should select 2 mA driving for those signals that do not need
high-current driving for power saving. The bit assignments for the register are shown in the following
display. The settings fo r the bits in th e register are listed in Ta ble 5-4.
IODCRI/O Drive Control Register0x(FF)FFF008
BIT 1514 13 12 11 10 987654321BIT 0
ABDBCBPMPKPJPGPFPEPDPCPBPA
TYPE
0 0 0 1 1 1 1111111111
RESET
Table 5-4. I/O Drive Control Register Description
NameDescriptionSetting
rwrwrwrwrwrwrwrwrwrwrwrwrw
0x1FFF
Reserved
Bits 15–13
AB
Bit 12
DB
Bit 11
CB
Bit 10
PM–PA
Bits 9–0
ReservedDo not use these bits.
Address Bus Signals I/O D rive Control—It should be
noted that A[23:20] are controlled by the PF bit.
Upper Data Bus Signals I/O Drive Control—The
lower data bus is controlled by the PA bit.
Control Bus Signals—Only those signals or functions
not multiplexed with GPIO are controlled by this bit.
Port M to Port A Group I/O Drive Control—Each bit
controls the drive current for the lines in the respective
port.
0 = I/O drive current for each pin is 2 mA.
1 = I/O drive current for each pin is 4 mA.
0 = I/O drive current for each pin is 2 mA.
1 = I/O drive current for each pin is 4 mA.
0 = I/O drive current for each pin is 2 mA.
1 = I/O drive current for each pin is 4 mA.
0 = I/O drive current for each pin is 2 mA.
1 = I/O drive current for each pin is 4 mA.
5-6MC68VZ328 User’s Manual
Chapter 6
Chip-Select Logic
This chapter describes the chip-select logic’s function and operation and provides programming
information for controlling its operation.
6.1 Overview of the CSL
The MC68VZ328 microprocessor contains eight general-purpose, programmable chip-select signals,
which are used to select external devices on the address and data bus. The signals are arranged in four
groups of two—C
SA0 is a special-purpose chip-select signal, which is the boot device chip-select. After reset, in normal
C
mode all the addresses are mapped to CSA0
and the chip-select enable (EN) bit is set in the appropriate chip-select register. From that point forward,
does not decode globally and is only asserted when decoded from the programming information in
CSA0
the chip-select register.
SA[1:0], CSB[1:0], CSC[1:0], an d CSD[1 :0 ].
until such time that the group base address A is programmed
Group C (CSC0
programmed as row address strobe (RAS0
DRAM interface. For details, refer to Section 7.3.2, “DRAM Control Register,” on page 7-14 and
Section 6.3.3, “Chip-Select Registers,” in this chapter.
Each memory area can be defined as an inte rnally genera ted cycle- terminati on signal, ca lled DTACK
a programmable number of wait states. This feature savesboard space that would otherwise be used for
cycle-termination logic . Usi ng CDL, t he syst em desi gner can adopt a fle xible memory c onfigur atio n base d
on cost and availability. Up to four different classes of devices and memory can be used in a system
without the need for e xte rnal decode or wait- st ate ge ner at ion l ogi c. Specifically, 8- o r 16-b it combinations
of ROM, SRAM, flash memory and DRAM (EDO RAM, Fast Page Mode, or sync hronous) are s upporte d,
as shown in Table 6-1 on page 6-2.
/CSC1) and Group D (CSD0/CSD1) chip-selects are unique in that they can also be
/RAS1) and column address strobe (CAS0/CAS1) for the
The basic chip-select model allows the chip-select output signal to assert in response to an address match.
The signals are asserted externally shortly after the internal Address Strobe (AS
) signal goes low. The
address match is descr ibed in t erms of a gr oup base ad dress reg ister and a c hip-sele ct regis ter. The memor y
size of the chip-select can be selected from a set of predefined ranges (32K, 64K, 128K, 256K, 512K,
1 Mbyte, 2 Mbyte, 4 Mbyte, 8 Mbyte, or 16 Mbyte). These memory ranges represent the most popular
memory sizes available on the market and apply to the registers CSB, CSC, and CSD. The CSA register
primarily supports ROM, which is usually 128K to 16 Mbyte. Using this scheme, it is easy to design
software without the necessity of programming a chip-select mask register.
The chip-select ca n be prog rammed t o allow r ead-only or read /write acce sses. Othe r paramet ers tha t can be
programmed include the number of wait states (from 0 to 13), data bus size selection, and whether a
TACK signal is automatically generated for the chip-select logic.
D
6.2 Chip-Select Operation
A chip-select output signal is asserted when an address is matched and after the AS signal goes low. The
base address and address mask registers are used in the compare logic to generate an address match. The
byte size of t he mat ching blo ck must be a power of two and th e base addr ess must b e an i ntege r multip le of
this size. Therefore, an 8K block size must begin on an 8K boundary, and a 64K block size can onl y begi n
on a 64K boundary. Each chip-select is programmable, and the registers have read/write capability so that
the programmed values can be read back.
NOTE:
The chip-select logic does not allow an address match during interrupt
acknowledge (Function Code 7) cycles.
6.2.1 Memory Protection
The chip-select range of the four chip-selects can be programmed as read-only or read/write. Chip-selects
that control the crucial system data are usually programmed as supervisor-only and read-only so they can
be protected from system misuse (for example, a low battery). However, a certain area of this
6-2MC68VZ328 User’s Manual
Chip-Select Operation
chip-select–controlled area can be programmed as read/write, which provides optimal memory use, as
shown in Figure 6-1. This area can be defined by programming the UPSIZ bits in th e CSB, CSC, and CSD
registers to between 32K and the entire chip-select area.
Unprotected Memory (Read/Write)
Up to 4 Mbyte
Memory
Map
Figure 6-1. Size Selection and Memory Protection for CSB0 and CSB1
RAM
CSB0
CSB1
Up to 16 Mbyte
Up to 16 Mbyte
Protected Memory
(Supervisor-Only, Read-Only)
6.2.2 Programmable Data Bus Size
Each chip-select can be conf igu re d to address an 8- or 16-bit space . Both 16- and 8-bit contiguou s add res s
memory devices can be mixed o n a 16-b it data bu s syst em. If the CPU pe rforms a 16-bi t dat a transf er in a n
8-bit memory space, then two 8-bit cycles will occur. However, the address and data strobes remain
asserted until the end of the second 8-bit cycle. In this case, only the external CPU data bus upper byte
(D[15:8]) is used, and the least significant bit of the address (A0) increment s automat ically fro m one to the
next. A0 should be ignored in 16-bit data bus cycles even if only the upper or lower byte is being read or
written. For an external peripheral that only needs an 8-bit data bus interface and does not require
contiguous address locations (unused bytes on empty addresses), use a chip-select configured to a 16-bit
data bus width and c onnect to the D[7:0] pi ns. This balances the l oad of t he two data bus halve s i n an 8-bit
system. The internal data bus is 16 bits wide. All internal registers can be read or written in a zero
wait-state cycle.
Except for CSA0
and EMUCS, all chip-select signals are disabled by default. The data bus width (BSW)
field of the chip-select option register enables 16- and 8-bit data bus widths for each of the 16 chip-select
ranges. The initia l bus width for th e boot chip -select can be s elected b y placing a logic 0 or 1 on the BUSW
pin at reset to sp ecify the width of the data bus. This a llows a boo t EPROM of the data bus wi dth to be used
in any given system. All external accesses that do not match one of the chip-select address ranges are
assumed to be a 16-bit devi ce. This results in a single access performe d for a 16-bit tr ansfer. If it i s applied
to an 8-bit port, the port is accessed every other byte.
The boot chip-select is initia lized fr om reset to ass ert in resp onse to any address exce pt the on-ch ip regist er
space (0xFFFFF000 to 0xFFFFFFFF). This ensures that a chip-select to the boot ROM or EPROM will
fetch the reset vector and execute the initialization code, which should set up the chip-select ranges.
A logic 0 on the BUSW pin sets the boot device’s data bus to be 8 bits wide, and a logic 1 sets it to be 16
bits wide. At reset, the data bus port size for CSA0
and the data width of the boot ROM device are
determined by the state of BUSW. The other chip-selects are initialized to be nonvalid, so they will not
assert until they are programmed and the EN bit is set in the chip-select registers.
Chip-Select Logic6-3
Programming Model
6.2.3 Overlapping Chip-Select Registers
Do not program group address and chip-select registers to overlap, or the chip-select signals will overlap.
Unused chip-selects must be disabled. Map them to an unused space, if possible.
When the CPU tries to write to a read -only l ocati on that ha s alrea dy be en progra mmed, the chip-s el ect and
DTACK
signals will not be gene rated internal ly . BERR will be asserted internally if the bus error time-out
function is enabled.
NOTE:
The chip-select logic does not allow an address match during interrupt
acknowledge cycles.
6.3 Programming Model
The chip-select module contains registers that are programmed to control external devices, such as
memory. Chip-selects d o not operate until the register in a particular group of devices is init i ali ze d a nd the
EN bit is set in the corres pon din g chip-select register. The only exception is the CSA0
boot device chip-selec t.
signal, which is the
6.3.1 Chip-Select Group Base Address Registers
The upper 15 bits of each base address register selects the starting address for the chip-select address
range. The GBAx field i s compared to the add res s on t he address bus to de te rmi ne if the group is dec oded .
The chip-select base address must be set according to the size of the corresponding chip-select signals of
the group. For example, if CSA1
register must be s et in a 4 Mbyte space boundary, such as syst em address 0
and so on. It cannot be set at 0
CSGBAChip-Select Group A Base Address Register 0x(FF)FFF100
Table 6-3. Chip-Select Group B Base Address Register Description
Name Description Setting
GBBx
Bits 15
–1
Reserved
Group B Base Address
the high-order bits (28–14) of the starting
address for the chip-select range.
Reserved This bit is reserved and should be set to 0.
—These bits select
The chip-select base address must be set
according to the size of the corresponding
chip-select signals of the group.
Bit 0
CSGBCChip-Select Group C Base Address Register 0x(FF)FFF104
BIT
1413121110987654321
15
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
C2
C2
7
8
TYPErwrwrwrwrwrwrwrwrwrwrwrwrwrwrw
RESET
0000000000000000
C2
C2
5
6
C2
C2
3
4
C2
C2
1
2
0x0000
C2
C1
9
0
C1
C1
7
8
C1
C1
5
6
BIT
0
GB
C1
4
Table 6-4. Chip-Select Group C Base Address Register Description
Name Description Setting
GBCx
Bits 15–1
Reserved
Group C Base Address—These bits select
the high-order bits (28–14) of the starting
address for the chip-select range.
The chip-select base address must be set
according to the size of the corresponding
chip-select signals of the group.
Reserved This bit is reserved and should be set to 0.
Bit 0
Chip-Select Logic6-5
Programming Model
CSGBDChip-Select Group D Base Address Register 0x(FF)FFF106
BIT
1413121110987654321
15
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
GB
D2
D2
7
8
TYPErwrwrwrwrwrwrwrwrwrwrwrwrwrwrw
RESET
0000000000000000
D2
D2
5
6
D2
D2
3
4
D2
D2
1
2
0x0000
D2
D1
9
0
D1
D1
7
8
D1
D1
5
6
BIT
0
GB
D1
4
Table 6-5. Chip-Select Group D Base Address Register Description
Name Description Setting
GBDx
Bits 15
–1
Reserved
Group D Base Address
the high-order bits (28–14) of the starting
address for the chip-select range.
Reserved This bit is reserved and should be set to 0.
—These bits select
The chip-select base address must be set
according to the size of the corresponding
chip-select signals of the group.
Bit 0
6.3.2 Chip-Select Upper Group Base Address Register
The default setti ng for c hip-se lect deco ding li mits ad dre ssing t o A28. When the ful l addr ess deco de enabl e
(UGEN) bit is set, it allows full address decoding. Full address decoding is enabled for all four of the
chip-select regi ster s by t he UGEN b it i n the chip- sele ct upp er gr oup bas e add ress regis ter (CSUGBA). The
bit value of the MSB for each of the four chip-select registers can be written into each of the four MSB
fields in this register. The settings for this register are shown in Table 6-6.
CSUGBAChip-Select Upper Group Base Address Register 0x(FF)FFF108
BIT
1413121110987654321
15
UG
EN
TYPErwrwrwrw
RESET
0000000000000000
AGBA[31:29]
BGBA[31:29]CGBA[31:29]DGBA[31:29]
rwrwrwrwrwrwrwrwrw
0x0000
Table 6-6. Chip-Select Upper Group Base Address Register Description
Name Description Setting
UGEN
Bit 15
AGBA[31:29]
Bits 14–12
Full Address Decode Enable—This bit
enables full address range decoding for all
chip-select registers.
MSB for Chip-Select A—The upper most significant bits for chip-select group A base
address. The value will be ignored if UGEN is
disabled.
0 = Ignores A31, A30, and A29.
1 = Decoding includes A31, A30, and A29.
Enter value for bits 31–29 of chip-select register A.
BIT
0
6-6MC68VZ328 User’s Manual
Programming Model
Table 6-6. Chip-Select Upper Group Base Address Register Description (Continued)
Name Description Setting
Reserved
Bit 11
BGBA[31:29]
Bits 10–8
Reserved
Bit 7
CGBA[31:29]
Bits 6–4
Reserved
Bit 3
DGBA[31:29]
Bits 2–0
Reserved This bit is reserved and should be set to 0.
MSB for Chip-Select B—The upper most significant bits for chip-select group B base
address. The value will be ignored if UGEN is
disabled.
Reserved This bit is reserved and should be set to 0.
MSB for Chip-Select C—The upper most significant bits for chip-select group C base
address. The value will be ignored if UGEN is
disabled.
Reserved This bit is reserved and should be set to 0.
MSB for Chip-Select D—The upper most significant bits for chip-select group D base
address. The value will be ignored if UGEN is
disabled.
Enter value for bits 31–29 of chip-select register B.
Enter value for bits 31–29 of chip-select register C.
Enter value for bits 31–29 of chip-select register D.
Chip-Select Logic6-7
Programming Model
6.3.3 Chip-Select Registers
There are four 16-bit chip-select (CSA, CSB, CSC, and CSD) registers for each corresponding chip-select
base address register. Each register controls two chip-select signals and can be configured to select the
memory type and size of t he me mory range supported as we ll as to program the required wait states or use
the external DTACK
page 6-14.
CSAChip-Select Register A0x(FF)FFF110
signal. The settings for the register s are descr ibed in Tabl e 6-7 through Table 6-10 on
BIT
RO
TYPErw
RESET
14 13 12 11 10 9 87 654321
15
FLASHBSWWS3–1SIZEN
rwrwrwrwrwrwrwrww
0 0 0 0 0 0 0 0 1 011000 0
0x00B0
Table 6-7. Chip-Select Register A Description
Name Description Setting
RO
Bit 15
Reserved
Bits 14–9
FLASH
Bit 8
Read-Only—This bit sets the chip-select to
read-only. Otherw i se , rea d and write access es
are allowed. A write to a read-only area will
generate a bus error if the BETEN bit of the
SCR is set. See Section 5.2.1, “System Control
Register,” on page 5-2 for more information.
Reserved These bits are reserved and should be set to 0.
Flash Memory Support—When enabled, this
bit provid es support for flash memory by forcing the LWE
chip-select.
Note: This bit is used for expanded memory
size for CSD when the DRAM bit in the CSD
register is enabled.
/UWE signal to go active after
0 = Read/write.
1 = Read-only.
0 = The chip-select and LWE
at the same clock edge.
1 = The chip-select signal goes low 1 clock before
/UWE.
LWE
BIT
0
/UWE signals go active
BSW
Bit 7
WS3–1
Bits 6–4
Data Bus Width—This bit sets the data bus
width for this chip-select area.
Wait State—This field determines the number
of wait states add ed before an internal DTACK
signal is returned for this chip-select.
Note: When using the external DTACK
signal, you must configure the
BUSW/DTACK
/PG0 pin.
0 = 8 bit.
1 = 16 bit.
000 = 0 + WS0 wait states.
001 = 2 + WS0 wait states.
010 = 4 + WS0 wait states.
011 = 6 + WS0 wait states.
100 = 8 + WS0 wait states.
101 = 10 + WS0 wait states.
110 = 12 + WS0 wait states.
111 = External DTACK
When using the external DTACK signal, you must
select DTACK
WS0 is the DWS0, CWS0, BWS0, or AWS0 bit in
the CSCTRL1 register.
function in Port G.
.
6-8MC68VZ328 User’s Manual
Table 6-7. Chip-Select Register A Description (Continued)
Name Description Setting
Programming Model
SIZ
Bits 3–1
EN
Bit 0
Chip-Select Size—This field determines the
memory range of the chip-select. For CSAx
and CSBx
128K and 16 Mbyte. For CSCx
chip-select size is between 32K and 16 Mbyte.
Chip-Select Enable—This write-only bit
enables each chip-select.
, the chip-select size is between
and CSDx, the
000 = 128K (32K or 8 Mbyte* for CSCx
001 = 256K (64K or 16Mbyte* for CS Cx
010 = 512K (128K for CSCx
011 = 1 Mbyte (256K for CSCx
100 = 2 Mbyte (512K for CSCx
101 = 4 Mbyte (1 Mbyte for CSCx
110 = 8 Mbyte (2 Mbyte for CSCx
111 = 16 Mbyte (4 Mbyte for CSCx
* Note: Large DRAM size selection requires the
DSIZ3 bit in the chi p-select control registe r to be set.
0 = Disabled.
1 = Enabled.
and CSDx).
and CSDx).
and CSDx).
and CSDx).
and CSDx).
and CSDx).
and CSDx).
and CSDx).
Chip-Select Logic6-9
Programming Model
CSBChip-Select Register B0x(FF)FFF112
BIT
15
ROSOPROPUPSIZ
TYPErwrwrwrw
RESET
1413121110987654321
FLASHBSWWS3–1SIZEN
rwrwrwrwrwrwrwrww
0 0 0 0 000 00 000000 0
0x0000
Table 6-8. Chip-Select Register B Description
Name Description Setting
RO
Bit 15
SOP
Bit 14
Read-Only—This bit sets the chip-select
to read-only. Otherwise, read and write
accesses are allowed. A write to a
read-only area will generate a bus error if
the BETEN bit of the SCR is set. See
Section 5.2.1, “System Control Register,”
on page 5-2 for more information.
Supervisor-Use-Only Protected Memory Block—This bit sets the protected
memory block to supervisor-only; otherwise, both supervisor and user accesses
are allowed. Attempts to access the su pervisor-only area result in a bus error if the
BETEN bit of the SCR is set. See
Section 5.2.1, “System Control Register,”
on page 5-2 for more information.
0 = Read/write.
1 = Read-only.
0 = Supervisor/user.
1 = Supervisor-only.
BIT
0
ROP
Bit 13
UPSIZ
Bits 12–11
Reserved
Bits 10–9
FLASH
Bit 8
BSW
Bit 7
Read-Only for Protected Memory
Block—This bit sets the protected mem-
0 = Read/write.
1 = Read-only.
ory block to read-only. Otherwise, read
and write accesses are allowed. If you
write to a read-only area, you will get a bus
error.
Unprotected Memory Block Size—This
field determines the unprotected memory
range of the chip-select.
00 = 32K.
01 = 64K.
10 = 128K.
11 = 256K.
Reserved These bits are reserved and should be set to 0.
Flash Memory Support—W hen e nab led ,
this bit provides support for flash memory
by forcing the LWE
/UWE signal to go
active after chip-select.
0 = The chip-select and LWE/UWE signals go active at
the same clock edge.
1 = The chip-select signal goes low 1 clock before
/UWE.
LWE
Note: This bit is used for expanded
memory size for CSD when the DRAM bit
in the CSD register is enabled.
Data Bus Width—This bit sets the data
bus width for this chip-select area.
0 = 8 bit.
1 = 16 bit.
6-10MC68VZ328 User’s Manual
Table 6-8. Chip-Select Register B Description (Continued)
Name Description Setting
Programming Model
WS3–1
Bits 6–4
SIZ
Bits 3–1
EN
Bit 0
Wait State—This field determines the
number of wait states added before an
internal DTACK signal is returned for this
chip-select.
Note: When using the external DTACK
signal, you must configure the
BUSW/DTACK
Chip-Select Size—This field determines
the memory range of the chip-select. For
CSAx
and CSBx, the chip-select size is
between 128K and 16Mbyte. For CSCx
and CSDx
32K and 16 Mbyte.
Chip-Select Enable—This write-only bit
enables each chip-select.
/PG0 pin.
, the chip-select size is between
000 = 0 + WS0 wait states.
001 = 2 + WS0 wait states.
010 = 4 + WS0 wait states.
011 = 6 + WS0 wait states.
100 = 8 + WS0 wait states.
101 = 10 + WS0 wait states.
110 = 12 + WS0 wait states.
111 = External DTACK.
When using the external DTACK
select DTACK
WS0 is the DWS0, CWS0, BWS0, or AWS0 bit in the
CSCTRL1 register.
000 = 128K (32K or 8 Mbyte* for CSCx
001 = 256K (64K or 16Mbyte* for CSCx
010 = 512K (128K for CSCx
011 = 1 Mbyte (256K for CSCx
100 = 2 Mbyte (512K for CSCx
101 = 4 Mbyte (1 Mbyte for CSCx
110 = 8 Mbyte (2 Mbyte for CSCx
111 = 16 Mbyte (4 Mbyte for CSCx
* Note: Large DRAM size selection requires the DSIZ3
bit in the chip-select control register to be set.
0 = Disabled .
1 = Enabled.
function in Port G.
signal, you must
and CSDx).
and CSDx).
and CSDx).
and CSDx).
and CSDx).
and CSDx).
and CSDx).
and CSDx).
Chip-Select Logic6-11
Programming Model
CSCChip-Select Register C0x(FF)FFF114
BIT
ROSOPROPUPSIZ
TYPErwrwrwrw
RESET
1413121110987654321
15
FLASHBSWWS3–1SIZEN
rwrwrwrwrwrwrwrww
0 000 0 0000 00000 0 0
0x0000
Table 6-9. Chip-Select Register C Description
Name Description Setting
RO
Bit 15
Read-Only—This bit sets the chip-select
to read-only. Otherwise, read and write
0 = Read/write.
1 = Read-only.
accesses are allowed. A write to a
read-only area will generate a bus error if
the BETEN bit of the SCR is set. See
Section 5.2.1, “System Control Register,”
on page 5-2 for more information.
SOP
Bit 14
Supervisor-Use-Only Protected Memory Block—This bit sets the protected
0 = Supervisor/user.
1 = Supervisor-only.
memory block to supervisor-only; otherwise, both supervisor and user accesses
are allowed. Attempts to access the su pervisor-only area result in a bus error if the
BETEN bit of the SCR is set. See
Section 5.2.1, “System Control Register,”
on page 5-2 for more information.
BIT
0
ROP
Bit 13
UPSIZ
Bits 12–11
Reserved
Bits 10–9
FLASH
Bit 8
BSW
Bit 7
Read-Only for Protected Memory
Block—This bit sets the protected mem-
0 = Read/write.
1 = Read-only.
ory block to read-only. Otherwise, read
and write accesses are allowed. If you
write to a read-only area, you will get a bus
error.
Unprotected Memory Block Size—This
field determines the unprotected memory
range of the chip-select.
00 = 32K.
01 = 64K.
10 = 128K.
11 = 256K.
Reserved These bits are reserved and should be set to 0.
Flash Memory Support—W hen e nab led ,
this bit provides support for flash memory
by forcing the LWE
/UWE signal to go
active after chip-select.
0 = The chip-select and LWE/UWE signals go active at
the same clock edge.
1 = The chip-select signal goes low 1 clock before
/UWE.
LWE
Note: This bit is used for expanded
memory size for CSD when the DRAM bit
in the CSD register is enabled.
Data Bus Width—This bit sets the data
bus width for this chip-select area.
0 = 8 bit.
1 = 16 bit.
6-12MC68VZ328 User’s Manual
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.