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

using UNUSED(REMOVE) linker directive

Hello, when i add linker directive UNUSED(REMOVE) in B51 misc tab , i get error


FATAL ERROR L204: INVALID KEYWORD
POS:1219

my intention is to force linker to remove unused functions. any pointer would
be of good help

thanks in advance
-rajan

Parents
  • Hello,

    i used LX51. Replaced RAM_SIZE directive by CLASSES directive. so LX51 flag is

    BankArea (0x00A000, 0x00FFFF) Rtx51Tiny
    CLASSES (XDATA (X:0x2000-X:0xFFFF), HDATA (X:0x2000-X:0xFFFF), CODE (C:0x2100-C:0x9FFF), CONST (C:0x2100-C:0x9FFF),
    ECODE (C:0x2100-C:0x9FFF), HCONST (C:0x2100-C:0x9FFF))

    my BL51 looked like this :

    TO ".\obj\final" BankArea(0xA000,0xFFFF) Rtx51Tiny
    RAMSIZE(256)
    CODE( 0X2100-0X9FFF )
    XDATA( 0X2000-0XFFFF )

    After linking, its giving error
    **** ERROR "ADDRESS OUTSIDE INTEL-HEX RANGE (USE 'H386' CONTROL)

    From online reading i understood that , address space is exceeding 64K so its
    giving error. When i compare Bl51 and LX51 memory setting (as above), i don't
    see any memory setting difference.

    i am wondering how using LX51 has increased address space ?
    thanks

    -rajan

Reply
  • Hello,

    i used LX51. Replaced RAM_SIZE directive by CLASSES directive. so LX51 flag is

    BankArea (0x00A000, 0x00FFFF) Rtx51Tiny
    CLASSES (XDATA (X:0x2000-X:0xFFFF), HDATA (X:0x2000-X:0xFFFF), CODE (C:0x2100-C:0x9FFF), CONST (C:0x2100-C:0x9FFF),
    ECODE (C:0x2100-C:0x9FFF), HCONST (C:0x2100-C:0x9FFF))

    my BL51 looked like this :

    TO ".\obj\final" BankArea(0xA000,0xFFFF) Rtx51Tiny
    RAMSIZE(256)
    CODE( 0X2100-0X9FFF )
    XDATA( 0X2000-0XFFFF )

    After linking, its giving error
    **** ERROR "ADDRESS OUTSIDE INTEL-HEX RANGE (USE 'H386' CONTROL)

    From online reading i understood that , address space is exceeding 64K so its
    giving error. When i compare Bl51 and LX51 memory setting (as above), i don't
    see any memory setting difference.

    i am wondering how using LX51 has increased address space ?
    thanks

    -rajan

Children