Shop OBEX P1 Docs P2 Docs Learn Events
Stamp and variables — Parallax Forums

Stamp and variables

ArchiverArchiver Posts: 46,084
edited 2003-02-05 21:30 in General Discussion
If a stamp looses power while running do the variables get lost? How
would one avoid this?

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2003-02-03 02:46
    Yes. You can prevent power-loss with battery supply (that would kick in when
    mains power is lost) or you can save important variables to EEPROM with WRITE
    (you can retrieve them with READ).

    Note: It is rarely necessary for a program to have to save ALL variables.

    -- Jon Williams
    -- Parallax

    In a message dated 2/2/2003 7:07:48 PM Central Standard Time,
    iphillips@s... writes:

    > If a stamp looses power while running do the variables get lost? How
    > would one avoid this?



    [noparse][[/noparse]Non-text portions of this message have been removed]
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-03 18:22
    iphillipsca wrote:

    > If a stamp looses power while running do the variables get lost? How
    > would one avoid this?


    You should write data that you wish to retain during power out
    periods to the eeprom rather than standard RAM variables. Data
    in the RAM area will be lost during power outages.

    --
    Our government it seems has got a new plan...
    Seize and search the private records of every man.
    No warrants, no judges, no due process required,
    With "Homeland Security" the 4th Amendment's retired.
    "Total Information Awareness" the project is called,
    Oh would our forefathers be aghast and appalled!

    http://geocities.com/totalinformationawareness/
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-03 22:01
    Is it accurate to say that you can't use write too often without wearing
    out the chip?

    On Sun, 2 Feb 2003, jonwms@a... wrote:

    > Yes. You can prevent power-loss with battery supply (that would kick in when
    > mains power is lost) or you can save important variables to EEPROM with WRITE
    > (you can retrieve them with READ).
    >
    > Note: It is rarely necessary for a program to have to save ALL variables.
    >
    > -- Jon Williams
    > -- Parallax
    >
    > In a message dated 2/2/2003 7:07:48 PM Central Standard Time,
    > iphillips@s... writes:
    >
    > > If a stamp looses power while running do the variables get lost? How
    > > would one avoid this?
    >
    >
    >
    > [noparse][[/noparse]Non-text portions of this message have been removed]
    >
    >
    > To UNSUBSCRIBE, just send mail to:
    > basicstamps-unsubscribe@yahoogroups.com
    > from the same email address that you subscribed. Text in the Subject and Body
    of the message will be ignored.
    >
    >
    > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
    >
    >
    >

    Sean T. Lamont, CTO / Chief NetNerd, Abstract Software, Inc. (ServNet)
    Seattle - Bellingham - Vancouver - Portland - Everett - Tacoma - Bremerton
    email: lamont@a... WWW: http://www.serv.net
    "Do not fear mistakes, There Are None" - Miles Davis
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-03 23:05
    You'll wear out yourself before you wear out the chip. That said, you should
    be clever in your design and not waste time resaving variables that haven't
    changed.

    -- Jon Williams
    -- Parallax

    In a message dated 2/3/2003 4:03:26 PM Central Standard Time,
    lamont@a... writes:

    > Is it accurate to say that you can't use write too often without wearing
    > out the chip?



    [noparse][[/noparse]Non-text portions of this message have been removed]
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-05 21:30
    Well, actually, the EEPROM only supports 10,000,000 writes to each 16-
    byte location for the BS2, less for BS2p. If you write once a
    second, you'll wear it out in 115 days. If you write 10 times a
    second, you'll wear it out in 11.5 days. You should keep this in
    mind when deciding what data is critical, and how often you want to
    write it.

    I want my hardware to be good for 5 years, so this can be an issue.
    And that little 2k or 4k eeprom looks hard to replace.


    --- In basicstamps@yahoogroups.com, jonwms@a... wrote:
    > You'll wear out yourself before you wear out the chip. That said,
    you should
    > be clever in your design and not waste time resaving variables that
    haven't
    > changed.
    >
    > -- Jon Williams
    > -- Parallax
    >
    > In a message dated 2/3/2003 4:03:26 PM Central Standard Time,
    > lamont@a... writes:
    >
    > > Is it accurate to say that you can't use write too often without
    wearing
    > > out the chip?
    >
    >
    >
    > [noparse][[/noparse]Non-text portions of this message have been removed]
Sign In or Register to comment.