HP65 Flags

The HP-65 calculator has two flags and you can set, clear or test these in your programs. They allow you to remember choices or situations for later. Something happens. You use f SF 1 (or f SF 2) to remember it, and later you use f TF 1 (or f TF 2) to choose between two different courses of action.

Where are the flags stored? How does it do all that?

The flags are stored in bits of the FS register.
Flag 1 is FS[4].
Flag 2 is FS[6].

You can see this by checking (menu), Advanced, View State. If you use “f SF 1” FS=….4… appears. If you use “f-1 SF 1” (i.e. clear flag 1) the “.4.” bit disappears.

The same occurs for Flag 2 and FS=……6.

It's only fair to share...Share on FacebookTweet about this on TwitterShare on Google+Share on LinkedInShare on StumbleUponDigg thisPin on PinterestEmail this to someone

Leave a Reply

Your email address will not be published. Required fields are marked *