<?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のトピックStoring User Input</title>
    <link>https://community.nxp.com/t5/8-bit-Microcontrollers/Storing-User-Input/m-p/168752#M11093</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, I'm using an HCS08LG32 with an external display and keypad.&amp;nbsp; I'm looking for a method to accept user preferences, to be used later after power is recycled.&amp;nbsp; For example, when displaying a temperature, the user can input whether&amp;nbsp;the default is&amp;nbsp;Celcius or Fahrenheit.&amp;nbsp; All subsequent uses of the board will then default to the user preference.&amp;nbsp; I would also like to store user inputted programs (a series of keystrokes stored in an array), to be recalled for later user over the life of the product.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; I am also using an RTC and want to store the number of hours the uP is in use (when powered&amp;nbsp;with the RTC running) over multiple uses (powered on/off over a period of months).&lt;/P&gt;&lt;P&gt;Any suggestions ?&amp;nbsp;&amp;nbsp;&amp;nbsp; Do I need to use an external Flash/EEPROM ?&lt;/P&gt;&lt;P&gt;BTW.&amp;nbsp; I am coding in C.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 20 Jan 2010 06:58:33 GMT</pubDate>
    <dc:creator>Thunder</dc:creator>
    <dc:date>2010-01-20T06:58:33Z</dc:date>
    <item>
      <title>Storing User Input</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/Storing-User-Input/m-p/168752#M11093</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, I'm using an HCS08LG32 with an external display and keypad.&amp;nbsp; I'm looking for a method to accept user preferences, to be used later after power is recycled.&amp;nbsp; For example, when displaying a temperature, the user can input whether&amp;nbsp;the default is&amp;nbsp;Celcius or Fahrenheit.&amp;nbsp; All subsequent uses of the board will then default to the user preference.&amp;nbsp; I would also like to store user inputted programs (a series of keystrokes stored in an array), to be recalled for later user over the life of the product.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; I am also using an RTC and want to store the number of hours the uP is in use (when powered&amp;nbsp;with the RTC running) over multiple uses (powered on/off over a period of months).&lt;/P&gt;&lt;P&gt;Any suggestions ?&amp;nbsp;&amp;nbsp;&amp;nbsp; Do I need to use an external Flash/EEPROM ?&lt;/P&gt;&lt;P&gt;BTW.&amp;nbsp; I am coding in C.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Jan 2010 06:58:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/Storing-User-Input/m-p/168752#M11093</guid>
      <dc:creator>Thunder</dc:creator>
      <dc:date>2010-01-20T06:58:33Z</dc:date>
    </item>
    <item>
      <title>Re: Storing User Input</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/Storing-User-Input/m-p/168753#M11094</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I suspect that it should be feasible to utilise a block of flash memory for the purpose of non-volatile storage for your project.&amp;nbsp; The task will be simpler if the total number of bytes required for all parameters does not exceed a single flash page (512 bytes), and you maintain an image of the parameters in RAM.&amp;nbsp; The lowest available flash page should be used so that flash block protection can be implemented, to protect your program code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A possible strategy is to "pre-erase" the flash page at the start of normal operation, and to program the RAM image to flash just prior to loss of power.&amp;nbsp; For this you will need early warning of power loss so there is sufficient time to complete the programming.&amp;nbsp; This approach should minimize the amount of re-programming, and the "wear out" of the flash.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you have some parameters that frequently change (such as the RTC data), and others that will rarely change, a variation of the above might be to update the infrequently changing parameters as each change occurs, and the others upon loss of power.&amp;nbsp; This will potentially reduce the amount of time required at power loss, but would require two different flash pages.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The erase and programming of the flash page(s) will require use of a small RAM based function when the flash array is inaccessible during the write process.&amp;nbsp; This issue has already been covered by many other threads within this forum.&amp;nbsp; Two different approaches are possible - the use of a fixed block of RAM, or the use of the stack.&amp;nbsp; The first approach is probably a little simpler.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Mac&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Jan 2010 11:20:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/Storing-User-Input/m-p/168753#M11094</guid>
      <dc:creator>bigmac</dc:creator>
      <dc:date>2010-01-20T11:20:53Z</dc:date>
    </item>
  </channel>
</rss>

