This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

C51:( LINk Error) fatal error: application calls too many recursions.

while using Keil8.04 compiling and link, there is a fatal error:
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?DISP_MOTORSETUP?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?_LCD_SHOWCHAR?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?_LCD_SHOWHZ?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?_LCD_SHOWSTR?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?DISP_CYCLICSETUP?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?DISP_MOTORRUNSETUI?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?DISP_GENERALSETUI?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?DISPAR_TIME?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?DISPAR_STARTTIME?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?DISPAR_ALARMTEMP?MAIN
*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?MAIN CALLER: ?PR?SETUP_MOTORRUNPAR?MAIN
*** FATAL ERROR L232: APPLICATION CONTAINS TOO MANY RECURSIONS
Target not created.

I don't konw why, if there are some error while use function pointer or the pro struct include too many layers? waiting for your idears. this problem has pazzled me several days. If mesessary, i can upload my code for you !

Parents
  • That is a selectable way to avoid function pointer

    you are using TWO things that the '51 architecture is singularily unsuited for "function pointers' and "recursive calls".

    What I suggested was to get rid of BOTH.

    If 'programmers convenience' is more important to you that 'process effiecienmcy' then what you are doing is just fine, but the overhead of using these twu things that the '51 must be "wrangled into" performing is very likely to get you on trouble some day.

    The case of a "working code" falling apart the day you are asked to make a "nominal addition" is not unheard of.

    Erik

Reply
  • That is a selectable way to avoid function pointer

    you are using TWO things that the '51 architecture is singularily unsuited for "function pointers' and "recursive calls".

    What I suggested was to get rid of BOTH.

    If 'programmers convenience' is more important to you that 'process effiecienmcy' then what you are doing is just fine, but the overhead of using these twu things that the '51 must be "wrangled into" performing is very likely to get you on trouble some day.

    The case of a "working code" falling apart the day you are asked to make a "nominal addition" is not unheard of.

    Erik

Children
No data