spotlessmind1975 / ugbasic

An isomorphic BASIC language compiler for retrocomputers
Apache License 2.0
87 stars 14 forks source link

Add support for TSB (syntax) #803

Open spotlessmind1975 opened 1 month ago

spotlessmind1975 commented 1 month ago

IMPORTANT

All activies are tracked on TSB Project https://github.com/users/spotlessmind1975/projects/2

ORIGINAL DESCRIPTION

It would be interesting to be able to support the syntax of other BASICs, and in particular that of Tuned Simon's Basic (TSB). The aim is to allow, as much as possible, a compilation of the original sources but using the ugBASIC compiler to generate the executables.

List of keywords supported by Simon's BASIC and by TSB:

godot64 commented 1 month ago

TSB has an additional command SOUND for invoking sounds at a given frequency. It is missing in this list of commands.

Also, I miss RESET to reset the DATA pointer to a new starting line for the next READ statement.

Arndt

spotlessmind1975 commented 1 month ago

Hi @godot64, and thank you for your comment!

Both commands are already present in ugBASIC.

The SOUND instruction is described here, and it is compatible with the TSB one: https://ugbasic.iwashere.eu/keyword/SOUND

The RESET instruction will be aliased with the RESTORE instruction, that already accept an (optional) line for the next READ statement: https://ugbasic.iwashere.eu/keyword/RESTORE