Interpreted BASIC?

Am 24.03.21 schrieb me # home.com@3:770/3 in RBERRYPI:

Hallo F.,

FW> Is there a very simple interpreter for BASIC for BASH?

I haven't tried it myself, but there is a "bwBASIC" (Bywater BASIC) which is a small BASIC interpreter modeled after GW-BASIC. And there is FreeBASIC, which is more like QuickBASIC/QBASIC, but it is also a compiler.

Maybe that helps you a little.

Regards, Anna

Reply to
Anna Christina Nass
Loading thread data ...

Is there a very simple interpreter for BASIC for BASH?

Thanx!

FW

Reply to
F. W.

It would appear that that are three: bwbasic, sdlbasic and yabasic

sdlbasic says its for game development using the SDL library. The SDL library manages video, audio, input devices, CD-ROM, threads, shared object loading, networking and timers.

bwbasic looks like a more complete ANSI Standard BASIC interpreter than yabasic and could be the only one to have a built-in editor.

All are supported on other operating systems as well as Linux.

FYI I used the command line:

sudo apt search "basic interpreter" | less

to find these Raspbian packages. Use "sudo apt install packagename" to install one or more of them. I have no idea which is the best: I haven't written BASIC since around 1985.

--
Martin    | martin at 
Gregorie  | gregorie dot org
Reply to
Martin Gregorie

Won't you only find packages that have the exact description "basic interpreter" that way, or is the search cleverer than that?

Two Raspberry Pi related options:

- Gordon's RTB seems to have vanished from the repos but can be downloaded here:

formatting link
I just tried it and it still works, and it does GPIO, but unfortunately for OP it requires a graphical screen. (And to install libsdl-sound1.2 first, even if you don't use sound.)

- Also graphical, harking back to the inspiration for the Raspberry Pi:

formatting link

The only interpreter that I saw (in a web search) that does support command line/batch mode is apparently bwbasic, which is in the standard repo like you found.

Reply to
A. Dumas

Its cleverer than that: it matches packages using a regex. Changing the regex to "basic.*interpreter" added one other relevant hit: 'brandy', a BBC BASIC V interpreter

Be aware that 'apt search' is looking at the package's description, not its name, so a fairly generic regex like the one I used is likely to include irrelevant packages in its hits list. Since it only displays the first sentence in each description, its not always obvious why a particular hit got into the list.

--
Martin    | martin at 
Gregorie  | gregorie dot org
Reply to
Martin Gregorie

Following is not really the answer to the OP, but I grew up with this thing, and think the javascript emulation is cool.

formatting link

enter the following at the prompt (on a PC keyboard for * use the @ character, next to the return/enter key)

*EXEC !BOOT

and you will be starting the game, Elite ...

The site

formatting link
may interest some with memories of long ago, the beginning of my interest in home computing.

--
Adrian C
Reply to
Adrian Caspersz

formatting link
will show you. There is also opencomal which is a basic like language with more structure.

Reply to
ray

If you are looking for an interactive interpreter as an alternative to a bash shell, and I would recommend iPython rather than a BASIC variant. Python is far more powerful language with a vast range of library modules, and iPython allows you to use all of that interactively.

---druck

Reply to
druck

Thank you! Vintage-Basic is excellent!

FW

Reply to
F. W.

I'd suggest PowerShell ...

--
Adrian C
Reply to
Adrian Caspersz

On the Raspberry Pi?! Because we're in comp.sys.raspberry-pi here.

Reply to
A. Dumas

Yup.

--
Adrian C
Reply to
Adrian Caspersz

... or you could run RiscOS and you'd have BBC BASIC built in - an *extremely* powerful (and quick) version.

Mind you this all depends on what other connectivity you need.

--
W J G
Reply to
Folderol

On Thu, 25 Mar 2021 12:34:50 +0100, "A. Dumas" declaimed the following:

MicroSloth made it somewhat open-source and have ports for four architectures/OS... Using the port of .NET runtime...

formatting link
formatting link

--
	Wulfraed                 Dennis Lee Bieber         AF6VN 
	wlfraed@ix.netcom.com    http://wlfraed.microdiversity.freeddns.org/
Reply to
Dennis Lee Bieber

It should work on the console without any GUI running.

Try running it with the -D flag:

rtb -D

then looking at the list of modes it prints, then you can pick the mode/resolution with

rtb -m X

where X is the mode number listed from the -D command. Mode 0 is usually the highest resolution one which is the default if you don't use the

-m flag.

RTB (and wiringPi) are sort of on holiday right now - I've had some health issues in the past year or 2 and am now in the middle of moving house, so once the dust has settled I'll be doing more with them.

Gordon

Reply to
Gordon Henderson

Right! Thanks. I looked at the documentation and did try the -D flag but I was another step removed, over ssh, and it just would not start. I have not tried forwarding the X-server, that seemed a little over the top for OP who intended it as a bash tool.

All the best!

Reply to
A. Dumas

I know... but........ that seems great if you do things with PowerShell on Windows, not so much as a deliberate/independent choice on the Pi.

Reply to
A. Dumas

Why would you fart about with that rather than using one of the standard shells such as zsh? Not that I'd ever dream of writing a script with a shell scripting language.

--
Tim
Reply to
TimS

Why?

The more sophisticated Windows users think PowerShell is wonderful because it give them access to a lot of stuff the GUI doesn't touch, including a lot of things that *should* be in management GUIs e.g. finding mailbox sizes in the last version of Exchange that I had dealings with. That shouldn't be a command-line-only job, given what else the GUI does cover.

But it's *Windows* stuff. *nix has always had a shell (indeed many) to reach the command-line APIs of various daemons and applications. This chap wants to get back to BASICs. Why, we don't know. I occasionally dabble with VBA in Access, and even more occasionally in Excel, but I have no other use for any form of BASIC.

--
Joe
Reply to
Joe

If you use ssh -X then it should also work, but it'll be slow. Running it over VNC also works.

Gordon

Reply to
Gordon Henderson

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.