A few simple HP 35s programs - Printable Version +- HP Forums (https://archived.hpcalc.org/museumforum) +-- Forum: HP Museum Forums (https://archived.hpcalc.org/museumforum/forum-1.html) +--- Forum: Old HP Forum Archives (https://archived.hpcalc.org/museumforum/forum-2.html) +--- Thread: A few simple HP 35s programs (/thread-187141.html) |
A few simple HP 35s programs - Lode - 07-03-2011 Hi, I made a few simple programs for the HP 35s which make it a little bit better imho :) I tried to let each one keep as much of the original stack as possible intact, this didn't succeed for every function however. There are: extract im/re, ->R, ->P, lambertw, complex loggamma, complex conjugate, complex asin/acos/atan and complex sqrt. They're almost all located on or near a key where either a function is similar, or the letter is a good mnemonic. The polar/rect and lambertw ones were inspired by posts from here but made simpler. What do you think of the programs? Got any tips to improve them? Are there any HP-35s related resources for other useful programs or programming tips and techniques? I found the Matrix Multitool which is very nice, but for the rest I only find surveying related programs... Any ideas for *games* that can be programmed on a device like this? Thanks!
//Get re in x and im in y. Located on the imaginary number key. Re: A few simple HP 35s programs - Paul Dale - 07-04-2011 I wrote a game for the 35s which still hasn't made it into the software library but is available as an article and buried in the archives. Also, we did a group effort on R->P and P->R functions, again available as an article. These behave the same as internal commands with respects to stack operations, LastX etc.
Re: A few simple HP 35s programs - Lode - 07-04-2011 Why is there so much flag 10 logic in these R/P examples? If it's to clear it for the equation, isn't just a single "CF 10" enough? If it's to keep the original state of flag 10: is that really so important to be worth so much extra lines (not to me)? If a program wants to display a message it will set the flag anyway...
The game looks cool! It's going to be a LOT of work to type it over though! I wish there existed a way to automate this inputting. When typing over the "Matrix Multitool", there was one big problem I had: since the calculator updates line numbers automatically when inserting lines, it sometimes messes with line numbers if you need to correct a mistake on an earlier line. It was hell. When I typed that matrix program, I had already added the "RTN" at the end while still typing all previous lines. It had changed almost all GTO's and XEQ's that pointed to the future, into line number 442. When going back to correct each of those, due to deleting and readding the GTO line, some others got messed up as well, etc... Any tips on efficiently entering a long program and not letting it mess up line numbers?
Re: A few simple HP 35s programs - Paul Dale - 07-04-2011 Quote: The logic is there so they act exactly like internal commands -- don't care about the state of the device on entry and don't change the state of the device on exit. Equations don't work if flag 10 is set so that has to be cleared and restored.
Quote:
A nice simple solution is to remove the bits you don't want.
Quote: And if the program neglects to clear this flag afterwards? What about a program that sets it to display messages and then does a rectangular polar conversion. These commands are designed to work regardless. Still, take out the bits you don't want or do your own.
Quote: Nope, it is just painful. When developing the game, I retyped it when substantial changes were made to avoid these issues.
|