"The string '__checksum' was not found in the string table"解决办法

转载 2013年12月05日 15:54:57



IELFTOOL Checksum - Basic actions

EW targets: ARM, RH850, RX, SH, STM8
EW component: General issues
Last update: September 6, 2013

Below follows the steps needed to set up an CRC16 checksum calcuation, both in the EW-tool-chain and in the application.

This note applies to...
...these versions of the following Embedded Workbenches products:
EWARM 5.11 (and later) - - - EWRX 2.10 (and later)
EWSH 2.10 (and later) - - - EWSTM8 1.10 (and later)

Include checksum calculation source in your application.

The minimum requirement is that your source uses the symbol __checksum.

Note: If your source doesn't use the symbol __checksum you will get an error message from IELFTOOL: "The string '__checksum' was not found in the string table".

To be able to link anyway, you can turn on Project > Options... > Linker > Extra Options > mark "Use command line options" and add the command line option "--keep __checksum".

Checksum calculation in the application

The supplied example(s) shows how to use the CRC16 checksum calculation. In the C source of the application you need to add the actual generic C source to calculate the same checksum value as EWARM calculates. There are two variants of the calculation:

Fast -- Short execution time, but it uses up more ROM/flash for a constant table.

Slow -- It uses less ROM/flash but more execution time.

Please note:

The checksum calculation must not (in order to work) be made over the bytes where the checksum is placed in memory. One solution is to place the checksum at the beginning or end of memory. So the bytes (1, 2 or 4) where the checksum is saved must be excluded from the checksum calculation.

If the slow function is used, you must make a final call to the checksum calculation with the same number of bytes, with value 0x00, as you have bytes (1, 2 or 4) in the checksum. See the 'Example (1 range, 3 diff. locations)' project for details. (Use the link to the upper right.)

Turn on checksum calculation in the options for the linker

You can use these options either in the Embedded Workbench or on the command line. If using command line the command should first run the linker, then run the IELFTOOL.

In the EW you set up calculation of the checksum in menu Project > Options > Linker > Checksum options tab.

The options used in the (place first) example are:
Fill unused code memory
Fill pattern 0xFF (can be any pattern)
Start address 0x0 (adjust to your application)
End address 0xFFFB (adjust to your application)
Generate checksum; size = 2 bytes; CRC16; Complement = as is; Bit order = MSB first; initial value = 0.

The corresponding command line is:

ielftool --fill 0xFF;0x0-0xfffb --checksum __checksum:2,crc16,0x0;0x0-0xfffb 

There are 2 requirements that you have to fulfill to make this work. - See the next 2 parts of the tech note.

Select the address range to be checksummed.
Select where the chacksum will be placed.
Select the range for which checksum will be calculated

The checksum should (normally) cover all non-RAM bytes of the application,excluding the bytes where the checksum is placed.

The way to get knowledge about this is to turn on

menu Project > Options... > Linker > Checksum > mark "Fill unused code memory" and mark "Generate checksum"

menu Project > Options... > Linker > List > mark "Generate linker map file"

menu Tools > Options... > Messages > Show build messages > All

Add usage of the symbol __checksum in your application.

Perform one build.

Then look in the .map file to see where the symbol __checksum is placed.

Look in the "Build Window" to see the memory range that will be used in the checksum calculation.

Specify where the checksum itself is stored

This is done in the .icf file. The following example will place it at the end of memory.

Add this in the .icf file.

place at end of ROM_region { ro section .checksum };

In the 'Example (1 range, 3 diff. locations)', configuration 'PlaceEndOfROM' , the start address is 0x0 and the end address is 0xFFFB.

Please Note: There are several other solutions on how/where to place the checksum in memory. - These solutions are presented in the Tech Note 62709.

All product names are trademarks or registered trademarks of their respective owners.


编译工程时出现异常“[Error] File not found: 'DIALOG.RES'”怎么解决


新建JSP无法运行出现错误The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Pat解决办法

The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
  • UckyK
  • UckyK
  • 2014年10月13日 23:33
  • 2389

关于eclipse提示:"The superclass "javax.servlet.http.HttpServlet" was not found on the Java"解决办法

by _Json 新建jsp页面老提示: Multiple annotations found at this line:   - The superclass "javax.servlet...
  • peade
  • peade
  • 2016年05月10日 23:28
  • 2321

The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path的解决办法

The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path的解决办法

bashfdiskcommand not found 解决办法

  • 2015年08月11日 15:57
  • 856B
  • 下载

FFI::NotFoundError: Function '_get_errno' not found in [msvcrt.dll]解决办法

案例: require 'watir'后,第一次执行 ie=Watir::IE.new报错如下: C:\>irb irb(main):001:0> require 'watir' => tru...
  • lt_fina
  • lt_fina
  • 2012年10月22日 16:18
  • 925

class java/lang/AutoCloseable not found in *.platforms\android-19\android解决办法

上一篇博客说到了,如何更新android sdk的问题,首先说一下,我的android sdk是直接搜索百度关键词:android sdk下载搜到的下载资源,这个资源包已经集成了eclipse+adt...

Android在编译和反编译时出现error: Error: String types not allowed错误的解决办法

最近在编译和反编译apk包时出现了如标题所示的错误,经过google在stackoverflow  http://stackoverflow.com/questions/7899767/admob-e...
  • Tibib
  • Tibib
  • 2013年05月02日 16:38
  • 5965

DateConverter does not support default String to 'Date' conversion解决办法

2011-6-10 10:48:41 org.apache.catalina.core.StandardWrapperValve invoke严重: Servlet.service() for ser...

解决安装MySQL-python出现的:Python version 2.7 required, which was not found in the registry

安装MySQL-python-1.2.3.win-amd64-py2.7.exe,时提示:Python version 2.7 required, which was not found in the...
您举报文章:"The string '__checksum' was not found in the string table"解决办法