Path: utzoo!censor!geac!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!usc!apple!agate!shelby!msi.umn.edu!noc.MR.NET!gacvx2.gac.edu!hhdist From: CW%APG.PH.UCL.AC.UK@pucc.princeton.edu Newsgroups: comp.sys.handhelds Subject: Message-ID: Date: 7 Jan 91 12:00:32 GMT Sender: dan@nic.gac.edu Lines: 86 To: HANDHELDS@gacvx2.gac.edu Return-path: Return-path: CW <@pucc.princeton.edu:CW@APG.PH.UCL.AC.UK> To: HANDHELDS@gacvx2.gac.edu Via: UK.AC.UCL.PH.APG; 7 JAN 91 12:26:12 GMT Hi again, Over my Christmas Holidays (thats vacation for the Americans :-) ) I poked around alot inside my 48SX internals with a very sharp stick (The memory scanner (WOW very useful)) and lo and behold I come back to work and read the bulletins and theres all the sort of stuff I've been looking into, explained nicely for me and many of my questions answered. Derek deserves a slap on the back (nicely of course). I wish now to add a few amateur bits to everything else. (all this was done on a version D !!) If you store an array in the top of memory (i.e. the first variable in the home directory) and look at it in the memory scanner you see this..... 8e920 Header for array ..... 5 nybbles for length (inc. these nybbles) 33920 header for type of object in array (in this case real)**** ..... 5 nybbles for number of rows ..... 5 nybbles for number of columns And this is followed by the actual data in the array (without the usual header (i.e. you just get the number in the case of a real) eg [ 1 2 3 ] looks like 8e920 44000 33920 10000 30000 0000000000000010 0000000000000020 0000000000000030 (I hope that comes out right when transmitted). Anyway why am I saying all this? Well if you put 55920 instead of 33920 and look at the object on the stack you get Array of Long Real Of course the data following this header is not in the form of long reals but it could be! You can actually put any prolog header in place of the 33920 and get the following Array of Long Real Array of String Array of Long Complex Array of Code Array of Character Array of Array !!!!!!!!! Array of Linked array etc....etc....etc You only need to organize the data after the whole array header into the specified form and voila nice new data types. Unfortunately not so simple :-( . Any attempt to extract an element from an array that is not real seems to results in a complex number being extracted (if you can actually do anything with the array atall). So I let this information out for further investigation........( I've tried uing lower level RPL calls but they all seem to assume that the array will contain numbers.) Wouldn't it be useful to have arrays of strings or dare I say Algebraic arrays (which you can of course get on the stack by putting 8ba20 instead of 33920 in the header)? one final question. what does the code at #5331h do ? It seems to be quite important! Conrad Disclaimer: Do not repeat any of the above actions ever! Never do it. I warned you.