<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>8-bit Microcontrollers中的主题 Re: About storing initialization information on HCS08 device</title>
    <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151101#M8169</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here it is :-D&lt;/P&gt;&lt;P&gt;Thanks a lot.&lt;/P&gt;&lt;P&gt;I know, may be it was a quite stupid question, but I wasn't able to solve it.&lt;/P&gt;&lt;P&gt;Now I have to understand how to merge the files (but I think this is possible through srecord utility, or may be through P&amp;amp;E tools)&lt;/P&gt;&lt;P&gt;Thanks again&lt;/P&gt;&lt;P&gt;Giovanni&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 27 Sep 2010 23:13:51 GMT</pubDate>
    <dc:creator>Giox79</dc:creator>
    <dc:date>2010-09-27T23:13:51Z</dc:date>
    <item>
      <title>About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151093#M8161</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Good morning,&lt;/P&gt;&lt;P&gt;I'm developing an application on a HCS08QE device and I need some help.&lt;/P&gt;&lt;P&gt;My problem is the following one:&lt;/P&gt;&lt;P&gt;my application need a set of initialization information that depends on the serial number of the installed device, and that therefore I cannot select at compile time.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In order to solve my problem I thought about using srecord (&lt;STRONG&gt;srecord&lt;/STRONG&gt;.sourceforge.net), creating (with a C++ desktop application) a binary file that contains a struct with the desired data, and then inserting it at the desired address through srecord.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;However I found no reference to this platform in this forum so I have 2 question:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;is there an easier way to accomplish the desired task, and therefore I don't need it on HCS08?&lt;/LI&gt;&lt;LI&gt;is there some "tutorial" that explain how to perform these operations?&lt;/LI&gt;&lt;/OL&gt;&lt;DIV&gt;I searched the web for Flash srecord modification, and similar words, but very often I get link to forum question (I will be one of them :-D) and no tutorial.&lt;/DIV&gt;&lt;DIV&gt;Is there someone that can help me?&lt;/DIV&gt;&lt;DIV&gt;Many thanks&lt;/DIV&gt;&lt;DIV&gt;Giovanni&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 25 Sep 2010 16:24:36 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151093#M8161</guid>
      <dc:creator>Giox79</dc:creator>
      <dc:date>2010-09-25T16:24:36Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151094#M8162</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Production programmers, such as PE Cyclone Pro, typically have a serial number feature implemented. I would check that out before starting to re-invent the wheel.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.pemicro.com/products/product_viewDetails.cfm?product_id=1&amp;amp;CFID=1127929&amp;amp;CFTOKEN=18794447" rel="nofollow" target="_blank"&gt;http://www.pemicro.com/products/product_viewDetails.cfm?product_id=1&amp;amp;CFID=1127929&amp;amp;CFTOKEN=18794447&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 13:15:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151094#M8162</guid>
      <dc:creator>Lundin</dc:creator>
      <dc:date>2010-09-27T13:15:10Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151095#M8163</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Lundin,&lt;/P&gt;&lt;P&gt;thanks a lot for your help.&lt;/P&gt;&lt;P&gt;In effect I need something more than a serial number.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The value that should be stored are about 300 bytes of data, and they dependens on the device (something like a crypto key).&lt;/P&gt;&lt;P&gt;I will check if this kind of data are supported by the P&amp;amp;E device.&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;&lt;P&gt;Giovanni&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 14:13:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151095#M8163</guid>
      <dc:creator>Giox79</dc:creator>
      <dc:date>2010-09-27T14:13:50Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151096#M8164</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In that case it might be best to do as you suggested in your first post: reserve memory for the data in the flash by allocating a "dummy struct", then edit the s-record externally before programming it.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 16:48:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151096#M8164</guid>
      <dc:creator>Lundin</dc:creator>
      <dc:date>2010-09-27T16:48:11Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151097#M8165</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;thanks for your help. And do you have any experience about the tools than could be useful to accomplish the desired task?&lt;/P&gt;&lt;P&gt;Any suggestion will be really appreciated (link to tool, C/C++ class able to parse and modify srecord etc).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot for your help&lt;/P&gt;&lt;P&gt;Giovanni&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 17:54:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151097#M8165</guid>
      <dc:creator>Giox79</dc:creator>
      <dc:date>2010-09-27T17:54:07Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151098#M8166</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You may find it easier to create a separate S19 file with only the 'unique-per-device' data block, and then simply combine the two S19 files into one.&amp;nbsp; You may have to remove the S9 record from one of the two (normally you'd want to do that for the firmware S19 because it's the one that will be built once per version), or simply sort the final S19 so that both S9 records end up at the end.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Another idea: If your 'key' is somehow mathematically derived solely from the S/N (and assuming the key generation code isn't too demanding in terms of code size), why not have the firmware generate it on very first power up (normally done in-house before testing), and save the generated key to Flash.&amp;nbsp; Following resets will see the data is already there and not mess with it, or re-calculate it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 20:05:54 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151098#M8166</guid>
      <dc:creator>tonyp</dc:creator>
      <dc:date>2010-09-27T20:05:54Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151099#M8167</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi thanks for your help.&lt;/P&gt;&lt;P&gt;The second idea is quite difficult: in effect I don't have enough memory to allocate both the data and the algorithm (the .text section is already almost full).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;About the first idea: do you have some suggestion on how to create a valid s19 file?&lt;/P&gt;&lt;P&gt;I'm able to write a binary file with the interesting data, how do I convert it to S19 file? Any C++ library (that I can integrate in my application) is available?&lt;/P&gt;&lt;P&gt;Any help will be very useful.&lt;/P&gt;&lt;P&gt;Thanks for your support&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Gio&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 22:19:59 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151099#M8167</guid>
      <dc:creator>Giox79</dc:creator>
      <dc:date>2010-09-27T22:19:59Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151100#M8168</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The S19 file format is very simple, and it should be rather easy to write a routine to get any binary data into S19.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="http://en.wikipedia.org/wiki/S19_%28file_format%29" rel="nofollow" target="_blank"&gt;Wikipedia&lt;/A&gt; has good description for it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Or, get a simple binary to S19 conversion utility like &lt;A href="http://aspisys.com/binex.exe" rel="nofollow" target="_self"&gt;this one&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;From the command line, type BINEX KEY.BIN KEY.S19 $F000&lt;/P&gt;&lt;P&gt;where KEY.BIN is your binary data file, KEY.S19 is the output file, and $F000 is whatever starting address you want to place the data at.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 23:08:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151100#M8168</guid>
      <dc:creator>tonyp</dc:creator>
      <dc:date>2010-09-27T23:08:27Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151101#M8169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here it is :-D&lt;/P&gt;&lt;P&gt;Thanks a lot.&lt;/P&gt;&lt;P&gt;I know, may be it was a quite stupid question, but I wasn't able to solve it.&lt;/P&gt;&lt;P&gt;Now I have to understand how to merge the files (but I think this is possible through srecord utility, or may be through P&amp;amp;E tools)&lt;/P&gt;&lt;P&gt;Thanks again&lt;/P&gt;&lt;P&gt;Giovanni&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 23:13:51 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151101#M8169</guid>
      <dc:creator>Giox79</dc:creator>
      <dc:date>2010-09-27T23:13:51Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151102#M8170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Merging the files is just a simply copy (or cat, if in Linux) operation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can have the whole process run from a single batch or MAKE file, something like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;generate_key mykey.bin&lt;/P&gt;&lt;P&gt;binex mykey.bin mykey.s19 $F000&lt;/P&gt;&lt;P&gt;copy firmware.s19+mykey.s19 final.s19&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;then load final.s19 into your device.&amp;nbsp; (I'm assuming you have edited out the S9 record from the firmware.s19 file using any ASCII text editor, like NotePad.)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Sep 2010 23:22:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151102#M8170</guid>
      <dc:creator>tonyp</dc:creator>
      <dc:date>2010-09-27T23:22:18Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151103#M8171</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, thanks again.&lt;/P&gt;&lt;P&gt;I'm sorry for the late replay but I was out of my office.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I didn't understand the line "I'm assuming you have edited out the S9 record from the firmware.s19 file using any ASCII text editor, like NotePad."&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;However I will try the suggested approach next weekend.&lt;/P&gt;&lt;P&gt;Thanks again&lt;/P&gt;&lt;P&gt;Giovanni&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Sep 2010 17:04:25 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151103#M8171</guid>
      <dc:creator>Giox79</dc:creator>
      <dc:date>2010-09-30T17:04:25Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151104#M8172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It was meant that you can concatenate two S-records files like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;copy file1.s19 + file2.s19&amp;nbsp; file1_plus_file2.s19&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But S9 records are usually found at the end of S-records file and some bootloaders or flash burners may assume S9-record is the sign&amp;nbsp;of the end of your S-records file, and will ignore S-records from 2nd file, because they come after S9-record. To solve this you should remove S9 record from the end of file1&amp;nbsp;or from the middle of concatenated file.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Sep 2010 18:01:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151104#M8172</guid>
      <dc:creator>kef</dc:creator>
      <dc:date>2010-09-30T18:01:43Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151105#M8173</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, finally I understood.&lt;/P&gt;&lt;P&gt;Thank you for your help.&lt;/P&gt;&lt;P&gt;May be it was a stupid question, but this is my first project.&lt;/P&gt;&lt;P&gt;Thanks again for this very useful forum.&lt;/P&gt;&lt;P&gt;Giovanni&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Sep 2010 18:48:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151105#M8173</guid>
      <dc:creator>Giox79</dc:creator>
      <dc:date>2010-09-30T18:48:15Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151106#M8174</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm looking in my s19/mot file (also tried the raw), and can't find where my data is located. What am I missing? If I initialize a static int array with some pattern of bytes, why can't I find that data somewhere in the flash file? I "read back" the contents of the entire chip with j-flash, and can't tell where anything is located. Many thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Feb 2013 19:33:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151106#M8174</guid>
      <dc:creator>admin</dc:creator>
      <dc:date>2013-02-08T19:33:35Z</dc:date>
    </item>
    <item>
      <title>Re: About storing initialization information on HCS08 device</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151107#M8175</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are initializing a static array within your code, the data will actually be located in RAM, starting at a specific address.&amp;nbsp; If you are using CW, the location of the data may be identified from the .MAP file generated by the CW compile/link process.&amp;nbsp; I suspect there may be some misunderstanding about the use of the 'static' modifier.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you require that the data array should be located within flash, you would initialize a constant array, using the 'const' modifier.&amp;nbsp; You should then observe, within the .MAP file, the flash address at which the array commences.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Mac&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Feb 2013 04:12:21 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/About-storing-initialization-information-on-HCS08-device/m-p/151107#M8175</guid>
      <dc:creator>bigmac</dc:creator>
      <dc:date>2013-02-11T04:12:21Z</dc:date>
    </item>
  </channel>
</rss>

