I ran out of time to try and find the error, and I never tried your second listing.
Well, there's always tomorrow.
I ran out of time to try and find the error, and I never tried your second listing.
Code: Select all
var a: array of Byte;
Code: Select all
var a: array of Integer;
Ran fine here on DJPP, MinGW and WinSDL.
Code: Select all
$ bbcbasic
PDP11 BBC BASIC IV Version 0.32
(C) Copyright J.G.Harston 1989,2005-2020
>_
Yep, VDU 2 starts a print job, and all OSWRCH goes to the VDU and the current printer (if not changed by *FX3), and VDU 3 terminates a print job, leaving OSWRCH going to just the VDU (again, if not changed by *FX3).scarybeasts wrote: ↑Mon Oct 14, 2019 8:33 pmI hadn't heard of Ctrl-B before. How does that work, is future OSWRCH activity also echoed to the printer port or something like that?
Code: Select all
$ bbcbasic
PDP11 BBC BASIC IV Version 0.32
(C) Copyright J.G.Harston 1989,2005-2020
>_
This was such a good idea that I had to implement it. It's now live on https://bbc.godbolt.org/BigEd wrote: ↑Mon Oct 14, 2019 11:18 amYes, paste from clipboard was a big help. But I made the tactical error of pasting the Sharp Basic original and then fixing it up within JSBeeb, instead of working on a master copy and re-importing it. So the other half of the function, copy-from-printer, would be very handy.
Very late to this party, but it seems to be a bug that has since been fixed, it runs fine on 32-bit and 64-bit on V1.22.3 (or the current pull from git).scruss wrote: ↑Mon Oct 14, 2019 1:52 amOr in BBC BASIC for SDL 2 on a i7-4790K @ 4.00GHz, 4400 digits in 44 seconds.
Couldn't get it to run at all in Matrix Brandy on the same machine. It failed with Address exception at line 100. I suspect a 64 bit problem, as it seems to run fine on a Raspberry Pi.
A Raspberry Pi 4 manages 5000 digits in 44 seconds.
Code: Select all
1MO.2:M=192:DIMB%(M):V.5:A=0:F.I=0TOM:B%(I)=20:N.:F.C%=M TO14S.-7:D%=0:A%=C%+C%-1:F.P%=C%TO1S.-1:D%=D%*P%+B%(P%)*100:B%(P%)=D%MODA%:D%=D%DIVA%:A%=A%-2:N.
6N=E%+D%DIV100:U=N DIV10:F.I=0TO1:MOVE608+420*SINA,528+420*COSA:GC.0,RND(7):P.;U;:A=A+.121:U=N MOD10:N.:E%=D%MOD100:N.:V.1
Code: Select all
0MO.4:?6548=16:M=126:DIMB%(M):F.C%=M TO14S.-7:D=0:A=C%*2-1:F.P%=C%TO1S.-1:D%=D%*P%+B%(P%)*100+2E3:B%(P%)=D%A-20:D%=D%/A:A=A-2:N.:N%=E%+D%/100:U=N%10:F.I=0TO1:K=K+.18:x=64*COSK:y=-64*SI.K:PL.4,608-7*y,528+7*x
1F.Y=0TO7:V=Y?(49280+U*8):V.1559;((16V)*48+(32V)*96+(64V)*192+(128V)*384)256,(1V)*3+(2V)*6+(4V)*12+(8V)*24,0;0;0;5:PL.17,x,y:PL.0,-x+y/8,-x/8-y:N.:U=N%10:N.:E%=D%100:N.:V.1