Title: YABASIC   Developer: SONY   Type: PS2 PROGRAMMING
Absolute PlayStation2
. . .
 
YABASIC
"Sony may do some more work on YaBasic, improve it's editor, add sound support, and tons of other useful stuff that could turn it into a simplified, free and more accessible version of the Yaroze for the PSOne"
YABASIC Box
 
. . .

PS2 Feature
 
Background:

Stop for a moment and cast your mind back about 15 years, to a time where undoubtedly some of you may not have been born and home computing and gaming were still very much in their infancy. In those good old days, or should that be bad old days, the likes of the ZX Spectrum, Commodore 64 and BBC Micro were cutting edge, and the magazines for these machines were filled with listings of code for games that you could type into your computer and play. Invariably these listing were either unreadable, error filled or both! Now we can do the same thing on our PS2's…

If your PS2 is either a European version, or an Australasian version, the demo disk that you received with your PS2 contains a program called YaBasic. This is a version of the computer language BASIC which you can use to create programs for your PS2, admittedly rather simple ones so don't expect to write the next Colin McRae Rally with it. Still awake? Good, hang on in there, we've only just begun…

YaBasic is a version of the BASIC computer language that was used on the home computers of the 80's, and is still in use today, all be it in a much more complex version to create Windows programs. It was written by John Kemeny and Thomas Kurtz from Dartmouth College, and is what is known as Open Source.

Open Source means that the source code for the language is freely available (you can download it from the Internet) and can be altered and added to by any third party. This obviously suits Sony's requirements since it can do whatever it wants to make YaBasic Playstation friendly. Of course the real reason for Sony supplying YaBasic with the PS2 is to get round a 2.5% import tax. By shipping the program with the PS2, Sony can claim that the PS2 is a computer and get round the tax!

Setting Up:

So that's a bit of history, now down to the nitty gritty… Load up YaBasic on your PS2 and what do you get? Well the answer is not much! All that's displayed is a blue background with some menu entries at the bottom; this is the editor for the YaBasic language. The editor can be used with a PS2 controller to enter in code; a 'virtual keyboard' will appear on the screen and letters can be entered one by one. However, using this method to program in YaBasic is nothing short of torture, so the best thing do is to buy a USB PC Keyboard, which can be plugged straight into one of the USB ports in the front of the PS2 and works immediately. Luckily a keyboard should only set you back about £10 (don't bother buying a keyboard with loads of Windows buttons, they will be useless and you will waste your money!) and is a worthwhile investment if you want to make any use of this program.

Included in the editor is some rudimentary help and documentation on how to program in YaBasic, however this is not a 'How to Program' manual and is really aimed at someone with some programming experience. Having said that, BASIC and it's variants is one of the easiest computer languages to learn and can be picked up pretty quickly. Unfortunately, the documentation is very YaBasic orientated and makes no mention of such obvious things as to how to make use of the PS2's controller. Luckily Sony have set up a web site at www.playstation-basic.com which has some extra information which wasn't included in the documentation when YaBasic was released. YaBasic also has it's own dedicated web site at www.yabasic.org.de, where you can download all the documentation for it, together with a PC compatible version of the program. Unfortunately there is no way of transferring anything that has been written on PC to the PS2, short of typing the whole lot in again!

The editor itself is very simple and easy to use, though it lacks many of the features that you would expect to find on a PC programming package, which an experienced programmer will find very frustrating (Sony please give me run time debugging and break points… PLEEEAAASSE !)

Included with the editor are a few sample programs, which give an idea of the types of things that can be done with YaBasic. These are mostly graphics demos including a Fountain, Rotating Cube, Bouncing 3D Ball and Fractal program. A simple game called Worm is also included, and is basically a version of the Worm game found on some mobile phones.

Any new programs can be saved onto the PS2's memory card, and take up minimal space. Unfortunately anything written in YaBasic cannot be run directly, but must first be loaded into the YaBasic editor, and then run. However this means that programs can easily be shared between users via the memory card and then altered or improved.

Features:

YaBasic itself is a pretty good implementation of the BASIC language, and is easy to write programs in although the error messages generated are very cryptic and also undocumented. All the usual programming concepts are supported including looping, subroutines, arrays, if - then statements, etc. Object Oriented Programming is not supported, and the language runs sequentially as opposed to being event driven.

Polygon and line graphics functions have been implemented, but obviously only plain shapes and textures can be created, although Gouraud shading is supported. Sprite animation can also be achieved, but only in a very simple fashion and is also undocumented in the editor.

As far as I can tell, there is no sound support in YaBasic except for a simple Beep command, which provides just that! Any file access would appear to also be out of the question unless there is a way of using the memory card to save runtime program data. YaBasic runs as parsed code, which means that it is not true compiled code, and hence suffers in the performance stakes. Runtime debugging is not supported which can make bug fixing a nightmare. Getting a full printout of the YaBasic documentation is particularly worthwhile, however I am not sure that some of the features in the documentation have been implemented in this version of YaBasic.

Opinion:

So, is YaBasic really any good? You may have thought, reading this article that YaBasic is a very simplistic program, hard to get to grips with, and boring anyway. In many ways you might be right. The editor is basic (no pun intended!) to say the least, the language is capable yet has some major omissions, and short comings, and who really want's to use their PS2 for this kind of thing when they could be playing DOA2 instead…

However YaBasic is free, a USB Keyboard costs next to nothing, and if you have an interest in programming, or fancy having a go at it without the outlay of an expensive PC, then it is certainly worth having a go at. Who knows, you might just create the next Colin McRae Rally after all…

With a bit of luck, Sony may do some more work on YaBasic, improve it's editor, add sound support, and tons of other useful stuff that could turn it into a simplified, free and more accessible version of the Yaroze for the PSOne.

I'm off to work on my version of the old classic, Breakout…

Useful Web Sites:

There's not that much on the web about YaBasic, however Sony have started up their own web site at www.playstation-basic.com. This site includes a Help section, Release Notes section and Search facility. The site is very small at the moment and has very little content, though maybe this will increase as interest in YaBasic increases.

The creators of the PC and Unix versions of YaBasic also have their own web site at www.yabasic.org.de, from which you can find out more about the language, it's origins and it's creators. You can also download the latest version of the YaBasic interpreter, get the full documentation for the language, and a useful editor for YaBasic for Windows.

There is also a developers forum for YaBasic at www.sourceforge.com where developers from around the globe can work collaboratively on projects, share ideas, post questions, etc.