Article 1491 of comp.sys.handhelds: Path: en.ecn.purdue.edu!noose.ecn.purdue.edu!iuvax!mailrus!uunet!microsoft!alonzo From: alonzo@microsoft.UUCP (Alonzo GARIEPY) Newsgroups: comp.sys.handhelds Subject: The HP 48 Programmer's ToolKit (review, long) Message-ID: <57750@microsoft.UUCP> Date: 26 Sep 90 07:00:28 GMT Organization: Microsoft Corp., Redmond WA Lines: 174 James Donnelly has done it again, but even better. The HP48 Programmer's TookKit is a set of primitive functions and utilities written in native RPL and machine code by one of Hewlett Packard's HP 48SX engineers. My copy arrived with an MS-DOS 5-1/4" floppy diskette containing HP 48 libraries and sample data, and a 124 page manual. You will need a serial cable and IBM-PC or compatible to load the libraries onto your HP 48. The manual is clearly written, but the typesetting looks little better than Donnelly's last effort, The HP 48 Handbook. One of these days I'll convince him to use a better font (lower x-height and serifs, please). It might have been better to call this package the HP 48 String/List Toolkit. It contains all the commands and utilities you need for creating, sorting, editing, searching, and viewing lists. There are many useful primitives for dealing with strings, dates, sets, graphics objects, and something called meta objects. Meta objects are what result when you execute LIST-> on a list. They can be manipulated more efficiently than lists because you work with pointers to list elements instead of the elements themselves. That is the basis of the quicksort speed-up I posted some months back. Meta-objects avoid continual garbage collection when you are manipulating large lists of information. I would have liked to see a more complete set of stack primitives for meta-objects. Among those omitted were MROT, MOVER, MDROP, and MDUP. MDROP is equivalent to DROPN, and MDUP is equivalent to << DUP 1 + DUPN >>, and I suppose you can use SRLL and MDUP to create your own MROT and MOVER. If you want to use the 48 as a personal organizer, this toolkit contains the necessary primitives to handle large amounts of data without tedious programming and time consuming loops of user code. And the built in browsers will satisfy most of your needs without writing much additional code. Below, I have reproduced the back cover and pages 37 to 39 of the manual. A more complete table of contents appears within the manual. There is no index. The HP 48 Programmer's ToolKit Getting Started 1 Character Set Catalog 5 Menu Label Builder 7 Flag Catalog 10 Data Browswer 13 Title Browser 22 Tool Library 26 Command Reference 40 Object Types 116 Character Codes 117 Character Translations 119 Flag 120 Alpha Keyboard 124 Array Operations ---------------- DELCOL Deletes a column from an array DELROW Deletes a row from an array EXCOL Exchanges two columns in an array GETCOL Extracts a column from an array GETROW Extracts a row from an array INSCOL Inserts a column into an array INSROW Inserts a row into an array PUTCOL Replaces a column in an array PUTROW Replaces a row in an array Graphics -------- PX+ Adds two grqaphics pixel coordinates PX- Subtracts two graphics pixel coordinates PXOFF Clears a pixel in an arbitrary graphics object PXON Sets a pixel in an arbitrary graphics object PX? Tests a pixel in an arbitray graphics object PX->R Converts pixel coordinates into two real numbers ROTATE Rotates a graphics object R->PX Converts two real numbers into pixel coordinates List Manipulation ----------------- CAR Returns the first object of a list CDR Returns a list minus its first object CUT Splits a list into the first and remaining objects EXTRACT Returns the mth element from each of a series of lists LSORT Sorts a series of lists based on the mth element NXTOB Returns the next choice from a list of choices PRVOB Returns the previous choice from a list of choices SPLIT Splits a list into two lists REPLACE Replaces all occurences of an object in a list REVERSE Reverses the order of objects in a list ROTATE Rotates the objects in a list ->SET Removes duplicate objects from a list Meta-Object Utilities --------------------- MAH Adds an object to the head of a meta-obj in position 1 MAH2 Adds an object to the head of a meta-obj in position 2 MAM2 Concatenates two meta-objs MAT Adds an object to the tail of a meta-obj in position 1 MAT2 Adds an object to the tail of a meta-obj in position 2 MDH Extracts an element from the head of a meta-obj in pos. 1 MDH2 Extracts an element from the head of a meta-obj in pos. 2 MDT Extracts an element from the tail of a meta-obj in pos. 1 MDT2 Extracts an element from the tail of a meta-obj in pos. 2 ML->M Converts lists in positions 1 and 2 into meta-objs MM->L Converts meta-objs in positions 1 and 2 into lists MREVERSE Reverses the order of the objects in a meta-obj MSWAP Swaps the meta-objs in positions 1 and 2 MZ2 Places an empty meta-obj in meta-stack position 2 Set Utilities ------------- ADJOIN Adds an object to a list if is unique DIFF Returns the set difference of two lists INTERSECT Returns the intersection between two lists SDIFF Returns the set symmetric difference of two lists ->SET Removes the duplicate objects from a list UNION Returns the set union of two lists Stack Manipulation ------------------ KEEP Keeps the bottom n objects on the stack MREVERSE Reverses the order of the first n stack objects NDUP Creates n copies of an object QSORT Sorts n objects on the stack SRLL Rotates n objects on the stack upward m times SRLLD Rotates n objects on the stack downward m times SXCH Exchange objects at levels m and n String Manipulation ------------------- CAR Returns the first character of a string CDR Returns a string minus its first character CUT Splits a string into the first and remaining characters ICAPS Converts the words in a string to initial caps LCASE Converts the characters in a string to lowercase LTRIM Removes leading spaces and tabs from a string PUTCHR Places character code n in a string REPLACE Replaces all occurences of a substring in a string REVERSE Reverses the order of characters in a string ROTATE Rotates the characters in a string RPTSTR Creates a string of n substrings RTRIM Removes trailing spaces and tabs from a string SPLIT Divides a string into two strings ->STDSTR Converts an object to a string in standard display mode STRCON Rapid creation of new character strings STRCTR Centers a string in a specified number of spaces SUBNUM Returns the character code of a string's nth character ->TIO Converts a string to its translated form for I/O TIO-> Converts a string from its translated form for I/O TRIM Removes leading and trailing spaces and tabs from a string UCASE Converts the characters in a string to uppercase ->WORDS Separates a string into individual words Other Commands -------------- DOW Return the day of the week given a date DOY Returns the day of the year given a date EQNVARS Returns a liset of global variables in an equation program VFIND Find all occurences of a variable or object type in user memory XTIME Calculates execution times The HP 48 Programmer's ToolKit, By James Donnely Armstrong Publishing Company 3135 NW Ashwood Drive Corvallis, OR 97330 USA I imagine you could also get the TookKit through Educalc. I have no information on price or availability. Alonzo Gariepy // I have no financial interest in this alonzo@microsoft // product, but I think it is way cool.