social.solarpunk.au

social.solarpunk.au

Trying to think what can be done in 2K RAM...

The computer would have to be more like a programmable digital calculator...

It could be like a little game console?

@vidak Have you played with either Atari VCS BASIC, or Odyssey^2 Computer Intro! ?

VCS BASIC is barely usable for anything, hard to enter with. Just not enough RAM.

O2CI had a thick ring-bound booklet that taught assembly language, with 99 bytes storage. Kinda cool, really, tho when I got it I was already programming real computers.

https://odyssey2.info/library/manuals/us_computerintro/Computer%20Intro%20(USA).pdf

@mdhughes just busy, will respond more fully later. Answer is yes.

Main motivation is--Arduino nanos are so cheap, but have 2K RAM...

@mdhughes @kim

this may be of some interest, and was the main motivation behind speculating about computers inspired by programmable calculators:

https://retrocomputingforum.com/t/mint-a-minimal-interpreter-for-resource-limited-cpus/3037

@kim this is definitely something I will explore.

Thank you! I cannot believe I forgot about boot sector sized programs.

2K is quite a restriction, but I think I can get something cobbled together which could make a simple bog standard Arduino Uno or Nano quite usable for some form of general purpose computing...

@vidak @kim Sure, but that way lies Brainfuck, which also came out of making a minimal stack-based language:
https://brainfuck.org

Long ago I wrote a similar but less stupid language, StreamFilter, in C, this is beer.sf:

99:b((
?b bottles of beer on the wall,"
?b bottles of beer,"
Take one down, pass it around,"
?b-1:b?b=))
?b bottles of beer on the wall."
)(()
No more bottles of beer on the wall!"

I don't remember how this works, exactly.

@mdhughes @kim I have experimented with brainfuck before. Certainly an esoteric language if there ever was one!

Not sure if this makes sense, but I had an idea to transpile some other, more human-readable language into brainfuck, but at that point you're right, why bother--turtles all the way down. 😂

@vidak
Way back I had a radio shack calculator that was programmable in basic and could save programs to tape. It had some small OS. It had 1.9k and a single line screen. 40 characters I think. A full qwerty keyboard. These days, an SD card would sure expand it nicely.

@vidak @kim Adding a few more instructions does make Brainfuck useful as a portable VM, instead of "can you make a language in <256 bytes" challenge. But that rapidly resembles just compiling to ASM.

@Zenie yes! This is kind of what I'm getting at. The 40 character-width displays are very nice.

replies
1
announces
0
likes
0

@mdhughes @kim yeah. I am thinking I may have to turn to assembly on the Arduino. Certainly possible. I have the Arduino IDE on Debian 13.

Keeping a would-be BASIC interpreter within 512B to 1K would, ironically, keep the project within acceptable afternoon hobby session limits, I think...

Hm... I am pretty good at 6502 assembly, how hard could it be on the Arduino Nano?

The idea would be to have enough memory to display small pages of text. If 80x25 is 2K, then maybe 40x25 could be acceptable?

@vidak @kim TRS-80 did 64x16, which is 1K and very readable, and CoCo did 32x16 but with a color attribute layer (2 bits per char).

@vidak
It would be a fun project. A very capable programmable calculator.

@mdhughes @kim hmm. maybe the idea has legs. the main reason i am going through all this pain is so people can just buy some entry-level Arduino and get going in Tiny BASIC very quickly.

there is, really, not much you can do in ~1K free RAM, so i suppose the next port of call would be to find some BASIC programs that would be interesting and entertaining to ship with the project.