Re: [ql-users] Not so Simple Arithmetic

2006-12-17 Thread Wolfgang Lenerz
On 16 Dec 2006 at 10:56, Marcel Kilgus wrote: Wolfgang Lenerz wrote: On an ordinary QL I can type f%=-32768/1 and find that f% now contains -32768. Well that must be a nice bug. unless I'm mistaken, 32768/1 = 32768 and 32768 just doesn't fit in an integer. Yes, but

Re: [ql-users] Not so Simple Arithmetic

2006-12-17 Thread Rich Mellor
On Sun, 17 Dec 2006 16:39:56 -, Wolfgang Lenerz [EMAIL PROTECTED] wrote: On 16 Dec 2006 at 10:56, Marcel Kilgus wrote: Wolfgang Lenerz wrote: On an ordinary QL I can type f%=-32768/1 and find that f% now contains -32768. Well that must be a nice bug. unless I'm

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread Bill Waugh
- Original Message - From: Marcel Kilgus [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, December 15, 2006 3:18 PM Subject: Re: [ql-users] waiting for QPC print - meanwhile Bill Waugh wrote: cheers - yep that works in Sbasic, will need something different to work in archive

Re: [ql-users] Not so Simple Arithmetic

2006-12-17 Thread P Witte
Marcel Kilgus writes: Still it's a bug and I'll try to investigate when I find the time. But n = -32768/1: n% = n throws an overflow error n = -32768: n% = n is ok Doing a PRINT FLOAT$(-32768/1) gives $0810 C000 while PRINT FLOAT$(-32768 DIV 1) gives $080F 8000 Its not

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread P Witte
Bill Waugh writes: My Archive prg is as below proc label lprint lprint lprint lprint ' '+name$ lprint ' '+adda$ lprint ' '+addb$ lprint ' '+addc$ lprint lprint lprint ( I need chr$ for ff in here

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread Bill Waugh
- Original Message - From: P Witte [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, December 17, 2006 6:51 PM Subject: Re: [ql-users] waiting for QPC print - meanwhile Bill Waugh writes: My Archive prg is as below proc label lprint lprint lprint lprint '

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread P Witte
P Witte writes: Thus: proc label spoolon '_par1' lprint lprint lprint lprint ' '+name$ lprint ' '+adda$ lprint ' '+addb$ lprint ' '+addc$

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread P Witte
P Witte writes: or slightly more elegantly: proc label local L, T let L = 2: let T = 22 spoolon '_par1' lprint rept(chr(10), L): rem L + 1 linefeeds lprint tab T; name$ lprint tab T; adda$ lprint tab T; addb$ lprint tab T; addc$

Re: [ql-users] Not so Simple Arithmetic

2006-12-17 Thread Laurence W Reeves
Rich Mellor wrote: On Sun, 17 Dec 2006 16:39:56 -, Wolfgang Lenerz [EMAIL PROTECTED] wrote: On 16 Dec 2006 at 10:56, Marcel Kilgus wrote: Wolfgang Lenerz wrote: On an ordinary QL I can type f%=-32768/1 and find that f% now contains -32768. Well that

Re: [ql-users] Not so Simple Arithmetic

2006-12-17 Thread Laurence W Reeves
P Witte wrote: Marcel Kilgus writes: Still it's a bug and I'll try to investigate when I find the time. But n = -32768/1: n% = n throws an overflow error n = -32768: n% = n is ok Doing a PRINT FLOAT$(-32768/1) gives $0810 C000 You've detected the cause of

Re: [ql-users] Not so Simple Arithmetic

2006-12-17 Thread P Witte
Laurence W Reeves writes: n=-32768/1:n2=n*n:PRINT n2? I'd hazard a guess that one might get something like $0821 2000 . Actually $081F 4000 To a degree, calculations on the stack /may/ normalise values, but there's no guarantee. Also, it will be no surprise that one of

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread Jeremy Taffel
Elegance is in the eye of the beholder. Yes it's shorter, and the layout can be modified by changing the value of L and T. However, when code is only updated rarely, it is rather nice for that you can see the layout in the code. Your elegant version makes it less apparent, and it has to be

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread Marcel Kilgus
Bill Waugh wrote: proc label lprint lprint lprint lprint ' '+name$ lprint ' '+adda$ lprint ' '+addb$ lprint ' '+addc$ lprint lprint lprint ( I need chr$ for ff in here right ) spoolon '_par' : spooloff

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread hitchies
Marcel wrote - For the record, if at all, the SPOOLON command should probably be issued before all the LPRINT statements... === At some time (empirically based) I have annotated Stephen Morris' 1986 User's Reference Manual p141 with - SPOOLON SCREEN - valid with

Re: [ql-users] Not so Simple Arithmetic

2006-12-17 Thread Marcel Kilgus
Laurence W Reeves wrote: PRINT FLOAT$(-32768/1) gives $0810 C000 You've detected the cause of the bug! SMSQ/E has allowed a unnormalised value to get on the stack. True. I found the following line in the code: [...] cmp.l #$c00,d1 ; funny value? [...] So there

Re: [ql-users] floppy drive and keyboard

2006-12-17 Thread Roy wood
In message [EMAIL PROTECTED], Tony Firshman [EMAIL PROTECTED] writes SNIP The actual RomDisq genesis was when Sturat and I were in Eindhoven. I brought a compact flash designed for the Z88 (I designed the pcb and build it). We talked about the RomDisq on the way back to UK (train and bike

Re: [ql-users] waiting for QPC print - meanwhile

2006-12-17 Thread P Witte
Jeremy Taffel writes: As you say: Elegance is in the eye of the beholder. Per ___ QL-Users Mailing List http://www.q-v-d.demon.co.uk/smsqe.htm

Re: [ql-users] Not so Simple Arithmetic

2006-12-17 Thread Laurence W Reeves
Marcel Kilgus wrote: Laurence W Reeves wrote: PRINT FLOAT$(-32768/1) gives $0810 C000 You've detected the cause of the bug! SMSQ/E has allowed a unnormalised value to get on the stack. True. I found the following line in the code: [...] cmp.l #$c00,d1