p. 45


Since the discovery of the registers of abnormal state and instructions.à postfixes at the end of 79, very many applications were used. The best application is the module created by club PPC and called PPC ROM. This module contains, among many progranmee of general interest a certain number of small progrannes using much synthetic programming, as one calls this special type of prograrnation. These progroemnes is perfectible but brings to the programmer best obvious, believe me, publicity that I faie with PPC ROM is free! It is available for all, even not members of the club, but at a price of approximately 1000F which east cannot be not accessible to all.

But PPC ROM is not essential, fortunately! A very convenient method was found.


Follow to the letter the instructions below (a very naked HP-4Ç is not only usable but desirable, however a card reader is welcome).

This procedure functions with all the machines. Certain accessories can sometimes disturb operation, therefore take a naked machine to start (HP 4Ç or CV). The numbers of registers indicated are those obtained starting from a standard 4Ç; with one CV or one CX these digits are different (no importance).

To make to see
1) MEMORY LOST (while making, starting from an extinct machine, ONE maintaining some < - inserted) MEMORY LOST
2) Assign + with key LN ASN. + 15
3) Assign LED with the key LOG ASN LED 14
4) place of mode TO WEAR 0.0000
5) place of mode programs itself and make what follows 00 REG 45

p. 46

b) SHIFT CAT 1 and immediately R/S LBL"T
c) LOG A LED 001



d) BST


4093 DEC


05 LBL 03

F) LOG C LED 003

04 STO 01


(note: do not go apparently on my CX #2352S41976 - note of Oct. 17, 1998 - functioning without problem on a 4Ç #2144S11951 - if as well is as these numbers, raised on the back case, have anything to see with the mother board!)

On one CX or if you left the module X-Functions, the null ones can be replaced by different thing, it does not matter. Leave the mode programs, make GTO.., it is finished.

Before continuing, if you have a card reader, record a card of state WSTS) on its two tracks.


has, B, C exploits a characteristic of machine called " BUG 9 " by the PPC Club and already described besides in a hardly different form in France (JACK).

**time-out** the number of line 4094 which appear fugitively then the number 4093 preceding DEC have not some significance, except Celt to you show that you be now with lower part of END., in fact in the register R(0C0), first register of assignement (see for more some detail with end of chapter, p. 50).

Remade operations of 1 with 5d, then, instead of making E) GTO.005, made several BST (be patient). You see:

program code
4086 " F0
4087 LBL 03 04
4088 LBL 01 02 équivallent of LED
4089 STO 01 31 code touches LOG
4090 LBL 03 04
4091 + 40 function +
4092 - 41 code touches LN
here 176 empty registers, or modulates it X-F
4093 DEC here are the registers of state...

When you make GTO.005, the HP resaisit a little and takes again a " normal " account of the lines starting from F0, the 05 LBL 03 which appears is thus that which precedes it +.

LED 003 thus erases LBL 03, + and -, leaving three null.

When you introduce the character strings, it covers the null ones: the first byte is Fn where N will vary from 1 to 7 progressively

p. 47

Fig. the 13 operation of revealed the Grabber Byte

To make, after a MEMORY LOST, GTO.. and enter programs you according to: O1 ENTER†; 02 ENTER†; 03 ENTER†; 04 ENTER†; 05 ENTER†; 06 ENTER†; 07 ENTER†(7 times ENTER†); 08 " ABCDEFGHIJ " (F followed by 10 characters = 11 characters).

By taking account of the 3 bytes of the END. you thus filled 7+11+3=21 bytes = 3 registers, a XEQ " PACK " to you will ensure it. Place you on your line 07 ENTER†and erase 3 lines you see:

04 ENTER† BG, you see then
05 --ÅÅABCD  

What does it occur? When you want to introduce a function in memory, the 4Ç knows (believes it!) that this function occupies with more the 3 bytes (there is a function of 3 bytes which can be assigned, it is a your function END; in fact only the byte C0 appears in the register of assignement, but the following bytes are built at the time of the introduction of the function in memory). If there is not enough place available to introduce the desired function, the 4Ç releases a whole register, therefore 7 bytes, which appears to him more than sufficient to place an instruction which can make only 3 of them.

But the Grabber Byte has two characteristics: it is related to three bytes (let us not forget that the Grabber Byte is a function which recopies in memory the 3 bytes contained in the register of assignement corresponding) and the first byte which it places in memory is a byte F7; two following bytes being variable according to BG'S used. The BG in memory is thus chains of 7 characters of which only the 2 first (and prefixes it) are provided; your 5 following is then taken among the close bytes in the report programs. Let us examine the various cases according to the situation preceding the execution by the BG.

L) no byte is free. Lhas HP releases 1 register and place F7 on the left of this register. The chains displayed includes/understands F7, the two following bytes of the BG, the 4 null remainder of the register, and 1 byte of the following register, the stolen byte. It is the usual case of use.

2) Only one byte is free. LE F7 is placed there, the HP releases a register for the two following bytes of the BG. The chains then covers these two bytes and your 5 null remainders with the released register; nothing is stolen but all the null bytes were covered and one finds oneself in the case numéro1.

3) 2 bytes are free. LE F7 is placed there, as well as the 2nd byte of the BG; the HP releases a register for the íéme byte of the BG; the chains does not cover whereas 6 bytes with this register, leaving no one, which brings back for us to the case of figure number 2.

4) 3 bytes are free. That is enough for the Grabber Byte, from the blow no register is released and the BG votes 5 characters. It is the case tested above. If one increases the number of null (unobtrusive†ENTER), one can thus choose between 0 and 5 the number of stolen natures.

p 48

introduction your letters, then?, byte 3f, then A, byte 41 (hold, the same code as -!) and the three null ones are covered. But you are on the right of R(0C0) it does not have nothing there below, the following letters thus fall into the vacuum and cannot be recorded. However, N of Fn increases well each time of a unit, and the display shows like null (-----) the part of " vacuum " included in the chains. If module X-F is present or if you have one Cx, there are here the registers of this module and their contents, in the place of the vacuum (attention, these contents will be modified).

You finish with chains of 7 characters (?, A and 5 null) whose first character is? and the second A. This A is included/understood by the machine as codes of key. Test another key: Does TAN have as a code from assignement 42, as the letter B Essayez? and 6 times B.

How, that does not go! Did you reflect? and yes, it is now the TAN key which it is necessary to assign with step 2.

Let us return to the first example (for example by reading the card recorded presently): You must now: to see when you press key LN in mode calculation-to use:

XROM 28,63

It is one of the multiple BG (Byte grabber = vole:ur you bytes) possible.

What makes the BG? Initially it is mainly useful in mode programs, and does not have to in no case to be used before a END or in a report programs vacuum (be wary, it is currently the case).

The BG creates in report programs a line of text of 7 characters. To be able to set up it, the HP releases a register of 7 bytes. But it forgets that in front of the chains there is F7 which occupies a byte and which thus this chains of 7 bytes in request makes 8 in memory. We thus created chains:

F7 00 3F 00 00 00 00

that is to say 7 bytes, but the HP wants with any force to find the 7éme character which it misses, and it annexes purely and simply the first byte, no one or not no one which comes (for the details, to see fig. 13, p. 17).

Example, type:

0l LBL"T

02 +

03 +

04 +

then made GTO.00l and BG (support on LN in use-program mode) you see: 02 "-?----@; on the right you have the caractére which has code 40, the same code as +, which stolen and was introduced into the chain.


Erase this Line and type:


make BST and BG it remains:


02 "?" = "-?----Å < - F7 of chains

03 -

04 *

05 /

06 X<Y?

07 X>Y?

08 X<=Y?

09 S+

10 +

11 +

12 END.

From which do these lines come from program? It is simply, as you can see it on the table of the codes, the instructions which have the same code as the letters entered previously. It is the masking of F7 of beginning of chains by the BG which prevents the HP from knowing that they are letters. You can SST or BST in this " program " without concern. Again make GTO.001, BG you see:

0lLBL " ' T " "

02 "?"

03 STO 15


What did it occur? the new BG stole F7 of the first BG, it is the stolen robber! The null ones are not seen, STO 15 has the same code as? F7 of the chains is released and the chains takes again its normal existence. You can erase Lines 2 and 3, packer and you returned at the beginning. We will appelerons this operation " to remove the Made BG ". it, and see the use of this new function.

With new BG, you find the provision of the first figure. Erase the line 06 X<Y? and replace to it by LBL 00 then GTO.001 and remove the BG. You see:


You replaced D, in the line of text by a symbol called " the complete man ". If you are mistaken in the course of operation, make simply PACK. Have fun to test other characters.

To introduce no one : Null the possibly necessary ones must be introduced in the last, because there is not any more the right to make PACK, therefore more the right to be mistaken. On the basis of the situation above, let us make GTO.001, BG.

Note: if, after a BG there is no character on the right chain, it is that there were null bytes which trainaient, do not make any you, make simply BG several times and leave cleaning for later. In this case, it can occur that the BG steals more than one byte.

p. 50

if that you gene, remove the BG in too much in the way usual and made PACK before starting again, if not, continue as if nothing were not. Erase LBL 00 and, without making PACK, BST to the line which contains the beginning of your character strings remove the BG, see:


Wouldn't a little household and a PACK make evil, not?

Note: before the execution of the BG, you must see with the screen the line which precedes the instruction that you want to steal. These complex explanations can paraitre, but with use they prove so convenient that I always have a BG assigned with a key of my 4Ç (note of the 4th edition: I now replaced the BG by a function microcodes, LOAD (cf p. 97), which places directly in report programs instructions starting from their decimal codes, a version very improved of LB (this being right to make you salivate!).

4094 : you undoubtedly wondered why one sees apparaitre a line 4094 during the creation of the BG. In fact, during a program the HP does not calculate the numbers of line of program, it does not need any.

But if one stops the program to look at it, it must all recompute. To remember the need for this calculation it places in the register E the number of line FFF. Or FFF is worth 4095 into decimal. In the process of creation of the BG, at the time when we erase the LBL"T ", the HP moves back of a line starting from FFF without realizing that this number is invalid, from where 4095-1 = 4094.


The Grabber Byte can be used to you to manufacture in report programs all the artificial functions which you will want. They are functions with 2 bytes, for example RCL, ISG, VIEV, FIX or TONE. The codes of prefix of these functions are row 9. We can build in memory chains of bytes which will put at the continuation one of the other this prefix and a byte that we will end well up transforming into postfixe. We will test, for example, to use byte 75 like postfixe. We will solve the problem while placing in tète of the train byte 90; we will have for example: 90 98 75

What known as of that the 4Ç? 90 = RCL; after RCL the 4Ç seeks a postfixe and thus takes the 98. As postfixe 98 is IND 24, remains one 75 whole alone which is then written RDN and the HP:



Etes you able to create these two lines of program? Yes? Then you can do everything. Did you include/understand? We will steal (BG) the 90 and to erase purely and simply character strings given by the BG. Restent the last 2 bytes.

p. 51

98 75

98 is read VIEW

75 is then a postfixe, it is displayed M


Leave the mode programs and re-enter in ALPHA: ABCDEFGHIJ Pressez SST, which carries out VIEW H, you see (mode FIX 9)!


It is the copy of characters DEFGHI, look at the codes (and do not forget the special writing of the negative exhibitors).


You will obtain: with

But there! amuse to test several times this instruction... There are still things to explore...



The program attached (fig, 14, p. 52) is an alternative of a program very running in club PPC called traditionally KA (Key Assignement, assignement of keys), modified to be absolutely without risk of MEMORY LOST. Attention nevertheless, you can stop program, the SST, but it is necessary imperatively to go until the end of 2 assignements if you want to find your machine in his starting state.

Description of the program: This program assignement manufactures in alpha the contents of a register of artificial and places these contents in R(0C0) which were previously occupied when the two keys were assigned. These assignements preliminary is also used to raise the indices in your registers | - or E.

The construction of this false register of assignement is begun line 05 where one places the character F0 in ALPHA.

With the appearance of??? enter into decimal the prefix of the function to assign, ENTER†, the postfixe, ENTER†, the code of key (this same code which the 4Ç displays when one assigns: With = 11...) then R/S.

Under program 02 converts the prefix into hexadecimal, then the postfixe and places these data in alpha, the code of the key is then formatted and is placed in alpha. Then a second??? ask the second assignement. It is absolutely necessary to answer this ìéme request, with the need to repeat simply the first assignement.

p. 53

Then the machine places the curtain in 00F (it is the effect of line 12) the register R(0C0) to fill has the relative address R177 then, from where the recourse to indirect storage, then the initial state is reconstituted.

It is this part of the program which constitutes its originality. Indeed, in general one is satisfied to place the curtain into R(0C0), a simple STO 00 is enough then with the filling to the register. But if, at this moment, one stops the program or one SST, there is MEMl0RY LOST! Indeed, the 4Ç tests the existence of a register under the curtain: there is always at least a register of program in this place, that of the END..

If the curtain is into R(0C0) it has there nothing (except on the CX, or with module X-F) with the lower part and the 4Ç rèagit brutally.

One can indefinitely start again the operation and thus enter as much of assignements that desired.

Realization of the program:

The BG will be useful to us. The line 08 X< > M (the printer does his, vèrifiez on the table or page 29 pourMN0PQ| - the translation by the printer) is obtained with RCL IND 78 / RDN.

Line 09 is RCL IND16 / SDEV. The ligne11 (F5 01 69 00 F0 F0) is much more difficult to obtain (the line 05 Fl F0 is on this same model). With the fact, it is contents for the register C, did you see the 169? Enter ALPHA ABCDE ALPHA, BG F5, remains - * / X<Y? X>Y?. Replace it - by LBL 00, replace it * by FRC, leave it /, erase the two tests and twice make " type RCL IND.T and BG the RCL, remains F0 ". Faire PACK (not GTO.., XEQ"PACK "), BST until / and erase it. It is finished, not packer before having supprimè the BG. You see:

" xX-XX (impossible to type!)

If with the execution, you have a MEMORY LOST in SST after this line, it that there is an error in the line, is undoubtedly remade are born to it that should not be.

Attention also with the line 05 which are Fl F0, and not all alone F0, as the listing could let it believe.

Line 12 is ASTO C (RCL IND 26 / SDEV), line 18 is STO C (RCL IND 17 / SDEV), the line 30 E 1 is one 1 E 1 of which one stole first 1; to test, it is to adopt it (profit of L byte and time).

Line 33 is STO 0 (RCL IND 17 / CLX), line 53 is the entrèe of a zèro, the line 54 X< > 0 is RCL IND 78 / CLX, line 64 is F5 7F 00 00 00 00. For that, type " | - ABCD ", BG F5, to jump the CLD and erase - * and X<Y? not packer, to remove the BG. Remains lines 70 and 83. X< > D is RCL IND 78 / AVIEV.

p 54

Figure 14 '

Comments on program KA:

Line 03 is 03"ASSIGNEZ 2 T " for " assign 2 keys ". you must then assign an unspecified function with the two keys which you intend to use (to assign) with the program. This has as a result to raise the indices of key in the register E (or | -) and to place a filling in the register 0C0, filling that KA will replace by the final assignements.

Attention also: if, having keys assigned before, you désassigné some of them before using KA the program has great chances not to go. It is better, at least at the beginning, to assignement use KA on the machine without other that those claimed by KA.

Two assignements interesting: the BG and eG0BEEP.

The BG which we created place in the register of assignement bytes F7 and 3f (decimal 247/63), but try to assign F7/80 (247/128). In same XROMf, even display, here with the card reader you have appearance of CARD READER (or CARD RDR lx), a convenient identification (F7/80=XROM 30,00).

eGOBEEP is assignement the xx/167, xx lying between 0 and F (0 to 15 decimal). It is a " unforeseen function " like the Grabber Byte. This function has the property to create (and possibly to carry out) the functions XROM 28 and 29 which are the functions of the HP, mass memory and control, and printers.

This function displays eGOBEEP --. if you answer by a figure from 0 to 41 you create a XROM 28, figure which corresponds to the HP IT. For example, the nombre12 gives XROM 28,12 which is function RENAME. if it IT is present as well as the cassette player, this function is carried out (or is registered RENAfME in a program) if not one has NONEXISTENT (or XROfM 28,12 in program).

Between 42 and 63 there is no function to answer. From 64 to 89 one obtains " XROM 29, (chiffre-64) ", to some extent should be made a reserve, and one has the functions of the printer.

Attention, 89 is FMT (Format) and exists only on the HP THERE; moreover, one can thus " carry out " the titles MASS STORAGE or PRINTER. With various, generally bad fortunes.

p. 55

Line 87, x< > N is RCL IND 78 / LASTX, line 88, STO M is RCL IND 17 / RDN.


When there are many artificial lines of program to create, the BG becomes tiresome. Moreover, it is not possible to obtain thus certain codes of the rows C with E of the table. the program below, written by Lionel Ancelet, and published in the newspaper of PPC-Toulouse, creates directly in report all the bytes which can be necessary. It is a version of a very widespread program in the club with a traditional name LB (Load Byte = load a byte) (cf fig.15 P.56).

Use of LB:

After having introduced LB in memory, to make GTO..; to enter in program LBL " + + " followed d"un a number of + higher of 12 than the number of artificial bytes to introduce, then XEQ " LB ", END. not to use other instructions. In putting (+) rather more than less, attention not to have a END too near on which you would come to encroach in the course of road.

To return in calculation mode and XEQ " LB ". After a few seconds, a number of form 1, mn is displayed, which means that one asks for the first byte of a program to you which will be able to contain nnn of it. If you did not return enough of +, a chain alpha or a number is displayed.

Then give the decimal value of the byte to be introduced, R/S, and so on.

If you do not want to return any more of byte, made R/S without anything introduce, the program enters in final phase.

When it stops, a SST brings back for you to the LBL"++ ", it does not remain you any more but with vèrifier your program and to remove the useless instructions.

There is a procedure of correction. If you were mistaken, made XEQ 01 instead of R/S and set out again with the number from the byte requested, 1 step or 1 register of 7 bytes behind according to case's.

Description of LB:

When one makes XEQ"LB ", the machine is not in alpha mode, therefore flag 48 is lowered, therefore the execution jumps to step 04. AON raises flag 48, CLST E RDN erases the pile and places 1 in the register T the execution is then transferred to the LBL"++ "; the continuation of " + " ensures the counting of the bytes, and one arrives at step XEQ"LB ": this one pushes in the register B the return address of the XEQ in the compacted form, and the execution is returned to program LB. As this time flag 48 is raised, the execution

p. 57

jump with the LBL 00. AOFF lowers again flag 48, les instructions 11 to 39 calculate the number of bytes available, instructions 40 to 50 decode the return address, which is that of the END of "++", and make use of it to build a register C provisional, in which this address will be that of a register provisional R00: the synthetic bytes will be grouped per packages of 7, and will be stored register by register.

The principal loop of the program is located at the lines 73 à130: the register R00 contains the pointer of byte; its contents are displayed with line 76, when the program stops to require a byte. if one pressed R/S without returning of byte, value 0 is used (lines 77 and 78). lines 79 and 80 ensure that the entered number is in the interval O-255, and lines 81 to 102 build in alpha the character corresponding to the decimal code entered (pour.ceux which has the module x-F, or the 4Çx, these lines can be replaced by XTOA).

Then, the program looks at if one finished constituting a register of 7 bytes. if it is the case, the address relating to the provisional register R00 is calculated with the lines l09 to 120, then the contents of C are modified to place R00 at the good place (lines 121 and 122). lines 123 and 124 store the register made up of the last 7 bytes entered to the address generated previously, then the contents of C are restored with its initial value. Alpha is then erased, and, if it is still possible to re-enter of the bytes, one continues.

Steps 55 to 72 contain the procedure of correction. The register R00 is dècrémenté, and the last character of the register alpha is unobtrusive knows finally that the code hexa of line 45 is: F4 10 00 0l 69

No the particular difficulty to create this line if you hold account owing to the fact that the code of l0 being that of figure 0, one needs packer the program after introduction of the 0 (and before erasure intended to produce no one), to remove no one that the HP places before any figure in memory.

Therefore to type " ABCD ", BG F4, to enter 0, erase - and make PACK, jump *, enter LBL 00 and FRC, to erase it * and to remove the BG.

You must now know to make all the other codes.

Sequence LBL"++ " + + +... XEQ"LB " is hard to introduce. Think of copying it from magnetic card; it is then enough to work on the last program (that whose END is the ENO.) and to place the sequence by making XEQ"MRG ". Thus perhaps you will discover this so useful function of the card reader.

The input of the GTO with 3 bytes is done for LB while re-entering the decimal values 208/0 / 0 to 127 (number of the label).

Do not try to assign these values, if not, you will have to read the next paragraph!

p. 58


It can arrive, more often than you hope for it, than, following a sometimes alleviating handling, the HP does not react any more or reacts in an abnormal way to the requests.

Two ways of reacting: RESET and MEMORY LOST

RESET is a function of the microprocessor envisaged of origin by HP to be accessible to the user.

On an old model, it is necessary to withdraw the piles and to give them (attention to have disconnected the printer, if it is one here 83143 this feeds the HP - with the fact, separately the display, the HP functions very well without pile when this printer is connected).

On a recent model, it is necessary to press < - and to give one or 2 pressures in ON position. If CLX is seen, it is freed.

MERORY LOST is obtained starting from an extinct machine while pressing < - then by carrying out a pressure on 0N and by releasing all.

In the serious cases, it is necessary to leave without pile the HP several days (to remove as a preliminary all the accessories). Generally, alarms are lost, the adjustment of the clock too.

End of the fifth chapter