From the PPCJ, V7N3P3 (Apr 80) Message #12 Posted by Ernie Malaga on 8 Oct 2002, 2:31 a.m., in response to message #1 by Glen Kilpatrick
From the PPC Journal, V7N3P3 (April 1980)
Dear Richard:
A month ago, I felt that there were 3 unsolved challenges remaining for HP-41C synthetic programming pioneers: how to recall the contents of any register without normalizing; how to generate synthetic program lines on a bugless 41C with no card reader; and finally, how to turn the flying goose around and make him fly backwards. The first two problems were solved by the discovery of the "byte jumper" function (which, incidentally, is best understood as the manual equivalent of a program text line). And now, rather to my surprise, the last problem has proved tractable.
The enclosed photograph (I apologize for its quality; all I had available was an oscilloscope camera) is a bit of HP-41C art entitled "Geese Resting on a Fence." You will notice not only multiple geese, but also that one is facing backwards. Thus, programs may be written to show any number of geese facing and flying forwards and backwards, and even flapping their wings if desired. The display shown in the photo is not faked in any way; it was produced on an unaltered HP-41C, using no external devices, no bed-bounding, no dying batteries or modules, etc. Yeah, of course I used the Black Box programs.
Rather than reveal the technique at this time, I will leave it as a challenge to PPC members to produce the display shown in the photo, or one like it. You now have one essential clue that I didn't have: namely that it can be done. Anyone who succeeds can consider himself a charter member of the exclusive "Goose Club" (if you want to be certified, send me a program card that generates the geese). Then in the PPCJ issue following the appearance of this letter, I'll tell all.
Happy Hunting,
-William C. Wickes (3735)
Ed Note. Bill's display consists of a 10-character display with a blank on each end. The "birds" are illustrated in the drawing below. The photograph was too small to reproduce well. Sometimes a photocopy works very well to show displays.
!-{-!--}}!
From the PPC Journal, V7N5P56 (June 1980)
Goosing the HP-41C
Congratulations to Egon Jensen (3489) and Charles Close (3878)! These stalwart programmers were the only PPC members to successfully solve the Great Goose Challenge (V7N3P3). It is time now to reveal the solution to this problem, which surely has vexed all serious HP-41C fanciers since the first goose went scrolling around a display. What more could a true calculator fanatic ask than the opportunity to exercise enormous ingenuity and persistence to achieve an impossible goal with no practical use whatsoever? It was alleged at the PPC Midwestern Conference that an unnamed HP engineer once promised a free calculator to anyone who could make the goose fly backwards. I'd like to meet that gentleman...
The problem of taming the goose is twofold: first, does the normal goose character have an associated hex code, and second, if it does, how does one trick the 41C into displaying the goose? That a trick is required is evident to anyone who has used REBLD (V6N8P30) to generate each character associated with the 16*16=256 possible 2 hexadecimal digit bytes. Nary a goose anywhere.
The answer to the first part of the puzzle is so blindingly obvious that I, for one, did not see it until it was thrust under my nose. I was slipped one of the secret HP Diagnostic ROMs one day by one of the shadier characters in the local PPC chapter. The character test routine in the ROM displayed not only a normal forward-facing goose frolicking among the standard characters, but also revealed a never-before-seen backward-facing goose! How could I rest until I had freed these creatures from the oblivion to which they were consigned by their creators? Anyway, a little reflection caused me to compare the displayed character sequence with the hex table (V6N5P23), and lo and behold, the geese were right where they had to be: in the positions 2C (backward) and 2E (forward) apparently already occupied by the "," and the ".". But those two characters, along with the colon ":", are not made from the "boxed star" grid-they come from the interspaced dots. So codes 2C, 2E and 3A are still "available" for boxed star characters, and, in fact, the first two are the nesting places of the geese. The extra 3A character is just another boxed star.
No combination of codes I have yet found will persuade the display ROM to show a goose as an ordinary alpha character; the 2C and 2E always display as "," and "." respectively. One promising idea turned out to be a blind alley: the manual (and the keyboard) forbids us from using any of the three interspace characters as part of an alpha label. But synthetic generation of such labels still only resulted in more displayed commas and periods. Rats.
Finally, while languishing in bed one day with a bout of the flu and hence being even more demented than usual, I dredged up from some muddy corner of my brain the recollection of the curious display status FIX A. This little-known instruction, code 9C0A, has the occasionally useful property of displaying only the mantissa of a number with a positive exponent (without altering the number, of course-it's just a display mode). When playing with this discovery some time ago, I had been mildly annoyed because the mode's utility was compromised since if the number in question had an exponent of 10, 11, 12, or 13 (mod 14), some of the number characters (from row 3 of the hex table) would be replaced by characters from row 2, making the number hard to read.
This "nuisance" turned out to be the key to the goose hunt. I found with a little experimentation that if one places a number with exponent 13 into X, then FIX A (assign it to a key or execute from program), CF 28, CF 29, then the display will show only the mantissa of the number, with the last 9 digits showing row 2 characters. The first digit always remains a row-3 character, which spoils the effect somewhat since there is always an unwanted character flying along with the geese. But the other 9 may be any characters from row 2, including, luckily, the space. So, for example, the display of "Geese Resting on a Fence" given in the original challenge was just the number 1.DCD1DDEE1*10^13 displayed in FIX A. To get a single backwards facing goose followed by a comma (a goose dropping?), try B.C00000000*10^13.
The newly liberated geese will perform a limited number of tricks. To truly make a goose appear to fly backwards (right to left) across the display, one needs only to write a program that successively VIEWs numbers that contain a digit C stepping leftwards among digit zeros (which give spaces in the display). One row 3 character will be fixed in the leftmost position. To make the goose appear to flap its wings, successive displays should alternate digits C and E in the same position. To replace the normal goose with a flock of geese during a running program, place the geese number in X (or any other register). Then at some point of the program with a default display, insert the lines RCL d, VIEW Y, STO d. This will work with any desired display, not just extra flying geese.
The story is not quite complete. The technique described does show both geese, but only with restrictions. In particular, I have not succeeded in enticing the geese into the Alpha register. ARCL X totally ignores the row-2 characters showing in X. And yet, we are enticed by the solitary goose and the goose next to other characters shown in certain of the strange catalogs shown by fooling around with the catalog flag 30. Perhaps the HP-41C still has a few secrets for us to find.
-William C. Wickes (3735)
|