HP Forums
Sea stack - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: General Forum (/forum-4.html)
+--- Thread: Sea stack (/thread-5066.html)

Pages: 1 2


Sea stack - ggauny@live.fr - 11-02-2015 08:56 PM

Hi,

Sometimes it is convenient to see what it is into stack, when no printer, to better programing.

Here is a little routine that I use always on my HP41, with WP34s, I use Printer virtual.

From PPC and HP41 examples book.

Wink Gérard.


RE: Sea stack - Dieter - 11-03-2015 08:17 PM

(11-02-2015 08:56 PM)ggauny@live.fr Wrote:  Here is a little routine that I use always on my HP41, with WP34s, I use Printer virtual.

The 34s has a SHOW command (g EXIT).
Try it (use the up and down arrows) and see what you get. ;-)

Dieter


RE: Sea stack - 4ster - 11-07-2015 03:12 PM

Thanks for posting the nifty little program.


RE: Sea stack - Sylvain Cote - 11-07-2015 03:52 PM

Bonjour Gérard,
Merci pour ce petit programme.
J'aime particulièrement la ligne 18 qui permet au programme d'être très compact.
Cordialement,
Sylvain

----

Hello Gérard,
Thanks for this small program.
By removing the unnecessary RDN or RUP in the main body, step 18 make it very compact
Best regards,
Sylvain


RE: Sea stack - Thomas Klemm - 11-08-2015 12:32 AM

Loop-unrolling saves 3 bytes but makes it 2 lines longer:

Code:
 01 LBL "STKDISP"
 02 "L="
 03 ARCL L
 04 AVIEW
 05 PSE
 06 "X="
 07 ARCL X
 08 AVIEW
 09 PSE
 10 "Y="
 11 ARCL Y
 12 AVIEW
 13 PSE
 14 "Z="
 15 ARCL Z
 16 AVIEW
 17 PSE
 18 "T="
 19 ARCL T
 20 AVIEW
 21 END

Kind regards
Thomas


RE: Sea stack - Sylvain Cote - 11-08-2015 02:38 AM

(11-08-2015 12:32 AM)Thomas Klemm Wrote:  Loop-unrolling saves 3 bytes but makes it 2 lines longer:

Hello Thomas,
Actually, it is 4 bytes shorter and effectively 2 lines longer.
Kind regards,
Sylvain

Code:
 BB  LL  Thomas (48 Bytes)  BB  LL  Gérard (52 Bytes)
--------------------------- --------------------------- 
 11  01  LBL "STKDISP"      11  01  LBL "STKDISP"
 03  02  "L="               02  02  X<> L
 02  03  ARCL L             03  03  "L="
 01  04  AVIEW              03  04  XEQ 00
 01  05  PSE                01  05  RUP
 03  06  "X="               02  06  X<> L
 02  07  ARCL X             03  07  "X="
 01  08  AVIEW              03  08  XEQ 00
 01  09  PSE                03  09  "Y="
 03  10  "Y="               03  10  XEQ 00
 02  11  ARCL Y             03  11  "Z="
 01  12  AVIEW              03  12  XEQ 00
 01  13  PSE                03  13  "T="
 03  14  "Z="               01  14  LBL 00
 02  15  ARCL Z             02  15  ARCL X
 01  16  AVIEW              01  16  AVIEW
 01  17  PSE                01  17  PSE
 03  18  "T="               01  18  RDN
 02  19  ARCL T             03  19  END
 01  20  AVIEW              
 03  21  END



RE: Sea stack - Thomas Klemm - 11-08-2015 02:50 AM

(11-08-2015 02:38 AM)Sylvain Cote Wrote:  it is 4 bytes shorter

That's because I counted the bytes before removing the final PSE instruction. Thanks for the correction.

Cheers
Thomas


RE: Sea stack - ggauny@live.fr - 11-08-2015 11:02 AM

Hi all,

Thank's for optimizations !

Gérard.


RE: Sea stack - Dieter - 11-08-2015 12:57 PM

(11-08-2015 11:02 AM)ggauny@live.fr Wrote:  Thank's for optimizations !

Optimized? Here comes the definitely optimized version for the '41:

Code:
01 7PRSTK
02 VIEW L
03 END

OK, this requires a card reader... ;-)

Dieter


RE: Sea stack - Massimo Gnerucci - 11-08-2015 01:37 PM

(11-08-2015 12:57 PM)Dieter Wrote:  OK, this requires a card reader... ;-)

Dieter

Or, at least, its ROM.


RE: Sea stack - ggauny@live.fr - 11-09-2015 06:41 PM

Hi,

Code:

Or, at least, its ROM

Xrom 30.33 for emulator.

On real machine, without card reader, was....

Gérard.


RE: Sea stack - Massimo Gnerucci - 11-09-2015 07:16 PM

(11-09-2015 06:41 PM)ggauny@live.fr Wrote:  Hi,

Code:

Or, at least, its ROM

Xrom 30.33 for emulator.

On real machine, without card reader, was....

Gérard.

Yeah, you got it right (http://www.hpmuseum.org/software/xroms.htm).


RE: Sea stack - ggauny@live.fr - 11-10-2015 06:42 PM

Hi,

Thank but I have already two cards readers....

Gérard.


RE: Sea stack - Massimo Gnerucci - 11-10-2015 08:01 PM

(11-10-2015 06:42 PM)ggauny@live.fr Wrote:  Hi,

Thank but I have already two cards readers....

Gérard.

I don't even remember how many I have.


RE: Sea stack - ggauny@live.fr - 11-10-2015 10:28 PM

Hi,

How you don't remember of this ?

May I no good understand.

I tink when we have, we remember


RE: Sea stack - Massimo Gnerucci - 11-10-2015 10:32 PM

(11-10-2015 10:28 PM)ggauny@live.fr Wrote:  Hi,

How you don't remember of this ?

May I no good understand.

I tink when we have, we remember

When you got too many it is difficult to track everything.


RE: Sea stack - ggauny@live.fr - 11-10-2015 10:38 PM

I dont understand why you seem agressiv with me.
you have no understand my message.
surely I was not clear.
Yes i have two card reader for my 3 hp41( one C and two 41Cx)
It was ma passion expensive.
Really I dont understand your messages


RE: Sea stack - ggauny@live.fr - 11-10-2015 10:43 PM

Again in Piave ?


RE: Sea stack - Sylvain Cote - 11-11-2015 01:58 AM

Salut Gérard,

Je pense qu'il y a un problème de compréhensions entre vous et Massimo.

Voici ma compréhension de vos échanges ...

Vous: vous avez deux lecteurs de carte magnétique.
Massimo: moi, je ne me souviens plus de comment j'en possède.
Vous: Comment pouvez-vous ne pas vous souvenir de la quantité que vous avez ?
Vous: Je n'ai probablement pas compris votre intervention.
Vous: Normalement on devrait se souvenir de ce qu'on possède.
Massimo: Lorsque tu en possèdes beaucoup, il arrive d'en perdre le décompte.

Je ne pense pas que Massimo n'a été en aucun moment agressif dans ces échanges.

Cordialement,

Sylvain


RE: Sea stack - Massimo Gnerucci - 11-11-2015 06:34 AM

Thanks Sylvain, and sorry Gérard: I didn't mean to sound offensive nor aggressive.
Actually I, sometimes, find difficult to fully understand what you mean. My fault, of course.

Massimo