Keil Logo Arm Logo

Special Function Registers

The 8051 family of microcontrollers provides a distinct memory area for accessing Special Function Registers (SFRs). SFRs are used in your program to control timers, counters, serial I/Os, port I/Os, and peripherals. SFRs reside from address 0x80 to 0xFF and can be accessed as bits, bytes, and words. For more information about Special Function Registers, refer to the Intel 8-Bit Embedded Controllers data book or other 8051 data books.

Within the 8051 family, the number and type of SFRs vary. Note that no SFR names are predefined by the Cx51 Compiler. However, declarations for SFRs are provided in include files.

The C51 Compiler provides a number of include files for various 8051 derivatives. Each file contains declarations for the SFRs available on that derivative. Refer to 8051 Special Function Register Include Files for more information about include files.

The Cx51 Compiler provides access to SFRs with the sfr, sfr16, and sbit data types.

Keil logo

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.