Can any one tell me how to access the XRAM at address 0xC000 on the C167CS. I have :- - ticked 'use on-chip xram' - added XRAM class in linker file is as follows :-
CLASSES (ICODE(000000h), IDATA0(00F600h), SDATA(00E000h-00E7FFh), SDATA0(00E000h-00E7FFh), XRAM(00C000h-00D7FFh), NCODE(010000h-013FFFh), .... etc
#pragma RENAMECLASS(SDATA = XRAM) #pragma NOINIT static int sdata Temp[20];
START STOP LENGTH TYPE RTYP ALIGN TGR GRP COMB CLASS SECTION NAME ===================================================================================== 00C000H 00C027H 000028H DATA REL WORD --- 2 PUBL XRAM ?SD?DEBUG
Have you tried this? http://www.keil.com/support/docs/1621.htm
Thanks for responding. Yes I have enabled XPEN in SYSCON register. I don't have any trouble with XRAM at addres 0xE000. I only have trouble accessing the XRAM at 0xC000.
I would double check to make sure that you are indeed enabling all of XRAM.
MOV XPERCON,#0C03H ; Enable CAN 1 and CAN 2 Xbus peripherals ; Enable XRAM 2 KByte memory ; Enable XRAM 6 KByte memory NOP NOP MOV SYSCON,#8184H ; Stack size = 512 words ; Internal rom starts at 00'0000 ; Segmentation enabled ; Internal rom disabled ; BHE pin enabled ; Clock out pin enabled ; WR is write low, BHE is write high ; Xbus peripherals are enabled ; Xbus accesses are not visible on external bus ; Xbus peripherals not accessable on external bus
SDATA0 (C000H-D7FFH, E000H-E7FFH)
Hari, The above works for sure because we are using with our C167CS.