Mini Development Board: Users Guide
Mini Development Board: Users Guide
Mini Development Board: Users Guide
DEVELOPMENT
BOARD
LPC
2148
USERS GUIDE
1
OVERVIEW
ARM LPC2148 Mini Development Board is a miniature and powerful hardware platform to evaluate
LPC2148 Flash memory microcontroller. The eCee ARM LPC2148 Board contains all hardware components
that are required in a single-chip LPC2148 controller system plus 1 COM port for serial RS232 interface.
2
1.1. KEY FEATURES OF PIC16F877A DEVELOPMENT BOARD-MINI
3
1.2. CONTROLLER SPECIFICATION
4
PACKAGE CONTENTS
Fully Assembled and Tested eCee ARM LPC2148 Mini Development Board
Software CDROM with
Schematic
Programming Software
Sample Hex Code
Example Codes
5
HARDWARE INTRODUCTION
6
2.2. INTERFACE OVERVIEW
7
2.3. PERIPHERAL DESCRIPTION
PERIPHERALS DESCRIPTION
ISP(J15) ISP Connector,To program the IC
K6,K7 PORT pins on male berg strip
K1 USB Socket
K2 To select power source as USB/DC
K3 2 pin male RMC connector for power
K4 DC barrel jack
K5 UART Interface via Female DB9 Connector
K14 RMC connector for 3V3/5V UART0
K13 Servo connector pin
K8-K9-K10-K11 PORT pins on female berg strip
LED1-LED3 Light Emitting Diodes
PWR Power indication LED
SW1-SW3 Pull-Up Switches
RESET(SW4) Reset Button
PROGRAMMER(SW5) To select Auto/ Manual mode of programming
LCD CONT (P1) LCD Contrast control Pot
ADC (P2) Potentiometer used as ADC input
U1 ARM LPC 2148
U2 LM7805(5V regulator IC)
U3 LD1117 (3V3 regulator IC)
U4 CP2102(USB interface)
U5 MAX232(Level converter)
U6 Temperature Sensor (MCP9700)
U7 Zigbee module connectors
IDC1 JTAG connector
BUZ1 Buzzer
LCD1 LCD
8
2.4. JUMPER SET DESCRIPTION
9
2.5. POWER SUPPLY
ARM LPC2148 Mini Development Board has 3 provisions for giving power supply input
USB connector
DC Barrel Jack Connector
2 Pin Male RMC Connector
The input source can be selected as DC/USB using the jumper. If DC source is selected, then either DC Barrel
Jack or RMC connector can be used and the supply voltage should be in the range of 7-12 V. Once the board is
powered, the power LED(red LED on the board) glows.
10
2.7. MICROCONTROLLER PINOUT
11
2.8. PORT EXPANDER(ADDITIONAL INPUT/OUTPUT PORTS)
12
2.9. JTAG CONNECTION
The Joint Test Action Group (JTAG), is an integrated method for testing interconnects on printed circuit
boards (PCBs) that are implemented at the integrated circuit (IC) level.
The microcontroller can also be programmed and be used to test the operation of the microcontroller
with the JTAG programmer. In order to enable the JTAG programmer to be used, it is necessary to place jumper
J8 in the position
13
2.10. LED INTERFACE
LEDs are semiconductor diodes, electronic devices that permit current to flow in only one direction. The
diode is formed by bringing two slightly different materials together to form a PN junction. In a PN junction, the P
side contains excess positive charge ("holes") while the N side contains excess negative charge (electrons).
When a forward voltage is applied to the semi conducting element forming the PN junction, electrons move from
N area toward P area and holes move from P area toward N area. Near the junction, the electrons and holes
combine. As this occurs, energy is released in the form of light that is emitted by the LED. The material used in
the semi conducting element of an LED determines its color. LEDs are the simplest devices to test port
functioning.
LPC 2148 mini development board has 3 SMD LED s connected to port pins P0.17, P0.18 & P0.19 via
jumpers J1 , J2 & J3. If any jumper is left open, then the corresponding port pin can be used independently. The
LEDs turn ON when the port pins are at logic high state and they get turned OFF when the port pins are at logic
low state. Each LED is interfaced via a current limiting resistor.
Note: Remove J1,J2 & J3 when P0.19,P0.18 & P0.17 are used for other purpose.
14
2.11. LCD INTERFACE
The display is a standard 16x2 LCD which displays 2 lines of 16 characters. Each character is
40 pixels, making it 1280 pixels overall. The display receives ASCII codes for each character at the
data inputs (D0D7). The data is presented to the display inputs by the MCU, and latched in by
triggering the E (Enable) input. The RW (Read/Write) line can be tied low (write mode), as the LCD is receiving
data only. The RS (Register Select) input allows commands to be sent to the display. RS selects
command/data mode. The display itself contains a microcontroller; the standard chip in this type of
display is the Hitachi HD44780. It must be initialized according to the data and display options required.
The module can be used 4-bit or 8-bit mode. The development board uses 4-bit interface. Data pins are P1.20-
P1.23 and control pins are P1.17(RS),P1.18(R/W) and P1.19(E). LCD contrast can be adjusted by using the
potentiometer.
15
2.12. PULL-UP KEY INTERFACING
The simplest input to a microcontroller is a switch or push button. This can operate with just one
additional support component, a pull-up resistor. The board has 3 externally pulled up switches (SW1,SW2 &
SW3) connected to port pins P0.14, P0.15 & P0.16 via jumpers J4, J5 & J6 respectively. On shorting these
jumpers, the switches can be used as general matrix keypad and if left open, then the port pins can be used for
other purposes.
When a switch is open, then the corresponding port pin gets pulled up to 5V by the pull-up resistor &
Note : Remove J4,J5,J6 when P0.14, P0.15 & P0.16 are used for other purpose.
16
2.13. BUZZER INTERFACING
Buzzer is a simple I/O device. Normally we use piezo electric element as buzzer. Buzzer is driven using
a simple NPN transistor with biasing. The transistors base is connected to P0.21 of the microcontroller via
jumper J10. If the port pin is configured as output pin and logic high, the transistor will be triggered on which
in turn switch on the Buzzer. If logic low is provided, the buzzer will be turned off.
17
2.14. UNIVERSAL ASYNCHRONOUS RECEIVER TRANSMITER
LPC2148 has two UART modules namely UART0 and UART1. It has only asynchronous(no clock
connection) mode of operation. For UART0, transmission & reception pins are respectively P0.0 & P0.1. UART1
communicates through P0.8(TXD1) and P0.9(RXD1).
UART0
UART0 communication via USB/Serial port is selected using jumpers J7 and J9. Through RMC
connector, UART0 can be used in two voltage levels of 3V3/5V which can be selected by jumper J16.
Note: While using UART0 for communication, PROGRAMMER switch should be in manual mode
The RS232 interfacing is done by using the serial driver IC MAX 232 and a DB9 connector.
The MAX232 is an IC that converts signal from RS232 serial port to signal suitable for use in TTL
compatible digital logic circuit. The MAX 232 is a dual driver/ receiver and typically converts RX, TX,
CTS and RTS
18
USB Interface using CP2102
CP2102 is a highly-integrated USB-to-UART Bridge Controller providing a simple solution for updating RS-
232 designs to USB using a minimum of components and PCB space. CP2102 includes a USB 2.0 full-speed
function controller, USB transceiver, oscillator, EEPROM, and asynchronous serial data bus (UART) with full
modem control signals in a compact 5 x 5 mm MLP-28 package. No other external USB components are
required.
19
Zigbee Module Interface
UART1
UART1 of LPC 2148 communicates through connector K12 on the board that has 3 pins namely
GND,TXD1 & RXD1.
TXD1 - Transmission pin of UART1 (P0.8)
RXD1 - Reception pin of UART1 (P0.9)
GND - Common ground
20
USING REALTERM IN PC
Real term is a testing, analyzing and simulation tool for serial communication protocols. It allows us to
monitor communication between two serial devices or to test the serial communication of a single devices.
Realterm can be download by (download)
The serial data transmitted through USART can be viewed on a PC using a Windows tool for Serial Port
Communication called Realterm.
21
Step 2: Display Tab- Here the output text format selected is ANSI and Half Duplex mode is
enabled to view the data sent by the user.
Step 3: Port Tab-To test the connection - make sure the Open button is
pressed, Select required baud rate and the Port dropdown here, select the number of
your COM port and then press the Change button.
22
Step 4: Send Tab- Insert the desired data to be transmitted and press "Send ASCII" button.
Step 5 : The output after data transmission to the controller is shown in the following diagram.
The text sent by user and controller is highlighted by callouts in the figure.
23
Step 6: To check reception, go to Send option, type the string in the space provided(encircled in
green) and click Send ASCII button. The first "hello" in green colour is transmitted from PC
& that in yellow colour is retransmitted by the controller
Sent from PC
24
2.15. SERVO MOTOR INTERFACING
Servos are small mechanical motorized devices whose sole purpose is to rotate a tiny shaft attached to
a servo wheel in a specified position. Servos are controlled by sending a pulse width signal from an external
electronic device that generate PWM signal values. PWM signal send to the servo are translated into position
values by electronics inside the servo. In the mini development board, servo is connected to P1.24.
LPC 2148 mini development board has a potentiometer connected to its ADC pin P0.29 (channel2) via
jumper J12.
.
Note : Remove J12 when P0.29 is used for other purpose
25
2.17. TEMPARATURE SENSOR INTERFACE
MCP 9700 temperature sensor can be used to measure temperature. It is connected to P0.28(channel
1) via jumper J11.
26
SOFTWARE DEVELOPMENT
27
The Keil uVision4 window opens as shown below
28
Step 2: Save the project in a suitable location with appropriate name
Step 3: The following window opens. Select LPC 2148 (listed under NXP) from the drop-down
list
29
Step 4: Click Yes for the following question to copy the Startup code to Project folder and add file to
project
30
Create New Source Files
Step 6: Create a new file either by clicking the New File icon, or by selecting File > New or
using keyboard shortcut CTRL + N
31
Add Source Files to Project
Step 8: Right click Source Group 1 to add C file to source group
32
Step 10: Now the c file gets added to the Source
33
Step 11: Double click on Startup.s to open the configuration window
Step 12: Set the options as shown below and save. The PLL setup is done for 12MHz crystal. The
divider &multiplier must be selected such that the PLL output is 30 MHz ((12/2)*5).If crystal
frequency schanged, thenthese values must be Changed accordingly
34
Step 13: Right click on Target1 to set target file options. You can also do this by using the icon on Build
toolbar or Project > Options for Target Target 1
Step 14: Configure Target, Output and Linker options as shown below
Target
35
Output
Linker
36
Step 15: Type the code
37
Now the hex file of the program will be generated in the working folder in the name of the project we created.
When you build an application, Keil uVision4 will display errors and warning messages in the Build page/Build
output. Double clicking a message line opens the corresponding error in the correct location in the Keil
uVision4 editor window. In this example the Hex file is Sample.hex. This file will be available in the folder
Sample.
38
PROGRAMMING STEPS
Now power up the board. The power LED(red LED on the board) glows. Open Flash Utility. Select the correct
COM port and suitable baud rate
39
Step18:Read device ID If auto mode is selected, simply clicking the Read device ID' button will read
the ID. But in manual mode, press reset switch and click
40
I/O DISTRIBUTION
PIN No NAME TYPE THE I/O ASSIGN OF LPC 2148 Mini Development Board
1 P0.21 I/O BUZZER/PWM5
2 P0.22 I/O UNUSED
3 RTXC1 - CRYSTAL
4 P1.19 I/O LCD(E)/TRACEPKT3
5 RTXC2 - CRYSTAL
6 VSS - GROUND
7 VDDA - 3V3
8 P1.18 I/O LCD(R/W),TRACEPKT2
9 P0.25 I/O AD0.4
10 P0.26 I/O D+
11 P0.27 I/O D-
12 P1.17 I/O LCD(RS)/TRACEPKT1
13 P0.28 I/O TEMPERATURE SENSOR/AD0.1
14 P0.29 I/O POTENTIOMETER/AD0.2
15 P0.30 I/O AD0.3/EINT3
16 P1.16 I/O TRACEPKT0
17 P0.31 I/O UP_LED
18 VSS - GROUND
19 P0.0 I/O TXD0/PWM1/ZIGBEE/ MAX 232(T2IN)/CP2102(RX)
20 P1.31 I/O TRST
21 P0.1 I/O RXD0/PWM3/ZIGBEE/ MAX232(R2OUT)/CP2102(TX)
22 P0.2 I/O SCL0
23 VDD - 3V
24 P1.26 I/O RTCK
25 VSS - GROUND
26 P0.3 I/O SDA0
27 P0.4 I/O SCK0/AD0.6
28 P1.25 I/O EXTIN0
29 P0.5 I/O MISO0/AD0.7
41
30 P0.6 I/O MOSI0
31 P0.7 I/O PWM2/SSEL0
32 P1.24 I/O SERVO MOTOR/TRACECLK
33 P0.8 I/O TXD1/PWM4
34 P0.9 I/O RXD1/PWM6/EINT3
35 P0.10 I/O RTS1
36 P1.23 I/O LCD(D7)
37 P0.11 I/O SCL1
38 P0.12 I/O
39 P0.13 I/O
40 P1.22 I/O LCD(D6)
41 P0.14 I/O SDA1/EINT1/SWITCH
42 VSS - GROUND
43 VDD - 3V3
44 P1.21 I/O LCD(D5)
45 P0.15 I/O EINT2/SWITCH SW2
46 P0.16 I/O EINT0/SWITCH SW3
47 P0.17 I/O SCK1/LED1
48 P1.20 I/O LCD(D4)/TRACESYNC
49 VBAT - 3V3
50 VSS - GROUND
51 VDD - 3V3
52 P1.30 I/O TMS
53 P0.18 I/O MISO1/LED2
54 P0.19 I/O MOSI1/LED3
55 P0.20 I/O EINT3/SSEL1
56 P1.29 I/O TCK
57 RESET - RESET
58 P0.23 I/O Vbus
59 VSSA - GROUND
60 P1.28 I/O TD1
61 XTAL2 - CRYSTAL
62 XTAL1 - CRYSTAL
63 VREF - 3V3
64 P1.27 I/O TD0
42
TECHNICAL SUPPORT
If you are experiencing a problem that is not described in this manual, please contact us.
Our phone lines are open from 9:00 AM 5.00 PM (Indian Standard Time) Monday
through Saturday excluding holidays. Email can be sent to support@rhydolabz.com
DISCLAIMER
Copyright Rhydo Technologies (P) Ltd.
All rights are reserved. Reproduction in whole or in part is prohibited without the prior written consent of the
copyright owner. The information presented in this document does not form part of any quotation or
contract, is believed to be accurate and reliable and may be changed without notice.
Contact Us
Rhydo Technologies (P) Ltd.
(An ISO 9001:2008 Certified R&D Company)
Golden Plaza, Chittoor Road, Cochin 682018, Kerala, India.
Tel: 0091 484 2370 444, 2371 666, Cell: 0091- 99466 70444
Fax: 0091 484 237 0579, Email: info@rhydolabz.com, sales@rhydolabz.com
For more information please visit: www.rhydolabz.com