Document # 001-20559 Rev. *D
45
3.
Supervisory ROM (SROM)
This chapter discusses the Supervisory ROM (SROM) functions and its associated registers. For a complete table of the
SROM registers, refer to the
“Summary Table of the Core Registers” on page 32
. For a quick reference of all PSoC registers
in address order, refer to the
Register Details chapter on page 47
3.1
Architectural Description
The SROM holds code that is used to boot the PSoC
device, calibrate circuitry, and perform Flash operations.
The functions provided by the SROM are called from code
stored in the Flash or by device programmers.
The SROM is used to boot the part and provide
functions to the Flash banks. (
lists the SROM
functions.) The SROM functions are accessed by executing
the Supervisory System Call instruction (SSC) which has an
opcode of 00h. Before executing the SSC, the M8C’s
needs to load with the desired SROM function code
from
.
Attempting to access undefined functions causes a halt. The
SROM functions execute code with calls; therefore, the
functions require stack space. With the exception of Reset,
all of the SROM functions have a
in
SRAM that you must configure before executing the SSC.
lists all possible parameter block variables. The
meaning of each
, with regards to a specific
SROM function, is described later in this chapter. Because
the SSC instruction clears the CPU_F PgMode bits, all
parameter block variable addresses are in SRAM Page 0.
The CPU_F value is automatically restored at the end of the
SROM function.
Note
For PSoC devices with more than 256 bytes of SRAM
(that is, more than 1 page of SRAM, see the table titled
“
PSoC Device SRAM Availability, on page 55
”), the
MVR_PP and the MVW_PP pointers are not disabled by
clearing the CPU_F PgMode bits. Therefore, the POINTER
parameter is interpreted as an address in the page indicated
by the MVI page pointers, when the supervisory operation is
called. This allows the data
used in the supervisory
operation to be located in any SRAM page. (See the
for more details regarding the
MVR_PP and MVW_PP pointers.)
Note
ProtectBlock (described on page
) and EraseAll (described on page
) SROM functions are not listed in the table above because they depend
upon external programming.
Two important variables that are used for all functions are
KEY1 and KEY2. These variables are used to help discrimi-
nate between valid SSCs and inadvertent SSCs. KEY1 must
always have a value of 3Ah, while KEY2 must have the
same value as the stack pointer (SP) when the SROM func-
tion begins execution. This would be the SP value when the
SSC opcode is executed, plus three. For all SROM func-
tions except SWBootReset, if either of the keys do not
match the expected values, the M8C halts. The SWBootRe-
set function does not check the key values. It only checks to
see if the accumulator’s value is 0x00. The following code
example puts the correct value in KEY1 and KEY2. The
code is preceded by a HALT, to force the program to jump
directly into the setup code and not accidentally run into it.
Table 3-1. List of SROM Functions
Function Code
Function Name
Stack Space
Needed
Page
00h
SWBootReset
0
01h
ReadBlock
7
02h
WriteBlock
10
03h
EraseBlock
9
06h
TableRead
3
07h
CheckSum
3
08h
Calibrate0
4
09h
Calibrate1
3
Summary of Contents for PSoC CY8C23533
Page 4: ...Contents Overview 4 Document 001 20559 Rev D Section G Glossary 385 Index 401 ...
Page 16: ...Contents Overview 16 Document 001 20559 Rev D ...
Page 24: ...24 Document 001 20559 Rev D Section A Overview ...
Page 30: ...30 Document 001 20559 Rev D Pin Information ...
Page 54: ...54 Document 001 20559 Rev D Supervisory ROM SROM ...
Page 60: ...60 Document 001 20559 Rev D RAM Paging ...
Page 68: ...68 Document 001 20559 Rev D Interrupt Controller ...
Page 76: ...12 Document 001 20559 Rev D General Purpose IO GPIO ...
Page 82: ...18 Document 001 20559 Rev D Internal Main Oscillator IMO ...
Page 84: ...20 Document 001 20559 Rev D Internal Low Speed Oscillator ILO ...
Page 90: ...26 Document 001 20559 Rev D External Crystal Oscillator ECO ...
Page 94: ...30 Document 001 20559 Rev D Phase Locked Loop PLL ...
Page 106: ...42 Document 001 20559 Rev D Sleep and Watchdog ...
Page 228: ...164 Document 001 20559 Rev D Section D Digital System ...
Page 234: ...170 Document 001 20559 Rev D Array Digital Interconnect ADI ...
Page 278: ...214 Document 001 20559 Rev D Digital Blocks ...
Page 296: ...232 Document 001 20559 Rev D Analog Interface ...
Page 304: ...240 Document 001 20559 Rev D Analog Array ...
Page 308: ...244 Document 001 20559 Rev D Analog Input Configuration ...
Page 312: ...248 Document 001 20559 Rev D Analog Reference ...
Page 338: ...274 Document 001 20559 Rev D Section F System Resources ...
Page 354: ...290 Document 001 20559 Rev D Multiply Accumulate MAC ...
Page 374: ...310 Document 001 20559 Rev D I2C ...
Page 400: ...336 Document 001 20559 Rev D Section G Glossary ...