EmbeddedRelated.com
Forums

code banking in keil

Started by ishita June 27, 2006
Hi all!

About "code banking" using keil compiler, I read first 32k memory of
bank is kept as common area and rest 32k for bank in each bank.
Can we reduce common area memory and increase actual bank memory as per
the requirement?

Best regards,
Ishita

In article <1151409058.076471.287790@x69g2000cwx.googlegroups.com>,
ishita <aparna247@gmail.com> writes
>Hi all! > >About "code banking" using keil compiler, I read first 32k memory of >bank is kept as common area and rest 32k for bank in each bank. >Can we reduce common area memory and increase actual bank memory as per >the requirement? > >Best regards, >Ishita
It is fully explained in the manuals. Ask Grant Edwards... he like answering this sort of question. -- \/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\ \/\/\/\/\ Chris Hills Staffs England /\/\/\/\/ /\/\/ chris@phaedsys.org www.phaedsys.org \/\/\ \/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
"ishita" <aparna247@gmail.com> wrote in message
news:1151409058.076471.287790@x69g2000cwx.googlegroups.com...
> Hi all! > > About "code banking" using keil compiler, I read first 32k memory of > bank is kept as common area and rest 32k for bank in each bank. > Can we reduce common area memory and increase actual bank memory as per > the requirement?
No manual available? Meindert
"ishita" <aparna247@gmail.com> wrote in message 
news:1151409058.076471.287790@x69g2000cwx.googlegroups.com...
> Hi all! > > About "code banking" using keil compiler, I read first 32k memory of > bank is kept as common area and rest 32k for bank in each bank. > Can we reduce common area memory and increase actual bank memory as per > the requirement? > > Best regards, > Ishita >
Where is the manual? Kees
In article <44a170f1$0$31655$e4fe514c@news.xs4all.nl>, -@?.? writes
> >"ishita" <aparna247@gmail.com> wrote in message >news:1151409058.076471.287790@x69g2000cwx.googlegroups.com... >> Hi all! >> >> About "code banking" using keil compiler, I read first 32k memory of >> bank is kept as common area and rest 32k for bank in each bank. >> Can we reduce common area memory and increase actual bank memory as per >> the requirement? >> >> Best regards, >> Ishita >> > >Where is the manual? >
on the CD -- \/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\ \/\/\/\/\ Chris Hills Staffs England /\/\/\/\/ /\/\/ chris@phaedsys.org www.phaedsys.org \/\/\ \/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
ishita wrote:
> Hi all! > > About "code banking" using keil compiler, I read first 32k memory of > bank is kept as common area and rest 32k for bank in each bank. > Can we reduce common area memory and increase actual bank memory as per > the requirement? > > Best regards, > Ishita
C51: CREATING CODE BANKING PROGRAMS http://www.keil.com/support/docs/158.htm 'For example, if you specify that the bank area is from 0x4000 to 0xFFFF, that gives 48K for the code banks and only 16K for the common area (0x0000 to 0x3FFF).' BL51 Code-banking Linker/Locator http://www.keil.com/support/index/bl51 BL51: WRITING YOUR OWN CODE BANKING SYSTEM http://www.keil.com/support/docs/1083.htm The answer must be in there somewhere.
Hi!
Thankyou for timely suggetion. This helped me a lot.
Best regards,
Aparna


sivadnz wrote:

> ishita wrote: > > Hi all! > > > > About "code banking" using keil compiler, I read first 32k memory of > > bank is kept as common area and rest 32k for bank in each bank. > > Can we reduce common area memory and increase actual bank memory as per > > the requirement? > > > > Best regards, > > Ishita > > C51: CREATING CODE BANKING PROGRAMS > http://www.keil.com/support/docs/158.htm > 'For example, if you specify that the bank area is from 0x4000 to > 0xFFFF, that gives 48K for the code banks and only 16K for the common > area (0x0000 to 0x3FFF).' > > BL51 Code-banking Linker/Locator > http://www.keil.com/support/index/bl51 > > BL51: WRITING YOUR OWN CODE BANKING SYSTEM > http://www.keil.com/support/docs/1083.htm > > The answer must be in there somewhere.
Hi!
Thankyou for timely suggetion. This helped me a lot.
Best regards,
Ishita

ishita wrote:
> Hi! > Thankyou for timely suggetion. This helped me a lot. > Best regards, > Ishita
Please share the solution with other readers. Or at least a pointer to the solution. Regards Alec
Hi!

Here is the solution to use code banking.
For eg. we want to use 8 code banks.

1. 8 code banks ie memory pages.
2. Steps to achive code banking-
	a. Enable code banking in Startup.a51 file.
	b. Target options-
		i.   Select code banking.
		ii.  Select no. of banks.
		iii. Write start & end address of bank area.**********
	c. Copy L51_bank.a51 file from LIB and modify as per the hardware.
	d. Modifications in L51_bank.a51-
		i.   ?B_NBANKS = 8   -no. of baks
		ii.  ?B_MODE = 4     -for user defined switch code.
		iii. Modify the switch code for first 4 banks.
		iv.  Add switch code for remaining 4 banks.
3. If you want to call any function/variable from one bank to other or
   from common area to bank or vise-versa, those functions/variables
have
   to be imported using keyword "extern".

Best regards,
Ishita


sivadnz wrote:
> ishita wrote: > > Hi! > > Thankyou for timely suggetion. This helped me a lot. > > Best regards, > > Ishita > > Please share the solution with other readers. Or at least a pointer to > the solution. > > Regards Alec