Page 1 of 1

Reading state of RSTi (RESET)?

Posted: Tue Jul 17, 2012 7:00 pm
by sblair
Is it possible to read the current state of the RSTi (aka RESET) pin on a Mod5270?

From digging through the Freescale 5270 manual, I see that I can read the Reset Status Register (RSR) and see whether the last reset event was caused by the RSTi pin or not, but I actually need to read the current value of that pin AFTER the reset has occurred.

I'm trying to emulate the classic reset button on the back of a Wifi Router where a short push does a normal reset and holding it down for 5 seconds causes it to reset all defaults.

I'm basically looking for a way to be able to read that pin after starting up to know if it is still being held down or not.

Any suggestions?

Thanks.
Scott

Re: Reading state of RSTi (RESET)?

Posted: Tue Jul 17, 2012 8:31 pm
by pbreed
As long as RSTI is low you will not have any code running.
Hard to read a value if your CPU is halted.

The right way to do this is with a Cap coupled reset circuit and a separate sense line.

Re: Reading state of RSTi (RESET)?

Posted: Tue Jul 17, 2012 8:50 pm
by sblair
Thanks Paul that's what I was afraid of. We do indeed have the reset switch on a cap-coupled line. If I hold the switch down it does a reset, but then will startup and run code normally. My HW guy swore I should be able to read the state of the switch after the reset.

I grilled him on it at the time as I was concerned about this.

I just went back and looked at his schematic closer and I can see there is a tag with it also going off to J2-35. So I guess maybe he did go off and research it after I expressed concern and connected it to a GPIO also exactly as you suggested. He just never told me.

Thanks.
Scott