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

WARNING L5: CODE SPACE MEMORY OVERLAP

Hello I'm a student and I have a full version uvision2.

I have the following linker warning.

*** WARNING L5: CODE SPACE MEMORY OVERLAP
FROM: 0000H
TO: 0418H

Program Size: data=182.0 xdata=0 code=2657
LINK/LOCATE RUN COMPLETE. 1 WARNING(S), 0 ERROR(S)

this my map file
* * * * C O D E M E M O R Y * * * *

TYPE BASE LENGTH RELOCATION

CODE 0000H 0419H ABSOLUTE
* OVERLAP * CODE 0000H 0003H ABSOLUTE

If I remove the main() fonction I have no
WARNING L5:

CODE 0000H 0419H ABSOLUTE use by assembler module

please someone help me.

Parents
  • this is my assembler module

    
    ;PGLEN 59          ;pour utilisation avec XASM51
    $PAGELENGTH(59)    ;pour utilisation avec ASM51
    ;$MOD52             ;pour utilisation avec ASM51
    
    TOUCHE      EQU 27H		;Touche (0-9) designe la case mémoire 27H
    TOUCHEASCII EQU 28H	        ;Touche (0-9) en ASCII case mémoire 28H
    DECI        EQU 29H		;Valeur des dizaines case memoire 29H
    UNI         EQU 2AH		;valeur des unités case memoire 2AH
    CONSIGNE    EQU 2BH	        ;consigne de NIVEAU case memoire 2BH
    NIVEAU      EQU 2CH		;niveau CAN case memoire 2CH
    CASE        EQU 2DH		;Case pour sous-programme LCD case memoire 2DH
    CONSIREEL   EQU 2EH             ;CONTIENT LA CONSIGNE ACTUEL
    
    GRAF0 EQU 30H      ;GRAF0 designe la case memoire 30H et suivantes servant a
    GRAF1 EQU 31H      ;memoriser l'etape active des GRAFCETs 0 et suivants
    GRAF2 EQU 32H      ;
    GRAF3 EQU 33H      ;Les 4 premiers GRAFCETs sont declares
    
    DRAPEAU0 EQU 30H   ;Designe un bit de la plage des bytes adressables bit a bit
    DRAPEAU1 EQU 31H   ;(byte 26H). Ce DRAPEAU (bit) est mis a 0 logique lorsque
    DRAPEAU2 EQU 32H   ;l'on franchi une transition. Ce DRAPEAU est mis a 1 logique
    DRAPEAU3 EQU 33H   ;lorsque les actions de l'etape correspondante sont executees
                       ;Ce DRAPEAU demeure a 1 jusqu'a ce qu'une nouvelle
                       ;transition soit franchie.
    
    TEMPO0  EQU 50H
    TEMPO1  EQU 51H
    TEMPO2  EQU 52H
    TEMPO3  EQU 53H
    NOMTIMER EQU 04H
    TIMERTH0 EQU 3CH
    TIMERTL0 EQU 0B0H
    
    DEBUTSP  EQU   6FH
    POINTEUR EQU   4FH
    WMCON    EQU   96H
    EEMEN    EQU   00001000b
    EEMWE    EQU   00010000b
    WDTRST   EQU   00000010b
    RS      EQU     P1.0
    E       EQU     P1.1
    DATALCD EQU     P0
    RDCAN   EQU     P1.2
    WRCAN   EQU     P1.3
    
            ORG 0
    
    DEBUT:    JMP PRINC
    ;jump over interup vector
              ORG 0BH
              LJMP SRTIMER0
    
             ORG 33H
    ....
    end
    

    I can't have an assembler file putting code at 0x0000!

    How I can keep free code at 0x0000 ?

    thanks for your help

Reply
  • this is my assembler module

    
    ;PGLEN 59          ;pour utilisation avec XASM51
    $PAGELENGTH(59)    ;pour utilisation avec ASM51
    ;$MOD52             ;pour utilisation avec ASM51
    
    TOUCHE      EQU 27H		;Touche (0-9) designe la case mémoire 27H
    TOUCHEASCII EQU 28H	        ;Touche (0-9) en ASCII case mémoire 28H
    DECI        EQU 29H		;Valeur des dizaines case memoire 29H
    UNI         EQU 2AH		;valeur des unités case memoire 2AH
    CONSIGNE    EQU 2BH	        ;consigne de NIVEAU case memoire 2BH
    NIVEAU      EQU 2CH		;niveau CAN case memoire 2CH
    CASE        EQU 2DH		;Case pour sous-programme LCD case memoire 2DH
    CONSIREEL   EQU 2EH             ;CONTIENT LA CONSIGNE ACTUEL
    
    GRAF0 EQU 30H      ;GRAF0 designe la case memoire 30H et suivantes servant a
    GRAF1 EQU 31H      ;memoriser l'etape active des GRAFCETs 0 et suivants
    GRAF2 EQU 32H      ;
    GRAF3 EQU 33H      ;Les 4 premiers GRAFCETs sont declares
    
    DRAPEAU0 EQU 30H   ;Designe un bit de la plage des bytes adressables bit a bit
    DRAPEAU1 EQU 31H   ;(byte 26H). Ce DRAPEAU (bit) est mis a 0 logique lorsque
    DRAPEAU2 EQU 32H   ;l'on franchi une transition. Ce DRAPEAU est mis a 1 logique
    DRAPEAU3 EQU 33H   ;lorsque les actions de l'etape correspondante sont executees
                       ;Ce DRAPEAU demeure a 1 jusqu'a ce qu'une nouvelle
                       ;transition soit franchie.
    
    TEMPO0  EQU 50H
    TEMPO1  EQU 51H
    TEMPO2  EQU 52H
    TEMPO3  EQU 53H
    NOMTIMER EQU 04H
    TIMERTH0 EQU 3CH
    TIMERTL0 EQU 0B0H
    
    DEBUTSP  EQU   6FH
    POINTEUR EQU   4FH
    WMCON    EQU   96H
    EEMEN    EQU   00001000b
    EEMWE    EQU   00010000b
    WDTRST   EQU   00000010b
    RS      EQU     P1.0
    E       EQU     P1.1
    DATALCD EQU     P0
    RDCAN   EQU     P1.2
    WRCAN   EQU     P1.3
    
            ORG 0
    
    DEBUT:    JMP PRINC
    ;jump over interup vector
              ORG 0BH
              LJMP SRTIMER0
    
             ORG 33H
    ....
    end
    

    I can't have an assembler file putting code at 0x0000!

    How I can keep free code at 0x0000 ?

    thanks for your help

Children
  • What is the point of your assembler file?

  • I can't have an assembler file putting code at 0x0000!

    Indeed you can't!

    I am not clear what it is that you wish to achieve.

    If you really want to write a C program, but to override the reset vector, then you should include STARTUP.A51 in your project and modify that (with great care).

    If you just want to include an assembly language function in your project that is called from C or invoked as an interrupt, then there are many ways of doing that, but you should let the linker worry about where to actually put your code.