EETimes

Embedded Systems September 2000 Vol13_10

Issue link: http://dc.ee.ubm-us.com/i/71837

Contents of this Issue

Navigation

Page 63 of 229

FIGURE 8 Rabbit 2000 register model Main Register Set ~- --- 1---- ~----~--~~~~~~ 8 Bits 1----------- ------------- H ---- ---------- 0 A B C E L - F ~:-.:.:..:·.:,:.::..:~- ·;.·-- B' Alternate Register Set 11----- i i i ' D' H' ---------- 1-------- EIR IIR ·---- 16-Bits IP The code for mapping of logical address to physical address for the stack segment is: PhysicalAddress = (STACKSEG << 12) + LogicalAddress; FIGURE 9 STACKSEG = OxEB, OxEC.. DATASEG SEGSIZE XPC OxFFFF ·. / Stack / Segment •• (4K) Data :!"">< .. ;! / Segment ••• '"" I Ox6000 Root ••••• ••• OxOOOO ·•.. · .... • •. ·. Logical Address Space (64K) ·············~ ··~ i ·I j! XPC· based:: ii I , ! : :! Code i! 'I [ Extended 'i 104K :! •I !i j! i OxOEOOO ·! ROM (128K) . ................ ...-·" ....... :i .. ········· ... · •• \ \........... 1 o.mH = OxEA Data (64K) : ::::. Ox01 ••.• · ••• ··········/_..····/" . 32K • , OxFOOOO PhysicalAddress LogicaLAddress; (XPC << 12) + Extended code is visible in the 64KB logical memory space in an 8KB window at the top of memory from OxEOOO to OxFFFF. The value of the XPC register is maintained by Lhe compiler. A context switch on the Rabbit is similar to the Z80 and 180-dass proces- sors, as shown in Listing 6. You will notice d1at d1e od1er two MMU regis- ters (SEGSIZE and DATASEG) are not saved during a context switch because, most likely, they will not be changed dynamically. A context switch for pC/ OS-Il on the Rabbit takes about 330 clock cycles (13ps at 25MHz). Physical Address Space (1024K) ZiLOG eZ80 Late last year ZiLOG announced their fourth-generation Z80 deriva- tive. ZiLOG's marketing literature indicates that eZ80s wi ll be available 62 SEPTEMBER 2000 Embedded Systems Programming Stacks (4K) This equation is valid only when the logical address is between OxDOOO and OxDFFF. The STACKSEG register is most likely maintained by the kernel and not the compil er. The code for mapping of logical address to physical address for the XPC segment is: - -1-- C' E' -- L-, - Critical section Exit critical section: POP IP Enter critical section: PUSH IP IP 1

Articles in this issue

Archives of this issue

view archives of EETimes - Embedded Systems September 2000 Vol13_10