From: PremiumBlend on 26 Apr 2010 12:15 On Apr 25, 11:43 pm, Virgil <Vir...(a)home.esc> wrote: > In article > <cfaf4ce2-ea70-496f-a045-fdd21d703...(a)i37g2000yqn.googlegroups.com>, > > > > > > PremiumBlend <mnhollin...(a)yahoo.com> wrote: > > On Apr 25, 1:12 pm, John H Meyers <jhmey...(a)nomail.invalid> wrote: > > > Found this replacement in my calculator > > > for INPUT STR\-> (but always returning a single list): > > > > \<< -55 CF { V } + 0 DO DROP DUP2 IFERR INPUT THEN > > > DROP2 DROP2 ERRN DOERR END "{" SWAP + "}" + STR\-> > > > UNTIL DUP SIZE END ROT ROT DROP2 \>> 'INPUTL' STO > > > > Something to make use of it: > > > > \<< "Volume of a box" { { 1 0 } > > > ":L: > > > :W: > > > :H:" } INPUTL LIST\-> \-> d > > > \<< d DUPN WHILE 'd' DECR REPEAT * END \>> > > > "Vol" \->TAG \>> 'Box' STO > > > > Note that during INPUT, > > > two consecutive presses of ON/Cancel will terminate the program, > > > but if you only press once (clearing all text) and then ENTER, > > > the original input form "regenerates" itself, just like "Doctor Who" > > > >http://en.wikipedia.org/wiki/Doctor_Whohttp://www.bbc.co.uk/doctorwho.... > > > ://www.bbcamerica.com/shows/doctor-who/http://www.bbcamerica.com/content... > > > /doctor-who-classic-doctors.jsp > > > > [r->] [OFF] > > > I'm getting # D964h, 117.5 for 'INPUTL', is that right? What checksum > > and byte count do you get for 'Box'? I get "Error: Invalid Dimension" > > when I execute it. > > # 9BB6h and 105.5 bytes compiling it in exact more (so that the integers > are ZINTs) or # A844h with 109.5 bytes compiling in appoximate mode (so > that integers compile as reals with decimal points). > I get- Hide quoted text - > > - Show quoted text - I'm actually using an HP 48G to work these examples but will eventually put the code on my HP 49G+. Are you referring to compiling the program on a calculator or on a computer?
From: Virgil on 26 Apr 2010 15:41 In article <04bebdca-6bde-40a5-8a0f-8bbc50f414d5(a)s9g2000yqa.googlegroups.com>, PremiumBlend <mnhollinger(a)yahoo.com> wrote: > On Apr 25, 11:43�pm, Virgil <Vir...(a)home.esc> wrote: > > In article > > <cfaf4ce2-ea70-496f-a045-fdd21d703...(a)i37g2000yqn.googlegroups.com>, > > > > > > > > > > > > �PremiumBlend <mnhollin...(a)yahoo.com> wrote: > > > On Apr 25, 1:12�pm, John H Meyers <jhmey...(a)nomail.invalid> wrote: > > > > Found this replacement in my calculator > > > > for INPUT STR\-> (but always returning a single list): > > > > > > \<< -55 CF { V } + 0 DO DROP DUP2 IFERR INPUT THEN > > > > DROP2 DROP2 ERRN DOERR END "{" SWAP + "}" + STR\-> > > > > UNTIL DUP SIZE END ROT ROT DROP2 \>> 'INPUTL' STO > > > > > > Something to make use of it: > > > > > > \<< "Volume of a box" { { 1 0 } > > > > ":L: > > > > :W: > > > > :H:" } INPUTL LIST\-> \-> d > > > > \<< d DUPN WHILE 'd' DECR REPEAT * END \>> > > > > "Vol" \->TAG \>> 'Box' STO > > > > > > Note that during INPUT, > > > > two consecutive presses of ON/Cancel will terminate the program, > > > > but if you only press once (clearing all text) and then ENTER, > > > > the original input form "regenerates" itself, just like "Doctor Who" > > > > > >http://en.wikipedia.org/wiki/Doctor_Whohttp://www.bbc.co.uk/doctorwho... > > > > ://www.bbcamerica.com/shows/doctor-who/http://www.bbcamerica.com/content > > > > :... > > > > /doctor-who-classic-doctors.jsp > > > > > > [r->] [OFF] > > > > > I'm getting # D964h, 117.5 for 'INPUTL', is that right? What checksum > > > and byte count do you get for 'Box'? I get "Error: Invalid Dimension" > > > when I execute it. > > > > # 9BB6h and 105.5 bytes compiling it in exact more (so that the integers > > are ZINTs) or # A844h with 109.5 bytes compiling in appoximate mode (so > > that integers compile as reals with decimal points). > I'm actually using an HP 48G to work these examples but will > eventually > put the code on my HP 49G+. That would make a difference!
From: John H Meyers on 27 Apr 2010 13:45 On 4/26/2010 10:55 AM: > I'm actually using an HP 48G to work these examples What ROM version? Since ROM addresses are largely incompatible between 48 series and 49/50 series, checksums of compiled binary objects containing ROM addresses also differ. Emu48 tells me: #EE9Bh 109.5 INPUTL #9D70h 124.5 Box This is for the programs on the stack, rather than 'name' BYTES (for which the checksums would be the same, but lengths increase by the size of the variable names stored in the directory) If you transferred using Kermit, did you set "translation mode 3"? 3 TRANSIO Or did you type it from the keyboard? \-> is a right-arrow character (right-shift zero), watch whether or not spaces exist between these and adjacent characters. [r->] [OFF]
From: PremiumBlend on 27 Apr 2010 17:37
On Apr 27, 1:45 pm, John H Meyers <jhmey...(a)nomail.invalid> wrote: > On 4/26/2010 10:55 AM: > > > I'm actually using an HP 48G to work these examples > > What ROM version? > > Since ROM addresses are largely incompatible between 48 series and 49/50 series, > checksums of compiled binary objects containing ROM addresses also differ.. > > Emu48 tells me: > > #EE9Bh 109.5 INPUTL > #9D70h 124.5 Box > > This is for the programs on the stack, rather than 'name' BYTES > (for which the checksums would be the same, > but lengths increase by the size of the variable names stored in the directory) > > If you transferred using Kermit, did you set "translation mode 3"? > > 3 TRANSIO > > Or did you type it from the keyboard? > > \-> is a right-arrow character (right-shift zero), > watch whether or not spaces exist between these and adjacent characters. > > [r->] [OFF] Version HP48-R, program typed from the keyboard. I'll double check my code again. |