HP Forums
power off and app restart - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: HP Prime (/forum-5.html)
+--- Thread: power off and app restart (/thread-5266.html)



power off and app restart - ji3m - 12-03-2015 10:29 PM

If I switch away from my app to another app and then switch back my app start function is called and I restart ok.

However, if I power off while in my app and then power on the prime does restart my app (at leadt the start function is called) but the app data is corrupted. So just what is saved on a power off?

Also, if I switch to another app, power off, power on, then switch to my app it restarts just fine.

Seems like the running app is messed up by a power off.


RE: power off and app restart - Tim Wessman - 12-03-2015 11:48 PM

When a power off happens, the application does not resume when it was when interrupted, rather it receives a message to exit and close. When you power down, any running user program will exit all the way out. Currently, there is no way to automatically "resume" or restart a program on power up.


RE: power off and app restart - ji3m - 12-04-2015 03:14 PM

I understand. However, after a power up it show the last active app as the selected one at the top of screen.

It just doesnt restart the app, i guess.


RE: power off and app restart - Han - 12-04-2015 05:27 PM

(12-03-2015 10:29 PM)ji3m Wrote:  If I switch away from my app to another app and then switch back my app start function is called and I restart ok.

However, if I power off while in my app and then power on the prime does restart my app (at leadt the start function is called) but the app data is corrupted. So just what is saved on a power off?

Also, if I switch to another app, power off, power on, then switch to my app it restarts just fine.

Seems like the running app is messed up by a power off.

Corrupted in what sense -- garbage data? or simply instances of values being changed?


RE: power off and app restart - ji3m - 12-05-2015 05:21 AM

Not really corrupted. Just not initialized.

Even though a power on shows that my app is the current one the START function was not called. The app must be restarted manually in such a case.

Fooled me, that's all. Expectations.

My problem is that the other hp calculators remembered everything unless you pulled the batteries for more than 10 seconds.


RE: power off and app restart - Han - 12-05-2015 08:03 AM

The START() function of an app is called only when switching to that app. Once you've already switched to the app, I don't think START() is ever called again. Powering on the calculator does not restart the app if you're already "in" the app. It simply ensures that all running subroutines are exited (i.e. you're back at the home/cas screen, or one of its default screens like a plot view) and then powers off. You're still "in" the app, though.