A BASIC Bonanza
All the BASICs
The Atari 8-bits were blessed with a wide variety of programming languages, including many different versions of BASIC. There are even a few newer BASICs that have been released since the 80s as the Atari 8-bits remain well-loved.
The versions from the 80s that I knew about are:
OSS BASIC A+
OSS BASIC XL
OSS BASIC XE
Turbo BASIC XL
Atari BASIC is the original, of course. The story behind this BASIC is quite interesting. Apparently Atari wanted to use Microsoft BASIC like everyone else did at the time but they could not get it to fit into an 8K cartridge. So they hired an outside company to do it and this company instead proposed an all-new BASIC, which became Atari BASIC.
Atari BASIC has some great features, but two significant limitations: 1) Strings worked completely differently than most other microcomputer BASICs of the time, making it more challenging to translate programs, and 2) It was rather slow due to the way it looked up line numbers for GOTO, GOSUB and FOR loops.
This is a Friday free post, but
paid subscriptions are on sale through the end of the year. Save 20%, get more posts, maybe win some Atari swagand access extra perks.
When Atari bought BASIC, they only purchased a license so the original rights remained with its creators. Eventually that became Optimized Systems Software (OSS) and they released several updated versions of Atari BASIC. First was BASIC A+ which was version of Atari BASIC with bugs fixed and a few enhancements. Because it used more than 8K and thus wouldn’t fit on a cartridge, it was disk-based.
BASIC XL and XE Arrive
Later, when cartridge bank-switching technology became viable, OSS released BASIC XL. BASIC XL improved on A+ by adding player/missile graphics commands and other things. It also had a FAST mode to help improve the slow line number lookups.
Shortly after the 130XE was released, OSS released BASIC XE. This improved on BASIC XL (adding procedures!) and made it easy to use the 128K of the 130XE for data or program use. Back in the 80s, I would mostly use BASIC XE for my projects (and still use it today), although I used it with an 800XL.
Microsoft BASIC did eventually arrive as a disk product (a cartridge version, Microsoft BASIC II, arrived a bit after that), but it did not catch on in the Atari community.
It seems like a pretty decent version of BASIC that had some nice Atari-specific commands, but with better compatibility with BASICs on other platforms.
Turbo BASIC XL
Turbo BASIC XL appeared in 1985/1986 and took the Atari world by storm. It was released as public domain in Germany (on a magazine, I believe) and quickly made its way to the states on PD disks. In addition to having a bunch of new commands (although strangely no player/missile graphics commands), it also had a compiler! So you could write and debug your programs in BASIC and then compile it for better performance and easier distribution when you were done.
The author of Turbo BASIC XL, Frank Ostrowski, went on to create GFA BASIC for the Atari ST (and other platforms). He sadly passed in 2011.
I played around a bit with Turbo Basic XL back in the 80s, but for the most part I continued to use BASIC XE.
Since the 80s, other BASICs have appeared, including:
Of these, I’ve only used Altirra BASIC from the folks that make the fine Altirra emulator. Altirra BASIC is compatible with Atari BASIC but speeds things up a bit and adds some player/missile graphics commands (as a bonus, those PMG are compatible with the ones in BASIC XL/XE). It is not as full-featured as BASIC XL or BASIC XE, but I recommend always using it instead of old Atari BASIC, at least.
More intriguing to me is FastBasic, an actively developed open-source BASIC. It looks incredibly powerful with lots of commands and it does not require line numbers, which can make editing much easier.
I’ve yet to give FastBasic a try, but it is on my to-do list for 2023!
Which BASICs do you prefer?
Join the free Goto 10 mailing list!
Atari Basic came from Shepardson Microsystems, which also developed Atari DOS. Incidentally, they also developed Apple DOS for the Apple II series.
Atari Basic was inspired by Data General Business Basic, with some inspiration from Cromemco Basic for the floating-point routines. The latter were interestingly factored out of Atari Basic, and included as part of the Atari's OS, so that every language (including assembly) could use them.
Once I discovered Turbo Basic, I got away from Atari Basic. It's a superset of Atari Basic. You can load Atari Basic programs into it, and they run significantly faster! It has some nice enhancements to the language, but their utility is limited. For example, it has procedures, but they're really named gosub's. They have no parameters, nor return values, and no local variables.
You still have to deal with line numbers, obviously, but it gives you the ability to get away from them as much as possible, by using labels as branch and restore points. One problem I ran into, though, is that labels take up memory in the variable memory store, which is limited to 128 of them, IIRC. On a project I've been working on, I actually ran out of variables I could use, partly because of this! Shocked! I had never had this happen before.
Using labels also takes up significantly more memory than line numbers, as I've found out. So, I've eschewed using them so much, and have gone back to using line numbers for them. :(
I seriously considered converting my project over to Basic XE, once I found out it uses extended memory, but I'm still sticking with TB, for now. I found out that the techniques I was using to make my code a little nicer were actually causing it to take up a significant amount of memory.
The most useful commands I've found in TB are RENUM for renumbering the program, and IF-ELSE. RENUM is just a tad buggy. You have to be a bit careful using it, or else it can mess up your program, but generally, it works really well (just save your program first).
I was excited about the compiler, but my enthusiasm has dimmed after using it. It has some significant limitations. The main one is it doesn't understand your code exactly the way the interpreter does. The interpreter I think is excellent. It does what I expect, no matter what I throw at it. The compiler is frustrating. There are some expressions it can't handle, that work just fine in the interpreter. I had to find these out through trial and error, and adjust my code to work with it. Even so, I still run into problems with the compiler, to the point that I've not wanted to use it.
What annoys me the most is the compiler will often fail silently, where it runs into a problem translating your program, which causes your program to crash, or error out when run (when it ran fine in the interpreter), but the compiler will say "no errors", as if everything went fine.
One thing I will say is that the runtime environment for your compiled program is pretty good. If it gives you an error message, it's an error you can look up in Atari Basic's or Turbo Basic's list of error codes, and sometimes it relates to a real error in your program. That has sometimes been helpful. It's not foolproof. I've seen the runtime crash, for some inexplicable reason, giving no error message. So, it's a mixed bag.
Compiled programs consistently run faster than the interpreted version. Though, the performance boost is not as much as you might expect. My suspicion is this is because Ostrowski recycled the interpreter runtime, and the compiler just translates the tokenized code into direct calls into the runtime. It seems like a better version of Fast mode in Basic XL/XE, where it just optimizes your interpreted program a little. Though, in the benchmarks I've seen, compiled TB programs are consistently faster than Basic XE's Fast mode.
Always enjoy a good article about the history of BASIC.