Renamed a cc253x SFRX to stop namespace conflicts

The TR0 SFRX can not use the name TR0 because it
conflicts with TCON.TR0 on the default 8051.

See SDCC bug 3513300
ico
George Oikonomou 2012-06-21 10:50:41 +01:00
parent 4b73b48f60
commit 62fbd389d8
2 changed files with 6 additions and 2 deletions

View File

@ -349,7 +349,11 @@ SFRX(OBSSEL4, 0x6247); /* Observation output control - register 4 */
SFRX(OBSSEL5, 0x6248); /* Observation output control - register 5 */
SFRX(CHVER, 0x6249); /* Chip version */
SFRX(CHIPID, 0x624A); /* Chip identification */
SFRX(TR0, 0x624B); /* Test register 0 */
/* TR0 below is renamed to TESTREG0 to avoid namespace conflicts with the
* bit-addressable TCON.TR0 on the default 8051. See SDCC bug 3513300 */
SFRX(TESTREG0, 0x624B); /* Test register 0 */
SFRX(DBGDATA, 0x6260); /* Debug interface write data */
SFRX(SRCRC, 0x6262); /* Sleep reset CRC */
SFRX(BATTMON, 0x6264); /* Battery monitor */

View File

@ -111,7 +111,7 @@ configure(int type, int value)
#if TEMP_SENSOR_ON
/* Connect temperature sensor to the SoC */
ATEST = 1;
TR0 = 1;
TESTREG0 = 1;
#endif
APCFG = 0; /* Disables Input Channels */
break;