Topic : incorrect data overlay for interrupt called routines

Forum : 8051

Original Post
Post Information Post
March 25, 2014 - 5:54pm
Guest

I've found that erratic behaviour of my program is caused by overlay of local data/bit variables from subroutines called from main and variables of subroutines called from interrupt service routines. I am using Rkit51 w. LX51 with default options.

I would expect that LX51 assumes that interrupt routine (and its subroutines) can be called from main (and its every subroutine) automatically.

Example:
SEGMENT BI_GROUP DT_GROUP ID_GROUP XD_GROUP
+--> CALLED SEGMENT START LENGTH START LENGTH START LENGTH START LENGTH
--------------------------------------------------------------------------------------

?PR?Ext0Int?MAIN?S?MAIN 0023H.0 0000H.1 0067H 0001H ------------- -----------------
+--> ?PR?_Burst_LUT_process?BURST

?PR?_Burst_LUT_process?BURST 0022H.4 0000H.1 003EH 0001H --------------- 87F1H 000EH
+--> ?PR?_idee_semilog_enc?BURST

?PR?_idee_semilog_enc?BURST --------------- 003FH 0005H --------------- ---------------

?PR?main?MAIN 0022H.1 0000H.1 0024H 0009H 001EH 0002H 872AH 0003H
+--> ?PR?_GetHSKa?ADC_UTILS

?PR?_GetHSKa?ADC_UTILS 0022H.2 0000H.2 0032H 0002H --------------- ---------------
+--> ?PR?_ReadADCint?ADC_UTILS

?PR?_ReadADCint?ADC_UTILS 0022H.4 0000H.4 003EH 0007H --------------- ---------------

Morover, I cannot add ?PR?Ext0Int?MAIN?S?MAIN to the LX51 OVERLAY directive to tell the linker there is a potential call.
LX51 returns error

Replies
Post Information Post
+1
0
-1
March 28, 2014 - 3:35pm
Raisonance Support Team

Hello,

These informations are not enough to understand the issue, could it be possible for you to send us your project.
If it's possible, please, send it to .

Thank you

Best regards,