
The central processing unit (CPU)
UM0404
64/564
DocID13284 Rev 2
programmed prescaled value of the f
CPU
(prescaler factor is programmable from 1 to 256
linearly, default value after reset is 1).
Note:
The output driver of port pin P3.15 is switched on automatically, when the CLKOUT function
is enabled. The port direction bit is disregarded.
After reset, the clock output function is disabled (CLKEN = ‘0’).
Segmentation disable/enable control
(
SGTDIS)
Bit SGTDIS allows to select either the segmented or non-segmented memory mode.
In non-segmented memory mode
(SGTDIS = '1') it is assumed that the code address
space is restricted to 64 Kbytes (segment 0) and thus 16 bits are sufficient to represent all
code addresses.
For implicit stack operations (CALL or RET) the CSP register is totally ignored and only the
IP is saved to and restored from the stack.
In segmented memory mode
(SGTDIS = '0') it is assumed that the whole address space is
available for instructions. For implicit stack operations (CALL or RET) the CSP register and
the IP are saved to and restored from the stack. After reset the segmented memory mode is
selected.
Note:
Bit SGTDIS controls if the CSP register is pushed onto the system stack in addition to the IP
register before an interrupt service routine is entered, and it is re-popped when the interrupt
service routine is left again.
System stack size (STKSZ)
This bit-field defines the size of the physical system stack, which is located in the IRAM of
the ST10F276. An area of 32...1024 words or all of the IRAM may be dedicated to the
system stack. A so-called “circular stack” mechanism allows to use a bigger virtual stack
than this dedicated IRAM area. These techniques as well as the encoding of bit-field STKSZ
are described in more detail in Stack Operations (see
Section 27.1: Stack operations on
).
Table 8. Stack size
(STKSZ)
Stack size (words)
IRAM addresses (words)
0 0 0b
256
00’FBFEh...00’FA00h (Default after Reset)
0 0 1b
128
00’FBFEh...00’FB00h
0 1 0b
64
00’FBFEh...00’FB80h
0 1 1b
32
00’FBFEh...00’FBC0h
1 0 0b
512
00’FBFEh...00’F800h
1 0 1b
---
Reserved. Do not use this combination.
1 1 0b
---
Reserved. Do not use this combination.
1 1 1b
1024
00’FDFEh...00’F600h (Note: No circular stack)