Shop OBEX P1 Docs P2 Docs Learn Events
Shut down problem — Parallax Forums

Shut down problem

slotcarzslotcarz Posts: 30
edited 2005-05-08 16:23 in BASIC Stamp
I am running into a problem with my BS2. I can write code to it and run the function but if I shut power off to it, the program goes haywire and won't read the code properly unless I re-program it. It this common? Just wondered if there was a cure for this..
thanks..
Jeff

Comments

  • CPUMANCPUMAN Posts: 55
    edited 2005-05-07 17:08
    That shouldn't happen.· The stamp uses EEPROM to store the program so power loss shouldn't affect the stamp.

    As for how to fix it I have no clue, I've never seen a stamp do that.· Is there any other details you could give about what you do when you power down your stamp?

    Chris
  • slotcarzslotcarz Posts: 30
    edited 2005-05-07 17:27
    Basically I have been in "testing" and lets say I am finished for the evening and just turn the power switch off. I get back to business with it and turn it on and what I have program in to it is lost. I hope I haven't done anything to harm the BS2. I purchased a 9v 500 MA power supply to run it and everythng seems to run fine except for the data loss on power down.


    Jeff
  • kb2hapkb2hap Posts: 218
    edited 2005-05-07 20:12
    How exactly do you know its lost? what is it suppose to do that its not doing?

    Did you try doing a reset after powering up?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    DTQ
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-05-07 20:22
    Are you use WRITE?· Perhaps your program is corrupting the EEPROM where the program tokens reside.· To answer your question, No, this is not normal -- the cure is correcting your programming error (posting your code will let others analyze it and give you better guidance).
    slotcarz said...
    I am running into a problem with my BS2. I can write code to it and run the function but if I shut power off to it, the program goes haywire and won't read the code properly unless I re-program it. It this common? Just wondered if there was a cure for this..
    thanks..
    Jeff
    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
    Dallas, TX· USA
  • slotcarzslotcarz Posts: 30
    edited 2005-05-07 22:20
    I am programming my Led's to scroll letters. After the code is programmed in it, only a segment of led's light up after the power is shut down and restarted. I use the reset button but it doesn't help.

    I do not have a WRITE command in the code but I am trying to figure out why it won't hold the programming. I am putting this sign I have made into my slot machine for a display and don't want to worry about having to reset every time. that would be a drag.

    I am using your tutorial code Jon as a guide and when try to use mine I get a bunch of scrambled LEDs. Just pushing forward to get it right...
    thanks for the replies

    Jeff
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-05-08 00:11
    We can be of little help without seeing your code ... all we can do is guess.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
    Dallas, TX· USA
  • KenMKenM Posts: 657
    edited 2005-05-08 00:21
    Does your program work correctly before it is powered down the first time?
  • allanlane5allanlane5 Posts: 3,815
    edited 2005-05-08 00:30
    1. Some computers hold the BS2 in reset, unless you use at least one DEBUG statement.

    2. Power problems can give these symptoms. The fact that "Reset" does nothing makes this more likely.

    3. I don't think a 500 mA power supply is good enough for all those LED's -- but since the 7819 'strobes' the LED's, perhaps it is.

    4. It IS possible to 'wear out' the EEPROM by using 'WRITE' statements under program control -- but this would cause a verify failure, not the symptom you are describing.

    5.· Are you using the EEPROM to store some of the data?· It is also possible to over-write your program tokens, and not realize you've done it (unlikely, but possible).
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-05-08 04:33
    Does this still happen if you unplug the serial cable?



    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Philip GamblinPhilip Gamblin Posts: 202
    edited 2005-05-08 05:13
    Almost sounds like the supply is cratering under load. Don't forget theat wall warts are notorious for poor regulation and may have significantly
    higher output under less than rated load.
  • slotcarzslotcarz Posts: 30
    edited 2005-05-08 15:16
    Thanks everyone. Chris it was that.
    Now I have to get the chips to flow the scroll instead of each having its own display scrolling each character. Did that make sense?

    ok cya
    Jeff
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-05-08 16:23
    Jeff,

    ·· I thought that might be it.· Glad you got it figured out.· Some computers have issues with taking over the COM Port when it's idle.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
Sign In or Register to comment.