Keil Logo


Information in this article applies to:

  • C251 Version 3.20
  • µVision2 Version 2.20


I want to use the Intel 80C251TB or the Atmel 80C251G2D in my new designs. The hardware provides 128KBytes RAM and 128KBytes Flash EPROM. What is the best way to configure the tools?


The µVision2 memory wizard makes the tool setup as easy as possible. You only need to specify the available memory of your target system under Project - Options for Target - Target. For example:

If you have RAM in the address range 00:0000-01:FFFF, under External Memory, enter...

  • RAM Start: 0
  • Size: 0x20000

If you have FLASH memory in the address range FE:0000-FE:FFFF, enter

  • ROM Start: 0xFE0000
  • Size: 0x20000

Use the far memory type for variables located in RAM (readable/writable) memory. Use the far const memory type for variables located in ROM (readable-only). You may use these memory types in any memory model of the C251 compiler.

The XSMALL memory model seems to be the best choice for programs that handle many variables. If the code size of your application program is larger than 64KB, you should select Code ROM Size: Huge.

The recommended settings in the Options for Target - Target dialog for big 251 applications are:

  • CPU Mode: Source (251 native)
  • Memory Model: XSmall: near vars, far const, ptr-4
  • Code Rom Size: Huge: 64K functions, 16M progr


Detailed information about the 251 Memory Models and Memory Types can be found in the C251 Compiler User's Guide, Chapter 3. Language Extensions.


Last Reviewed: Wednesday, January 23, 2002

Did this article provide the answer you needed?
Not Sure
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.