Skip to content

Commit

Permalink
updated the linker script and the description
Browse files Browse the repository at this point in the history
fix on pointer definition to avoid compiler warnings
  • Loading branch information
GiPa committed Aug 7, 2013
1 parent f4d9282 commit af089cb
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 16 deletions.
5 changes: 4 additions & 1 deletion G14/crc_calculation/README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,7 @@ The high speed CRC sum is computed over flash range 0x0 t0 0xFFFB
The project can be flashed via the renesas flash programmer software.
A workspace and project for the renesas flash programmer is placed in the TB_flash folder, to flash the application using the E1 emulator.

However the E1 emulator cannot be used for debugging within IAR since the rom monitor firmware is included in the last 512/256 bytes of the flash and conflicts with the CRC signature placement in the last 4 bytes of the flash.
However the E1 emulator cannot be used for debugging within IAR in this configuration.
This since the rom monitor firmware is included in the last 512/256 bytes of the flash address space and there is a conflict with the CRC signature placement in the last 4 bytes of the flash

An alternative would be to place the signature in the data flash, which is separate by the code flash
21 changes: 7 additions & 14 deletions G14/crc_calculation/applilet3_src/md_lnkr5f104le.xcl
Original file line number Diff line number Diff line change
Expand Up @@ -141,22 +141,15 @@
// Startup, Runtime-library, Near, Interrupt
// and CALLT functions code segment and near switch.
//-------------------------------------------------------------------------
// -Z(CODE)RCODE,CODE=000D8-0FDFF
// -Z(CONST)SWITCH=000D8-0FDFF
-Z(CODE)RCODE,CODE=000D8-_CRC_TEST_FLASH_END
-Z(CONST)SWITCH=000D8-_CRC_TEST_FLASH_END


-Z(CODE)RCODE,CODE=000D8-0FDFF
-Z(CONST)SWITCH=000D8-0FDFF

//-------------------------------------------------------------------------
// Near data initializer segments.
//-------------------------------------------------------------------------
// -Z(CONST)NEAR_ID=[000D8-0FDFF]/10000
// -Z(CONST)SADDR_ID=[000D8-0FDFF]/10000
// -Z(CONST)DIFUNCT=[000D8-0FDFF]/10000
-Z(CONST)NEAR_ID=[000D8-_CRC_TEST_FLASH_END]/10000
-Z(CONST)SADDR_ID=[000D8-_CRC_TEST_FLASH_END]/10000
-Z(CONST)DIFUNCT=[000D8-_CRC_TEST_FLASH_END]/10000
-Z(CONST)NEAR_ID=[000D8-0FDFF]/10000
-Z(CONST)SADDR_ID=[000D8-0FDFF]/10000
-Z(CONST)DIFUNCT=[000D8-0FDFF]/10000

//-------------------------------------------------------------------------
// Allocate the read/write segments that are mapped to RAM.
Expand Down Expand Up @@ -205,10 +198,10 @@
//-------------------------------------------------------------------------
// CRC specific options
//-------------------------------------------------------------------------
-Hff -h0x0000-0xFFFB
-Hff -h0x0000-_CRC_TEST_FLASH_END

// -Jsize,algo,flag,sym,seg,align,m#val
-J2,crc16,L,,CHECKSUM,,0x0=0x0-0xFFFB
-J2,crc16,L,,CHECKSUM,,0x0=0x0-_CRC_TEST_FLASH_END

-Z(CONST)CHECKSUM=0xFFFC-0xFFFD

Expand Down
2 changes: 1 addition & 1 deletion G14/crc_calculation/applilet3_src/r_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ void main(void)
/* High-speed CRC */

/* Get High-speed CRC calculated result that OC output. */
oc_calc_hs_crc = (uint16_t*)HIGHSPEED_CALC_ADDR;
oc_calc_hs_crc = (uint16_t __far*)HIGHSPEED_CALC_ADDR;

result_hs_crc = my_HighSpeedCRCProc();

Expand Down

0 comments on commit af089cb

Please sign in to comment.