S12X EBI

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

S12X EBI

2,707 Views
sfb
Contributor I
Hi,
Is there any reference design about using RAM (16 bit) on EBI (especially hardware connections)? Or documents about this article?
Labels (1)
0 Kudos
5 Replies

490 Views
kef
Specialist I
0 Kudos

490 Views
sfb
Contributor I
Hi,
Thanks for reply. And one more question:
 
When I created a new project with 9S12XDP512 with XGATE in RAM option and banked memory I saw in prm file :
 
RAM_F9        = READ_WRITE  0xF91000 TO 0xF91FFF
 
For 0xF91000 address, which part is belong to RPAGE and which part is CPU address. I know that CPU address part ise 12 bit (11:0), RPAGE ise 8 bit (12:19) and 000 (20:22).
0 Kudos

490 Views
Nabla69
Contributor V
Hiya,

0x1FFF is the 16-bit address for the "local" = "CPU".

The higher part = "0xF9" is the content of the PAGING.

Look at Figure 1-4. S12X CPU & BDM Global Address Mapping
From datasheet p°41 of MC9S12XDP512.

Cheers,
Alban.
0 Kudos

490 Views
sfb
Contributor I
Hi,
I created sample project with CodeWarrior and checked the prm file (prm was created by Code Warrior for S12XDP512 with XGATE in RAM and banked memory model options). I saw that RAM area is:
 
---------------------------------------------------------------------------------------------------------------
RAM_XGATE_STK = READ_WRITE  0xF81000 TO 0xF810FF;
RAM_F8        = READ_WRITE  0xF81100 TO 0xF81FFF ALIGN 2[1:1];
RAM_F9        = READ_WRITE  0xF91000 TO 0xF91FFF ALIGN 2[1:1];
RAM_FA        = READ_WRITE  0xFA1000 TO 0xFA1FFF ALIGN 2[1:1];
RAM_FB        = READ_WRITE  0xFB1000 TO 0xFB1FFF ALIGN 2[1:1];
RAM_FC        = READ_WRITE  0xFC1000 TO 0xFC1FFF ALIGN 2[1:1];
RAM_FD        = READ_WRITE  0xFD1000 TO 0xFD1FFF ALIGN 2[1:1];
---------------------------------------------------------------------------------------------------------------

-According to AN2734 on page 6
Memory Address Bits = 000 PPPP PPPP aaaa aaaa aaaa
Global Address Range = $00_0000 to $0F_FFFF
I couldn't understand the relation between Global Address Range, Memory Address Bits and
above prm file.
 
-I want to use two external RAM (256K 16 bits). How can I organise them?
0 Kudos

490 Views
Nabla69
Contributor V
Hello,

The RAM area mentioned is for "internal" memory.
If you wish to add external RAM, you will therefore address in the EXTERNAL SPACE.

Note that the XGATE cannot access external space.
The ALIGN 2 is only necessary when XGATE can access the area because XGATE can only do ALIGNED 16-BIT accesses, while the CPU can do mis-aligned accesses.

Therefore, when you declare your external RAM in the external space, you will not be able to access it from the XGATE and will not need the ALIGN in the prm. This will save you space if you store 8-Bit variables (for instance).

Alban.
0 Kudos