Reason for entry
The Users Guide has changed from Revision 3 (UM3) to Revision 4 (UM4).
Significant Changes:
1. Typographical errors corrected.
2. Manual adapted for 90 MHz operation.
3. Crystal and PLL precision increased to 4 decimal points where applicable.
4. Distinction between 18-74 MHz (PLL) “mode” and precise “operation” frequency made. Example, at 90.3168
operating frequency the processor is in PLL, or 18-74 MHz, mode with a higher PLL Multiplier value.
5. Programming example on page 10-1 updated for consistency.
Updated Tables and Figures:
1. Revision 3, Chapter 5, ADCKSEL table on page 5-5 to 5-6 updated (Revision 4, new table is Table 5-3 on page 5-6.)
2. Revision 3, Chapter 8, Wait State tables on page 8-4 updated (Revision 4, new tables are Tabl e 8 -3 and Table 8-4 on
page 8-4.)
3. Revision 3, Chapter 9, Figure 9-2 on page 8-4, LCD Data to Pixel Mapping updated (Revision 4, new figure is Figure
9-2 on page 9-6.)
4. Revision 3, Chapter 15, Table 15-A on page 15-3, ADC Interface Operation Frequencies updated (Revision 4, new
table is Table 15-2 on page 15-3.)
5. Revision 3, Chapter 16, Table 16-A on page 16-3, Matrix for Programming the MUX updated (Revision 4, new table
is Table 16-2 on page 16-3.)
6. Revision 3, Chapter 16, Figure 16-2 on page 18-5), Digital Audio Clock Generation updated (Revision 4, new figure
is Figure 16-2 on page 16-3.)
7. Revision 3, Chapter 16, Table 16-D on page 16-5, Programmable Audio Divisors for 74 MHz updated (Revision 4,
new table is Table 16-5 on page 16-5.)
8. Revision 4, Chapter 16, Table 16-6 on page 16-6, Programmable Audio Divisors for 90 MHz added.
9. Revision 4, Chapter 17, Table 17-2 on page 17-2, UART Bit Rate at 90 MHz added.
Note: In the online version of this manual, you can click on cross-references that appear in blue text to jump
to the targetedreference.
Contacting Cirrus Logic Support
For all product questions and inquiries contact a Cirrus Logic Sales Representative.
To find the one nearest to you go to www.cirrus.com
IMPORTANT NOTICE
Cirrus Logic, Inc. and its subsid iaries ("Cirrus") believe that the information contained in this document is accurate and reliab le. However, the
information is subj ect to change without notice and is provided "AS IS" without warranty of any kind (express or implied). Customers are advised
to obtain the latest v ersion of relevant information to verify, before placing orders, that information be ing relied on is current and complete. All
products are sold subject to the terms and conditions of sale supplied at the time of order acknowledgment, including those pertaining to
warranty, patent infringement, and limitation of liability. No responsibility is assumed by Cirrus for the use of this information, including use of this
information as the basis for manufacture or sale of any items, or for infringement of patents or other rights of third parties. This document is the
property of Cirrus and by furnishing this information, Cirrus grants no license, express or implied under any patents, mask work rights,
copyrights, trademarks, trade secrets or other intellectual property rights. Cirrus owns the copyrights associated with the information contained
herein and gives consent for copies to be made of the information only for use within your organization with respect to Cirrus integrated circuits
or other products of Cirrus. This consent does not extend to other copying such as copying for general distribution, advertising or promotional
purposes, or for creating any work for resale.
CERTAIN APPLICATIONS USING SEMICONDUCTOR PRODUCTS MAY INVOLVE POTENTIAL RISKS OF DEATH, PERSONAL INJURY,
OR SEVERE PROPERTY OR ENVIRONMENTAL DAMAGE (“CRITICAL APPLICATIONS”). CIRRUS PRODUCTS ARE NOT DESIGNED,
AUTHORIZED OR WARRANTED FOR USE IN AIRCRAFT SYSTEMS, MILITARY APPLICATIONS, PRODUCTS SURGICALLY IMPLANTED
INTO THE BODY, LIFE SUPPORT PRODUCTS OR OTHER CRITICAL APPLICATIONS (INCLUDING MEDICAL DEVICES, AIRCRAFT
SYSTEMS OR COMPONENTS AND PERSONAL OR AUTOMOTIVE SAFETY OR SECURITY DEVICES). INCLUSION OF CIRRUS
PRODUCTS IN SUCH APPLICATIONS IS UNDERSTOOD TO BE FULLY AT THE CUSTOMER’S RISK AND CIRRUS DISCLAIMS AND
MAKES NO WARRANTY, EXPRESS, STATUTORY OR IMPLIED, INCLUDING THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS FOR PARTICULAR PURPOSE, WITH REGARD TO ANY CIRRUS PRODUCT THAT IS USED IN SUCH A MANNER. IF THE
CUSTOMER OR CUSTOMER’S CUSTOMER USES OR PERMITS THE USE OF CIRRUS PRODUCTS IN CRITICAL APPLICATIONS,
CUSTOMER AGREES, BY SUCH USE, TO FULLY INDEMNIFY CIRRUS, ITS OFFICERS, DIRECTORS, EMPLOYEES, DISTRIBUTORS AND
OTHER AGENTS FROM ANY AND ALL LIABILITY, INCLUDING ATTORNEYS’ FEES AND COSTS, THAT MAY RESULT FROM OR ARISE IN
CONNECTION WITH THESE USES.
Cirrus Logic, Cirrus, the Cirrus Logic logo designs, MaverickKey ar e trademarks of Cirrus Logic, Inc. All other brand and product names in this
document may be trademarks or service marks of their respective owners.
Microsoft Windows and Microsoft are registered trademarks of Microsoft Corporation.
LINUX is a registered trademark of Linus Torvalds.
Features .............................................................................................................................................................. 2-1
CPU Register Definitions................................................................................................................................. 2-7
CPU Clocks ................................................................................................................................................. 2-9
CPU State Control.................................................................................................................................... 2-12
State Control Register Descriptions ............................................................................................................. 2-13
Enter the Standby State Register (STDBY)..................................................................................... 2-13
Enter the Idle State Register (HALT) ............................................................................................... 2-14
Power Up Sequence................................................................................................................................. 2-14
Features .............................................................................................................................................................. 3-1
Programming Example .................................................................................................................................... 3-1
Features .............................................................................................................................................................. 4-1
Features .............................................................................................................................................................. 5-1
System Register List ......................................................................................................................................... 5-2
Features .............................................................................................................................................................. 6-1
Features .............................................................................................................................................................. 7-1
Programming Example .................................................................................................................................... 7-2
System Initialization..................................................................................................................................7-2
Features .............................................................................................................................................................. 8-1
SRAM / Expansion Bus Register List ............................................................................................................ 8-1
Programming Example .................................................................................................................................... 8-1
Features .............................................................................................................................................................. 9-1
Programming Example .................................................................................................................................... 9-2
Color LCDs ................................................................................................................................................. 9-6
Features ............................................................................................................................................................ 10-1
Register List ..................................................................................................................................................... 10-1
Programming Example .................................................................................................................................. 10-1
Features ............................................................................................................................................................ 11-1
General Purpose I/O (GPIO) Register List................................................................................................. 11-1
Features ............................................................................................................................................................ 12-1
LED Flasher Register List .............................................................................................................................. 13-1
Features ............................................................................................................................................................ 14-1
Features ............................................................................................................................................................ 15-1
SSI Port Register List ...................................................................................................................................... 15-1
Features ............................................................................................................................................................ 16-1
DAI Interface ............................................................................................................................................ 16-4
Features ............................................................................................................................................................ 17-1
UART and SIR Encoder Register List .......................................................................................................... 17-1
Programming Example .................................................................................................................................. 17-1
SIR Encoder .............................................................................................................................................. 17-4
UART and SIR Encoder Register Descriptions...........................................................................................17-5
UART Data Registers (UARTDR1 and UARTDR2) ......................................................................... 17-5
Bit Rate and Line Control Registers (UBRLCR1 and UBRLCR2) ................................................... 17-6
Contents
Appendix A. Boot Code
Index ................................................................................................................................................................... 1-1
Table 16-2: Matrix for Programming the MUX........................................................................................... 16-3
Table 16-3: Pin Sharing for Multiplexor....................................................................................................... 16-4
Table 16-4: Communication Interface Performance................................................................................... 16-4
Table 16-5: Programmable Audio Divisors at 74 MHz ............................................................................. 16-5
EP7309/11/12 User’s Manual - DS508UM4xi
Copyright Cirrus Logic, Inc. 2003
Table 16-6: Programmable Audio Divisors at 90 MHz ............................................................................. 16-6
Table 17-1: UART and SIR Encoder Registers ............................................................................................17-1
Table 17-2: UART Bit Rates at 90 MHz ........................................................................................................ 17-2
Table 17-3: UART Bit Rate in PLL Clock Mode (74 MHz) ........................................................................ 17-3
Table 17-4: UART Bit Rate from 13 MHz Clock ......................................................................................... 17-3
Table 17-5: Word Length Selection............................................................................................................... 17-6
EP7309/11/12 User’s Manual - DS508UM4xii
Copyright Cirrus Logic, Inc. 2003
EP7309/11/12 User’s Manual - DS508UM4xiii
Copyright Cirrus Logic, Inc. 2003
Overview
Processor
Chapter 1
1Introduction
This chapter describes the EP73xx ARM processor, mem ory map, registers, an d
signals. See the data sheet that is associated with a specific EP73xx device for more
informationaboutpinassignmentsforthatproduct.
The EP73xx incorporates an ARM 32-bit RISC m icro controller that controls a wide
range of on-chip peripherals.The ARM720T includes a a 8 Kbytes unified cache and a
MMU compatible with operating systems like Windows
®
CE and Linux®.
11
1
Peripherals
See the A RM 720T Technical Reference Manual, as cited on page 1-12.
On-chip EP73xx peripherals are product-specific for each chip. The supersetof
available features includes:
• 48 Kbytes of on-chip SRAM th at can be shared b etween the LCD controller
and general application use
• Memory interfaces (chip selects) for up to six independent 256 M byte
expansion segments with programmable width and wait states
• 27 general purpose Input/Outputs.
• Digital Audio Interface (DAI) to interface with CD-quality DACs and
CODECs
• Interrupt Controller
• Advanced system state controller and power management
• Two full-duplex 16550 A compatible UARTs with 16-byte transmit and
receive FIFOs.
• IrDA SIR protocol controller capable of speeds up to 115.2 kbps
• Programmable LCD controller for 1,2 or 4-bit-per-pixel with 16-level
grayscaler and frame buffer start address.
• On-chip boot ROM programmed for serial port download of boot code.
EP7309/11/12 User’s Manual - DS508UM41-1
Copyright Cirrus Logic, Inc. 2003
Introduction
• Two 16-bit general purpose timer counters
• 32-bit RTC (Real-Time-Clock) timer and comparator
• Dedicated LED flasher pin driven from the RTC with programmable du ty
ratio (Multiplexed with GPIO pin)
1
• Two synchronous serial interfaces for M icro-wire or SPI interfaces s uch as
ADCs, one supporting both the master and slave and other supporting
only master mode.
• Two programmable PWM (Pulse Width Modulation) interfaces
• SDRAM i nterface for direct interface to a maximum of two external banks
of SDRAM memory. Each bank can be up to 256 Mbit in size and
configurable for 32 or 16-bit wide accesses.
• PLL (Phase Lock Loop) oscillator for generating core speeds of 18-90 MHz
from an external 3.6864 MHz crystal.
• Low power 32.768 kHz RTC (Real Time Clock)
• MaverickKey - Unique and Random IDs for SDMI compliance
Memory Map and Register List
The lower 2 GByte of the address space is allocated to memory. The 64 MByte of
address space from 0xC000.0000 to 0xCFFF.FFFF is allocated to SDRAM. About
1.5 GBytes of address space, less 8 Kbytes for internal registers, is not accessible in the
EP73xx. The M MU in the EP73xx should be programmed to g enerate an abort
exception for access to this area.
Internal peripherals are addressed through a set of internal memory l oca tions from
hex address 0x8000.0000 to 0x8000.3FFF. These are known as the internal registers in
the EP73xx. In Table 1-1 also shows how the 4-Gbyte address range of the ARM720T
processor (as configured within this chip) is mapped in the EP73xx. The external boot
ROM is not fully decoded (i.e., the b oot code will repeat within the 256-Mbyte space
from 0x7000.0000 to 0x8000.0000). See Table 6-1 on page 6-2 for the m emory map
when booted from on-chip boot ROM. The SRAM is fully decoded up to a maximum
size of 48 Kbytes. Access to any location above this range will be wrapped to within
the range.
Global Memory Map
Table 1-1: EP73xx Memory Map in External Boot Mode
AddressContentsSize
0xF000.0000Reserved256 Mbytes
0xE000.0000Reserved256 Mbytes
0xD000.0000Reserved256 Mbytes
0xC000.0000SDRAM64 Mbytes
1-2EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Table 1-1: EP73xx Memory Map in External Boot Mode (Continued)
AddressContentsSize
0x8000.4000Unused~1 Gbyte
0x8000.0000Internal registers8 Kbytes
0x7000.0000Boot ROM (nCS[7])128 bytes
0x6000.0000SRAM (nCS[6])48 Kbytes
0x5000.0000 Expansion (nCS[5])256 Mbytes
0x4000.0000Expansion (nCS[4])256 Mbytes
0x3000.0000Expansion (nCS[3])256 Mbytes
0x2000.0000Expansion (nCS[2])256 Mbytes
0x1000.0000ROM Bank 1 (nCS[1])256 Mbytes
0x0000.0000ROM Bank 0 (nCS[0])256 Mbytes
Internal Register Map
Table 1-2 on page 1-4 shows the Internal Registers of the EP73xx when the CPU is
configured to a little endian memory system. Table 1-3 on page 1-6 shows the
differences that occur when the CPU is configuredto a big endian memorysystemfor
byte-wide access to Ports A, B, an d D. All the internal registers are inherently little
endian (i.e., the least significant byte is attached to bits 7 to 0 of the data bus). Hence,
the system Endianness affects the addresses required for byte accesses to the internal
registers, resulting in a reversal of th e byte address required to read/write a
particular byte within a register.
Introduction
11
1
There is no effect on the register addresses for word accesses. Bits
internal address bus are only decoded for Ports A, B, and D (to allow read/write to
individual ports). For all other registers,bits
will return the whole register contents onto the E P 73xx’s intern al bus, from where the
appropriate byte (according to the en dianness) will be read by the CPU. To avoid the
additional c omplexity, it is preferable to perform all internal register accesses as word
operations, except for ports A to D which are explicitly designed to operate with byte
accesses, as well as with w ord ac cesses.
An 8 Kbytes segment of memory in the range 0x8000.0000 to 0x8000.3FFF is reserved
for internal use in the EP73xx. Accesses in this range will not cause any external bus
activity unless debug mode is enabled. Writes to bits that are not explicitly defined in
the internal area are legal and will have no effect. Reads from bits not explicitly
defined in the internal area are legal but will read undefined values. A ll the internal
addresses s hould only be ac cessed as 32-bit words an d are always on a word
boundary, except for the GPIO port registers, which can be accessed as bytes. A ddress
bits in the range
internal register is valid for 64 bytes (i.e., the SYSFLG1 register appears at locations
0x8000.0140 to 0x8000.017C). There are some gaps in the register map for backward
compatibility reasons, but registers located next to a gap are still only decoded for
64 bytes.
The GPIO port registers are byte-wide and can be accessed as a word but not as a halfword. These registers additionally decode
notation.
A[0-5] are not decoded (except for Ports A–D), this means each
A[0-1] arenot decoded, s o that byte reads
A[0-1]. All addresses are in hexadecimal
A[0-1] of the
EP7309/11/12 User’s Manual - DS508UM41-3
Copyright Cirrus Logic, Inc. 2003
1
Introduction
Note: All byte-wideregisters should be accessed as words (except Port A to Port D
registers, which are designed to work in both word and byte modes).
All registers bit alignment starts from the LSB of the register (i.e., they are all
right shift justified). The registers which interact with the 32 kHz clock or which
could change during readback (i.e., RTC data registers, SYSFLG1 register
(lower 6-bits only), the TC1D and TC2D data registers,port registers, and
interrupt status registers), should be read twice and comparedto ensure that a
stable value has been read back.
All internal registers in the EP73xx are reset (cleared to zero) by a system reset (i.e.,
nPOR, nRESET,ornPWRFL signals becoming active), and the Real Time Clock data
register (RTCDR) and match register (RTCMR), which are only reset by
nPOR
becoming active. This ensures that the system time preserved through a user reset or
power fail condition. In the following register descriptions, little endian is assumed.
0x8000.2440UNIQID0R3232-bit unique ID for the EP73xx devicepage 5-13
0x8000.2600DAI64Fs0RW32DAI 64Fs Control Registerpage 16-11
0x8000.2610PLLWW8Write Register for PLL Multiplierpage 2-11
0x8000.A5A8PLLRRRead Register for PLL Multiplierpage 2-11
0x8000.2700RANDID00R32Bits 31-0 of 128-bit random ID for the EP73xx devicepage 5-13
0x8000.2704RANDID10R32Bits 63-32 of 128-bit random ID for the EP73xx devicepage 5-13
0x8000.2708RANDID20R32Bits 95-64 of 128-bit random ID for the EP73xx devicepage 5-13
0x8000.270CRANDID30R32Bits 127-96 of 128-bit random ID for the EP73xx devicepage 5-13
All other address
space that is not
assigned to a
register listed in
this table
Reserved
All addresses that are outside the address space of the
registers listed in this table are reserved. The undefined
areas contain test registers used during manufacturing
tests. Writes to this area should never be attempted
during normal operation as this may cause unexpected
behavior. Any read from this register will be undefined.
0X8000.00C3PEDDR0RW3Port E Data Direction Register
0x8000.0000PDDR0RW8Port D Data Register
0x8000.0001——8Reserved
0x8000.0002PBDR0RW8Port B Data Register
0x8000.0003PADR0RW8Port A Data Register
0x8000.0040PDDDR0RW8Port D Data Direction Register
0x8000.0041——8Reserved
0x8000.0042PBDDR0RW8Port B Data Direction Register
0x8000.0043PADDR0RW8Port A data Direction Register
Pin Description
Table 1-4 on page 1-7 describes the function of all external signals to the EP 73xx. Note
that all output signals and all I/O pins ( when acting as ou tputs) are High-Z capable.
This is to enable the High-Z test modes to be supported.
1-6EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
External Signal Functions
Table 1-4: External Signal Functions
FunctionSignal NameSignalDescription
Introduction
11
Data busD[0-31]I/O32-bit system data bus for memory, SDRAM, and I/O interface
A[0-31]O32 bits of system byte address during memory and expansion cycles
DRA[0-14] are multiplexed with A[27-13] for SDRAM memory accesses. A27
corresponds to DRA0 on SDRAM device. This offers additional power savings since
Address bus
Memory Interface
A[27-13]/
DRA[0-14]
BA[0-1]/
A[13-14]
nMOE/nSDCASOROM expansion OP enable/ SDRAM CAS control signal
nMWE/nSDWEOROM expansion write enable/ SDRAM write enable control signal
nCS[0-5]OChip select; active low, SRAM-like chip selects for expansion
SDQM[0-1]OLDQM; lower byte masks for SDRAM accesses
SDQM[2-3]OUDQM; upper byte masks for SDRAM/ multiplexed with PD[6-7]. See GPIO section
SDCS[0-1]OSDRAM chip selects
EXPRDYI
WRITE/nSDRASO
the lightest loading is expected on the high order ROM address lines.
Whenever the EP73xx is in the Standby State, the external address and data buses
O
are driven low. The RUN signal is used internally to force these buses to be driven
low. This is done to prevent peripherals that are powered-down from draining current.
Also, the internal peripheral’s signals get set to their Reset State.
I/O A13 and A14, during SDRAM accesses, become bank select pins BA0 and BA1.
Expansion port ready; external expansion devices dr ive this low to extend the bus
cycle. This is used to inser t wait states for an external bus cycle.
Transfer Direction for expansion bus/SDRAM RAS control signal during SDRAM
access
To do write accesses of different sizes Word and Half-Word must be externally
decoded. The encoding of these signals is as follows:
1
Access SizeWordHalf-Word
Word10
Half-Word01
WORD/
HALFWORD
EP7309/11/12 User’s Manual - DS508UM41-7
O
The core will generate an address. When doing a read, the ARM core will select the
appropriate byte channels. When doing a write, the correct bytes will have to be
enabled depending on the above signals and the least significant bits of the address
bus.
The ARM architecture does not support unaligned accesses. For a read using x 32
memor y, it is assumed that you will ignore bits 1 and 0 of the address bus and
perform a word read (or in power critical systems decode the relevant bits depending
on the size of the access). If an unaligned read takes place, the core will rotate the
resulting data in the register. For more information on this behavior see the LDR
instruction in the ARM7TDMI data sheet.
Copyright Cirrus Logic, Inc. 2003
Byte00
1
Introduction
Table 1-4: External Signal Functions (Continued)
FunctionSignal NameSignalDescription
Expansion clock rate is the same as the CPU clock for 13 MHz and 18 MHz. It runs
External ClockEXPCLKI/O
nMEDCHG/
nBROM
Interrupts
Power
Management
State Control
nEXTFIQIExternal active low fast interrupt request input
EINT[3]IExternal active high interrupt request input
nEINT[1-2]ITwo general purpose, active low interrupt inputs
nPWRFL
nEXTPWRI
nBATCHG
RUN/CLKENO
WAKEUP
1
1
BATOK
1
nPORI
1
at 36.864 MHz for 36,49 and 74 MHz modes; in 13 MHz mode this pin is used as the
clock input.
Media changed input; active low, deglitched. Used as a general purpose FIQ
interrupt during normal operation. It is also used on power up to configure the
I
processor to either boot from the internal Boot ROM, or from external memory.
When low, the chip will boot from the internal Boot ROM.
IPower fail input; active low, deglitched input to force system into the Standby State
Main battery OK input; falling edge generates a FIQ, a low level in the Standby State
I
inhibits system star t up; deglitched input
External power sense; must be driven low if the system is powered by an external
source
New battery sense; driven low if battery voltage falls below the "no-battery"
I
threshold; it is a deglitched input
Power-on reset input. This signal is not deglitched. When active it completely resets
the entire system, including all the RTC registers. Upon power-up, the signal must be
held active low for a minimum of 100 µsec. after V
operation, nPOR needs to be held low for at least one clock cycle of the selected
clock speed (i.e., when running at 13 MHz, the pulse width of nPOR needs to be >
77 nsec).
Note that nURESET, TEST[0], TEST[1], PE[0], PE[1], PE[2], DRIVE[0], DRIVE[1],
nMEDCHG, are all latched on the rising edge of nPOR.
This pin is programmed to either output the RUN signal or the CLKEN signal. The
CLKENSL bit is used to configure this pin. When RUN is selected, the pin will be
high when the system is active or idle, low while in the Standby State. When CLKEN
is selected, the pin will only be driven low when in the Standby State (For RUN, see
Table 1-6 on page 1-10).
Wake up is a deglitched input signal. It must also be held high for at least 125 µsec to
guarantee its detection. Once detected it forces the system into the Operating State
from the Standby State. It is only active when the system is in the Standby State.
This pin is ignored when the system is in the Idle or Operating State. It is used to
I
wakeup the system after first power-up, or after software has forced the system into
the Standby State. WAKEUP will be ignored for up to two seconds after nPOR goes
HIGH. Therefore, the external WAKEUP logic must be designed to allow it to rise and
stay HIGH for at least 125 usec, two seconds after nPOR goes HIGH.
User reset input; active low deglitched input from user reset button.
has settled. During normal
DD
DAI, CODEC or
SSI2 Interface
(See Table 1-5 on
page 1-10 for pin
assignment and
direction following
multiplexing)
nURESET
SSICLKI/ODAI/CODEC/SSI2 clock signal
SSITXFRI/ODAI/CODEC/SSI2 serial data output frame/synchronization pulse output
SSITXDAODAI/CODEC/SSI2 serial data output
SSIRXDAIDAI/CODEC/SSI2 serial data input
SSIRXFRI/O
1
I
This pin is also latched upon the rising edge of nPOR and read along with the input
pins nTEST[0-1] to force the device into special test modes. nURESET does not
reset the RTC.
SSI2 serial data input frame/synchronization pulse
DAI/CODEC external clock input
1-8EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Table 1-4: External Signal Functions (Continued)
FunctionSignal NameSignalDescription
ADCCLKOSerial clock output
ADC
Interface
(SSI1)
IrDA and
RS232
Interfaces
LCD
Keyboard &
Buzzer drive
LED Flasher
General
Purpose I/O
PWM
Drives
nADCCSOChip select for ADC interface
ADCOUTOSerial data output
ADCINISerial data input
SMPCLKOSample clock output
LEDDRVOInfrared LED drive output (UART1)
PHDINIPhoto diode input (UART1)
TXD[1-2]ORS232 UART1 and 2 TX outputs
RXD[1-2]IRS232 UART1 and 2 RX inputs
DSRIRS232 DSR input
DCDIRS232 DCD input
CTSIRS232 CTS input
DD[0-3]I/O
CL[1]OLCD line clock
CL[2]OLCD pixel clock
FRMOLCD frame synchronization pulse output
MOLCD AC bias drive
COL[0-7]OKeyboard column drives (SYSCON1)
BUZOBuzzer drive output (SYSCON1)
PD[0]/
LEDFLSH
PA[0-7]I/OPort A I/O (bit 6 for boot clock option); also used as keyboard row inputs
PB[0-7]I/OPort B I/O. All eight Port B bits can be used as GPIOs.
PD[0-5]I/OPort D I/O / PD0 multiplexed at LEDFLSH. See above.
PD[6-7]/SDQM
[0-1]
PE[0]/
BOOTSEL[0]
PE[1]/
BOOTSEL[1]
PE[2]/
CLKSEL
DRIVE[0-1]I/O
FB[0-1]IPWM feedback inputs
LCD serial display data; pins can be used on power up to read the ID of some LCD
modules (See Table 1-6 on page 1-10).
LED flasher driver — multiplexed with Port D bit 0. This pin can provide up to 4 mA
O
of drive current.
I/OPort D I/O/dedicated byte mask select for SDRAM
Port E I/O (3 bits only). Can be used as general purpose I/O dur ing normal
I/O
operation.
During power-on reset, PE[0] and PE[1] are inputs and are latched by the rising edge
I/O
of nPOR to select the memory width that the EP73xx will use to read from the boot
code storage device (i.e., external 8-bit-wide FLASH bank).
During power-on reset, PE[2] is latched by the rising edge of nPOR to select the
I/O
clock mode of operation (i.e., either the PLL or external 13 MHz clock mode).
PWM drive outputs. These pins are inputs on power up to determine what polarity
the output of the PWM should be when active. Otherwise, these pins are always an
output (See Table 1-6 on page 1-10).
Introduction
11
1
EP7309/11/12 User’s Manual - DS508UM41-9
Copyright Cirrus Logic, Inc. 2003
1
Introduction
Table 1-4: External Signal Functions (Continued)
FunctionSignal NameSignalDescription
TDIIJTAG data in
TDOOJTAG data out
Boundary
Scan
TestnTEST[0-1]I
Oscillators
No ConnectsN/CNo connects should be left as no connects; do not connect to ground
1. All deglitched inputs are via the 16.384 kHz clock. Each deglitched signal must be held active for at least two clock
periods. Therefore, the input signal must be active for at least ~125 µs to be detected cleanly.
The RTC crystal must be populated for the device to function properly.
TMSIJTAG mode select
TCLKIJTAG clock
nTRSTIJTAG async reset
Test mode select inputs. These pins are used in conjunction with the power-on
latched state of nURESET to select between the various device test models.
MOSCIN
MOSCOUT
RTCIN
RTCOUT
I
Main 3.6864 MHz oscillator for 18.432 MHz–90.3168 MHz PLL
O
I
Real Time Clock 32.768 kHz oscillator
O
DAI/CODEC/SSI2 Pin Multiplexing
Table 1-5: SSI/CODEC/DAI Pin Multiplexing
SSI2CODECDAIDirectionStrength
SSICLK PCMCLKSCLKI/O 1
SSITXFRPCMSYNCLRCKI/O1
SSITXDAPCMOUTSDOUTOutput1
SSIRXDAPCMINSDINInput
SSIRXFRp/u*MCLKI/O1
* p/u = use an ~10 k pull-up
The selection between SSI2 an d the CO DEC is controlled by the state of the SER SEL
bit in SYSCON2 (See SYSCON2 System Control Register 2). The choice between the
SSI2, CODEC, and the DAI is controlled by the DAISEL bit in SYSCON3 (See “System
Control Register 3 (SYSCON3)” on page 5-8).
Output B i-Directional Pins
Table 1-6: Output Bi-Directional Pins
RUN
The RUN pin is looped back in to skew the address and data bus from each other.
Drive [0-1]
DD[0-3]
The above output pins are implemented as bi-directional pins to enable the output side of the pad to be monitored and
1-10EP7309/11/12 User’s Manual - DS508UM4
Drive 0 and 1 are looped back in on power up to determine what polarity the output of the PWM should be when
active.
DD[0-3] are looped back on power up to bits 7:4 of the SYSFLG1 register. Pin values are latched upon the enabling of
the LCD Controller via the LCDEN bit. This is useful for reading the panel ID of some LCD modules. When some LCD
modules are reset, they will output a panel ID onto these pins. See the SYSFLG1 register for more information.
hence provide more accurate control of timing or duration.
• ARM System-on-Chip Architecture, 2nd Edition, b y Steve Furberu
Note: Click on the ARM Documentationsite to view more documents.
1-12EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Introduction
The 7312 processor u tilizes the ARM720T wh ich is based on the ARM7TDMI RISC
(Reduced Instruction Set Computer) core running at a dynamically programmable
speed from 18-90 MHz. This chapter discusses the key features of the ARM core.
Features
Key features include:
22
Chapter 2
2CPU Core
2
• ARM7TDMI CPU core (which supports the logic for the Th um b instruction
set, core debug, enhanced multiplier, JTAG, and the Embedded ICE)
running at a dynamically programmable clock speeds.
• Memory Management Unit (MMU) compatible with the ARM710 core
(providing address translation and a 64-entry translation lookaside buffer)
with added supp ort for Windows CE.
• 8 Kbytes of unified instruction an d data cache with a four-way set
associative cache controller.
ldrr0 , =0x80000000 ; base address for Standby and Idle(Halt) registers
movr1, #0xAA ; value to be written to registers
strr1, [r0,#0x0840] ; write to Standby - system will now enter Standby
strr1, [r0,#0x0800] ; write to Idle(Halt) - system, will now enter Idle
;
state
state
EP7309/11/12 User’s Manual - DS508UM42-3
Copyright Cirrus Logic, Inc. 2003
CPU Core
Operational Overview
Using the Von Neumann (load/store) architecture, the ARM720T core h as a three
stage instruction pipeline to increase the speed of the instruction execution within the
processor. The fetch-decode-execute of concurrent instructions are done in parallel
requiring approximately 1.9 CPI (cycles per instruction).
2
The core provides a 8 Kbytes un ified cache and a memory managem ent unit (MMU).
The MMU supports a two-level page table arrangement and controls the cache and
write buffer for each page created.
ARM720T core has 37 32-bit registers: 1-program counter, 1-current program status
register, 5-saved program status registers, 30-general purpose registers. The core also
supports 16 co-processor registers for control of the on-chip cache, MMU, and buffers.
Thecoresupportstwoinstructionsets,ARMandThumbforfull32-bitor16-bit
instruction decoding. State switching between ARM and Thumb, and register
assignments for each, are detailed in the ARM720T document provided by ARM. The
core supports both big as well as little-endian modes.
The core contains an embedded debug architecture. The 5-pin JTAG port will allow
the host s ystem to convert debugger commands into JTAG commands for the
purpose of hardware c ontrol to do th e following:
• Set breakpoints and watchpoints
•HalttheARMprocessor
• Access internal registers
• Access system memory
MMU
The MMU (Memory M anagement Unit) does the following
• Translates virtual addresses to physical addresses
• Controls memory access permissions, cache and write buffer accesses for
each page.
The MMU consists of a TLB (translation look aside buffer) an d hardware for page
table accesses as well as the access control logic.
Memory is divided by the MMU i n the following m anner:
• Sections: 1 Mbyte memory blocks
• Large Page: 64 Kbytes memory b locks which allows mapping of large
region with only a single entry in the TLB.
• Small Page: 4 Kbytes memory blocks
Based on the entry for the section or page, the cache and write buffer wi ll be either
enabled or disabled for that region of memory.
2-4EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
TLB
CPU Core
22
The TLB (Translation look-aside Buffer) is a 64-entry associative cache of recent
virtual address to physical address translations to eliminate a two- stage search for a
higher proportion of internal register or external bus accesses.
Cache
• Provides the translation and access permission information for memory
accesses
• For a TLB miss, the TLB walking hardware accesses the transition table
from physical memory to update itself (two-stage).
• If the TLB is full, a stored value will be over-written.
Cacheis 4-wayset associativewith 8 Kbytes of mixedinstructionand data,organized
as 512 lines of 4 words (16-byte). Connected directly to the core, cache only stores the
virtual address. Cache can only be used once the MMU is enabled. Once en abled, the
specific sections or pages of memory that are segmentedcan control whether cacheor
write buffer is used for that region. Cache is disabled at power on reset. See Figure
2-2 on page 2-6 for cache organization.
2
EP7309/11/12 User’s Manual - DS508UM42-5
Copyright Cirrus Logic, Inc. 2003
CPU Core
3111 1043210
virtual add ress
2
tag R A M
128 entry
=?=?=?=?
tag R A M
128 entry
encode
hitdata
tag R A M
128 entry
Figure 2-2. ARM720T Cache Organization
tag R A M
128 en try
[10:0]
[10:9]
byte
addresses
[1:0]
Data RAM
[8:2]
2048 x 32-bit
word
Write Buffer
Cache is direct-mapped. The copy of the address or data is stored along with an
address tag that is compared with the location in system memory. Cache is also writethrough and uses a replacement al gorithm to select which of the four possible
locations will be overwritten in the case of a cache miss.
The write buffer h olds four addresses and eight data words.The MMU defines which
addresses are bufferable. Each address can be associated with any number of data
words. Data words a re written to sequential memory s tarting at that address.
The write bufferbecomes full when all four addresses are used or all eight data words
are used. The processor can write into the write buffer at fast cache speed and
continue executing instructions stored in cache while the write buffer storesdata to
external memory at the current memory bus speed. If there is a memory fault
generated by a buffered write, the system will not be able to recover from it since the
processor state is not recoverable.
2-6EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Debug Interface
JTAG (Joint Test Action Group) or IEEE 1149 provides a boundary scan test interface
with 5 dedicated signals connected directory to the CPU core:
•TRST-TestReset(activelow)
•TCK-TestClock
• TMS - Test Mode Select
•TDI-TestDataIn
•TDO-TestDataOut
See Chapter 14 for more information on debugging the EP73xx via the JTAG interface.
CPU Register Definitions
ARM has 37 32-bit internal registers. If operating in Thumb mode, the processor must
switch to ARM m ode before taking an exception. The return instruction will restore
the processor to Th umb state. Most tasks are executed out of User mode.
CPU Core
22
2
User: Unprivileged normal operating mode.
FIQ:Fast interrupt (high priority) mode when FIQ is asserted
IRQ:Interrupt request (norm al) mode whe n IRQ i s asserted
Supervisor: Software interrupt instruction (SWI) or reset will cause entry into
this mode
Abort:Memory access violation will cause entry into this mode
Undef:Undefined instructions
System:Privileged mode. Uses same registers as user mode
Figure 2-3 on page 2-8 illustrates the use of all registers for the following core
operating modes. Each will bank or store a specific number of registers. Banked
register information is not shared between m odes. FIQs bank the fewest number of
registers which increases performance.
EP7309/11/12 User’s Manual - DS508UM42-7
Copyright Cirrus Logic, Inc. 2003
2
CPU Core
UserFIQIR QSVCUndefAbort
r13 (sp)
r14 (lr)
r15 (pc )
r0
r1
r2
r3
r4
r5
r6
r7
r8
r9
r10
r11
r12
Banked
r8
r9
r10
r11
r12
r13 (sp)
r14 (lr)
Banked
r13 (sp)
r14 (lr)
Banked
r13 (sp)
r14 (lr)
Banked
r13 (sp)
r14 (lr)
Thum b state
Low registers
Banked
Thum b state
High registers
r13 (sp)
r14 (lr)
cpsr
sps r
sps r
Figure 2-3. Register Organization Summary
spsr
User mode in Thumb state generally limits access to r0-r7. There are a f ew
instructions that allow access to the high registers. For the 5 exceptions, the processor
must revert to ARM state.
R0-R12:General pu rpose read/write 32-bit registers
R13 (sp):Stack Pointer
R14 (lr):Link Register
R15 (pc):Program Counter
CPSR:Current Program Status Register (contains condition codes and
operating modes)
SPSR:Saved Program Status Register (saves CPSR when exception oc curs)
ARM720T Core Coprocessor Registers
spsr
spsr
The ARM720T core has 16 coprocessor registers for control over the MMU. See Table
2-2 on page 2-9 Updates to the co- processor registers are written using the CP15
instruction.
2-8EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Table 2-2: ARM720T Core Coprocessor Registers
RegisterDescription
CPU Core
22
0
1
2
3
4Reserved
5
6Fault Address (Read/Write) register contains address of the last data access abort
7
8TLB Operation (Write) register can configure or clean (flush) when written to
9-12Reserved
13Used to support WinCE. Returns a logic “1” if WinCE enhancements are enabled.
14-15Reserved
ID Register (Read/Write) register than may return an ID consisting of an
architecture version and AR M trademark
Control (Read/Write) register to enable MMU, cache, write buffer, and other
coprocessor operations
Translation Base Table (Read/Write) register contains the start address of the first
level translation table
Domain Access Control (Read/Write) register specifies permissions for all 16
domains
Fault Status (Read/Write) register indicates type of fault and domain of last data
abort. Write to this location flushes entire TLB.
Cache Operation (Write) register will configure or perform a clean (flush) of the
cache and write buffer when written to
2
CPU Clocks
There are two clocks required to maintain any of the processor states that will be
described in the following section.
•RealTimeClock(RTC)
• On-chip PLL (Phase Lock Loop) Clock
• External 13 MHz Clock (Optional)
Real Time Clock (RTC)
The RTC is generated from an external 32 kHz crystal oscillator created by the crystals
fundamental tone. The RTC, from the crystal will be clocked at 1 Hz. Internally, it
contains a match and data registers that are updated once per second. More
information is contained in Chapter3 of the manual.
Real Time Clock Characteristics and Interface Requirements
• The external crystal conn ects directly to the RTCIN and RTCOUT pinson the
processor.
• 32.768 kHz frequency should be created by the fundamental tone of the
external crystal.
EP7309/11/12 User’s Manual - DS508UM42-9
Copyright Cirrus Logic, Inc. 2003
CPU Core
• Start-up resistor is n ot necessary. One is provided internally.
• Start-up capacitors may be placed on each side of the external crystal and
ground. Value for each should be around 10 pF but also should be selected
based upon crystal specifications. Capacitance of the traces and crystal
leads should be subtracted from the load capacitor value for precision.
2
• The crystal should have a maximum of 5 ppm frequency drift over the
chips’s operating temperature range.
• Voltage for the crystal must be 2.5 V+
A digital clock source can be used to drive the
the clock should match that of Vdd supply for the processor pads or the supply
voltage used to drive the non-core Vdd pins on the EP73xx. In this configuration, the
output clock pin should be left floating.
RTCIN ontheEP73xx.Voltagelevelsof
On-Chip PLL
The on-chip PLL is generated f rom an external 3.686 MHz crystal. The ARM720T
CPU clock, from the PLL, can then be programmed to 18.432, 36.864, 49.152, 73.728,
and 90.3168 MHz.
The external bus is controlled by the PLL and defaults to 18 MHz until the internal
CPU clock reaches 36 MHz or above, at which point the external bus runs at 1/2 the
CPU clock speed. Modifying the PLL speed in the SYSCON3 register will require a
NOP at the next instruction for the system to stabilize. Internally, the state controller
switches from the current clock to the new clock speed, by bringing both clocks low,
then perform the switch to the new speed to insure a glitch-free transition.
PLL Clock Characteristics and Interface Requirements
0.2 V.
• The 3.6864 M Hz frequency should be c reated by the crystals fundamental
tone.
• Start-up resistor is p rovided internally
• Value of loading capacitors should be in the range of 10 pF. However, the
actual value will depend on the crystal’s specifications. The total sum of the
capacitance on the pins and the leads should factor into the value of the
loading capacitors.
• The crystal should have a maximum of 10 ppm frequency drift over the
operating temperature of the chip.
A digital clock source can be used to drive the
levels of the clock source should match the Vdd supply for the EP73xx non-core pins.
The output clock pin (
MOSCOUT) should be left floating.
PLL Multiplier for 90 MHz Operation
There are two internal register that can be used to increase the PLL frequency beyond
74 MHz. The intention is to increase the speed to 90 MHz for use with the D AI and to
increaseoverall performance. This can affectdevices and their times ru nning from the
MOSCIN pin of the EP73xx. Voltage
2-10EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
internal PLL clock so adjustments and consideration will need to be tak en into
account.
PLL Equation: (PLL Multiplier/2)* 3.686 MHz = PLL Frequency
ex. For 90 MHz operation, PLL M ultiplier = 49
CPU Core
22
It should be noted that using the PLL Multiplier to achieve 90 MHz operation will
result in a shifting up of frequencies and rates derived from the PLL by 22. 5%. For
example, the data bus will move from 36 MHz to 45 MHz. Take care wh en using a
PLL-derived system bec ause such shifting may be in effect.
PLL_Multiplier_Write_Register EQU 0x80002610; the location of the PLL multiplier
Value_For_90_MHz_Operation EQU 0x31000000; the value for 90Mhz operation
ldr r0= PLL_Multiplier_Write_Register
ldr r1= Value_For_90_MHz_Operation
str r1, [r0]; store R1 at R0
;end
PLL Register Descriptions
2
;Write register
PLL Multiplier Write Register (PLLW)
Address: 0x8000.2610, Write Only
Definition:PLL Multiplier is written to the upper 8 b its of this register only. Do
not read from this location
PLL Multiplier Read Register (PLLR)
Address: 0x8000.A5A8, Read Only
Definition:PLL Multiplier value written to above register can be read at this
location in the upper 8 bit only. Do not write to this location.
Note: Increasing the PLL clock too high will cause the processor to abort any
operation.Decreasing the speed willnot clear the condition. A system reset and
a lower setting will be required. PLL must be preset to 74MHz via SYSCON3
before PLL m ultiplier can be used properly.
External 13 MHz Clock
An external 13 MHz crystal oscillator can be used to drive the EP73xx. When selected,
the CPU and external buses are both clocked at 13 MHz. In this c onfiguration, the
EP7309/11/12 User’s Manual - DS508UM42-11
Copyright Cirrus Logic, Inc. 2003
2
CPU Core
internal PLL is n ot used. The default value “00” for the PLL setting in SYSCON3 must
not change.
CPU State Control
There are three principal power management states on the EP73xx processor
• Operating State (highest power consumption)
• Idle State
• Standby State (lowest power consumption)
nPOR, power fail,
or user reset
Interrupt or rising wakeup
StandbyOperating
Write to standby location,
power fail, or user reset
t
p
u
r
r
e
t
n
I
Standby State
Idle
Write to halt location
Figure 2-4. State Diagram
Each state leaves on or turns off a unique set of CPU peripherals which can serve to
reduce or limit the power required for the system for blocks of time in which there is
no external system activity. The processor can enter or exit any one of the three states.
Standby state is the lowest p ower state the processor can achieve and still be c apable
of returning to operating state or equates to the system being switched off. The RTC
clock remains on to insure that the processor can “wake up” from an external
interrupt or the “wak e up” signal.
When the EP73xx is first powered on, the processor is in a “cold reset”. The same
condition can be created by asserting
nPOR. Cold reset for the processor is the
standby state. In this instance, none of the peripherals have been initialized so the
only method for entering th e operating state is by means of the
WAKEUP pin.
Clock Status
• If internal PLL is used, it will shut off
• If external 13 MHz clock is being used, CPU will ignore input. External
2-12EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
CPU Core
logic (CLKEN) pin can be used to disable external oscillator if desired. In
this configuration,
•RTCremainson.
Entering standby state can be accomplished in software by writing to the STDBY
register, or in hardware with i npu t from the
Before entering th e stand by state, the software m us t properly disable the DAI. Failing
to do so will result in higher than ex pec ted power consumption while in this state as
well as unpredictable behavior of the DAI.
During standby state, all system memory and state are m aintained and the system
time is kept up-to-date. The external address and data bus are forced low internally
by the
are powered down from draining current. Sincethe
also be used to disable external devices to further reduce power drain while in this
state. The internal peripherals external signals return to their reset state.
Exiting standby is accomplished with the following external stimulus of a keyboard
interrupt (if enabled), power management inputs, external interrupts
WAKEUP.
RUN signal which is also driven low. This is done to prevent peripherals that
nURESET or by nPWRFL.
RUN signal is driven low, it can
EINT[3:1],or
22
2
The following register will allow the system software to put the processor into
Standby state. Writing to this location will not clear the internal registers settings of
the processor. The processor will s it until an ex tern al interrupt or the
asserted and continue executing code from the poi nt of entry into Standby.
State Control Register Descriptions
Enter the Standby State Register (STDBY)
Address: 0x8000.0840, Write Only
Definition:A write to this location will put the s ys tem into the Standby State by
halting the main oscillator. A write to this location while there is an
active interrupt will have no effect.
Note: Before enteringthe Standby State, the LCD Controller should be disabled. The
LCD controller shouldbe enabled on exit from the StandbyState. If the EP73XX
is attemptingto get into the Standby State when there is a pending interrupt
request, it will not enter into the low power mode. The instructionwill get
executed, but the processor will ignore the command.
Idle State
From operating state, th e processor can en ter Idle state by writing to the HALT
register of the EP 73xx. When an interrupt occurs, the processor will return to the
operating state and execute the next instruction.
WAKEUP pin is
WAKEUP cannot be used.
In the I dle state, the device will function as it would in operating s tate with the
exception of the CPU clock which is halted. The PLL (if enabled) or the external
13 MHz clock source will remain active during this state.
EP7309/11/12 User’s Manual - DS508UM42-13
Copyright Cirrus Logic, Inc. 2003
CPU Core
The following register will allow the system software to put the processor into Idle
state.
Enter the Idle State Register (HALT)
Address: 0x8000.0800, Write Only
2
Definition:A write to this location will put the system into the Idle State by
halting the clock to the processor until an interrupt is generated. A
write to this location while there is an active interrupt will have no
effect
Below is a list of peripherals and clocks and their status during each of the three
states:
Table 2-3: Status of Peripherals and Clocks by Operating State
Address (W/B)OperatingIdleStandby
SDRAM ControlOnOnSELFREFOffN/A
UARTsOnOnOffResetReset
LCD FIFOOnOnResetResetReset
LCDOnOnOffResetReset
ADC InterfaceOnOnOffResetReset
SSI2 InterfaceOnOnOffResetReset
DAI InterfaceOnOnOffResetReset
CODECOnOnOffResetReset
TimersOnOnOffResetReset
nPOR
RESET
nURESET
RESET
RTCOnOnOnOnOn
LED FlasherOnOnOnResetReset
DC-to-DCOnOnOffResetReset
CPUOnOffOffResetReset
Interrupt ControlOnOnOnResetReset
PLL/CLKEN SignalOnOnOffOffOff
Power Up Sequence
The EP73xx has a power-up sequence that mu st be followed for a proper start. If any
of the recommended timing sequences below are viol ated, the part may not s tart
properly and may not recover without a hard reset.
1. Upon power-up,
Vdd has settled
Note: nURESET must be stable before nPOR rising.
2-14EP7309/11/12 User’s Manual - DS508UM4
nPOR must be held low for a minimum of 100 µsafter
Copyright Cirrus Logic, Inc. 2003
CPU Core
2. Once nPOR goes high, the EP73xx will enter Standby State. In this state, the
PLL is not enabledand thus the CPU is not turned on. The
must be asserted
WAKEUP signal
22
RESET
3. After
4. Once the WAKEUP signal is detected internally, it first enters a deglitching
5. Once the
There are three asynchronous resets to the EP73xx: nPOR, nPWRFL,andnURESET.If
any of these are active, a system reset is generated internally. This will reset all
internal registers in the EP73xx except the RTC data and match registers. These
registers are only cleared by
nPOR goes high, the WAKEUP signal will be detected by the processor
after one to two seconds. After such time, the
can be detected but must be asserted high for a minimum of 125 µs
Note: IMPORTANT. nURESET must not be asserted during the period between
WAKEUP assertion and transition from Standbyto Operating s tate. This will
cause t he processor to enter an unknown s tate and require a system r eset to
clear this condition.
circuit which is the reason for the 125 µs duration. The PLL is then enabled
and the CPU turns on.
read ag ain after a
time the EP73xx will return to Standby.
Idle state.
WAKEUP signal has been detected, a maximum of 250 ms will
elapse before the CPU is turned on and begins fetching the first instruction.
WAKEUP signal is then ignored and will only be
nPOR assertion or power is cycled on the device at which
nPOR.
WAKEUP (active high) signal
WAKEUP is also ignored during
2
Any reset will also reset the CPU and cause it to start execution at the reset vector
(address 0x0) when the EP73xx returns to the operating state.
Internal to the EP73xx, three different s ignals are used to reset the storag e elements.
These are
nPOR (active low) is the highest priority reset signal and is also the external signal
that forces the internal signals
signal) active. nPOR will only be active after the EP73xx has first powered up and not
during any other resets.
the cold reset flag (CLDFLG) which is bit 15 of the SYSFLG register.
nSYSRES (System R eset, active low) is generated internally to the EP73xx if nPOR,
nPWRFL,or nURESET are active. It is the second highest priority reset signal, used to
asynchronouslyresetmostinternalregistersintheEP73xx.
forces
going into Standby.This can be done without co-operation from the system software.
nSTDBY and RUN signals are high when the EP73xx is in Operating or Idle state.
The
The
except the RTC.
EP7309/11/12 User’s Manual - DS508UM42-15
nPOR, nSYSRES,andnSTDBY.
nSYSRESandnSTDBY (equivalent to the external RUN
nPOR active will clear all flags in the status register ex cept for
nSYSRES (when active)
nSTDBY and RUN low which is the result of the CPU resetting and the EP73xx
nSTDBY will disable any peripheral block that is clocked from the CPU clock
Copyright Cirrus Logic, Inc. 2003
2
CPU Core
This page intentionally blank.
2-16EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Introduction
EP73xx has three g eneral purpose timers that can serve as watchdogs for system
resources or and events. Two timers are based on the internal P LL or 13 MHz clock
and the third is fed by the RTC. Routines requiring periodic service to check status
and new values can make use of these timers.
Features
All timers have the following characteristics
33
Chapter 3
3Timers
3
• Programmable for two modes: free running and pre-scale
• Interrupt flags and corresponding mask for control and status
• Timer 16-bit read/write data register to set and read values. Can be
accessed at any time.
These identical count-down timers derive their clock from the internal PLL or
external 13 MHz clock. Values for these timers are programmed into the read/write
registers as seen below and are decremented on the s econd active edge of the clock
once the write to th e register is com plete (i.e., after the first complete period of the
clock). When the timer reaches 0, the corresponding interrupt is asserted (if enabled).
Values can be written to the data registers at any time.
When running from the PLL clock, 512 kHz and 2 kHz rates are possible for each
timer. When using the external 13 M H z crystal, the default frequencies for the timers
will be 541 and 2.115 k Hz. Optionally, in 13 MHz mode, a divider of 26 can be used to
generate a frequency of 500 kHz. This is set automatically in 13 MHz mode by setting
the OSTB bit in SYSCON2 register thus routing a 500 kHz clock to the timer. This
however, does not affect the frequencies derived for any of the other internal
peripherals.
Settingthe clock source frequencyfor TC1 and TC2 involves writesto SYSCON1 bit 5
and 7. C learing each b it sets the clock to 2 kHz. Setting this bit sets the clock at
512 kHz.
Interrupts masks f or these registers are s et in the INTMR1 register and status seen in
the INTSR1 register. To clear the interrupt for TC1 and TC2, a write to the TE2EOITC1 and TE2EOI-TC2 registers respectively will clear the underflow interrupt.
When operating at 90 Mhz, the two timers deriving their clocks from the PLL will be
shifted upwards by 22.5%. Therefore the 512 kHz clock will become 627.2 kHz and
the 2 kHz clock will become 2.45 kHz. The timer deriving its clock from the RTC is not
affected.
Free Running Mode
In free running mode, the counter will wrap around to 0xFFFF when it underflows
and will c ontinue to count down. Any value written will be decremented on the
second edge of the selected clock rate. A value of 0 in bit 4 or 6 of SYSCON1 will set
free running mode for TC1 and TC2 respectively.
3-2EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Prescale Mode
Any value wri tten to TC1 or TC2 is automatically re-loaded when the counter
underflows. Any value written to TC1 or TC2 will be decremented on the second
edge of the selected clock. Setting bit 4 or 6 in SYSCON1 for TC1 and TC2
respectively, will initiate prescale mode.
RTC Timer
The RTC timer is derived from the RTC clock. The timer interface creates a 1 Hz tick
that can be controlled by the RTCDR (RTC data register). This 32-bit read/write
register value corresponds to the number of 1 Hz ticks and will be incremented on the
next rising edge of the 1 Hz clock. Any value may be written to this register.
The interrupt driven from this c lock comes from th e RTCMR (RTC Match R egister).
Once the value in th e match register actually “matches” the value in the data register,
the interrupt will assert.
Timers
33
3
Timer Register Descriptions
Timer Counter 1 Data Register (TC1D)
Address: 0x8000.0300, Read/Write
Definition:The timer counter 1 data register is a 16-bit read/write register
which sets and reads data to TC1. Any value written will be
decremented on the next rising edge of the clock.
Timer Counter 2 Data Register(TC2D)
Address:0x8000.0340, Read/Write
Definition:The timer counter 2 data register is a 16-bit read/write register
which sets and reads data to TC2. Any value written will be
decremented on the next rising edge of the clock
Real Time Clock Data Register (RTCDR)
Address: 0x8000.0380, Read/Write
Definition:The Real Time Clock data register is a 32-bit read/write register,
which sets and reads th e binary time in the RTC. Any v alu e written
will be incremented on the next rising edge of the 1 Hz clock. This
register is reset only by
nPOR.
EP7309/11/12 User’s Manual - DS508UM43-3
Copyright Cirrus Logic, Inc. 2003
3
Timers
Real Time Clock Match Register (RTCMR)
Address: 0x8000.03C0, Read/Write
Definition:The Real Time Clock match register is a 32-bit read/write register,
which sets and reads the binary match time to RTC. Any value
written will be compared to the current binary time in the RTC, if
they match it will assert the RTCMI interrupt source. This register is
reset only by
nPOR.
3-4EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Introduction
Like most modern microprocessors, the EP73xx contains an interrupt controller to
manage both external and internal exceptions. When an expected or unexpected
event arises du ring the execution of a p rogram (i.e. interrupt or memory fault) an
exception is generated. If more than one exception occurs at the same time, a fixed
priority system determines the order in which they are handled.
Features
44
Chapter 4
4Interrupt Controller
4
• Interrupt requests received from 22 different sources
• Standard (IRQ) and Fast (FIQ) interrupt types
• Interrupts can be used to wake th e CPU from IDLE or STANDBY
ldrr0, =0x80000000 ; base address for interrupt status register
ldrr1, [r0,#0x240] ; r1 contains timer status from INTSR1
cmpr1, #TIMERCHECK
4-2EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Interrupt Controller
bnenextstatuscheck ; not the timer - moving down the IRQ routine
movr2, #0x0
strb r2, [r0,#0x0] ; setting PA0-8 low
movr2, #0xFFFFFFFF
strr2, [r0,0x06C0] ; Write to TC1EOI register - clear interrupt
44
; ........ code...........
subs pc, lr, #4 ; Return from interrupt to pending instruction
;
Operational Overview
Once an exception occurs, the ARM720T will attempt to complete the current
instruction (except for a system reset) and will then identify the interrupt type. The
interrupt vector table, already loaded by the system software contains a reference or
address of the specific interrupt routine for each type of exception identified by the
processor. The CPU will jump to the appropriate routine for servicing of the interrupt.
The vector table for all interrupt types is as follows:
Table 4-2: Vector Addresses by Interrupt Type
InterruptVector Address
Reset0x0
Undefined Instruction0x4
Software Interrupt (SWI)0x8
4
Prefetch Abort (Instruction fetch)0xC
Data abort (Data access)0x10
IRQ (normal interrupt)0x18
FIQ (fast interrupt)0x1C
Within each routine for eac h interrupt type created by the system software, the
specific interrupt can be determined by examining any one of the three status
registers. After an action is taken, a write to the appropriate “End of I nterrupt”
register must be issued to clear the interrupt status register to prevent re-entry an d an
endless loop.
For severalinterrupts occurring simultaneously, the pre-determined priority based on
type of interrupt will cause the highest interrupt priority to execute first and queue
any remaining interrupts. I nterrupts of the same type that occur simultaneously
simplyrequiresystemsoftwaretocheckallpossibleinterruptsforthespecifictype.
EP7309/11/12 User’s Manual - DS508UM44-3
Copyright Cirrus Logic, Inc. 2003
4
Interrupt Controller
Interrupt Types and Priorities
The EP73xx interrupt controller can generate two types of interrupts: Standard (IRQ)
or Fast (FIQ).Seventeenof thetwenty-twointerrupt sources areIRQ interrupts,while
the remaining five are F IQ. FIQs have a higher priority than IRQs. If two interrupts
are received from within the same group (IRQ or FIQ), the order in whichthey are
serviced must be resolved in software. The priorities are listed in Table 4-3.
Table 4-3: Exception Priority Handling
PriorityException
HighestReset
.Data Abort
.FIQ
.IRQ
.Prefetch Abort
LowestUndefined Instruction, Software Interrupt
Interrupt Operation
All i nterrupts are level sensitive; that is, they must conform to the following
sequence:
1. The interrupting dev ic e (either external or internal) asserts the ap propriate
2. If the appropriatebit is setin the interruptmask register, then eitheran FIQ
3. If interrupts are enabled, the processor jumps to the appropriate address.
4. Within the interrupt h an d ler routine, the status register is read to
5. Software in the interrupt service routine will clear the interrupt source by
The interrupt service routine may then re-enable interrupts; other pending interrupts
are serviced in a similar way. Alternately, the service routine may return to the
interrupt dispatch code, which can check for pending interrupts and dispatch them
accordingly. The “ End of I nterru pt” type interrupts are latched . All other interrupt
sources (i.e., external i nterrupt source) must b e held active until its respective service
routine starts executing. See “End-Of-Interrupt Locations” on page 4-13 for more
details.
interrupt.
or an IRQ will be asserted by the interrupt controller. (Descriptions of each
bit in this register can be found in “Interrupt Status Register 1 (INTSR1)”
on page 4-8.)
determine if the source of the interrupt(s). This will determine which
subroutine(s) to call to service said interrupt(s).
an action specific to the devi ce requesting the interrupt (i.e., reading the
UART RX register).
4-4EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Interrupt Listing
Table 4-4, Table 4-5,andTable 4-6 show the names and allocation of interrupts in the
EP73xx.
Interrupt Controller
44
Table 4-4: Interrupt Allocation in the First Interrupt Register
Interrupt
FIQ0EXTFIQExternal fast interrupt input (nEXTFIQ pin)
IRQ13URXINT1Internal UART1 receive FIFO full interrupt
IRQ14UMSINTInternal UART1 modem status changed interrupt
IRQ15SSEOTISynchronous serial interface 1 end of transfer interrupt
Bit in INTMR1
and INTSR1
NameComment
4
Table 4-5: Interrupt Allocation in the Second Interrupt Register
Interrupt
IRQ0KBDINTKey press interrupt
IRQ1SS2RXMaster / slave SSI 16 bytes received
IRQ2SS2TXMaster / slave SSI 16 bytes transmitted
IRQ12UTXINT2UART2 transmit FIFO empty interrupt
IRQ13URXINT2UART2 receive FIFO full interrupt
Interrupt
FIQ0DAIINTDAI interface interrupt
EP7309/11/12 User’s Manual - DS508UM44-5
Bit in INTMR2 and
INTSR2
Table 4-6: Interrupt Allocation in the Third Interrupt Register
Bit in INTMR3 and
INTSR3
Copyright Cirrus Logic, Inc. 2003
NameComment
NameComment
4
Interrupt Controller
Interrupt Latencies in Different States
Operating State
The ARM720T processor checks for a low level on its FIQ and IRQ inputs at th e end of
each instruction. The interrupt latency is therefore directly related to the amount of
time it takes to complete execution of the current instruction when the interrupt
condition is detected. There is a one to two clock cycle synchronization penalty
following the assertion of the interrupt. For example, if the EP73xx is operating at
13 MHz with a 16-bit external memory system, and instruction sequence stored in
one wait state FLASH memory, the worst-case interrupt latency is 251 clock cy cles.
This delay will include:
• Instruction fetch to complete LDM r0!, (r0-r15) worst case. This is a quad
word quad instruction burst on the memory bus.
• Time for interrupt signal(data abort)
• Write Buffer flush (result of LDM instruct ion)
•3TLBmisses(worstcase)
Idle State
•6cachemisses(worstcase)
• 1 additional cache and MMU miss due to fetch from vector space
The ARM720T processor, operating at 13 MHz, has a worst-case interrupt latency of
about 19.3 ms in the example system. For those interrupt inputs which have de-
glitching, the interrupt latency is increased by the maximum time required to p a ss
through the deglitcher, which is approximately 125 µs (2 cycles of the 16.384 kHz
clock derived from the RTC oscillator). Adding the deglitcher creates an absolute
worst-case latency of approximately 141 ms. If the ARM720T is run at 36 MHz or
greater, the 19.3 ms value will be reduced.
All serial data transfer peripherals included in the EP73xx (except the master-only
SSI1) have local buffering to ensure a reasonable interrupt latency response
requirement for the OS of 1 ms or less. This assumes that the design data rates do not
exceed the d ata rates described in this specification. If the OS cann ot meet this
requirement, there will be a risk of data over/underflow occurring.
When leaving the Idle State as a result of an interrupt, the CPU clock is restarted after
approximately two clock cycles. However, there is potentially up to 20 ms latency as
described above, unless the code is written to include at least two single cycle
instructions immediately after the write to the I DLE register (in whic h case the
latency drops to a few microseconds).
This is im portant, as the Idle State can only be left because of a pending interrupt,
which has to be synchronized by the processor before it can be serviced.
4-6EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Standby State
Interrupt Controller
The Standby State equates to the system b eing switched “off” (i.e., no display, and the
main oscillator is shut down). If the 18.432–73.72 MHz mode is selected, th e PLL will
be shut dow n. In the 13 MHz mode, if the CLKENSL bit is set low, the
CLKEN signal
will be forced low and can, if required, be used to disable an external oscillator.
44
In Standby State, all system memory an d state is maintained and s ys tem time is kept
current. The PLL/on-chip oscillator or external osc illator is disabled and the system i s
static, except for the low-power watch crystal (32 kH z) os ci llator and divider chain to
the RTC and LED flasher. The
the system to power down other system modules.
When the EP73xx i s in Standby State, external address and data buses are driven low.
RUN signal is used internally to force these buses to be driven low. This is done to
The
prevent peripherals that are power-down from draining current.
In Standby State, internal peripherals’ signals are set to their Reset States.
Table 4-7 summarizes the five external interrupt sources and the effect they have on
the processor interrupts.
Interrupt
Pin
nEXTFIQ
nEINT1–2Not deglitched
EINT3Not deglitched
nMEDCHG
Input State
Not deglitched; must be
active for 20 µs to be
detected
Deglitched by
16.384 kHz clock; must
be active for at least
122 µs to be detected
RUN signal is driven low, and can be used externally in
Table 4-7: External Interrupt Sources
Operating
State Latency
Worst-case
latency of 20 µs
Worst-case
latency of 20 µs
Worst-case
latency of 19.3 µs
Worst-case
latency of 141 µs
Idle State LatencyStandby State Latency
Worst-case 20 µs: if only
single cycle instructions,
less than 1 µs
Worst-case 20 µs: if only
single cycle instructions,
less than 1 µs
Worst-case 20 µs: if only
single cycle instructions,
less than 1 µs
Worst-case latency
141 µs; if any single cycle
instructions = 125 µs
4
Including PLL / osc. settling time,
approx. 0.25 sec, or approx. 500
µs when in Idle State if in 13 MHz
mode with CLKENSL set
Including PLL / osc. settling time,
approx. 0.25 sec, or approx. 500
µs when in Idle State if in 13 MHz
mode with CLKENSL set.
Including PLL / osc. settling time,
approx. 0.25 sec, or approx. 500
µs when in Idle State if in 13 MHz
mode with CLKENSL set.
As above (note difference if in
13 MHz mode with CLKENSL set)
EP7309/11/12 User’s Manual - DS508UM44-7
Copyright Cirrus Logic, Inc. 2003
4
Interrupt Controller
Interrupt Register Descriptions
Interrupt Status Register 1 (INTSR1)
31302928272625242322212019181716
RSVD
1514131211109876543210
SSEOTI UMSINT URXINT1 UT XINT1TINTRTCMITC2OITC1OIEINT3EINT2EINT1CS INT MCINTWEINTBLINT EXTFIQ
Address:0x8000.0240, Read Only
Definition:The interrupt status register is a 32-bit read only register. The
interrupt status register reflects the current state of the first 16
interrupt s ources within the EP73xx. Each bit is set if the appropriate
interrupt is active. The interrupt assignment is given below.
Bit Descriptions:
RSVD:Unknown during Read.
EXTFIQ:External fast interrupt. This interrupt will be active if the
nEXTFIQ
input pin is forced low and is mapped to the FIQ input on the
ARM720T processor.
BLINT:Battery low interrupt. This interrupt will be active if no external
supply is present (
BATOK is forced low. This interrupt is de-glitched with a 16 kHz
nEXTPWR is high) and the battery OK input pin
clock, so it will only generate an interrupt if it is active for longer
than 125 µs. It is mapped to the FIQ i nput on the ARM720T
processor and is c leared by writing to th e BLEOI location. BLINT
is disabled during The Standby State.
WEINT:Tick Watch dog exp ired interrupt. This interrupt wi ll become
active on a rising edge of the periodic 64 Hz tick interrupt clock if
the tick interrupt is still active (i.e., if a tick interrupthas not been
serviced for a complete tick p eriod). It is mapped to the FIQ input
on the ARM720T processor and the TEOI location.
Note: WEINT and watchdog timer are disabledduring the StandbyState. The watch
dog timer tick rate is 64 Hz (in 13 MHz and 73.728–18.432MHz modes).
4-8EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Interrupt Controller
MCINT:Media changed interrupt. This interrupt will be active after a
rising edge on the
input is de-glitched with a 16 kHz clock so it will only generate an
interrupt if it is active for longer than 125 µs. It is mapped to the
FIQ input on the ARM7TDMI processor and is cleared by writing
to the MCEOI location. On power-up, the Media change pin
(
nMEDCHG) is used as an input to force the processor to either
boot from the internal Boot ROM, or from external memory. After
power-up, the pin can be used as a general purpose FIQ interrupt
pin.
CSINT:CODEC sound interrupt, generated when the data FIFO has
reached half full or empty (depending on the interface direction).
It is cleared by writing to the COEOI location.
EINT1:External interrupt input 1. This interrupt will be active if the
nEINT1 input is active (low). It is clearedby returning nEINT1 to
the passive (high) s tate.
EINT2:External interrupt input 2. This interrupt will be active if the
nEINT2 input is active (low). It is clearedby returning nEINT2 to
the passive (high) s tate.
nMEDCHG input pin has been detected, This
44
4
EINT3:External interrupt input 3. This interrupt will be active if the
input is active (high). It is cleared by returning EINT3 to the
passive (low) state.
TC1OI:TC1 under flow interrupt. This interrupt becomes active on the
next falling edge of the timer c ounter 1 clock after the timer
counter has under flowed (reached zero). It is cleared by writing
to the TC1EOI location.
TC2OI:TC2 under flow interrupt. This interrupt becomes active on the
next falling edge of the timer c ounter 2 clock after the timer
counter has under flowed (reached zero). It is cleared by writing
to the TC2EOI location.
RTCMI:RTC compare match interrupt. This interrupt becomes active on
the next rising edge of the 1 Hz Real Time Clock (one second later)
after the 32-bit ti me written to the Real Time Clock match register
exactly matches the current time in the RTC. It is cleared by
writing to the RTCEOI location.
TINT:64 Hz tick interrupt.This interrupt becomes active on every rising
edgeof the internal64 Hz clock signal.This 64 Hz clock is derived
from the 15-stage ripple counter that divides the 32.768 kHz
oscillator input down to 1 Hz for the Real Time Clock. This
interrupt is cleared by writing to the TEOI location. TINT is
disabled/turned off during the Standby State.
EINT3
EP7309/11/12 User’s Manual - DS508UM44-9
Copyright Cirrus Logic, Inc. 2003
4
Interrupt Controller
UTXINT1: Internal UART1 transmit FIFO half-empty interrupt. The function
of this i nterrupt source depends on whether the UART1 FIFO is
enabled. If the FIFO is disabled (FIFOEN bit is clear in the UART1
bitrate and line controlregister), this interruptwillbe activewhen
thereisnodataintheUART1TXdataholdingregisterandbe
cleared by writing to the UART1 data register. I f the FIFO is
enabled this interrupt will be active when the UART1 TX FIFO is
half or more empty, and is cleared by filling the FIFO to at least
half full. The FIFO is 16 bytes deep.
URXINT1: Internal UART1 receive FIFO half full interrupt. The function of
this interrupt source depends on whether the UART1 FIFO i s
enabled. If the FIFO is disabled this interrupt will be active when
there is valid RX data in the UART1 RX data holding register and
be cleared by reading this data. If the FIFO is enabled this
interrupt will be active when the UART1 RX FIFO is half or more
full or if th e FIFO is non empty and no more characters have been
received for a three character time out period. I t is cleared by
reading all the data from the RX FIFO. The FIFO is 16 bytes deep.
UMSINT:Internal UART1 modem status changed interrupt. This interrupt
will be active if either of the two modem status lines (CTS or DSR)
change state. It is cleared by writing to the UMSEOI location.
SSEOTI:Synchronous serial interfaceend of transfer interrupt. This
interrupt will be active after a complete data transfer to and from
the external ADC has been completed. It is cleared by reading the
ADC data from the SYNCIO register.
Address:0x8000.0280, Read / Write
Definition:This interrupt mask register is a 32-bit read/write register, used to
selectively enable any of the first 16 interrupt sources within the
EP73xx. Interrupts associated with bits 0 through 3 generate a fast
interrupt request to the ARM720T processor (FIQ), causing a jump
to processor vi rtual address 0000.001C. All other interrupts generate
a standard interrupt request (IRQ), causing a jump to processor
virtual address 0000.0018. Set the appropriate bit in this register to
enable the c orresponding interrupt. All bits are cleared by a system
reset. Consult the bit definitions for INTSR1 for information about
interrupts associated with each mask bit.
4-10EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Interrupt Controller
Interrupt Status Register 2 (INTSR2)
31302928272625242322212019181716
RSVD
44
1514131211109876543210
RSVDURXINT 2 UTXINT2RS VDSS2TXSS2RX KB DINT
Address:0x8000.1240, Read / Write
Definition:This register is an extension of INTSR1. This interrupt status register
also reflects the currentstate of the new interruptsources within the
EP73xx. Each bit is set if the ap propriate interrupt is active. The
interrupt assignment is given below .
Bit Descriptions:
RSVD:Unknown during Read.
KBDINT:Keyboard interrupt. This interrupt is generated whenever a key is
pressed, from the logical OR of th e first 6 or all 8 of the P ort A
inputs (depending on the state of the KBD6 bit in the SY SCON2
register.The interrupt request is latched and can be de-asserted by
writing to the KBDEOI location. KBDINT is not deglitched.
SS2RX:Synchronous serial interface 2 receives FIFO half or greater full
interrupt. This is generated when RX FIFO contains 8 or more
half-words. This interrupt is cleared only when the RX FIFO is
emptied or one SSI2 clock after RX is disabled.
4
SS2TX:Synchronous serial interface 2 transmit FIFO less than half empty
interrupt. This is generated when TX FIFO contains fewer than
8 byte pairs. This interrupt gets cleared by loading the FIFO w ith
more data or disabling the TX. One synchronization clock is
required when disabling the TX side before it takes effect.
UTXINT2: UART2 transmit FIFO half empty interrupt. The function of this
interrupt source depends on whether the UART2 FIFO is enabled.
If the FIFO is disabled (FIFOEN bit is clear in the UART2 bit rate
and line control register), this interrupt will be active when there
is no data in the UART2 TX data holding register and be cleared
bywritingtotheUART2dataregister.IftheFIFOisenabled,this
interrupt will be active when the UART2 TX FIFO is half or more
empty and is cleared by filling the FIFO to at least half full. The
FIFO is 16 bytes deep.
EP7309/11/12 User’s Manual - DS508UM44-11
Copyright Cirrus Logic, Inc. 2003
4
Interrupt Controller
URXINT2: UART2 receiveFIFO half full interrupt. The function of this
interrupt source depends on whether the UART2 FIFO is enabled.
If the FIFO is disabled, this interrupt will be active when there is
valid RX data in the UART2 RX data holding register and be
cleared by reading this data. If the FIFO is enabled, this interrupt
will be active when the UART2 RX FIFO is half or more full or if
the FIFO i s non-empty, and no more ch aracters have been received
for a three-character time-out period, it is cleared by reading all
the data from the RX FIFO. The FIFO is 16 bytes deep.
Interrupt Mask Register 2 (INTMR2)
31302928272625242322212019181716
RSVD
1514131211109876543210
RSVDURXINT2 UTXINT2RSVDSS2TXSS2RX KBDINT
Address:0x8000.1280, Read / Write
Definition:This register is an extension of INTMR1, containing the interrupt
mask bits. All of the interrupts represented in INTMR2 trigg er the
standard interrupt (IRQ) signal of the ARM720T core. Please refer to
INTSR2 for individual bit details.
Descriptions:
(See “Interrupt Status Register 2 (INTSR2)” for details)
Interrupt Status Register 3 (INTSR3)
31302928272625242322212019181716
RSVD
1514131211109876543210
RSVDDAIINT
Address:0x8000.2240, Read / Write
Definition:This register is an extension of INTSR1 and INTSR2 containing only
the status bit for the DAI interface of the EP73xx. Each bit is set if the
appropriate interrupt is active. The interrupt assignment is given
below.
Bit Descriptions:
RSVD:Unknown during Read.
DAIINT:DAI interface interrupt. The cause must be determined by reading
the DAI status register. It is mapped to the FIQ interrupt on the
ARM720T processor
4-12EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Interrupt Controller
Interrupt Mask Register 3 (INTMR3)
31302928272625242322212019181716
RSVD
44
1514131211109876543210
RSVDDAIINT
Address:0x8000.2280, Read / Write
Definition:This register contains the interrupt mask for the DAI interface. This
interrupt triggers the fast interrupt (FIQ) signal of the ARM720T
core.
Bit Descriptions:
DAIINT:DAI interface interrupt. The cause must be determined by reading
the DAI status register. It is mapped to the FIQ interrupt on the
ARM720T processor.
End-Of-Interrupt Locations
The “End of Interrupt” locations that follow are written to after the app ropriate
interrupt has been serviced. The write is performed to clear the interrupt status bit, so
other interrupts can be serviced. Any value may be written to these locations.
Battery Low End of Interrupt (BLEOI)
4
Address:0x8000.0600
Definition:A write to this location will clear the interrupt generated by a low
battery (falling edge of
Media Change End of Interrupt (MCEOI)
Address:0x8000.0640
Definition:A write to this location will clear the interrupt generated by a falling
edge of th e
Tick End of Interrupt (TEOI)
Address:0x8000.0680
Definition:A write to this location will clear the current pending tick interrupt
and tick watch dog interrupt.
TC1 End of Interrupt (TC1EOI)
Address:0x8000.06C0
Definition:A write to this location will clear the under flow interrupt generated
by TC1.
nMEDCHG input pin.
BATOK with nEXTPWR high).
EP7309/11/12 User’s Manual - DS508UM44-13
Copyright Cirrus Logic, Inc. 2003
Interrupt Controller
TC1 End of Interrupt (TC2EOI)
Address:0x8000.0700
Definition:A write to this location will clear the under flow interrupt generated
by TC2.
4
RTC Match End of Interrupt (RTCEOI)
Address:0x8000.0740
Definition:A write to this location will clear the RTC match interrupt.
UART1 Modem Status Changed End of Interrupt (UMSEOI)
Address:0x8000.0780
Definition:A write to this location will clear the modem s tatus changed
interrupt.
CODEC End of Interrupt (COEOI)
Address:0x8000.07C0
Definition:A write to this location clears the sound interrupt (CSINT).
Keyboard End of Interrupt (KBDEOI)
Address:0x8000.1700
Definition:A write to this location clears the KBDINT keyboard interrupt.
SSI2 FIFO Overflow End of Interrupt (SRXEOF)
Address:0x8000.1600
Definition:A write to this location clears the SSI2 RX FIFO ov e rflo w status bit.
4-14EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Introduction
The SYSCON and SYSFLG registers control and report the status of the various
components of the EP73xx sy stem-on-chip device. There are three read/write
SYSCON system configuration registers, and two SYSFLG read on ly system flag
registers.
Features
The system registers affect aspects of the following features and peripherals:
55
Chapter 5
5System Registers
5
• Keyboard scanner
•Timers
• UART/SIR control
• Buzzer output control
•Debugmodeselect
• SSI/CODEC/DAI/ADC
•LCD
• Expansion clock
•Wakeupcontrol
•SDRAM
•OStimercontrol
•
RUN/CLKEN select
• Clock speed/wait state select
•Version
• Media change detect
•Powerstatus
• RTC subdivide
• Boot mode status
•PartID
•VersionID
• MaverickKey Unique-ID
EP7309/11/12 User’s Manual - DS508UM45-1
Copyright Cirrus Logic, Inc. 2003
System Registers
System Register List
Table 5-1: System Registers
5
AddressNameTypeSizeDescriptionPage
0x8000.0100SYSCON1R/W32System Control Register 1page 5-4
0x8000.1100SYSCON2R/W16System Control Register 2page 5-7
0x8000.2200SYSCON3R/W16System Control Register 3page 5-8
0x8000.0140SYSFLG1Read32System Status Flag Registerpage 5-9
0x8000.1140SYSFLG2Read32System Status Flag Registerpage 5-12
0x8000.05C0STFCLRR/W-Clear all Star t-up Reasons Flagpage 5-13
0x8000.2440UNIQIDRead3232-bit Unique-ID page 5-13
0x8000.2700RANDID0Read32Bits 31-0 of Random IDpage 5-13
0x8000.2704RANDID1Read32Bits 63-32 of Random IDpage 5-13
0x8000.2708RANDID2Read32Bits 95-64 of Random IDpage 5-13
0x8000.270CRANDID3Read32Bits 127-096 of Random IDpage 5-13
strr1,[r11,#0x200] ;SYSCON3 register at 0x8000.2200
;
5-2EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Operational Overview
Most of the functions represented in the SYSCON and SYSFLG registers are either
described thoroughly i n other chapters or require little explanation. Below i s a
detailed explanation of th ose that do not get covered sufficiently elsewhere in this
manual.
Buzzer
The BUZ output pin on the EP 73xx is intended as a signal source for a basic
annunciator. Two hardware sources and one software source are available for
controllingthe frequency of the signal. In software mode, the
state of the BZTOG bit in SYSCON1. It is the responsibility of the software executing
on the EP73xx to toggle BZ TOG at the desired frequency. Software mode can be used
to generate au dio tones with a controlled volume by varying the duty cy cle of the
pulse that BZTOG is fed. BZMOD must be cleared to enable the use of BZTOG.
System Registers
55
5
BUZ output reflects the
Choices of hardware sources for
chip timer TC 1. BUZFREQ selects between these two hardware sources. When
BUZFREQ is cleared, the buzzer is generated from the TC1 timer underflow bit. The
output changes every time the timer wraps around. The frequency depends on how
timer TC1 is configured. Prescale mode for timer TC1 provides the greatest flexibility
in the s election of a f requency for
programming the timers. If B UZFR EQ is set, then a 500 Hz internal timer i s fed to
BUZ. Note that in the externally clocked 13 MHz mode, this clock will be 528 Hz
unless the OSTB bit (bit 12) in SYSCON2 is set.
BUZ is also used to created MCLK for external CODECs when the DAI is enabled. For
annunciator applications,
Debug Mode
Setting the debug mode bit in the SYSCON1 register allows internal memory accesses
that would n ormally not be represented to appear on the ex ternal memory bus. In
addition, the clock for this bus as well as the two interrupt signals that are generated
by the interrupt controller are output on Port E.
When in debug mode,
addition to its usual function as an external memory strobe. External memory
accesses to the 0x5000.0000-0x5FFF.FFFF range will still cause
addition to internal memory accesses.
BUZ include the timer clock and the output of on-
BUZ.SeeChapter 3 for a detailed description of
BUZ for MCLK in the DAI must be disabled.
nCS5 becomes the address strobe for the internal accesses in
nCS5 to assert in
The nFIQ and nIRQ signals between th e interrupt controller and th e ARM720T core
will appear on Port E pins when debug mode is enabled.
of nIRQ, and
output the intern al bus clock. Using these extra signals requiresthat the data direction
bits for Port E pins
EP7309/11/12 User’s Manual - DS508UM45-3
PE2 will represent nFIQ. To aid in following memory accesses, PE0 will
PE0-PE2 must be set to output.
Copyright Cirrus Logic, Inc. 2003
PE1 will represent the state
System Registers
5
MaverickKey
™
Unique-ID
MaverickKey registers are unique ID numbers th at are p rogrammed f or use in secure
web content and commerce. TheseIDs, burnedinto specificregisterlocations givethe
OEMs a method for SD MI (Secure Digital Music Initiative) or any oth er
authentication mechanism.
There is a single 32-bit Unique ID as well as a 128-bit random ID and are laser
programmed at th e factory. These nu mbers can be used to match secure or
copyrighted content with the I D of the 73xx device f or the purpose of transmitting
said information over a secure connection.
The Unique ID is located at 0x8000.2440. The 128-bit random ID c an be found at
0x8000.2700-270C.
Address:0x8000.0100, Read / Write
Definition:The SYSCON1 system control register is a 21-bit read/write register
which controls some of the general configuration parameters for the
EP73xx as well as the c ontrol and status of internal peripherals. All
bits in this register are cleared upon system reset (nSYSRES).
Bit Descriptions:
Keyboard Scan:This four bit field defines the state of the keyboard column
driver. The following table defines these states.
Table 5-2: Keyboard Column Drive State
ValueColumn Drive State
0All high
1All low
2-7All Hi-Z (tristate)
8Column 0 high, all others Hi-Z
9Column 1 high, all others Hi-Z
10Column 2 high, all others Hi-Z
5-4EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Table 5-2: Keyboard Column Drive State (Continued)
ValueColumn Drive State
11Column 3 high, all others Hi-Z
12Column 4 high, all others Hi-Z
System Registers
55
13Column 5 high, all others Hi-Z
14Column 6 high, all others Hi-Z
15Column 7 high, all others Hi-Z
TC1M:Timer counter 1 mode. Setting this b it sets TC1 clock to prescale
mode, clearing it sets free running mode.
TC1S:Timer counter 1 clock source. Setting this bit sets the TC1 c lock
source to 512 kHz, clearing it sets the clock source to 2 kHz.
Note: Refer to “Operational Overview” on page 3-2 for more information on timers
whenthePLLissetto90MHz.
TC2M:Timer counter 2 mode. Setting this b it sets TC2 clock to prescale
mode, clearing it sets free running mode.
TC2S:Timer counter 2 clock source. Setting this bit sets the TC2 c lock
source to 512 kHz, clearing it sets the clock source to 2 kHz.
Note: Refer to “Operational Overview” on page 3-2 for more information on timers
whenthePLLissetto90MHz.
UART1EN: Internal UART enable bit. Setting this bit en ables the internal
UART.
5
BZTOG:Bit to drive (i.e. tog gle) the buzzer output directly when software
mode of operation is selected (i.e. bit BZMOD=0).
BZMOD:Buzzer drive mode select. When set, the buzzer source is
determined by BUZFREQ. When cleared, the
the state of the B ZTOG bit.
DBGEN:Forces the internal memory accesses (SRAM, boot ROM , register
space) to appear on the external address/data bus. Also outputs
the status of the internal IRQ and FIQ outp uts of the interrupt
controller and the internal bus clock on bits of Port E.
LCDEN:Enables the LCD controller when set.
CDENTX: CODEC interface TX enable bit. Setting this bit enables the
CODEC interface for data transmission to an external CODEC
device.
CDENRX: CODEC interface RX enable bit. Setting this bit enables the
CODEC interface for data reception f rom an external CODEC
device. Note that C DENRX and CDENTX must be enabled in
tandem, otherwise data may be lost.
SIREN:SIR protocol encoding bit.This enables the IrDA input and output
from UART1 as opposed to logic level serial.
BUZ output reflects
EP7309/11/12 User’s Manual - DS508UM45-5
Copyright Cirrus Logic, Inc. 2003
5
System Registers
ADCKSEL: Microwire/SPI peripheral clock speed select. This two bit field
selects the frequency of the ADC sample clock, which is twice the
frequency of the synchronous serial ADC interface clock. The
table below shows the available frequencies for operation when
the CPU is operated in either PLL mode or in 13 MHz external
clock mode. Th ese bits are also u sed to select th e master mode
shift clock frequency for the SSI2 interface when set into master
mode.
Table 5-3: ADC Sample Clock Settings
ADC Sample Frequency (kHz) — SMPCLKADC Clock Frequency (kHz) — ADCCLK
EXCKEN: External expansion clock enable. If this bit is set, the
EXPCLK is
enabled continuously as a free running clock assuming that the
main oscillator is running. Refer to CLKCTL bits[1-2] on
SYSCON3.
EXPCLK corresponds to the memory bus frequency in
the table provided. This bit should not be left set all the time for
power consumption reasons. If the system enters the Standby
State, the
EXPCLK will be active during memory cycles to expansion slots
EXPCLK will become undefined. If this bit is clear,
that have extern al wait state generation enabled only.
WAKEDIS: Setting this bit disables wak ing up from the Standby State, via the
wakeup input.
IRTXM:IrDA TX mode bit. Th is bit controls the IrDA encoding strategy.
Clearing this bit means that each zero bit transmitted i s
represented as a pulse of width 3/ 16th of the bit rate period.
Setting this bit means each zero bit is represented as a pulse of
width 3/16th of the period of 115,200-bit rate clock (i.e., 1.6 ms
regardless of the selected bit rate).
*
Setting this b it will use less
power, but will probably reduce transmission distances.
* The p ulse width will be reduced by 22.5% when operating at 90.3168 MHz.
5-6EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
System Registers
System Control Register 2 (SYSCON2)
31302928272625242322212019181716
RSVD
55
1514131211109876543210
RSVDBUZFREQCLKENSLOSTBRSVDSS2MAENUART2ENSS2RXE
Address:0x8000.1100, Read / Write
Definition:The SYSCON2 system control register is a 15-bit read/write register
which controls some of the general configuration parameters for the
EP73xx as well as the c ontrol and status of internal peripherals. All
bits in this register are cleared upon system reset (nSYSRES).
Bit Descriptions:
SERSEL:SSI2/CODEC select. When this bit is cleared, SSI 2 is connected to
the external pins. When it is set, the COD EC interface is
connected. The value of this bi t is overridden when the DAISEL
bit of SYSCON3 is set, attaching the DAI to the pins.
KBD6:The state of this bit determines how many of the Port A inputs are
OR’ed together to create the keyboard interrupt. When zero (the
reset state), all eight of the P ort A inputs will generate a keyboard
interrupt. When set high, only Port A bits 0 to 5 will generate an
interrupt from the keyboard. It is assumed that the keyboard row
lines are connected into Port A.
N
RSVDS S2TXENKBWEN SDRAMZKBD6 SERSEL
5
SDRAMZ: The bit determines the width of the SDRAM memory interface,
where: 0=32-bit SDRAM and 1=16-bit SDRAM.
KBWEN:When set, the CPU will wake from the STANDBY or IDLE states
upon the assertion of a signal on any of the Port A inputs.
Enabling this feature will allow th e CPU to wake up regardless of
the state of the KBD INT interrupt mask (INTMR2 b it 0).
SS2TXEN: Transmit enable for the synchronous serial interface 2. The
transmit side of SSI2 will be disabled until this bit is set. When set
low, this bit also disables the
mode, if the receive side is low.
SS2RXEN: Receive enable for the synchronous serial interface 2. The receive
side of SSI2 will be disabled until this bit is set. When both
SSI2TXEN and SSI2RXEN are disabled, the SSI2 interface will be
in a power saving state.
UART2EN: Internal UART2 enable bit. Setting this bit enables the internal
UART2.
SSICLK pin(to save power)in master
EP7309/11/12 User’s Manual - DS508UM45-7
Copyright Cirrus Logic, Inc. 2003
5
System Registers
SS2MAEN: Master mode enable for the synchronous serial interface 2. When
low, SSI2 will b e configured for slave mode operation. When high,
SSI2 will be configured for master mode operation. This bit also
controls the directionality of the interface pins.
OSTB:This bit (operating system timing bit) is for use only with the
13 MHz clock source mode. Normally it w ill be set low, however
when set high it will cause a 500 kHz clock to be generated for the
timers instead of the 541 kHz which would normally be available.
The divider to generate this frequency is not clocked when this bit
is set low.
CLKENSL:
BUZFREQ: Selects the hardware source for the
CLKEN select.Whenlow,theCLKEN signal will be output on the
RUN/CLKEN pin. When high, the RUN signal will be output on
RUN/CLKEN.
BUZ pin. When set, a fixed
500 Hz ( 528 Hz in 13 MHz mode and 612 Hz at 90 MHz) clock is
used as the source. When cleared, the overflow bit f rom timer TC1
is used as the clock signal.
System Control Register 3 (SYSCON3)
31302928272625242322212019181716
RSVD
1514131211109876543210
RSVDENPD67 128Fs Reserve
Address:0x8000.2200, Read / Write
Definition:The SYSCON3 system control register is a 11-bit read/write register
d-0
which controls some of the general configuration parameters for the
EP73xx as well as the c ontrol and status of internal peripherals. All
bits in this register are cleared upon system reset (nSYSRES).
VERSN (read-only)ADCCK
NSEN
DAISEL CLKCTL1CLKCTL0ADCCO
N
Bit Descriptions:
ADCCON: Determines whether the ADC Configuration E xtension field
SYNCIO[16-31] is to be used for ADC configuration data. When
this bit = 0 (default state) the ADC Configuration Byte SYNCIO[0 7] only is used for backwards compatibility. When this bit = 1, the
ADC Configuration Extension field in the SYNCIO register is
used for ADC Configuration d ata and the value in the ADC
Configuration Byte (SYNCIO[0-6]) selects the length of the data
(8-bit to 16-bit).
CLKCTL:This two-bit field determines the clock speed for the ARM720T
core, the clock speed for the memory bus, and the wait state
scaling factor. When operating the CPU from an external 13 MHz
clock, CLKCTL must be set to 00. The following table lists the
options.
5-8EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Table 5-4: ARM720T Clock Speed Settings
System Registers
55
CLKCTL[1-0]
Value
0018.432 MHz18.432 MHz1
0136.864 MHz36.864 MHz2
1049.152 MHz36.864 MHz 2
1173.728 MHz36.864 MHz2
DAISEL:When set, selects the DAI interface. Wh en cleared, selects the SSI
ADCCKNSEN:When set, ADC configuration data is transmitted on
VERSN:These read-only bits will always read ‘000’ on th e EP73xx.
Reserved-0:This bit must always be set to zero.
128Fs:DAI Frame size select. When set, th e DAI will operate on 128-bit
Processor
Frequency
Refer to the Expansion Bus Controller chapter for explicit details
on programmed wai t states at different bus frequencies.
interface.
at the rising edge of the ADCCLK, and data is read b ack on the
falling edge of the
used.
frames. When cleared, the DAI uses 64-bit f rames.
Memory Bus
Frequency
ADCIN pin. When clear, the opposite edges are
Wait State
Scaling
ADCOUT
5
ENPD67:Port D bits 6 and 7 enable. When this bit is set, these bits on Port D
are enabled as GPIOs. When cleared, the pins assigned
PD[7] are used as SDQM[0] and SDQM[1] respectively for the
SDRAM interface. ENPD67 mu st be clear in order to properly use
Address:0x8000.0140, Read Only
Definition:The SYSFLG1 system flag register is a 32-bit read only register. It
providesinformation regardingthe status of the CPU and associated
peripherals.
EP7309/11/12 User’s Manual - DS508UM45-9
Copyright Cirrus Logic, Inc. 2003
5
System Registers
Bit Descriptions:
MCDR:Media changed direct read. This bit reflects the inverted, non-
latched status of the me dia changed input.
DCDET:This bit will be set if a non-battery operated power supply is
powering the system (it is the i nverted state of the
input pin).
WUDR:Wake up direct read. This bit reflects the non-latched state of the
wakeup signal.
WUON:This bit will be set if the system has been brought out of the
Standby State by a rising edge on the wakeup signal. It is cleared
by a s ystem reset or by writing to the HALT or STDBY locations.
DID:Display ID nibble. This 4-bit nibb le reflects the l a tched state of the
four LCD data lines. The state of the four LCD data lines is latched
by the LCDEN bit, and so it will always reflect the last state of
these lines before the LCD controller was enabled.
CTS:This bit reflects the current status of the clear to send (CTS)
modem control input to UART1.
nEXTPWR
DSR:This bit reflects the current status of the data set ready (DSR)
modem control input to UART1.
DCD:This bit reflects the current status of the da ta carrier de tect (DCD)
modem control input to UART1.
UBUSY1:UART1 transmitter busy. This bit is set while UART1is busy
transmitting data, it is guaranteed to remain set until the complete
byte has been sent, including all stop bits.
NBFLG:New battery flag. This bit will be set if a low to high transition has
occurred on the
STFCLR location.
RSTFLG:Reset flag. This bit will be set if the RESET button has been
pressed, forcing the
the STFCLR location.
PFFLG:Power Fail Flag. This bit will be set if the system has been reset by
the
nPWRFL input pin, it is cleared by writing to the STFCLR
location.
CLDFLG:Cold start flag. This bit will be set if the EP73xx has been reset
with a power on reset, it is cleared by writing to the STFCLR
location.
nBATCHG input, it is cleared by writing to the
nURESET input low. It is cleared by writing to
RTCDIV:This 6-bit field reflects the number of 64 Hz ticks that have passed
since the last increment of the RTC. It is the output of the divide
by 64 c hain that divides the 64 Hz tick clock down to 1 Hz for the
RTC. The MSB is the 32 Hz output, the LSB is the 1 Hz output.
5-10EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
System Registers
URXFE1:UART1 receiver FIFO empty. The meaning of this bit dep ends on
providesinformation regardingthe status of the CPU and associated
peripherals.
Bit Descriptions:
SS2RXOF: Master/slave SSI2 RX FIFO overflow. This bit is s et when a write
is attempted to a full RX FIFO (i.e., wh en RX is still receiving data
and the FIFO is full). This can be clearedin one of two ways:
1) Empty the FIFO (remove data from FIFO) and then
write to
SRXEOF l ocation.
2) Disable the RX (affects of disabling the RX will not take
place until a full SSI2 clock cycle after it is disabled)
RESVAL:Master/slave SSI2 RX FIFO residual b yte present, cleared by
popping the residual byte into the SSI2 RX FIFO or by a new R X
frame sync pulse.
OF
RESFRM:Master/slave SSI2 RX FIFO residual byte present, cleared only by
anewRXframesyncpulse.
SS2RXFE: Master/slave SSI2 RX FIFO empty bit. This will be s et if the
16 x 1 6 RX FIFO is empty.
SS2TXFF:Master/slave SSI2 TX FIFO full b it. This will be set if the 16 x 16
TX FIFO is full. This will get cleared when data is removed from
the FIFO or the EP73xx is reset.
SS2TXUF: Master/slave SSI2 TX FIFO Underflow bit. This wi ll be set if there
is attempt to transmit when TX FIFO is empty. This will be cleared
when FIFO gets loaded with data.
CKMODE: This bit reflects the status of the
during
nPOR. When low, the PLL is running and the chip is
CLKSEL (PE[2])input,latched
operating in 18.432–73.728 MHz mode. When high the c hip is
operating from an external 13 MHz clock.
UBUSY2:UART2 transmitter busy. This bit is set while UART2is busy
transmitting data; it is guaranteed to remain set until the complete
byte has been sent, including all stop bits.
5-12EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
System Registers
URXFE2:UART2 receiver FIFO empty. The meaning of this bit dep ends on
thestateoftheUFIFOENbitintheUART2bitrateandlinecontrol
register. If the FIFO is disabled, this bit will be set when the RX
holding register contains is empty. If the FIFO is enabled, the
URXFE bit will be set when the RX FIFO is empty.
55
UTXFF2:UART2 transmitFIFO full. The meaningof thisbit depends onthe
state of the UFIFOENbit in the UART2 bit rate and line control
register. If the FIFO is disabled, this bit will be set when the TX
holding register is full. If the FIFO is enabled, the UTXFF bit will
be set when the TX FIFO is full.
Clear all Start-up Reason Flag Register (STFCLR)
Address: 0x8000.05C0, Write
Definition: A write to this location will clear all ‘Start-up reason’ flags in the
system flag status register SYSFLG. The SYSFLG register should be
read to determine the reason why the chip was or entered operating
state: (i.e., new battery installed). Any value may be written to this
location.
32-bit Unique ID Register (UNIQID)
Address:0x8000.2440, Read Only
Definition:Unique-ID for SDMI compliance for secure internet applications.
This register is read-only, and is laser programmed at the factory.
Random ID 0 Register, bits 31-0 (RANDID0)
5
Address:0x8000.2700, Read Only
Definition: This represents th e first 32 bits of a 128 bit random ID created at the
factory. This is a read only register.
Random ID 1 Register, bits 63-32 (RANDID1)
Address:0x8000.2700, Read Only
Definition:This represents the second 32 bits of a 128 bit random I D created at
the factory. This is a read only register
Random ID 2 Register, bits 95-64 (RANDID2)
Address:0x8000.2700, Read Only
Definition:This represents the third 32 bit register of a 128 bit random ID
created at the factory. This is a read only register
Random ID 3 Register, bits 127-96 (RANDID3)
Address:0x8000.2700, Read Only
Definition:This represents the upper 32 bits of a 128 bi t random ID created at
the factory. This is a read only register
EP7309/11/12 User’s Manual - DS508UM45-13
Copyright Cirrus Logic, Inc. 2003
5
System Registers
This page intentionally blank.
5-14EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Introduction
The EP73xx processor h as an internal and external boot mode. In each instance, the
processor will fetch from ROM memory, either internal or external ROM respectively.
The processor, in either mode, can be configured to interface with a big or little endian
device.
Features
66
Chapter 6
6Processor Support
6
• Internal Boot ROM for bootloader as sistance
• External BOOT mode for system boot
• Big/little endian Configuration
Operational Overview
The EP73xx processor has two boot modes: internal and external. Each mode dictates
the memory map and how the processor will perform. The p rocessor w ill boot into
either mode by latching values s een on
on the value, the processor will look to the internal BOOT ROM or to an external
ROM (
Internal Boot Mode Characteristics
External Boot Mode
CS0) and being fetching instructions from there.
•Uniquememorymap
• Boots from internal Boot ROM
•WaitsforinputfromUART1
•Uniquememorymap
•Bootsbyfetchinginstructionsfromaddress0x0
nMEDCHG pin during power on reset. Based
EP7309/11/12 User’s Manual - DS508UM46-1
Copyright Cirrus Logic, Inc. 2003
6
Processor Support
Internal Boot Mode
The 128 bytes of on-chip Boot ROM contain an instruction sequence that configure
UART1 to receive up to 2 Kbytes of serial data which is then placed in the on -chip
SRAM. Once the download is complete, the program counter jumps to SRAM to
begin executing th e downloaded data. The purpose of this mode is to allow the
downloaded code to facilitate programming of F LASH or other ROM device. See
Appendix A for code details.
Selection of the internal Boot ROM is accomplished by setting
before power-on-reset. Th e value read is latched at the rising edge of
The processor at power-on-reset is in Standby state in this mode and
nMEDCHG (active low)
nPOR.
WAKEUP must
be asserted in accordance with the power-up sequence to wake up the processor and
putitintoOperatingState.
The memory map is as follows:
Table 6-1: Chip Select Address Ranges for On-Chip Boot ROM
Address Range Chip Select
0000.0000–0FFF.FFFF
1000.0000–1FFF.FFFF
2000.0000–2FFF.FFFFnCS[5]
3000.0000–3FFF.FFFFnCS[4]
4000.0000–4FFF.FFFFnCS[3]
5000.0000–5FFF.FFFFnCS[2]
6000.0000–6FFF.FFFFnCS[1]
7000.0000–7FFF.FFFFnCS[0]
CS[7]
(Inter nal only)
CS[6]
(Inter nal only)
External Boot Mode
Normal boot mode here involves the processor sensing that nMEDGHG is not active
and then c hecks for boot width by looking at the pin values on
the width of the boot device. Table 6-2 below is the interpretation by the processor.
Table 6-2: Boot Options
PE[1]PE[0]Boot Block (nCS0)
0032-bit
018-bit
1016-bit
11Undefined
6-2EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
PE[1:0] to determine
Processor Support
External ROM i.e., FLASH or EEP ROM will be configured for access by CS0 and the
processor will begin fetching instructions from address 0x0. Before this will occur, the
processor must be put into operating state as described in the power-up sequence.
The default m emory map before the MMU is enabled and configured is as seen
below. Note that any of the chip selects can be reconfigured once the processor is in
operatingstateandproperlyfetchinginstructions.
with the maximum number of wait states for either random or s equential accesses
which will require re-programming of the MEMCFG1 register to optimize
performance for ROM accesses.
Table 6-3: Memory Map in External Boot Mode
AddressContentsSize
0xF000.0000Reserved256 Mbytes
0xE000.0000Reserved256 Mbytes
0xD000.0000Reserved256 Mbytes
0xC000.0000SDRAM64 Mbytes
0x8000.4000Unused~1 Gbyte
0x8000.0000Internal registers16 Kbytes
0x7000.0000Boot ROM (nCS[7])128 bytes
0x6000.0000SRAM (nCS[6])48,400 bytes
0x5000.0000Expansion (nCS[5])256 Mbytes
0x4000.0000Expansion (nCS[4])256 Mbytes
0x3000.0000Expansion (nCS[3])256 Mbytes
0x2000.0000Expansion (nCS[2])256 Mbytes
0x1000.0000ROM Bank 1 (nCS[1])256 Mbytes
0x0000.0000ROM Bank 0 (nCS[0])256 Mbytes
CS0 by default will a ccess memory
66
6
Note: For configuration of the individual chip selects, refer to the SDRAM/SRAM
chapter of the manual for full details.
EP7309/11/12 User’s Manual - DS508UM46-3
Copyright Cirrus Logic, Inc. 2003
6
Processor Support
Endianess
The EP73xx uses little endian configuration for the internal registers. However, it is
possible to connect to a big endian external memory device. The big-endian/littleendian bit in the i nternal registers sets whether the EP73xx treatswords in memory as
being stored in big endian or little endian format.
• Big endian - least significant byte (LSB) read as most significant byte (MSB)
• Little endian - LSB read a s LSB
Table 6-4: Effect of Endianess on Read Operations
Data in
Address
(W/B)
Word + 0(W)1122334444332211443322111122334411223344
Word + 1(W)1122334444332211443322114411223344112233
Word + 2(W)1122334444332211443322113344112233441122
Word + 3(W)1122334444332211443322112233441122334411
Word + 0 (H)1122334444332211443322110000112200003344
Word + 1(H)11223344443322114433221122000001144000033
Word + 2(H)1122334444332211443322110000334400001122
Word + 3(H)1122334444332211443322114400003322000011
Word + 0 (B)11223344dcdcdc1144dcdcdc0000001100000044
Word + 1 (B)11223344dcdc22dcdc33dcdc0000002200000033
Word + 2 (B)11223344dc33dcdcdcdc22dc0000003300000022
Word + 3 (B)1122334444dcdcdcdcdcdc110000004400000011
Note: dc = don’t care
Memory
(as seen
by the
EP73xx)
Bold indicates active byte lane.
7:015:823:1631:247:015:823: 16 31: 24 Big Endian
Byte Lanes to Memory/Ports/Registers
R0 Contents
Big Endian MemoryLittle Endian Memory
Little
Endian
Table 6-5: Effect on Endianess on Write Operations
Byte Lanes to Memory / Ports / Registers
Address
(W/B)
Word + 0 (W)112233444433221144332211
Word + 1 (W)112233444433221144332211
Word + 2 (W)112233444433221144332211
Word + 3 (W)112233444433221144332211
Word + 0 (H)112233444433443344334433
Word + 1 (H)112233444433443344334433
6-4EP7309/11/12 User’s Manual - DS508UM4
Register
Contents
Big Endian MemoryLittle Endian Memory
7:015:823:1631:247:015:823:1631:24
Copyright Cirrus Logic, Inc. 2003
Address
(W/B)
Table 6-5: Effect on Endianess on Write Operations (Continued)
Byte Lanes to Memory / Ports / Registers
Register
Contents
7:015:823:1631:247:015:823:1631:24
Big Endian MemoryLittle Endian Memory
Processor Support
66
Word + 2 (H)112233444433443344334433
Word + 3 (H)112233444433443344334433
Word + 0 (B)112233444444444444444444
Word + 1 (B)112233444444444444444444
Word + 2 (B)112233444444444444444444
Word + 3 (B)112233444444444444444444
Note: Bold indicates active byte lane.
Values seen above are not values stored into memory but what is actually seen on the
memory bus. Given the architecture, only load and store instructions will be affected
by endianess. For more information, refer to ARM Application Note 61, Big and Little
Endian Byte Addressing.
6
EP7309/11/12 User’s Manual - DS508UM46-5
Copyright Cirrus Logic, Inc. 2003
6
Processor Support
This page intentionally blank.
6-6EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Introduction
External SDRAM on the EP7311 and EP 7312 is supported via the SDRAM controller.
It allows industry standard SDRAM memories to be used within the address space of
the EP73xx with no software overhead. The controller is attached to the ARM core
through the internal high speed bus. It operates at a m aximum clock speed of
36.864 MHz (45 MHz when is CPU running at 90 MHz), providing all the necessary
connections to interface to two banks of SDRAM. For information on implementing
external SDRAM with the EP7312, s ee the Application N ote, “Interfacing the EP7312
with SDRAM” (AN218). The EP7309 does not include the SDRAM controller.
Features
77
Chapter 7
7SDRAM Controller
7
The SDRAM controller wi thin the EP7311 and EP7312 provides a convenient method
for usinginexpensiveSDRAM devices as local memory.
It supports:
• Standard NEC or compatible devices in s izes of 16 to 256 Mbit, yielding a
total memory capacity of 2 to 64 MByte
•UptotwoexternalbanksofSDRAM
internal banks for each SDRAM device.
• A programmable bus width for accessing 16 or 32 bit wide banks
• Putting the SDRAM devices into self-refresh mode when the C P U is put
into Standby
When the EP73xx encounters a power-on reset or a user reset, the SDRAM controller
is disabled. T o configure the SDRAM controller:
1. Before initializing the controller, insure that the ENDP67 bit in the
SYSCON3 register is set to its default value of 0, and the DRAMZ bit in
SYSCON2 is s et for the appropriate SD RAM access width.
2. Load the requested refresh rate into the SDRFPR register.
3. Write the SDCONF with a configuration word containing the desired
CASLAT,SDSIZE, SDWIDTH, and CLKCTL for your SDRAM devices plus
a 1 i n the SDA CTIVE bit field to activate the controller.
4. Cache (MMU ) must be enabled for the SDRAM memory regions allocated
to the sy stem software.
Immediately after initializing the controller, the SDRAM controller:
1. Sends a PRECHARGE comman d to all c onfigured SDRAM banks.
2. Sends a LOAD MOD E REGISTER command to all SDRAM devices in all
banks.
3. Loads the mode registers on all SDRAM devices with a configuration word
containing the CAS latency set in the CASLAT bits of SDCONF, a burst
length of 4, and the configuration bits to enable sequential programmed
length bursts.
4. Performs eight CBR (auto) refresh cycles to complete the initialization
sequence.
7-2EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
The SDRAM controller will continue to provide refresh cycles at the rate set in
SDRFPR until the SDACTIVE bit is set to 0 or the CPU is reset.
Byte Masks
Pins PD6 and PD7 are multiplexed with the SDQM0 and SDQM1 signals, respectively.
ENPD67, bit 10 in the SYSCON3 register, enables pins
when set. This is useful in applications which do not involve the SDRAM interface.
When cleared, pins
from the SDRAM controller. ENPD67 must be cleared in order to properly use the
SDRAM interface.
PD6 and PD7 represent the SDQM0 and SDQM1 output signals
00 = 4 bits
01 = 8 bits
10 = 16 bits
11 = 32 bits
This value is independent of the bus width setting and is
necessary to differentiate the individual devices within a bank.
CLKCTL:Control over th e SDRAM c lock:
0 = SDRAM clock is permanently enabled except when in standby
mode.
1 = SDRAM clock stops when the EP73xx is put into the
STANDBY state or SDA CTIVE = ‘0’.
There will be an additional delay of one clock cycle for any access
request made when the SDRAM clock is stopped.
SDACTIVE: Enables the SDRAM controller:
0 = Disable SDRAM controller
1 = En able SDRAM c ontroller
Thedefaultstateis‘0’.
SDRAM Refresh Period Register (SDRFPR)
31302928272625242322212019181716
RSVD
1514131211109876543210
REFRATE
Address:0x80002340, Read / Write
Definition:SDRFPR is a register containing a 16-bit value representing the
interval between SDRAM refresh commands. The value
programmed is in bus clock cycles. The following example
calculates the value for REFRATE for a 16 µSrefreshperiodwitha
bus clockof 36 MHz:
16E-6 * 36E6 = 576
The refresh timer is set to 256 by nPOR to ensure a refresh tim e of
better than 16 µS even at 13 MHz. This register should not be
programmed to a value below 2. Otherwise, the bus may become
locked.
7-4EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Introduction
The SRAM/Expansion bus controller allows for control and access to
internal/external SRAM memory as well as external peripherals th at require
read/write access to the EP73xx memory bus. The following description will
encompass both situations and detail the programming and configuration of each of
bus.
All chip selects can be configured as 8, 16, or 32-bit wide memory to interface to a
wide range of external hardware. Each chip select has a default address at power on
reset, but can change based on how the pagetable in th e MMU remaps the memory.
At power on reset, the initial setting for the Bus width for all chip selects will depend
on the state of
selects. Wait states are programmable f rom 1-8 additional clocks.
PE1 and PE0 at that time. Th e software can then reconfigure the chip
There are two internal registers for p rogramming the chip selects: MEMCFG1 and
MEMCFG2. These registers are described below.
Note: At power-on-reset or system reset, all values are cleared.
There are a total of six chip selects CS0-CS5, that are user controlledto access memory
or devices throughout th e system. Programming includes, bus width from 8-32 bits,
wait states, and bus clock access, in the event that the interface is not asynchronous.
Note: The memory area decode by CS[6] is reserved for on-chip SRAM and does not require
programming.The default configuration is 32-bit wide and no wait states.CS[7]accesses internal boot
ROM and defaults to 8-bit wide and no wait states. No additional programming is possible.
8-2EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
SRAM/Expansion Bus Controller
SRAM / Expansion Bus Register Descriptions
Memory Configuration Register 1 (MEMCFG1)
31302928272625242322212019181716
88
nCS[3] Configur ationnCS[2] Configuration
1514131211109876543210
nCS[1] Configur ationnCS[0] Configuration
Address:0x8000.0180, Read / Write
Definition:Each of the chip selects contain the same 8-bit programmable bit
fields that make up the entire configuration. The table below
describes each 0-7 bit configuration for all of the chip selects in
MEMCFG1 and MEMCFG2.
765:21:0
CLKENBSQAENWait States FieldBus width
Bit Descriptions:
Bus Width[0:1]:The table below indicates what to program into the 2-bit field.
PE1 and PE0 are examined at power-on-reset. Based on those
values,theBusWidthfieldvaluescanbedetermined.Thiswill
require examining the external hardware to know the default state
of each pin at power-on-reset.
PE1 and PE0 are both low at nPOR,thebuswidthfield
Ex. If
would then be 00 for the chip select to be programmed. This
assumes the external memory is 32 bits wide.
8
Table 8-2: Bus Width Selection Settings
Bus Width FieldExpansion Transfer Mode
0032-bit wide bus accessLow, Low
0116-bit wide bus accessLow, Low
108-bit wide bus accessLow, Low
11ReservedLow, Low
008-bit wide bus accessLow, High
01ReservedLow, High
1032-bit wide bus accessLow, High
1116-bit wide bus accessLow, High
0016-bit wide bus accessHigh, Low
EP7309/11/12 User’s Manual - DS508UM48-3
Copyright Cirrus Logic, Inc. 2003
Port E bits 1,0 during
nPOR reset
SRAM/Expansion Bus Controller
Table 8-2: Bus Width Selection Settings
8
Bus Width FieldExpansion Transfer Mode
0132-bit wide bus accessHigh, Low
10ReservedHigh, Low
118-bit wide bus accessHigh, Low
Port E bits 1,0 during
nPOR reset
Wait States Field[2:5]: There are two tables to use to program a chip select wi th
a specific number of wait states. One table is specifically for 13
and 18 MHz operation and the other is for 36 MHz and above. The
operating speed of the bu s will determine which table is used.
Table 8-3: Wait States at 13 / 18 MHz Operation
13 MHz / 18 MHz Operation
Bit 3Bit 2Bit 1Bit 0Wait States RandomWait States Sequential
xx0043
xx0132
xx1021
xx1110
Table 8-4: Wait States at 36 MHz Operation
36 MHz Operation
Bit 3Bit 2Bit 1Bit 0Wait States RandomWait States Sequential
000083
000173
001063
001153
010042
010132
011022
011112
100081
100171
101061
101151
110040
110130
111020
111110
8-4EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
SRAM/Expansion Bus Controller
SQAEN[6]: Sequential access enable. Settingthis bit will enable the sequential
accesses that are on a quad word boundary to take advantage of
faster access times from devices that s upport page mode. The
sequential accesses will be fau lted after four words (to allow video
refresh cy cles to occur), even if the access is part of a longer
sequential access. In addition, when this bit is not set, nonsequential accesses will have a single idle cycle inserted at least
every four cycles so that the chip select is de-asserted periodically
between accesses for easier debug.
88
8
CLKENB[7]: Expansion clock enable. Setting this bit enables the
active during accesses to the s elected expansion device. This will
provide a timing reference for devices that need to extend bus
cycles using the
page mode) accesses will result in a continuous clock. This bit will
only affect
18.432 MHz mode. ) When operating in 13 MHz mode, the
programming the remaining chip selects. Same programming
features and requirements apply.
EXPRDY input. Back-to-back (but not necessarily
EXPCLK when the PLL is being used (i.e., in 73.728-
EXPCLK to be
Note: CS6 and CS7 are not configurable.
EP7309/11/12 User’s Manual - DS508UM48-5
Copyright Cirrus Logic, Inc. 2003
8
SRAM/Expansion Bus Controller
This page intentionally blank.
8-6EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Introduction
The LCD interface provides all the necessary control signals to interface directly to a
single panel multiplexed LCD. It is programmable for different line lengths, bits-perpixel and refresh rates. The frame buffer can reside in either SDRAM and RAM
memory. 1/4 VGA support is typical but 1/2 VGA (monochrome) support is possible
assuming a refresh rate above 40 Hz is not required.When the CPU speed is set to 74
MHz, the bus speed will be 36 MHz. When the CPU speed is set to 90 Mhz, the bus
speed will be 45 MHz. Calculations made using the formulas in this chapter must
take C PU and bus speed variables into account.
Features
99
Chapter 9
9LCD Interface
9
• 1-2-4 bpp (bits per pixel)
• Programmable panel size to a maximum of 1024x256 at 4 bps
• Relocatable Frame Buffer (SRAM or SD RAM)
• Programmable refresh rates
•16grayscalevalues
• Color screen interface capability
LCD Register List
AddressNameTypeSizeDescriptionPage
0x8000.02C0LCDCONR/W32LCD Control Registerpage 9-7
0x8000.0580PALLSWR/W32Least Sig. Word Palettepage 9-8
0x8000.540PALMSWR/W32Most Sig Word Palettepage 9-8
; LCD Controller C onfiguration for a 640x240x4 b pp LCD Panel (ALPS)
; AC P rescale = 0x18 (LCD Manufacturer Nu mber)
;RefreshRate=60Hz
; LCD Palettes require 1 to 1 mapping between pixel value to intensity
; Pixel Prescale = 3
The LCD frame buffer is m app ed to any external SRAM or SDRAM by means of the
frame bufferstart address registers FBA DD R. The eight bit value stored in the register
represents th e physical location of this memory region (before the MMU is turned
on), not the virtual memory region. This memory must be controlled by one of the
processor chip selects.
9-2EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
The frame buffer start address begins with 0x0000000 within each memory region to
the value programmed with the FBADDR will define only the most significant byte of
the start address. F or instance, programming the register with 0xC will define the
frame buffer start address to be 0xC0000000. The register can therefore be
programmed with values from 0x1 to 0xC, d epending on the external RAM/SDRAM
memory location. Values0x7 and 0x8 are dedicated system memory for the p rocessor
Boot ROM and internal registers respectively so these values are not valid for the
LCD frame buffer. This region cannot be used. If internal SRAM is used (FBADDR =
0x6), the amount of storage is limited to 48 Kbytes but i s accessible. Calculating total
memory requirements will be necessary prior to using this fixed memory region.
The screen is mapped as on contiguous b lock of memory where each horizontal line
of pixels is mapped to a set of consecutive bytes or words. Pixel 0 represent the LSB in
a word wide access of the frame buffer memory consistent with l ittle endian
configuration.
LCD DMA Controller
LCD Interface
99
9
The DMA controller for the LCD controller is dedicated to the controller and is
designed to fetch from the frame buffer memory and fill a nine-word deep FIFO.
Once the controller is enabled, it will continue to operate without requiring service
from the CPU. The DMA controller will request data when there are only 5 words
remainingin the FIFO. The DMA bandwidth canbe calculatedbased on the following
criteria:
•refreshrate
• panel size
•bitsperpixel
1/2 VGA with 4 bpp@ 80 Hz refresh = (640x240) x 4 bps x 80 Hz = 6.14 Mb ytes/s.
This assumes that the frame buffer is stored in a 32-bit-wide memory. Sixteen-bitwidememorycanbeusedwhichwilldoubletheaccesstimeandtheDMAlatency
DMA latency calculations are based on a 32-bit-wide memory. Assuming 1/2 VGA, 5
words for a FIFO fill, 80 Hz refresh rate at 4 bpp, the maximum allowable latency can
only be ap proximately:
(5 words x 32 bits/word)/(640x240x4 bppx80 Hz) = 3.25 µs.
This number represents the worst case latency or the total number of cycles from
when the DMA request appears to when the first DMA data word actually becomes
available or is written to the FIFO. DMA has the highest priority in the system so the
FIFO fill will always occur next in sequence.
The maximum number of cycles between a DMA request for data and the first word
seen in the FIFO is 42. At 13 MHz bu s speed (77 n s cycle time), th e latency is
approximately 3.23us. At 18 MHz, the latency is reduced to 2.26 µs. At 36 MHz bus
speed, or 74 MHz internal CPU speed, the number is even furth er reduce to about
1.49 µs. The calculation is m ore c omplex. The total n umber of cycles at 36 MHz is
(12x4) + 7 = 55.
EP7309/11/12 User’s Manual - DS508UM49-3
Copyright Cirrus Logic, Inc. 2003
LCD Interface
Latency and access times will need to be calculated prior to selecting an LCD panel to
guarantee available bandwidth for the rest of the system. It should be noted that the
refresh rate is not affected by the total number of pixels.
9
Gray Scale
The figure below shows the organization of the video map for all bits-per-pixel
combinations. As seen the in the diagram, the gray s cale blocks represent the two 32bit palette registers. Each palette register represents eight 4-bit n ibbles for a total of 16
nibbles.
Gray scale creates an intensity for each of the pixel values stored in memory. Four
bits-per-pixel corresponds to a theoretical color depth of 16. Two bits-per-pixel
corresponds to a color depth of four and so on. Since gray s cale values 7 and 8 create
the same intensity, the actual color depth for 4bpp is 15. The effect is created by
simply controlling the amount of time the pixel remains on. See the Gray scale value
to Color Mapping diagram for more details.
An example of this would be the value 12, that is stored in a nibble in the framebuffer
memory. If the 4 bpp is programmed into the controller, the value 12 is mapped to the
LCD palette register for gray scale value for pixel value 12, assuming a one-to-one
correspondence between the number 12 in memory, and the i ntensity (Gray scale
value), this pixel will have a duty cycle of about 11/15 or will be lit approximately
73.3% of the time.
Programming the controller includes the following
• LCDCON: Configuration interface for a specific LCD panel
• PALLSW/PALMSW: Sets the palette registers
• FBADDR: Sets the start location in system memory for the LCD frame
buffer
• SYSCON1: LCDEN bit turns LCD controller on (enabled).
Note: LCD controllermust not be enabled until the above r egisters are programmed.
9-4EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
Pixel 1 Pixel 2 Pixel 3 Pixel 4
LCD Interface
99
Gray scale
Bit 0 Bit 1Bit 2 Bit 3 Bit 4Bit 5 Bit 6 Bit 7
4 Bits per pixel
Pixel 1 Pixel 2 Pixel 3 Pixel 4
Gray scale Gray scale
Bit 0Bit 1 Bit 2 Bit 3 Bit 4Bit 5 Bit 6 Bit 7
2 Bits per pixel
Pixel 1 Pixel 2 Pixel 3 Pixel 4
Gray scale
Gray scaleGray scale
9
Gray scaleGray scale
Bit 0 Bit 1Bit 2 Bit 3 Bit 4Bit 5 Bit 6 Bit 7
Figure 9-1. Pixel Gray Scale Mapping
EP7309/11/12 User’s Manual - DS508UM49-5
Copyright Cirrus Logic, Inc. 2003
Gray scale Gray scale
1 Bit per pixel
LCD Interface
Hardware Interface
9
DD3 DD2DD0DD1
1,1 1,2
1,3
1,4
1,640
640x240 LCD Screen
240,1
Figure 9-2. LCD Data to Pixel Mapping
DD3-DD0 carries the data that is output from th e gray scale palette registers. D ata for
240,640
each pixel will begin with the first nibble (assuming 4 bpp) at the beginning of the
framebufferwhich willcorrespond to the first pixel location as seen above. For 2 bpp
and 1 bp p, the same h ardware interface applies.
Color LCDs
The EP73xx does not directly support color LCDs. However, with minimal external
logic and a slight modification to the LCD driver, color can be supported. There are
no changes required for the control registers, on ly the data stored in the frame buffer.
• Maximum 3,375 simultaneous c olor s upport (i.e. 15 different colors per
sub-pixel)
• 1/4 VGA color STN display maximum size
• 120 x 320 x 8 b pp VGA color TFT display maximum size.
The external hardware splits
will be routed through a shift register, the other ha lf route to the LCD screen directly.
CL2 (pixel cl ock) is halved by means of a D-flip flop which is fed to both the LCD
screen and the shift register. The result is 8 bits of data present at the LCD screen at
the same time along with its pixel clock and remaining control signals. See
Application Note 179 for a completeschematic.
9-6EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
DD3-DD0 to create 8 bits of information. Half of the data
LCD Register Descriptions
LCD Control Register (LCDCON)
LCD Interface
99
31302928272625242322212019181716
GSMDGSENAC PrescalePixel PrescaleLine
1514131211109876543210
LengthVIdeo Buffer Size
Address: 0x8000.02C0, Read / Write
Bit Descriptions:
Video Bu ffer Size [0:12]:Total number of bits in the video display buffer.
Formula: (Total bits in video buffer/128) - 1
ex. 640x240 LCD with 4 bits-per-pixel
Video Buffer: 640x240x4 = 614400
Video Buffer Size = (614400/128)-1 = 4799 or 0x12BF
Note: Minimum value for this field is 3.
Line Length[13:18]:Number of p ixels in one com plete line (row).
Formula: (Number of pixels per line/16) - 1
ex. 640x240 LCD
Line length = (640/16) - 1 = 39 or 0x27
Note: Minimum value for this field is 1.
9
Pixel Prescale[19:24]: Sets the pixel rate prescale and is always derived from
36 MHz clock when in PLL mode or 13 M Hz when using the
external 13 MHz external c rystal.
Pixel Prescale = ((CPU clock (Hz))/(Refresh Rate x Total pixels) - 1
Pixel Rate = (CPU Clock (MHz)/(Pixel P rescale + 1)
ex. 640x240 in PLL mode(18-74 MHz CPU clock). 70 Hz refresh
rate is desired.
6
Pixel Prescale = (36x10
down)
Pixel rate = (36x10
rate is: 12.288x10
Note: If the EP73xx is running at 90 M Hz, the data bus r ate would increase f rom 36 to
45 MHz.
AC prescale[24:19]: Sets the LCD AC bias frequency. This frequency is the
requiredAC bias frequency for a given manufacturer’s LC D p late.
it is derived from the frequency of the line clock (CL[1]). The LCD
M signal will toggle after n+1 counts of the line clock where is M
is the number programmed into this field.
EP7309/11/12 User’s Manual - DS508UM49-7
Copyright Cirrus Logic, Inc. 2003
6
)/(70x640x240) - 1 = 2.428 or 2 (round
6
)/((2 + 1) = 12.288 MHz so the actual refresh
/(640x240) = 80 Hz
LCD Interface
GSEN[30]: Gray scale enable bit. Enables gray scale output to the LCD.
When cleared, each bi t in the vi deo map directly corresponds to a
pixel in the display.
GSMD[31]: Gray scale mode bit. Clearing this bit sets the controller to 2 bpp
(4-gray scale). Setting this bits enables 4 bpp (16-gray scale).
9
LCD Palette Registers
Least S ignificant Word (PALLSW)
31302928272625242322212019181716
Gray scale value for pixel value 7Gray scale value for pixel value 6Gray scale value for pixel value 5Gray scale value for pixel value 4
1514131211109876543210
Gray scale value for pixel value 4Gray scale value for pixel value 3Gray scale value for pixel value 2Gray scale value for pixel value 1
Address: 0x8000.0580, Read / Write
Most S ignificant Word (PALMSW)
31302928272625242322212019181716
Gray scale value for pixel value 15Gray scale value for pixel value 14Gray scale value for pixel value 13Gray scale value for pixel value 12
1514131211109876543210
Gray scale value for pixel value 11Gray scale value for pixel value 10Gray scale value for pixel value 9Gray scale value for pixel value 8
Address:0x8000.0540, Read / Write
Bit Descriptions:
The least and most significant word of the LCD palette registers
(read/write) map the pixel value stored i n the frame buffer to a
physical gray scale level. The two 32-bit registers define all gray
scale levels for a total of 4 bpp. If 2 bpp is required, only the palette
least significant word need be programmed. At 1 bpp, only the first
two nibbles in the least significant register are required to be
programmed.
Table 9-2 on page 9-8 represents the mapping of the pixel value from memory to the
Address:0x8000.1000, Read / Write
Definition:This register contains the start address for the LCD Frame Buffer. It
assumes that the frame buffer starts at location 0x0000000 within
each chip select memory region. Value programmed will set the start
address in system memory. On reset, th e default value i s 0xC which
corresponds to the physical l ocation of 0xC0000000.
The register is 4 bits wide and m ust only be programmed when the
LCD is disabled (LCDEN bit in SYSCON1 is cleared).
EP7309/11/12 User’s Manual - DS508UM49-9
Copyright Cirrus Logic, Inc. 2003
9
LCD Interface
This page intentionally blank.
9-10EP7309/11/12 User’s Manual - DS508UM4
Copyright Cirrus Logic, Inc. 2003
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.