ArtsAutosBooksBusinessEducationEntertainmentFamilyFashionFoodGamesGenderHealthHolidaysHomeHubPagesPersonal FinancePetsPoliticsReligionSportsTechnologyTravel

All About 8051 based Microcontroller for Projects

Updated on July 18, 2011

8051 Microcontroller BASICS based Projects

When you start to learn about microcontrollers you need to start from the basic model. The 8051 microcontroller is first of the 8-bit microcontroller designed by Intel. It was optimized for 8-bit math and single bit Boolean operations. Its family MCS-51 includes, 8031, 8051 and 8751 microcontrollers. Each of them varies in their internal memory, timer and interrupts configuration. To quote an application, 8051 microprocessors can be used to drive small motor with very high precision and control; this cannot be done by any manual arrangements. Such accuracy is very essential from laser surgery to rocket launching.There are lots of 8051 Microcontoller Kits for projects availabel online, you can choose and decide to do one of them for better experience.

Difference between 8051 Microcontroller and Microprocessor


  • Microprocessor contains ALU, general purpose registers, stack pointer, program counter, and clock timing circuit and interrupt circuit. But microcontrollers contain the circuitry of microprocessor and in addition it has built-in ROM, RAM, I/O devices, timers and counters.
  • Microcontrollers have separate memory map for data and code. Whereas, microprocessor has single memory map for data and code.
  • The Microprocessor based system requires more hardware but for microcontrollers most of the necessary things are come as built-in.

8051 Microcontroller Pins


The 8051 microcontroller is packaged in a 40-pin DIP. For microcontrollers it is important to notice that many pins are used for more than one function.


Central Processing Unit of 8051 Microcontroller


The CPU of 8051 consists of eight-bit Arithmetic and logic unit with associated registers like A, B, PSW, SP, the sixteen bit program counter and “Data Pointer” (DPTR) registers. Along with these registers it has a set of special function registers.

The 8051’s ALU can perform addition, subtraction, multiplication and division. The logic unit can perform logical operations such as AND, OR and Exclusive-OR, as well as rotate, clear, and complement. The ALU also looks after the branching decisions. An important unique feature of 8051 architecture is that the ALU can also manipulator one bit as eight-bit data types. Individual bits may be set, cleared, complemented, moved, tested, and used in logic computation.

On Chip Data Memory and Program Memory of 8051 microcontroller


The 8051 microcontroller has 128-byte internal RAM. It is accessed using RAM address register. The internal RAM is organized into three distinct areas:

  • Working Registers
  • Bit Addressable
  • General Purpose

The 8051 Microcontroller has 4 Kbyte of internal ROM with address space from 0000H to 0FFFH. It is programmed by manufacturer when the chip is built. This part cannot be erased or altered after fabrication .This is used to store final version of the program.

It is accessed using program address register. The program addresses higher than 0FFFH, which exceed the internal ROM capacity will cause the 8051 automatically fetch code bytes from external program memory. However, code bytes can also be fetched exclusively from an external memory addresses 000H to FFFFH, by connecting the external aces pin to ground.

8051 Microcontroller Input Output Ports


The 8051 Microcontroller has 32 I/O pins configured as four eight-bit parallels ports. All four ports are bidirectional, i.e. each pin will be configured as input or output under software control. Each port consists of a latch, an output driver, and an input buffer.

The output drives of Ports 0 and 2 and the input buffers of Port 0 , are used in access to external memory address, time multiplexed with the data being written or read, and Port 2 outputs the high order byte of the external memory address when the address is 16 bits wide. Otherwise Port 2 gives the contents of special function register P2.All port pins of port 3 are multifunctional. They have other special funcitions.These are the port descriptions of 8051 microcontroller.

8051 Microcontroller Register Set

  • Register A

It is an 8-bit register. It holds a source operand and receives the result of the arithmetic instructions . The accumulator can be the source or destination for logical operations and a number of special data movement instructions.

  • Register B

In addition to accumulator, an 8-bit B-register is available and as a general purpose register when it is not being used for the hardware multiply/divide operation. Apart from these two the 8051 Microcontroller also has other register such as Program Status Word, Stack and Stack Pointer, Data Pointer, Program Counter and special function registers.

8051 Microcontroller Interrupts

An interrupt request is an instance when the microcontroller is requested to suspend its present activities in order to handle and unexpected situation. The 8051 has five interrupts

  • External hardware interrupts 0
  • Timer 0 interrupt
  • External hardware interrupts 1
  • Timer 1 interrupt
  • Serial communication interrupt

Well, this is an overview about the 8051 Microcontroller it has much more in-depth specifications which you could dig up from any related books if you want to go deeper into the world of microcontrollers.

More Microcontroller Resources...

Comments

    0 of 8192 characters used
    Post Comment

    • royaldsouza1 profile image

      royaldsouza1 

      6 years ago

      nice one

    • profile image

      Microcontroller projects 

      7 years ago

      Thanks for sharing this , very useful to juniors, keep going...

    • profile image

      Tushar 

      8 years ago

      It is very helpful for the basic cocepts about microcontroller

    • profile image

      anuja 

      8 years ago

      its good to have abbreviated data...helps to remember important points

    • Sky321 profile image

      Sky321 

      8 years ago from Canada

      Great hub, there is still lot's of stuff that I don't know.

    working

    This website uses cookies

    As a user in the EEA, your approval is needed on a few things. To provide a better website experience, hubpages.com uses cookies (and other similar technologies) and may collect, process, and share personal data. Please choose which areas of our service you consent to our doing so.

    For more information on managing or withdrawing consents and how we handle data, visit our Privacy Policy at: https://hubpages.com/privacy-policy#gdpr

    Show Details
    Necessary
    HubPages Device IDThis is used to identify particular browsers or devices when the access the service, and is used for security reasons.
    LoginThis is necessary to sign in to the HubPages Service.
    Google RecaptchaThis is used to prevent bots and spam. (Privacy Policy)
    AkismetThis is used to detect comment spam. (Privacy Policy)
    HubPages Google AnalyticsThis is used to provide data on traffic to our website, all personally identifyable data is anonymized. (Privacy Policy)
    HubPages Traffic PixelThis is used to collect data on traffic to articles and other pages on our site. Unless you are signed in to a HubPages account, all personally identifiable information is anonymized.
    Amazon Web ServicesThis is a cloud services platform that we used to host our service. (Privacy Policy)
    CloudflareThis is a cloud CDN service that we use to efficiently deliver files required for our service to operate such as javascript, cascading style sheets, images, and videos. (Privacy Policy)
    Google Hosted LibrariesJavascript software libraries such as jQuery are loaded at endpoints on the googleapis.com or gstatic.com domains, for performance and efficiency reasons. (Privacy Policy)
    Features
    Google Custom SearchThis is feature allows you to search the site. (Privacy Policy)
    Google MapsSome articles have Google Maps embedded in them. (Privacy Policy)
    Google ChartsThis is used to display charts and graphs on articles and the author center. (Privacy Policy)
    Google AdSense Host APIThis service allows you to sign up for or associate a Google AdSense account with HubPages, so that you can earn money from ads on your articles. No data is shared unless you engage with this feature. (Privacy Policy)
    Google YouTubeSome articles have YouTube videos embedded in them. (Privacy Policy)
    VimeoSome articles have Vimeo videos embedded in them. (Privacy Policy)
    PaypalThis is used for a registered author who enrolls in the HubPages Earnings program and requests to be paid via PayPal. No data is shared with Paypal unless you engage with this feature. (Privacy Policy)
    Facebook LoginYou can use this to streamline signing up for, or signing in to your Hubpages account. No data is shared with Facebook unless you engage with this feature. (Privacy Policy)
    MavenThis supports the Maven widget and search functionality. (Privacy Policy)
    Marketing
    Google AdSenseThis is an ad network. (Privacy Policy)
    Google DoubleClickGoogle provides ad serving technology and runs an ad network. (Privacy Policy)
    Index ExchangeThis is an ad network. (Privacy Policy)
    SovrnThis is an ad network. (Privacy Policy)
    Facebook AdsThis is an ad network. (Privacy Policy)
    Amazon Unified Ad MarketplaceThis is an ad network. (Privacy Policy)
    AppNexusThis is an ad network. (Privacy Policy)
    OpenxThis is an ad network. (Privacy Policy)
    Rubicon ProjectThis is an ad network. (Privacy Policy)
    TripleLiftThis is an ad network. (Privacy Policy)
    Say MediaWe partner with Say Media to deliver ad campaigns on our sites. (Privacy Policy)
    Remarketing PixelsWe may use remarketing pixels from advertising networks such as Google AdWords, Bing Ads, and Facebook in order to advertise the HubPages Service to people that have visited our sites.
    Conversion Tracking PixelsWe may use conversion tracking pixels from advertising networks such as Google AdWords, Bing Ads, and Facebook in order to identify when an advertisement has successfully resulted in the desired action, such as signing up for the HubPages Service or publishing an article on the HubPages Service.
    Statistics
    Author Google AnalyticsThis is used to provide traffic data and reports to the authors of articles on the HubPages Service. (Privacy Policy)
    ComscoreComScore is a media measurement and analytics company providing marketing data and analytics to enterprises, media and advertising agencies, and publishers. Non-consent will result in ComScore only processing obfuscated personal data. (Privacy Policy)
    Amazon Tracking PixelSome articles display amazon products as part of the Amazon Affiliate program, this pixel provides traffic statistics for those products (Privacy Policy)