Arduino Projects    |   Raspberry Pi  |     Electronic Circuits   |   Electronics Reference Design Library  |   AVR    |    PIC    |    8051    |    Electronic Projects

Introduction to ARM7 Based Microcontroller (LPC2148)

Summary

Developed By: 
Dishant Shah

Increasingly, embedded systems developers and system-on-chip designers select specificmicroprocessor cores and a family of tools, libraries, and off-the-shelf components toquickly develop new microprocessor-based products and applications. ARM is one of the major options available for embedded system developer.

 

Over the last few years, the ARM architecture has become the most pervasive 32-bitarchitecture in the world, with wide range of ICs available from various IC manufacturers. ARM processors are embedded in products ranging from cell/mobilephones to automotive braking systems. A worldwide community of ARM partners andthird-party vendors has developed among semiconductor and product design companies,including hardware engineers, system designers, and software developers.

 

ARM7 is one of the widely used micro-controller family in embedded system application. This section is humble effort for explaining basic features of ARM-7.

 

ARM is a family of instruction set architectures for computer processors based on a reduced instruction set computing (RISC) architecture developed by British company ARM Holdings.

A RISC-based computer design approach means ARM processors require significantly fewer transistors than typical processors in average computers. This approach reduces costs, heat and power use. These are desirable traits for light, portable, battery-powered devices—including smartphones, laptops, tablet and notepad computers), and other embedded systems. A simpler design facilitates more efficient multi-core CPUs and higher core counts at lower cost, providing higher processing power and improved energy efficiency for servers and supercomputers.

 

SOME FACTS YOU MUST KNOW

In 2005, about 98% of all mobile phones sold used at least one ARM processor. The low power consumption of ARM processors has made them very popular: 37 billion ARM processors have been produced as of 2013, up from 10 billion in 2008. The ARM architecture (32-bit) is the most widely used architecture in mobile devices, and most popular 32-bit one in embedded systems.

According to ARM Holdings, in 2010 alone, producers of chips based on ARM architectures reported shipments of 6.1 billion ARM Based processors, representing 95% of smartphones, 35% of digital televisions and set-top boxes and 10% of mobile computers. It is the most widely used 32-bit instruction set architecture in terms of quantity produced.

 

LET’S START WITH LPC 2148

LPC2148 is the widely used IC from ARM-7 family. It is manufactured by Philips and it is pre-loaded with many inbuilt peripherals making it more efficient and a reliable option for the beginners as well as high end application developer.

 
Let us go through the features of LPC214x series controllers.

 

8 to 40 kB of on-chip static RAM and 32 to 512 kB of on-chip flash program memory.128 bit wide interface/accelerator enables high speed 60 MHz operation.

In-System/In-Application Programming (ISP/IAP) via on-chip boot-loader software.Single flash sector or full chip erase in 400 ms and programming of 256 bytes in 1ms.

EmbeddedICE RT and Embedded Trace interfaces offer real-time debugging with theon-chip RealMonitor software and high speed tracing of instruction execution.

USB 2.0 Full Speed compliant Device Controller with 2 kB of endpoint RAM.In addition, the LPC2146/8 provides 8 kB of on-chip RAM accessible to USB by DMA.

One or two (LPC2141/2 vs. LPC2144/6/8) 10-bit A/D converters provide a total of 6/14analog inputs, with conversion times as low as 2.44 us per channel.

Single 10-bit D/A converter provides variable analog output.

Two 32-bit timers/external event counters (with four capture and four comparechannels each), PWM unit (six outputs) and watchdog.

Low power real-time clock with independent power and dedicated 32 kHz clock input.

Multiple serial interfaces including two UARTs (16C550), two Fast I2C-bus(400 kbit/s), SPI and SSP with buffering and variable data length capabilities.

Vectored interrupt controller with configurable priorities and vector addresses.

Up to 45 of 5 V tolerant fast general purpose I/O pins in a tiny LQFP64 package.

Up to nine edge or level sensitive external interrupt pins available.

On-chip integrated oscillator operates with an external crystal in range from 1 MHz to30 MHz and with an external oscillator up to 50 MHz.

Power saving modes include Idle and Power-down.

Individual enable/disable of peripheral functions as well as peripheral clock scaling foradditional power optimization.

Processor wake-up from Power-down mode via external interrupt, USB, Brown-OutDetect (BOD) or Real-Time Clock (RTC).

Single power supply chip with Power-On Reset (POR) and BOD circuits:

CPU operating voltage range of 3.0 V to 3.6 V (3.3 V ± 10 %) with 5 V tolerant I/Opads.

 

* adopted from datasheet of LPC 2148. Each inbuilt peripheral will be explained in brief later on.

 

The list of feature is enough to explain why it has covered such a huge market for high end applications such as mobile phones, tablets etc.

 

FIRST STEP- HARDWARE REQUIREMENT

 

Here is the pin configuration of LPC 2148.

LPC2148 Pin Diagram

Now let us start with the hardware requirement of LPC2148.

LPC2148 need minimum below listed hardware to work properly.

 

1.                  Power Supply

2.                  Crystal Oscillator

3.                  Reset Circuit

4.                  RTC crystal oscillator (This is not necessary if you are not using RTC. However this is considered as necessary requirement)

5.                  UART

 

1. Power Supply

LPC2148 works on 3.3 V power supply. LM 117 can be used for generating 3.3 V supply. However, basic peripherals like LCD, ULN 2003 (Motor Driver IC) etc. works on 5V. So AC mains supply is converted into 5V using below mentioned circuit and after that LM 117 is used to convert 5V into 3.3V.

Power Supply Block Diagram

 

Block diagram for power supply is given below.

           

Transformer:It is used to step down 230V AC to 9V AC supply and provides isolation between power grids and circuit.

 

Rectifier: It is used to convert AC supply into DC.

 

Filter:It is used to reduce ripple factor of DC output available from rectifier end.

 

Regulator:It is used to regulate DC supply output.

Circuit for this is as shown below.

 

Here, Regulator IC 7805 is used to provide fix 5V dc supply.

 

Now we can use LM 117 for generating 3.3V supply from 5V using below circuit.

 

Calculations

2. Reset Circuit

 

Reset button is essential in a system to avoid programming pitfalls and sometimes to manually bring back the system to the initialization mode. Circuit diagram for reset is as shown below.

 

MCP 130T is a special IC used for providing stable RESET signal to LPC 2148.

Reset Circuit

 

3. Oscillator Circuit

Oscillations, the heartbeat, are provided using a crystal and are necessary for the system to work.

 

The value of capacitors C20 & C21 depends upon the frequency of crystal Y3. General circuit and its equivalent circuit is as shown below.

 

Recommended values are as shown in table.

 

We can also use external oscillator for providing system clock. Circuit for this application is as given below.

4. RTC Oscillator Circuit

It provides clock for RTC operation.

 

5. UART

LPC 2148 has inbuilt ISP which means we can program it within the system using serial communication on COM0. It has also COM1 for serial communication. MAX 232/233 IC must be used for voltage logic conversion. Related connections are as given below.

 

Once above listed circuit design is ready, we are ready to go further.

 

You are here