Program stops prematurely
JoeA
Posts: 33
HELP!· I've posted this to the PEK Labs thread but haven't received an answer.
I·recently got the ·Propeller Education Kit, and have been working through the "I/O and Timing Basics" Lab.
My programs have suddenly begun stopping prematurely.
I had called tech support, and they said try the forums.
I had completed the 12/7/6 version of the lessons up to the repeat while ...AND... case (page 16 of 29 top, just before "Some other Vocabulary").
Then it would only count to 15 (not 20) and stop (all LEDS off.)
What I had been doing is, starting with the first loop example, I just added each new example to the program at the beginning, so all examples were in the same file.
Anyway, after the AND example failed, I went back to try simpler programs, and got premature termination on those also.
For example, even the simple setup program: [noparse][[/noparse]edited 8/2/2007]
will turn on the LED but it goes back off in a few seconds or fraction of second.
(The actual time seems to vary from run to run).·
Sometimes·a program·will appear to work for the first few programs tried after being off a while, but eventually reverts to the early termination behavior.
I had rearragned some LEDs and circuit wires occasionally during the exercises,
but I've been over the board and it seems to be correctly wired.
I've tried disconnecting and reconnecting the board, and reloading the DoNothing program before trying again.· It also doesn't seem to matter whether I load the program to RAM or EEPROM; I get the same early temination (sometimes followed by restart (?) and repetition).
Is there a simple way to test the chips for damage? As you see, even the "pin test" program behaves erratically. (I don't have an oscilliscope or any test equipment beyond a VOM).
JoeA
I·recently got the ·Propeller Education Kit, and have been working through the "I/O and Timing Basics" Lab.
My programs have suddenly begun stopping prematurely.
I had called tech support, and they said try the forums.
I had completed the 12/7/6 version of the lessons up to the repeat while ...AND... case (page 16 of 29 top, just before "Some other Vocabulary").
Then it would only count to 15 (not 20) and stop (all LEDS off.)
What I had been doing is, starting with the first loop example, I just added each new example to the program at the beginning, so all examples were in the same file.
Anyway, after the AND example failed, I went back to try simpler programs, and got premature termination on those also.
For example, even the simple setup program: [noparse][[/noparse]edited 8/2/2007]
PUB LedOn ' Method declaration dira[noparse][[/noparse]4] := 1 ' Set P4 to output outa[noparse][[/noparse]4] := 1 ' Set P4 high repeat ' Endless loop prevents program from ending
will turn on the LED but it goes back off in a few seconds or fraction of second.
(The actual time seems to vary from run to run).·
Sometimes·a program·will appear to work for the first few programs tried after being off a while, but eventually reverts to the early termination behavior.
I had rearragned some LEDs and circuit wires occasionally during the exercises,
but I've been over the board and it seems to be correctly wired.
I've tried disconnecting and reconnecting the board, and reloading the DoNothing program before trying again.· It also doesn't seem to matter whether I load the program to RAM or EEPROM; I get the same early temination (sometimes followed by restart (?) and repetition).
Is there a simple way to test the chips for damage? As you see, even the "pin test" program behaves erratically. (I don't have an oscilliscope or any test equipment beyond a VOM).
JoeA
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Parallax Forums - If you're ready to learn, we're ready to help.
The restart behavior does indicate a potentially low battery.
Assuming the battery is new but the problem persists, you can use your voltmeter to measure the voltage at the Propeller chip's GND and 3.3 V terminals. Does it remain stable at 3.3 V when the reset occurs?
Andy
P.S. Please email me using the email icon to the left of this post so we can schedule a telephone trouble shooting session.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Andy Lindsay
Education Department
Parallax, Inc.
Post Edited (Andy Lindsay (Parallax)) : 8/8/2007 6:18:42 AM GMT
When connecting the VOM with the old battery, I did notice a slight dip in voltage when all the LEDs came on at once. Come to think of it, that was a consistent symptom of "failure"--it would work with just a couple leds on but once a larger number were on, it would halt. I suppose leaving a single led on a longer time had a similar effect.
As a programmer, I'm used to debugging software, but hardware glitches are a new experience for me!
Thanks,
JoeA
Shining an LED will need an extra of 20 mA and an outworn battery cannot deliver so much current. Even new batteries sometimes can't; especially 9 V batteries are not the best power supply for a Prop board.
Accumulators are MUCH better with respect to current! There are a lot of ready made "packs" on the market, used for model cars (sometimes called "racing packs", 7,2 V). They are not exactly cheap, but very powerful.
What are you refering to when you say accumulator? This is just another word for battery as far as I am aware.
Graham
Accumulator is another term for rechargable battery.
I am not so aware of the price level in the U.S.... In Europe "rechargeable batteries" - even "clean" ones (NiMH) - have dropped considerably in price; and recharging stations are also low priced.
There are essential differences between rechargeables and non-rechargeable batteries wrt to the max. current they deliver and the decay of voltage during discharge.
A "wall wart" is fine, though I prefer portability and rippleless supply voltage.