HP Forums

Full Version: Custom RPN Calculator for Prime
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Like many, I struggled making the Prime my regular calculator for every day use and the point of this thread is not to revisit all the reasons but rather to present my effort to do something about it. With the latest implementation I feel like I could use this full-time now.

Today I submitted an update to a previous version I had submitted to hpcalc.org and should be available on that site once it is updated. I have also attached the file to this post.

I don't think my implementation will be something that will work for everybody but curious to get some feedback, good or bad.

What this app can do:
- Store variables to HVars and have them show up in the menu where they can be recalled, overwritten or purged
- Assign units to values and then convert to another unit with a single touch event.
- Manipulate the stack with key shortcuts and menus like many of us are used to from 50g
- Undo last action

Shortcomings of the app:
- Unfortunately the Prime does not go to sleep when an app is running, so user must exit app to prevent battery drain or have calculator plugged in while in use
- Limited unit supported, this was created for what I typically use the calculator for and thus includes angle, distance, area and volume units. The system could be expanded to other units but not sure how well it would scale with all the available units.
- No support for lists, vectors, etc. This is a pure number cruncher and not a full replacement of a fully developed RPN/RPL calculator.

The source code is included as a TXT file for anyone interested.

Jacob
Phenomenal!

Any plans to implement a feature where result can be displayed as feet-inches-fractions of inches?
(06-10-2019 01:46 AM)Jacob Wall Wrote: [ -> ]Shortcomings of the app:
- Unfortunately the Prime does not go to sleep when an app is running, so user must exit app to prevent battery drain or have calculator plugged in while in use

I had the same problem with a program that displayed user tabs using a forever loop and WAIT(-1) command. If I left the program running, it would drain my calculator's battery, even if the screen was in low power mode. I installed a loop counter that counted the number of times the WAIT(-1) loop cycled. If no key or tab was pressed after 5 minutes, the program would exit the loops, go to the end of program, and then exit to the home screen. After 5 minutes in the Home screen, the calculator would naturally turn off. An example of the loop counter is shown in this post. https://www.hpmuseum.org/forum/thread-12...#pid115217
Quote:Any plans to implement a feature where result can be displayed as feet-inches-fractions of inches?

Already in place, the included PDF talks a bit about feet and inches. In general:
- Feet and inches are entered comma-delimited as feet,inches,fractions (for example 10,6,1/4 is 10'-6 1/4") and the input parser will assign the current distance unit to the final result. This means if your distance unit is set to metres, the conversion happens automatically. You can even enter something like 0,313 and the final result will be represented in the current distance unit (equal to 313 inches)
- There is a setting to display feet as decimal or fractional, this applies to all feet distances

I realize now that the settings can only be accessed while the app is not running, I'll make it easier to access the settings while calculator is running, with same keys Shift+Num.
(06-14-2019 11:33 PM)Gene222 Wrote: [ -> ]I had the same problem with a program that displayed user tabs using a forever loop and WAIT(-1) command. If I left the program running, it would drain my calculator's battery, even if the screen was in low power mode. I installed a loop counter that counted the number of times the WAIT(-1) loop cycled. If no key or tab was pressed after 5 minutes, the program would exit the loops, go to the end of program, and then exit to the home screen. After 5 minutes in the Home screen, the calculator would naturally turn off. An example of the loop counter is shown in this post. https://www.hpmuseum.org/forum/thread-12...#pid115217

I like that idea, it is a very practical way of dealing with it. Thanks!
(06-15-2019 12:53 AM)Jacob Wall Wrote: [ -> ]
(06-14-2019 11:33 PM)Gene222 Wrote: [ -> ]I had the same problem with a program that displayed user tabs using a forever loop and WAIT(-1) command. If I left the program running, it would drain my calculator's battery, even if the screen was in low power mode. I installed a loop counter that counted the number of times the WAIT(-1) loop cycled. If no key or tab was pressed after 5 minutes, the program would exit the loops, go to the end of program, and then exit to the home screen. After 5 minutes in the Home screen, the calculator would naturally turn off. An example of the loop counter is shown in this post. https://www.hpmuseum.org/forum/thread-12...#pid115217

I like that idea, it is a very practical way of dealing with it. Thanks!

Just to add to this: you might even want to have a user-defined variable that allows users to set their own time-out with a default of, say, 5 minutes.
(06-15-2019 03:56 PM)Han Wrote: [ -> ]Just to add to this: you might even want to have a user-defined variable that allows users to set their own time-out with a default of, say, 5 minutes.

Absolutely, I will post an updated version with the improvements soon.
Updated version attached.
- Added ability to access settings and Info screen while calculator is running
- Added setting for auto exit, app will close after specified time
- Minor optimizations
- Updated PDF, including some corrections
Reference URL's