Gavin.Flower@comp.vuw.ac.nz (Gavin Flower) (05/17/91)
The following I tried sending directly, but it bounced. Not sure what if any, documentation he has. ****Charles do you have sufficient documentation? If not, what do you have? And what do you want to do with the Beeb? id <AA00546@kio.comp.vuw.ac.nz>; Thu, 16 May 91 18:54:27 +1200 Date: Thu, 16 May 91 18:54:27 +1200 From: gavin Message-Id: <9105160654.AA00546@kio.comp.vuw.ac.nz> To: cccph@jessica.cs.ucla.edu (Charles Hobbs) Subject: Re: BBC microcomputer Hi, Yes & No! - Now mostly Arc stuff, but the odd hard bitten Beeb (BBC) and Elk (Electron) owner sometimes contribute! However you have bought a good machine. BASIC is very good. About 5* faster than that of an Apple II or Commodore 64. Keywords must always be in uppercase, awkward until you get used to it, BUT a very good idea. Keep all, except single character, variable names, in lower case and you will not run into key word problems that you do on most other micros. eg orange% = 4 this would generate an error on an Apple as "OR" is a reserved word and the Apple is not case sensitive! No need to uses goto's and gosubs !!!!! try this 10 MODE 2 20 REPEAT 30 GCOL RND(4), RND(7) 40 PLOT 85, RND(1280), RND(1024) 50 UNTIL FALSE 60 END or this 1 MODE 1 5 GCOL 1, 2 10 MOVE 100, 100 20 DRAW 100, 200 30 DRAW 200, 200 40 DRAW 200, 100 50 DRAW 100, 100 60 END can not remember details of GCOL BUT one number selects the logical colour the other the drawing action replace, XOR, OR, AND, invert there are 8 MODEs 0 to 7 MODE 2 has 16 logical colours 8 to 15 flash I use MODEs 0, 1, 2 for graphics +text and 3, 6 for text only all grahics modes have 1280 (0...1279) "grahical units" wide pixels vary in size from 2*2 to 8*2 GUs vertically 1024 (0...1023) at least on standard tv's probably less on US NTSC tv's !!! NB origin is at standard position for maths bottom left, therefore x increases to the left and y increases vertically has procedures - call by value try this 10 FOR I% = 1 TO 32 20 PROC_powers(I%, 2, top%) 30 NEXT 40 END 50 60 DEF PROC_powers(num%, p1%, p2%) 70 LOCAL I% 80 FOR I% = p1% TO p2% 90 PRINT num%^I%; 100 NEXT 110 PRINT 120 ENDPROC integers are 32 bit try 10 PRINT 2^30 20 END peek & poking use "?" for bytes "!" for words (32 bit) eg 10 MODE 6 20 DIM area% 100 :REM grab 101 bytes, area% contains address, note spaces! 30 PRINT ~area% 40 PRINT ?area% 50 PRINT !area% 60 ?area% = &FA 70 area%?1 = &DE 80 area%?2 = &BA 90 area%?3 = &BE 100 PRINT ~!area% 110 END normally DIMs are used for arrays eg define an array 5 by 6 least element xyz(0,0) last element xyz(4, 5) 10 MODE 6 20 DIM xyz(4, 5) :REM NB no space between name and dimensions !!!! 30 xyz(2, 3) = 77 40 PRINT TAB(5, 10) xyz(2, 3) 50 END floating point numbers are stored in 5 bytes 4 byte mantisa 1 byte for the exponent try typing in ("*" indicate a MOS command) *FX0 *HELP most things done on other 8-bit machines using pokes are done using *FX a, x, y a, x, y are byte sized values try this 10 PRINT ~HIMEM 20 *FX254 30 PRINT ~HIMEM :REM you now have lost 16K 40 END also look at LOMEM TOP PAGE programs are saved as SAVE "name" loaded, but not run LOAD "name" loaded and run CHAIN "name" programs in memory are simply RUN try *key9OLD|mRUN|m then press Function key 9 "f9" the symbol between "D" and "m" is the pipe or "broken line" chr I have an Archimedes now as well as a BBC model "B", the Arc BASIC is even more structured and much faster *************have fun wont guarantee answering, but you can try emailing me if you have questions - or just post to the net Regards, Gavin Flower -- The main "user" of well brought up, and educated, children is the community at large. So if you really believe in "user pays", charge the correct users - stop overloading parents with financial penalties. ******* These comments have no known correlation with dept. policy! *******