Steps for Programming LPC2129

download Steps for Programming LPC2129

If you can't read please download the document

description

lpc2129

Transcript of Steps for Programming LPC2129

===============================================================================================----------------- Steps for programming LPC2129 using Keil IDE & Flash Utility ----------------===============================================================================================This Programming is done using:Integrated development environment (IDE) - KeilProgrammer Software - Flash Utility for LPC2100Programmer Hardware - Serial Port Programmer for LPCHardware Experiment Board - LPC2129 Development BoardSteps for programming LPC2129 using Keil IDE:Step- 1 : Open Keil Uvision3Step- 2 : Goto->Project & Select->New Project. Give project name & path and Click Save.Step- 3 : It opens a Dialog Box to select Microcontroller.Goto->Philips & Drag the '+' mark beside philips.Then select->LPC2129 and press OK.It will Specify to add a startup code to the project. Click->Yes.Step- 4 : Goto->File & Select New.It opens a text window in which the program has to be written.After writing the program Goto->File & Click->SaveAs.Give a name to the file and save it with an extension of '.c'Step- 5 : On the leftside of the Program window there is a 'Project Workspace' window.In that window drag the target by Clicking on '+'It opens a sub Folder called 'Source Group 1'.Right Click on 'Source Group 1' and Click->"Add Files to Group'Source Group 1'"Add the program file which has been created previously.Step- 6 : Goto->Project & Click Build Target.The compilation starts and the process can be seen on the output window at the bottom.If there are any errors it shows with specific line numbers.Otherwise it will stop with '0 Errors & 0 Warnings'.Step- 7 : For Creating hex file just Right Click on 'Target 1'Click on 'options for 'target 1'.It opens a Dialog Box. Select the 'output option in the above options of the dialog box.Step- 8 : Click on 'create hex file'. Then select OK.Compile the code once again to create the hex file.The hex file is created in the location where the project is stored and is named with the project name.===============================================================================================Steps for Dumping Program to LPC2129 using Flash Utility Step- 1 : Open LPC2100 Flash Utility by PlilipsStep- 2 : It opens a Dialog Box with multiple BlocksStep- 3 : Connect LPC2129 Development Board using Serial Port.Step- 4 : In 'Device' Block, Click 'Read Device ID'.Step- 5 : If the Device is connected properly then the message 'Device Read Successfully' can be seen on the status bar.Otherwise there might be other messages like 'Reading of part ID failed'.Then Reconnect the device and try again.Step- 6 : After the device is read, Goto-> 'Erase/Blank' block and Click 'Erase'.This will erase the flash of LPC2129. cStep- 7 : Under the 'Flash Programming' Block give the path of the created Hex file under the 'Filename'.Step- 8 : Then Click 'Upload to Flash'. The status can be seen obove the status bar & After completion of the process the status bar retuns 'Uploaded Successfully'.Step- 9 : Disconnect the Serial Port and continue working with LPC2129 Development Board. =============================================================================================================================================================================================================================================================================================================================================================================================================