Talk:BBC BASIC
| ↓ | Skip to table of contents | ↓ |
| This is the talk page for discussing improvements to the BBC BASIC article. | |||
|---|---|---|---|
|
|
||
| This article is of interest to the following WikiProjects: | |||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||
| Sources for development of this article may be located at "BBC BASIC" — news, books, scholar, images |
Contents |
[edit] Developed when?
when and where was basic language developed —Preceding unsigned comment added by 202.176.233.36 (talk) 16:41, 2 August 2005 (UTC)
[edit] BCPL
Was there some BCPL influence on BBC Basic? For example the unparenthesized DIM and ! operator mimic BCPL vector notation. And Acorn also implemented a version of BCPL meaning that Acorn employees were aware of, and probably used BCPL. (Note also that the OS calls OSWRCH and OSRDCH correspond to the BCPL function names WRCH and RDCH - exactly the same abbreviation.)
... Yes. BCPL was the primary teaching language of the Cambridge University Computer Science courses at the time. I was taught to program in BCPL by Martin Richards - who invented it, and it undoubtedly was a major influence on the developments at Acorn. The use of "!" for instance as mentioned, but also the BBC's OS has definate parallels with the BCPL global vector.
Acornsoft published a BCPL compiler/runtime system for the BBC. This was written by John Richards (Martin's brother) and Chris Jobson, and I had the task of project managing it through to publication. It was one of the first group of "other" programming languages which we produced for the BBC.
82.21.98.46 (talk) 01:09, 19 December 2011 (UTC)Paul Fellows, Acornsoft Languages Group Leader
[edit] BAS128
iirc there was a version of BBC basic supplied on disk with the master that ran from the 32K of main memory and used the 64K of sideways ram to store the basic program. I think it was called BAS128 but i've never actually seen it running.
Yes there was. It was an idea cooked up by myself when the BBC Model B+ was being launched. The relocation of the interpreter code into main memory, and use of the 4 x 16K of sideways ram banks gave a full 64K of free memory available for the user's program. It was slightly slower as a result of the need to deal with the bank-switching, but the difference was small. Tony Thompson of AcornSoft did the work taking the assembler source and modifiying it. It was shipped on disc with all BBC B+ systems as I recall.
82.21.98.46 (talk) 01:01, 19 December 2011 (UTC) Paul Fellows, Acornsoft Languages group leader
[edit] ENVELOPE
Did the ENVELOPE command really do nothing? I certainly used it (although 14 parameters were a bit of a challenge). —The preceding unsigned comment was added by 217.30.113.248 (talk • contribs).
- It only says it did nothing from bbc basic V (archimedes basic) onwards. You probably used it in older versions. Plugwash 16:10, 18 August 2006 (UTC)
- ENVELOPE changed the sound envelope on the BBC computers. Archimedes used a totally different sound system, so envelope was silently ignored (no pun intended) to retain backwards compatibility with old BBC machines. Kim Bruning 21:42, 18 August 2006 (UTC)
- No. Technically ENVELOPE has always done exactly the same thing in all Acorn OS hosted BBC Basics – it calls OS_Word/OSWORD 8. Whether the host OS (or any module) does anything as a result isn’t really BASIC’s responsibility. It is certainly possible for ENVELOPE to do something under Arthur or RISC OS. nemo (talk) 12:04, 14 April 2011 (UTC)
- ENVELOPE changed the sound envelope on the BBC computers. Archimedes used a totally different sound system, so envelope was silently ignored (no pun intended) to retain backwards compatibility with old BBC machines. Kim Bruning 21:42, 18 August 2006 (UTC)
[edit] ONE LINER
The maximum line length in BBC BASIC was 255 characters (IIRC, give or take). This combined with the fact that multiple commands could be combined onto a single program line gave rise to a very popular programming challenge: the "one liner". Quite simply the challenge was to write a program which dumbfounds the observer who could not believe that something so useful or visually impressive could be achieved in such an impossibly small amount of code.--Ear1grey 02:33, 15 December 2006 (UTC)
[edit] Xtreme BASIC program storage abuse
- Or, an insightful guide to the BASIC interpreter.
- You could do really loopy things with BASIC. There were two limits. The OS line editor call had a 255-character limit, but BASIC stored tokenised code not plain text. BASIC's limit was 255 characters of tokenised data. First and foremost, you could enter all the BASIC commands abbreviated; when you LISTed the lines, they would expand from the tokens back out to more than 255 characters.
- You could omit spaces in weird places; "
IFA ANDB" would succeed if (A & B). As soon as I and F were parsed, "IF" was assumed and 'A' was considered a variable. Ditto the AND. Variables cannot start with BASIC keywords (as per the User Guide), allowing for short-circuit parsing of "IF" in "IFA". "LET IFA=1" will be treated not as creating IFA and setting it to 1, but as "LET IF A=1", resulting in "Syntax error".
- The tokens themselves were nothing more than extended ASCII characters, which could be inserted by pressing the red function keys. For example, the token for AND was 128, or shift-ƒ0. Thus, you can write "
IFA<shift-ƒ0>B". BASIC will list this as "IFAANDB" which is normally invalid ("No such variable", referring to "AANDB") but owing to direct insertion of a token, will run in this instance. With judicious use of the red function keys, abbeviations and omitted spaces, you can create lines of code that are far too long, or simply too invalid to re-enter.
- A note on verifiability: all above examples were fully tested just now on an Issue 4 BBC Microcomputer, Acorn MOS 1.20, BBC BASIC 2.
- — Ghiraddje 13:42, 17 July 2007 (UTC)
[edit] Diagram
Mark Plumbleys BASIC book has a nice understandable diagram of the operation of BBC BASIC (i.e. evaluation engine), would it be appropriate to include it on the page?
- Wow, a fascinating book, I just found a copy of it on the BBC Documentation Project. To include that diagram in Wikipedia, though, you'd need to get permission from the original author. The diagram would count as copyrighted material, and I'm not sure that you could claim that fair use applies in this situation. Cmdrjameson 11:42, 20 April 2007 (UTC)
I've added the diagram but tell me if it meshes ok with the rest of the article.
[edit] BASIC III
I can't be certain enough to edit the article, but didn't the B+ use BASIC II? The article almost implies as much, since it says the only different in BASIC III was in the US version, so the UK B+ version would effectively have had basic II.--195.137.91.247 (talk) 22:37, 20 June 2008 (UTC)
[edit] Image
Surely we can get a better image than the About box from an application running on Windows. BBC Basic was developed for the BBC originally, I would like to see some Basic code being displayed on a BBC micro. What do you think? Darrenaustralia (talk) 08:57, 9 January 2009 (UTC)
- Not sure if my micro still works, but I do have an emulator on my PC that looks like the original. I guess I could take a screenshot of a very simple program running? Let me know... —Preceding unsigned comment added by 86.160.185.61 (talk) 14:42, 31 May 2010 (UTC)
-
Agree The original image was introduced 3 years ago and has now been replaced with what should be considered to be a more appropriate one. -- Trevj (talk) 21:17, 5 December 2011 (UTC)
[edit] Acorn Archimedes (RISC OS) - 'Main article' link
The section BBC BASIC#Acorn Archimedes (RISC OS) links to Acorn Archimedes by using{{Main|Acorn Archimedes}}. Would it be more appropriate to use {{Main|RISC OS}}? --trevj (talk) 09:53, 29 March 2011 (UTC)