Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] problem in compile with keil uvision

Status
Not open for further replies.
Check post #19, "Attached ReDos"

---------- Post added at 09:21 ---------- Previous post was at 09:19 ----------

@ckshivaram - The startup code is in the zips!
 

I had the generate HEX file box unchecked.

Attached ReDos
i programmed chip,but that didn't work,also when i debug that whit keil,it stoped on
DAbt_Handler B DAbt_Handler
from lpc2300.s

---------- Post added at 12:55 ---------- Previous post was at 12:53 ----------

without startup code in your project the code would never work on hardware... so add startup code.... and compile and get hex file....
when it asks for add file,i click on yes.
but when i use GCC compiler,it gives error from that and i have to use default comiler
 

go to disassembly and see the address where it is going wrong..

put a break point on main() line and when you debug run the program.. see if the control comes to main()....

@ bigdogguru.. sorry i was not referring your posts , but was telling OP to add the startup code and try to compile....
 

Is this hardware or Proteus simulation?
I tried both of them,didn't work

---------- Post added at 13:02 ---------- Previous post was at 13:01 ----------

go to disassembly and see the address where it is going wrong..

put a break point on main() line and when you debug run the program.. see if the control comes to main()....

@ bigdogguru.. sorry i was not referring your posts , but was telling OP to add the startup code and try to compile....
I did that and control didn't come in main()
 

mehran123,

I have a Keil MCB2378 board here, that is the closest LPC23xx I have to a LPC2368. If you would like I will test it with Flash Magic tomorrow and let you know the results.

I have a feeling it is a ROM address conflict.

BigDog
 

thank you.
I will try until tomorrow and if it solved will say that.
 

but hex file that generate keil,didn't work in proteus(for lpc2132)

I faced the same problem. Hex file generated by keil 4 does not work with proteus (but works in real hardware) that is why I started using Keil 3.xx
 
do step by step debug in keil window and observe each step execution's address and see where it jumps.... read the data abort register when you loose control of program...
 

it stop on line 426 of lpc2300.s
and this is that command
DAbt_Handler B DAbt_Handler
 

Yes, that is the Data Abort Error Handler referenced from the vector table.

It indicates a memory read/write error.

BigDog
 

i downloaded keil 3.7
now when i make a HEX file,it work in proteus.
but when i program chip,it doesn't work
 

in simulator it makes a square signal
crystal of board is 12MHz
voltage of P0[14]=3.5 v

---------- Post added at 20:41 ---------- Previous post was at 19:04 ----------

and finally the problem solved
in options for target---->target check Use MicrLIB
options for target---->C/C++ check Optimize for time
and the program worked.
thanks for your help
 
and finally the problem solved
in options for target---->target check Use MicrLIB
options for target---->C/C++ check Optimize for time
and the program worked.

Does it work for both hardware and Proteus using the above setting?
 

yes
but also should start of IROM=0x2000 and size=0x7e00 for using bootloader
 
Yes,

I figured it was a memory conflict of some sort. It also explains the Data Abort Error you were experiencing and why it was stuck at the error handler, "DAbt_Handler B DAbt_Handler."

Another troubleshooting tip to keep in mind when using Flash Magic.


BigDog
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top