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

.LST and .M51 SFR mapping mismatches (uvision2 6.02 and 6.10)

Hi,

In an older version of my software, I use a specific SFR (CNTRL_REG) mapped on 0xC5 SFr address.
In the new version, I need to map it at 0xC1.
I thought it was very easy just by changing the definition line from

sfr CNTRL_REG = 0xC5
to
sfr CNTRL_REG = 0xC1

After compiling the newer version, we still get CNTRL_REG mapped to 0xC5 in the simulator disassembler. In the .m51 file, CNTRL_REG is also mapped to 0xC5, whereas .LST and .SRC files mapped it to 0xC1 as requested.

Anybody has an idea ?

Thanks for your help.

Arnaud DELEULE

Parents
  • Sorry for adding a new message, but I found the problem and I think that it may be interessant.

    In fact, all the problems come from the

    #pragma src
    line I put at the beginning of my .C file.

    When this line is commented, all is fine. The modification of SFR mapping is taken into account when I rebuild all the project.
    On the contrary, when this pragma line is active, any changes in the source code of my .C file concerning SFR mapping is ignored, whenever I rebuild all the project.

    Is it normal or is it a bug ?

    Arnaud DELEULE

Reply
  • Sorry for adding a new message, but I found the problem and I think that it may be interessant.

    In fact, all the problems come from the

    #pragma src
    line I put at the beginning of my .C file.

    When this line is commented, all is fine. The modification of SFR mapping is taken into account when I rebuild all the project.
    On the contrary, when this pragma line is active, any changes in the source code of my .C file concerning SFR mapping is ignored, whenever I rebuild all the project.

    Is it normal or is it a bug ?

    Arnaud DELEULE

Children