Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
08/10/04 05:36
Read: times


 
#75687 - ASM works not C PART 2: LCALL vs. ACALL
Hello everyone. I recently posted a topic discussing my inability to run programs in C created for my 80C51 produced by Keil C eval. version compiler.

I discovered that programs using a function call resulted in a 'dead' program, until I changed Options for Target > Target tab > Code Rom size: to "Small: program 2k or less" option.
This produces an ACALL (instead of LCALL) in my .LST file, and thus my programs may work.

I have searched data sheet/Keil/8052.com/internet without direct solution/explanation. I believe other beginners may find this problem relevant and just as frustrating.

My questions for you experienced and knowledgeable guys:
1. Why is one simple LCALL causing my 8051 to hang/crash? I can't find explanation...considered SP fault but how? (Plenty of stack space)
2. What are your recommendations for dealing with this situation (in general) and functions called in C?

Please excuse me for being a novice here...I am trying extremely hard to resolve this, and have spent literally days working/experimenting/troubleshooting on this!!!

Thanks to everyone here (especially advice from Erik, Kai, Russell, Oleg, Bartosz),
Marty

*Note: my external code EEPROM is 0x0000-0xFFFF (64k) but my progs. < 1K

List of 20 messages in thread
TopicAuthorDate
ASM works not C PART 2: LCALL vs. ACALL            01/01/70 00:00      
   RE: ASM works not C PART 2: LCALL vs. ACALL            01/01/70 00:00      
   RE: ASM works not C PART 2: LCALL vs. ACALL            01/01/70 00:00      
      eval            01/01/70 00:00      
   RE: ASM works not C PART 2: LCALL vs. AC            01/01/70 00:00      
      RE: ASM works not C PART 2: LCALL vs. AC            01/01/70 00:00      
         RE: ASM works not C PART 2: LCALL vs. AC            01/01/70 00:00      
            RE: ASM works not C PART 2: LCALL vs. AC            01/01/70 00:00      
      RE: ASM works not C PART 2: LCALL vs. AC            01/01/70 00:00      
   \            01/01/70 00:00      
      RE: \            01/01/70 00:00      
         RE: \            01/01/70 00:00      
            Reply to off-topic comments...            01/01/70 00:00      
               RE: Reply to off-topic comments...            01/01/70 00:00      
               RE: Reply to off-topic comments...            01/01/70 00:00      
               Hardware bug?            01/01/70 00:00      
   Testing C program results...            01/01/70 00:00      
      RE: Testing C program results...            01/01/70 00:00      
      RE: Testing C program results...            01/01/70 00:00      
         The Next Step...            01/01/70 00:00      

Back to Subject List