Samsung's S3C4510B 16/32-bit RISC microcontroller is a cost-effective, high-performance microcontroller
solution for Ethernet-based systems. An integrated Ethernet controller, the S3C4510B, is designed for use in
managed communication hubs and routers.
The S3C4510B is built around an outstanding CPU core: the 16/32-bit ARM7TDMI RISC processor designed by
Advanced RISC Machines, Ltd. The ARM7TDMI core is a low-power, general purpose microprocessor macro-cell
that was developed for use in application-specific and custom-specific integrated circuits. Its simple, elegant, and
fully static design is particularly suitable for cost-sensitive and power-sensitive applications.
The S3C4510B offers a configurable 8K-byte unified cache/SRAM and Ethernet controller which reduces total
system cost. Most of the on-chip function blocks have been designed using an HDL synthesizer and the
S3C4510B has been fully verified in Samsung's state-of-the-art ASIC test environment.
Important peripheral functions include two HDLC channels with buffer descriptor, two UART channels, 2-channel
GDMA, two 32-bit timers, and 18 programmable I/O ports. On-board logic includes an interrupt controller, DRAM/
SDRAM controller, and a controller for ROM/SRAM and flash memory. The System Manager includes an internal
32-bit system bus arbiter and an external memory controller.
The following integrated on-chip functions are described in detail in this user's manual:
— 8K-byte unified cache/SRAM
XCLK80IS3C4510B system clock source. If CLKSEL is Low, PLL output
clock is used as the S3C4510B internal system clock. If
CLKSEL is High, XCLK is used as the S3C4510B internal
system clock.
MCLKO/SDCLK
(note)
CLKSEL83IClock select. When CLKSEL is '0'(low level), PLL output clock
nRESET82INot reset. nRESET is the global reset input for the S3C4510B.
CLKOEN
TMODE63ITest Mode. The TMODE bit settings are interpreted as follows:
FILTER55AIIf the PLL is used, 820pF ceramic capacitor should be
TCK58IJTAG Test Clock. The JTAG test clock shifts state information
TMS59IJTAG Test Mode Select. This pin controls JTAG test operations
TDI60IJTAG Test Data In. The TDI level is used to serially shift test
TDO61OJTAG Test Data Out. The TDO level is used to serially shift test
nTRST62IJTAG Not Reset. Asynchronous reset of the JTAG logic.
77OSystem clock out. MCLKO is monitored with some delay as the
same phase of internal system clock, MCLK(SCLK).
SDCLK is system clock for SDRAM.
can be used as the master clock. When CLKSEL is '1'(high
level), the XCLK is used as the master clock.
To allow a system reset, and for internal digital filtering,
nRESET must be held to low level for at least 64 master clock
cycles. Refer to "Figure 3. S3C4510B reset timing diagram" for
more details about reset timing.
76IClock out enable/disable. (see the pin description for MCLKO.)
'0' = normal operating mode, '1' = chip test mode.
This TMODE pin also can be used to change MF of PLL.
To get 5 times internal system clock from external clock, '0'(low
level) should be assigned to TMODE. If '1'(high level), MF will
be changed to 6.6
connected between the pin and analog ground(pin # 54).
and test data into, and out of, the S3C4510B during JTAG test
operations. This pin is internally connected pull-down.
in the S3C4510B. This pin is internally connected pull-up.
data and instructions into the S3C4510B during JTAG test
operations. This pin is internally connected pull-up.
data and instructions out of the S3C4510B during JTAG test
operations.
This pin is internally connected pull-up.
1-6
S3C4510BPRODUCT OVERVIEW
Table 1-1. S3C4510B Signal Descriptions (Continued)
SignalPin No.TypeDescription
ADDR[21:0]/
ADDR[10]/AP
(note)
117–110,
129–120,
135–132
OAddress Bus. The 22-bit address bus, ADDR[21:0], covers the full
4M word address range of each ROM/SRAM, flash memory,
DRAM, and the external I/O banks.
The 23-bit internal address bus used to generate DRAM address.
The number of column address bits in DRAM bank can be
programmed 8bits to 11bits use by DRAMCON registers.
ADDR[10]/AP is the auto precharge control pin. The auto
precharge command is issued at the same time as burst read or
burst write by asserting high on ADDR[10]/AP.
XDATA[31:0]141–136,
154–144,
I/OExternal (bi-directional, 32-bit) Data Bus. The S3C4510B data
bus supports external 8-bit, 16-bit, and 32-bit bus sizes.
166–159,
175–169
nRAS[3:0]/
nSDCS[3:0]
(note)
94, 91, 90,
89
ONot Row Address Strobe for DRAM. The S3C4510B supports up
to four DRAM banks. One nRAS output is provided for each
bank. nSDCS[3:0] are chip select pins for SDRAM.
nCAS[3:0]
nCAS[0]/nSDRAS
nCAS[1]/nSDCAS
nCAS[2]/CKE
(note)
98, 97, 96,
95
ONot column address strobe for DRAM. The four nCAS outputs
indicate the byte selections whenenver a DRAM bank is
accessed. nSDRAS is row address strobe signal for SDRAM.
Latches row addresses on the positive going edge of the SDCLK
with nSDRAS low. Enable row access and precharge. nSDCAS is
column address strobe for SDRAM. Latches column addresses
on the positive going edge of the SDCLK with nSDCAS low.
Enables column access. CKE is clock enable signal for SDRAM.
Masks SDRAM system clock, SDCLK to freeze operation from
the next clock cycle. SDCLK should be enabled at least one cycle
prior to new command. Disable input buffers of SDRAM for
power down in standby.
nDWE99ODRAM Not Write Enable. This pin is provided for DRAM bank
write operations. (nWBE[3:0] is used for write operations to the
ROM/ SRAM/flash memory banks.) .
nECS[3:0]70, 69, 68,
67
ONot External I/O Chip Select. Four external I/O banks are
provided for external memory-mapped I/O operations. Each I/O
bank stores up to 16 Kbytes. nECS signals indicate which of the
four external I/O banks is selected.
nEWAIT71INot External Wait. This signal is activated when an external I/O
device or ROM/SRAM/flash bank 5 needs more access cycles
than those defined in the corresponding control register.
When de-assert the nEWAIT, you must synchronize the nEWAIT
with MCLKO rising edge. If not, memory state machine can get
into the Wrong State.
1-7
PRODUCT OVERVIEWS3C4510B
Table 1-1. S3C4510B Signal Descriptions (Continued)
SignalPin No.TypeDescription
nRCS[5:0]88-84, 75ONot ROM/SRAM/Flash Chip Select. The S3C4510B can access
up to six external ROM/SRAM/Flash banks. By controlling the
nRCS signals, you can map CPU addresses into the physical
memory banks.
B0SIZE[1:0]74, 73IBank 0 Data Bus Access Size. Bank 0 is used for the boot
program. You use these pins to set the size of the bank 0 data
bus as follows: '01' = one byte, '10' = half-word, '11' = one word,
and '00' = reserved.
nOE72ONot Output Enable. Whenever a memory access occurs, the nOE
output controls the output enable port of the specific memory
device.
nWBE[3:0]/
DQM[3:0]
(note)
107,
102–100
ONot Write Byte Enable. Whenever a memory write access
occurs, the nWBE output controls the write enable port of the
specific memory device (except for DRAM). For DRAM banks,
CAS[3:0] and nDWE are used for the write operation.
DQM is data input/output mask signal for SDRAM.
ExtMREQ108IExternal Bus Master Request. An external bus master uses this
pin to request the external bus. When it activates the ExtMREQ
signal, the S3C4510B drives the state of external bus pins to high
impedance. This lets the external bus master take control of the
external bus. When it has the control, the external bus master
assumes responsibility for DRAM refresh operations. The
ExtMREQ signal is deactivated when the external bus master
releases the external bus. When this occurs, ExtMACK goes Low
level and the S3C4510B assumes the control of the bus.
ExtMACK109OExternal Bus Acknowledge. (See the ExtMREQ pin description.)
MDC50OManagement Data Clock. The signal level at the MDC pin is used
as a timing reference for data transfers that are controlled by the
MDIO signal.
MDIO48I/OManagement Data I/O. When a read command is being
executed, data that is clocked out of the PHY is presented on this
pin. When a write command is being executed, data that is
clocked out of the controller is presented on this pin for the
Physical Layer Entity, PHY.
LITTLE49ILittle endian mode select pin. If LITTLE is High, S3C4510B
operate in little endian mode. If Low, then in Big endian mode.
Default value is low because this pin is pull-downed internally.
COL/COL_10M38ICollision Detected/Collision Detected for 10M. COL is asserted
asynchronously with minimum delay from the start of a collision
on the medium in MII mode. COL_10M is asserted when a 10-
Mbit/s PHY detects a collision.
TX_CLK/
TXCLK_10M
46ITransmit Clock/Transmit Clock for 10M. The controller drives
TXD[3:0] and TX_EN from the rising edge of TX_CLK. In MII
mode, the PHY samples TXD[3:0] and TX_EN on the rising edge
of TX_CLK. For data transfers, TXCLK_10M is provided by the
10-Mbit/s PHY.
1-8
S3C4510BPRODUCT OVERVIEW
Table 1-1. S3C4510B Signal Descriptions (Continued)
SignalPin No.TypeDescription
TXD[3:0]
LOOP_10M
TXD_10M
44, 43, 40,
39
OTransmit Data/Transmit Data for 10 M/Loop-back for 10M.
Transmit data is aligned on nibble boundaries. TXD[0]
corresponds to the first bit to be transmitted on the physical
medium, which is the LSB of the first byte and the fifth bit of that
byte during the next clock. TXD_10M is shared with TXD[0] and
is a data line for transmitting to the 10-Mbit/s PHY. LOOP_10M is
shared with TXD[1] and is driven by the loop-back bit in the
control register.
TX_EN/
TXEN_10M
47OTransmit Enable/Transmit Enable for 10M. TX_EN provides
precise framing for the data carried on TXD[3:0]. This pin is
active during the clock periods in which TXD[3:0] contains valid
data to be transmitted from the preamble stage through CRC.
When the controller is ready to transfer data, it asserts
TXEN_10M.
TX_ERR/
PCOMP_10M
45OTransmit Error/Packet Compression Enable for 10M. TX_ERR is
driven synchronously to TX_CLK and sampled continuously by
the Physical Layer Entity, PHY. If asserted for one or more
TX_CLK periods, TX_ERR causes the PHY to emit one or more
symbols which are not part of the valid data, or delimiter set
located somewhere in the frame that is being transmitted.
PCOMP_10M is asserted immediately after the packet's DA field
is received. PCOMP_10M is used with the Management Bus of
the DP83950 Repeater Interface Controller (from National
Semiconductor). The MAC can be programmed to assert
PCOMP if there is a CAM match, or if there is not a match. The
RIC (Repeater Interface Controller) uses this signal to compress
(shorten) the packet received for management purposes and to
reduce memory usage. (See the DP83950 Data Sheet, published
by National Semiconductor, for details on the RIC Management
Bus.). This pin is controlled by a special register, with which you
can define the polarity and assertion method (CAM match active
or not match active) of the PCOMP signal.
CRS/CRS_10M28ICarrier Sense/Carrier Sense for 10M. CRS is asserted
asynchronously with minimum delay from the detection of a nonidle medium in MII mode. CRS_10M is asserted when a 10Mbit/s PHY has data to transfer. A 10-Mbit/s transmission also
uses this signal.
RX_CLK/
RXCLK_10M
37IReceive Clock/Receive Clock for 10M. RX_CLK is a continuous
clock signal. Its frequency is 25 MHz for 100-Mbit/s operation,
and 2.5 MHz for 10-Mbit/s. RXD[3:0], RX_DV, and RX_ERR are
driven by the PHY off the falling edge of RX_CLK, and sampled
on the rising edge of RX_CLK. To receive data, the TXCLK_10 M
clock comes from the 10-Mbit/s PHY.
RXD[3:0]/
RXD_10M
35, 34, 33,
30
IReceive Data/Receive Data for 10M. RXD is aligned on nibble
boundaries. RXD[0] corresponds to the first bit received on the
physical medium, which is the LSB of the byte in one clock
period and the fifth bit of that byte in the next clock. RXD_10M is
shared with RXD[0] and it is a line for receiving data from the 10Mbit/s PHY.
1-9
PRODUCT OVERVIEWS3C4510B
Table 1-1. S3C4510B Signal Descriptions (Continued)
SignalPin No.TypeDescription
RX_DV/LINK_10M29IReceive Data Valid/Link Status for 10M. PHY asserts RX_DV
synchronously, holding it active during the clock periods in which
RXD[3:0] contains valid data received. PHY asserts RX_DV no
later than the clock period when it places the first nibble of the
start frame delimiter (SFD) on RXD[3:0]. If PHY asserts RX_DV
prior to the first nibble of the SFD, then RXD[3:0] carries valid
preamble symbols. LINK_10M is shared with RX_DV and used to
convey the link status of the 10-Mbit/s endec. The value is stored
in a status register.
RX_ERR36IReceive Error. PHY asserts RX_ERR synchronously whenever it
detects a physical medium error (e.g., a coding violation). PHY
asserts RX_ERR only when it asserts RX_DV.
TXDA9OHDLC Ch-A Transmit Data. The serial output data from the
transmitter is coded in NRZ/NRZI/FM/Manchester data format.
RXDA7IHDLC Ch-A Receive Data. The serial input data received by the
device should be coded in NRZ/NRZI/FM/Manchester data
format. The data rate should not exceed the rate of the
S3C4510B internal master clock.
nDTRA6OHDLC Ch-A Data Terminal Ready. nDTRA output indicates that
the data terminal device is ready for transmission and reception.
nRTSA8OHDLC Ch-A Request To Send. The nRTSA output goes low when
there is exist data to be sent in TxFIFO. The data to be sent is
transmitted when the nCTS is active(Low) state.
nCTSA10IHDLC Ch-A Clear To Send. The S3C4510B stores each
transition of nCTS to ensure that its occurrence would be
acknowledged by the system.
nDCDA13IHDLC Ch-A Data Carrier Detected. A High level on this pin resets
and inhibits the receiver register. Data from a previous frame that
may remain in the RxFIFO is retained. The S3C4510B stores
each transition of nDCD.
nSYNCA15OHDLC Ch-A Sync is detected. This indicates the reception of a
flag. The nSYNC output goes low for one bit time beginning at
the last bit of the flag.
RXCA14IHDLC Ch-A Receiver Clock. When this clock input is used as the
receiver clock, the receiver samples the data on the positive
edge of RXCA clock. This clock can be the source clock of the
receiver, the baud rate generator, or the DPLL.
TXCA16I/OHDLC Ch-A Transmitter Clock. When this clock input is used as
the transmitter clock, the transmitter shifts data on the negative
transition of the TXCA clock . If you do not use TXCA as the
transmitter clock, you can use it as an output pin for monitoring
internal clocks such as the transmitter clock, receiver clock, and
HDLC Ch-B transmit data. See the TXDA pin description.
HDLC Ch-B receive data. See the RXDA pin description.
1-10
S3C4510BPRODUCT OVERVIEW
Table 1-1. S3C4510B Signal Descriptions (Continued)
SignalPin No.TypeDescription
nDTRB17OHDLC Ch-B data terminal ready. See the nDTRA pin description.
nRTSB19OHDLC Ch-B request to send. See the nRTSA pin description.
nCTSB23IHDLC Ch-B clear to send. See the nCTSA pin description.
nDCDB24IHDLC Ch-B data carrier detected. See the nDCDA pin
description.
nSYNCB26OHDLC Ch-B sync is detected. See the nSYNCA pin description.
RXCB25IHDLC Ch-B receiver clock. See the RXCA pin description.
TXCB27I/OHDLC Ch-B transmitter clock. See the TXCA pin description.
UCLK64IThe external UART clock input. MCLK or PLL generated clock
can be used as the UART clock. You can use UCLK, with an
appropriate divided by factor, if a very precious baud rate clock is
required.
UARXD0202IUART0 receive data. RXD0 is the UART 0 input signal for
receiving serial data.
UATXD0204OUART0 transmit data. TXD0 is the UART 0 output signal for
transmitting serial data.
nUADTR0203INot UART0 data terminal ready. This input signals the S3C4510B
that the peripheral (or host) is ready to transmit or receive serial
data.
nUADSR0205ONot UART0 data set ready. This output signals the host
(or peripheral) that UART 0 is ready to transmit or receive serial
data.
UARXD1206IUART1 receive data. See the RXD0 pin description.
UATXD14OUART1 transmit data. See the TXD0 pin description.
nUADTR13INot UART1 data terminal ready. See the DTR0 pin description.
nUADSR15ONot UART1 data set ready. See the DSR0 pin description.
P[7:0]185–179,
I/OGeneral I/O ports. See the I/O ports, chapter 12.
176
XINTREQ[3:0]
P[11:8]
nXDREQ[1:0]/
P[13:12]
nXDACK[1:0]
P[15:14]
191–189,
186
I/OExternal interrupt request lines or general I/O ports.
See the I/O ports, chapter 12.
193, 192I/ONot external DMA requests for GDMA or general I/O ports.
See the I/O ports, chapter 12.
195, 194I/ONot external DMA acknowledge from GDMA or general I/O ports.
See the I/O ports, chapter 12.
TOUT0/P[16]196I/OTimer 0 out or general I/O port. See the I/O ports, chapter 12.
TOUT1/P[17]199I/OTimer 1 out or general I/O port. See the I/O ports, chapter 12.
SCL200I/OI2C serial clock.
SDA201I/OI2C serial data.
1-11
PRODUCT OVERVIEWS3C4510B
Table 1-1. S3C4510B Signal Descriptions (Continued)
SignalPin No.TypeDescription
VDDP1, 21, 41, 56, 78,
PowerI/O pad power
92, 105, 118, 130,
155, 167, 177, 197
VDDI11, 31, 51, 65,
PowerInternal core power
103, 142, 157,
187, 207
VSSP2, 22, 42, 57, 79,
GNDI/O pad ground
81, 93, 106, 119,
131, 156, 168,
178, 198
VSSI12, 32, 52, 66,
GNDInternal core ground
104, 143, 158,
188, 208
VDDA53PowerAnalog power for PLL
VSSA/VBBA54GNDAnalog/bulk ground for PLL
NOTE: SDRAM or EDO/normal DRAM interface signal pins are shared functions. It's functions will be configured by
SYSCFG[31].
EthernetMDC1Opob4Management data clock.
ControllerMDIO1I/Optbcut4Management data I/O.
(18)COL/
COL_10M
TX_CLK/
1IptisCollision detected/collision detected for
10 M.
1IptisTransmit data/transmit data for 10 M.
TXCLK_10M
TXD[3:0]/
4Opob4Transmit data/transmit data for 10 M.
TXD_10M
LOOP_10M
TX_EN/
TXEN_10M
TX_ERR/
PCOMP_10M
CRS/
IOpob4Transmit enable or transmit enable for 10
M.
1Opob4Transmit error/packet compression
enable for 10 M.
1IptisCarrier sense/carrier sense for 10 M.
CRS_10M
RX_CLK/
1IptisReceive clock/receive clock for 10 M.
RXCLK_10M
RXD[3:0]/
41ptisReceive data/receive data for 10 M.
RXD_10M
RX_DV/
1IptisReceive data valid.
LINK_10M
RX_ERR1IptisReceive error.
HDLCTXDA1Opob4HDLC channel A transmit data.
Channel ARXDA1IptisHDLC channel A receive data.
(9)nDTRA1Opob4HDLC channel A data terminal ready.
nRTSA1Opob4HDLC channel A request to send.
nCTSA1IptisHDLC channel A clear to send.
nDCDA1IptisHDLC channel A data carrier detected.
nSYNCA1Opob4HDLC channel A sync is detected.
RXCA1IptisHDLC channel A receiver clock.
TXCA1I/Optbsut1HDLC channel A transmitter clock.
HDLCTXDB1Opob4HDLC channel B transmit data.
Channel BRXDB1IptisHDLC channel B receive data.
(9)nDTRB1Opob4HDLC channel B data terminal ready.
nRTSB1Opob4HDLC channel B request to send.
nCTSB1IptisHDLC channel B clear to send.
nDCDB1IptisHDLC channel B data carrier detected.
nSYNCB1Opob4HDLC channel B sync is detected.
RXCB1IptisHDLC channel B receiver clock.
TXCB1I/Optbsut1
HDLC channel B transmitter clock.
1-14
S3C4510BPRODUCT OVERVIEW
Table 1-2. S3C4510B Pin List and PAD Type (Continued)
NOTE: pticu and pticd provides 100K Ohm Pull-up(down) register. For detail information about the pad type, see Chapter 4.
Input/Output Cells of the "STD90/MDL90 0.35 um 3.3 V Standard Cell Library Data Book", produced by Samsung
Electrionic Co., Ltd, ASIC Team.
nRESET
64*f
MCLK
nRSCO
NOTE: After the falling edge of nRESET, the S3C4510B count 64 cycles for a system reset
and needs further 512 cycles for a TAG RAM clear of cache.
After these cycles, the S3C4510B asserts nRCS0 when the nRESET is released.
512*f
MCLK
Figure 1-3. Reset Timing Diagram
1-16
S3C4510BPRODUCT OVERVIEW
CPU CORE OVERVIEW
The S3C4510B CPU core is a general purpose 32-bit ARM7TDMI microprocessor, developed by Advanced RISC
Machines, Ltd. (ARM). The core architecture is based on Reduced Instruction Set Computer (RISC) principles.
The RISC architecture makes the instruction set and its related decoding mechanism simpler and more efficient
than those with microprogrammed Complex Instruction Set Computer (CISC) systems. High instruction
throughput and impressive real-time interrupt response are among the major beneifts of the architecture.
Pipelining is also employed so that all components of the processing and memory systems can operate
continuously. The ARM7TDMI has a 32-bit address bus.
An important feature of the ARM7TDMI processor that makes itself distinct from the ARM7 processor is a unique
architectural strategy called THUMB. The THUMB strategy is an extension of the basic ARM architecture
consisting of 36 instruction formats. These formats are based on the standard 32-bit ARM instruction set, while
having been re-coded using 16-bit wide opcodes.
As THUMB instructions are one-half the bit width of normal ARM instructions, they produce very high-density
codes. When a THUMB instruction is executed, its 16-bit opcode is decoded by the processor into its equivalent
instruction in the standard ARM instruction set. The ARM core then processes the 16-bit instruction as it would a
normal 32-bit instruction. In other words, the THUMB architecture gives 16-bit systems a way to access the 32-bit
performance of the ARM core without requiring the full overhead of 32-bit processing.
As the ARM7TDMI core can execute both standard 32-bit ARM instructions and 16-bit THUMB instructions, it
allows you to mix the routines of THUMB instructions and ARM code in the same address space. In this way, you
can adjust code size and performance, routine by routine, to find the best programming solution for a specific
application.
Address
Register
Address
Incrementer
Instruction
Register Bank
Multiplier
Barrel
Shifter
32-Bit ALU
Write Data
Register
Decoder and
Logic Controll
Instruction
Pipeline and Read
Data Register
Figure 1-4. ARM7TDMI Core Block Diagram
1-17
PRODUCT OVERVIEWS3C4510B
INSTRUCTION SET
The S3C4510B instruction set is divided into two subsets: a standard 32-bit ARM instruction set and a 16-bit
THUMB instruction set.
The 32-bit ARM instruction set is comprised of thirteen basic instruction types, which can, in turn, be divided into
four broad classes:
•Four types of branch instructions which control program execution flow, instruction privilege levels, and
switching between an ARM code and a THUMB code.
•Three types of data processing instructions which use the on-chip ALU, barrel shifter, and multiplier to
perform high-speed data operations in a bank of 31 registers (all with 32-bit register widths).
•Three types of load and store instructions which control data transfer between memory locations and the
registers. One type is optimized for flexible addressing, another for rapid context switching, and the third for
swapping data.
•Three types of co-processor instructions which are dedicated to controlling external co-processors. These
instructions extend the off-chip functionality of the instruction set in an open and uniform way.
NOTE
All 32-bit ARM instructions can be executed conditionally.
The 16-bit THUMB instruction set contains 36 instruction formats drawn from the standard 32-bit ARM instruction
set. The THUMB instructions can be divided into four functional groups:
•Four branch instructions.
•Twelve data processing instructions, which are a subset of the standard ARM data processing instructions.
•Eight load and store register instructions.
•Four load and store multiple instructions.
NOTE
Each 16-bit THUMB instruction has a corresponding 32-bit ARM instruction with an identical
processing model.
The 32-bit ARM instruction set and the 16-bit THUMB instruction set are good targets for compilers of many
different high-level languages. When an assembly code is required for critical code segments, the ARM
programming technique is straightforward, unlike that of some RISC processors which depend on sophisticated
compiler technology to manage complicated instruction interdependencies.
Pipelining is employed so that all parts of the processor and memory systems can operate continuously.
Typically, while one instruction is being executed, its successor is being decoded, and the third instruction is
being fetched from memory.
1-18
S3C4510BPRODUCT OVERVIEW
MEMORY INTERFACE
The CPU memory interface has been designed to help the highest performance potential to be realized without
incurring high costs in the memory system. Speed-critical control signals are pipelined so that system control
functions can be implemented in standard low-power logic. These pipelined control signals allow you to fully
exploit the fast local access modes, offered by industry standard dynamic RAMs.
OPERATING STATES
From a programmer′s point of view, the ARM7TDMI core is always in one of two operating states. These states,
which can be switched by software or by exception processing, are:
•ARM state (when executing 32-bit, word-aligned, ARM instructions), and
• THUMB state (when executing 16-bit, half-word aligned THUMB instructions).
OPERATING MODES
The ARM7TDMI core supports seven operating modes:
•User mode: a normal program execution state
•FIQ (Fast Interrupt Request) mode: for supporting a specific data transfer or channel processing
•IRQ (Interrupt ReQuest) mode: for general purpose interrupt handling
•Supervisor mode: a protected mode for the operating system
•Abort mode: entered when a data or instruction pre-fetch is aborted
•System mode: a privileged user mode for the operating system
•Undefined mode: entered when an undefined instruction is executed
Operating mode changes can be controlled by software. They can also be caused by external interrupts or
exception processing. Most application programs execute in user mode. Privileged modes (that is, all modes
other than User mode) are entered to service interrupts or exceptions, or to access protected resources.
1-19
PRODUCT OVERVIEWS3C4510B
REGISTERS
The S3C4510B CPU core has a total of 37 registers: 31 general-purpose 32-bit registers, and 6 status registers.
Not all of these registers are always available. Whether a registers is available to the programmer at any given
time depends on the current processor operating state and mode.
NOTE
When the S3C4510B is operating in ARM state, 16 general registers and one or two status registers can
be accessed at any time. In privileged mode, mode-specific banked registers are switched in.
Two register sets, or banks, can also be accessed, depending on the core′s current state, the ARM state registerset and the THUMB state register set:
•The ARM state register set contains 16 directly accessible registers: R0-R15. All of these registers, except for
R15, are for general-purpose use, and can hold either data or address values. An additional (17th) register,
the CPSR (Current Program Status Register), is used to store status information.
•The THUMB state register set is a subset of the ARM state set. You can access 8 general registers, R0-R7,
as well as the program counter (PC), a stack pointer register (SP), a link register (LR), and the CPSR. Each
privileged mode has a corresponding banked stack pointer, link register, and saved process status register
(SPSR).
The THUMB state registers are related to the ARM state registers as follows:
•THUMB state R0-R7 registers and ARM state R0–R7 registers are identical
•THUMB state CPSR and SPSRs and ARM state CPSR and SPSRs are identical
•THUMB state SP, LR, and PC are mapped directly to ARM state registers R13, R14, and R15, respectively
In THUMB state, registers R8-R15 are not part of the standard register set. However, you can access them for
assembly language programming and use them for fast temporary storage, if necessary.
1-20
S3C4510BPRODUCT OVERVIEW
EXCEPTIONS
An exception arises when the normal flow of program execution is interrupted, e.g., when processing is diverted
to handle an interrupt from a peripheral. The processor state just prior to handling the exception must be
preserved so that the program flow can be resumed when the exception routine is completed. Multiple exceptions
may arise simultaneously.
To process exceptions, the S3C4510B uses the banked core registers to save the current state. The old PC value
and the CPSR contents are copied into the appropriate R14 (LR) and SPSR registers. The PC and mode bits in
the CPSR are adjusted to the value corresponding to the type of exception being processed.
The S3C4510B core supports seven types of exceptions. Each exception has a fixed priority and a corresponding
privileged processor mode, as shown in Table 1-4.
SystemSYSCFG0x0000R/WSystem configuration register0x37FFFF91
ManagerCLKCON0x3000R/WClock control register0x00000000
EXTACON00x3008R/WExternal I/O timing register 10x00000000
EXTACON10x300CR/WExternal I/O timing register 20x00000000
EXTDBWTH0x3010R/WData bus width for each memory bank0x00000000
ROMCON00x3014R/WROM/SRAM/Flash bank 0 control register0x20000060
ROMCON10x3018R/WROM/SRAM/Flash bank 1 control register0x00000060
ROMCON20x301CR/WROM/SRAM/Flash bank 2 control register0x00000060
ROMCON30x3020R/WROM/SRAM/Flash bank 3 control register0x00000060
ROMCON40x3024R/WROM/SRAM/Flash bank 4 control register0x00000060
ROMCON50x3028R/WROM/SRAM/Flash bank 5 control register0x00000060
DRAMCON00x302CR/WDRAM bank 0 control register0x00000000
DRAMCON10x3030R/WDRAM bank 1 control register0x00000000
DRAMCON20x3034R/WDRAM bank 2 control register0x00000000
DRAMCON30x3038R/WDRAM bank 3 control register0x00000000
REFEXTCON0x303CR/WRefresh and external I/O control register0x000083FD
EthernetBDMATXCON0x9000R/WBuffered DMA receive control register0x00000000
(BDMA)BDMARXCO
Ethernet MAC control register
CAM control register
MAC transmit control register
MAC transmit status register
MAC receive control register
MAC receive status register
I/O PortsIOPMOD0x5000R/WI/O port mode register0x00000000
IOPCON0x5004R/WI/O port control register0x00000000
IOPDATA0x5008R/WInput port data registerUndefined
InterruptINTMOD0x4000R/WInterrupt mode register0x00000000
ControllerINTPND0x4004R/WInterrupt pending register0x00000000
UARTULCON00xD000R/WUART channel 0 line control register0x00
ULCON10xE000R/WUART channel 1 line control register0x00
UCON00xD004R/WUART channel 0 control register0x00
UCON10xE004R/WUART channel 1 control register0x00
USTAT00xD008RUART channel 0 status register0xC0
USTAT10xE008RUART channel 1 status register0xC0
UTXBUF00xD00CWUART channel 0 transmit holding registerUndefined
UTXBUF10xE00CWUART channel 1 transmit holding registerUndefined
URXBUF00xD010RUART channel 0 receive buffer registerUndefined
URXBUF10xE010RUART channel 1 receive buffer registerUndefined
UBRDIV00xD014R/WBaud rate divisor register 00x00
UBRDIV10xE014R/WBaud rate divisor register 10x00
TimersTMOD0x6000R/WTimer mode register0x00000000
TDATA00x6004R/WTimer 0 data register0x00000000
TDATA10x6008R/WTimer 1 data register0x00000000
TCNT00x600CR/WTimer 0 count register0xFFFFFFFF
TCNT10x6010R/WTimer 1 count register0xFFFFFFFF
1-25
PRODUCT OVERVIEWS3C4510B
NOTES
1-26
S3C4510BPROGRAMMER'S MODEL
2PROGRAMMER′′S MODEL
OVERVIEW
S3C4510B was developed using the advanced ARM7TDMI core designed by advanced RISC machines, Ltd.
Processor Operating States
From the programmer′s point of view, the ARM7TDMI can be in one of two states:
— ARM state which executes 32-bit, word-aligned ARM instructions.
— THUMB state which operates with 16-bit, half-word-aligned THUMB instructions. In this state, the PC uses bit
1 to select between alternate half-words.
NOTE
Transition between these two states does not affect the processor mode or the contents of the registers.
SWITCHING STATE
Entering THUMB State
Entry into THUMB state can be achieved by executing a BX instruction with the state bit (bit 0) set in the operand
register.
Transition to THUMB state will also occur automatically on return from an exception (IRQ, FIQ, UNDEF, ABORT,
SWI etc.), if the exception was entered with the processor in THUMB state.
Entering ARM State
Entry into ARM state happens:
1. On execution of the BX instruction with the state bit clear in the operand register.
2. On the processor taking an exception (IRQ, FIQ, RESET, UNDEF, ABORT, SWI etc.). In this case, the PC is
placed in the exception mode′s link register, and execution commences at the exception′s vector address.
MEMORY FORMATS
ARM7TDMI views memory as a linear collection of bytes numbered upwards from zero. Bytes 0 to 3 hold the first
stored word, bytes 4 to 7 the second and so on. ARM7TDMI can treat words in memory as being stored either in
Big-Endian or Little-Endian format.
2-1
PROGRAMMER'S MODELS3C4510B
BIG-ENDIAN FORMAT
In Big-Endian format, the most significant byte of a word is stored at the lowest numbered byte and the least
significant byte at the highest numbered byte. Byte 0 of the memory system is therefore connected to data lines
31 through 24.
Higher address
Lower address
31
24
8
4
0
wMost significant byte is at lowest address
wWord is addressed by byte address of most signficant byte
9158 70Word address
5
9
5
1
10
11
6
2
7
3
8
4
0
Figure 2-1. Big-Endian Addresses of Bytes within Words
NOTE
The data locations in the external memory are different with Figure 2-1 in the S3C4620. Please refer to
the chapter 4, system manager.
LITTLE-ENDIAN FORMAT
In Little-Endian format, the lowest numbered byte in a word is considered the word′s least significant byte, and
the highest numbered byte the most significant. Byte 0 of the memory system is therefore connected to data lines
7 through 0.
2-2
Higher address
Lower address
31
24
11
7
3
wMost significant byte is at lowest address
wWord is addressed by byte address of least signficant byte
23158 70
16
10
6
2
9
5
1
8
4
0
Figure 2-2. Little-Endian Addresses of Bytes Words
Word address
8
4
0
S3C4510BPROGRAMMER'S MODEL
INSTRUCTION LENGTH
Instructions are either 32 bits long (in ARM state) or 16 bits long (in THUMB state).
DataTypes
ARM7TDMI supports byte (8-bit), half-word (16-bit) and word (32-bit) data types. Words must be aligned to fourbyte boundaries and half words to two-byte boundaries.
OPERATING MODES
ARM7TDMI supports seven modes of operation:
— User (usr):The normal ARM program execution state
— FIQ (fiq):Designed to support a data transfer or channel process
— IRQ (irq): Used for general-purpose interrupt handling
— Supervisor (svc):Protected mode for the operating system
— Abort mode (abt):Entered after a data or instruction prefetch abort
— System (sys):A privileged user mode for the operating system
— Undefined (und): Entered when an undefined instruction is executed
Mode changes may be made under software control, or may be brought about by external interrupts or exception
processing. Most application programs will execute in User mode. The non-user modes known as privileged
modes-are entered in order to service interrupts or exceptions, or to access protected resources.
2-3
PROGRAMMER'S MODELS3C4510B
REGISTERS
ARM7TDMI has a total of 37 registers-31 general-purpose 32-bit registers and six status registers - but these
cannot all be seen at once. The processor state and operating mode dictate which registers are available to the
programmer.
The ARM State Register Set
In ARM state, 16 general registers and one or two status registers are visible at any one time. In privileged (nonUser) modes, mode-specific banked registers are switched in. Figure 2-3 shows which registers are available in
each mode: the banked registers are marked with a shaded triangle.
The ARM state register set contains 16 directly accessible registers: R0 to R15. All of these except R15 are
general-purpose, and may be used to hold either data or address values. In addition to these, there is a
seventeenth register used to store status information.
Register 14is used as the subroutine link register. This receives a copy of R15 when a branch
and link (BL) instruction is executed. At all other times it may be treated as a
general-purpose register. The corresponding banked registers R14_svc, R14_irq,
R14_fiq, R14_abt and R14_und are similarly used to hold the return values of
R15 when interrupts and exceptions arise, or when branch and link instructions are
executed within interrupt or exception routines.
Register 15
holds the Program Counter (PC). In ARM state, bits [1:0] of R15 are zero and bits
[31:2] contain the PC. In THUMB state, bit [0] is zero and bits [31:1] contain the PC.
Register 16
is the CPSR (Current Program Status Register). This contains condition code flags
and the current mode bits.
FIQ mode has seven banked registers mapped to R8-14 (R8_fiq-R14_fiq). In ARM state, many FIQ handlers do
not need to save any registers. User, IRQ, Supervisor, Abort and Undefined each have two banked registers
mapped to R13 and R14, allowing each of these modes to have a private stack pointer and link registers.
2-4
Loading...
+ 392 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.