OOLONG 1

Project introduction

Oolong is a virtual computer with a custom architecture that runs its own assembly language. Its use is as a compilation target for other programming languages, as it can compile to C or be interpreted.

Over the last few weeks I've been working on Oolong as a compilation target for Lazuli, a programming language I have been working on as well. Oolong also comes with a (very rushed) assembler written in python if you want to write code directly.

Current features

Oolong supports the following commands:

0x00: nop

ld reg, val, 0x01, reg, val, 3 bytes

st reg, addr, 0x02, reg, addr, 4 bytes

poke val, addr, 0x03, val, addr, 4 bytes

peek addr, 0x04, addr, 3 bytes (stores value at a reg)

push val, 0x05, val, 2 bytes

pop reg, 0x06, reg, 2 bytes (stores value at a reg)

Operations: c = a OP b

add, 0x07, 1 byte

sub, 0x08, 1 byte

mul, 0x09, 1 byte

div, 0xA, 1 byte

halt, 0xB, 1 bytes

jmp addr, 0xC, addr, 3 bytes

Logic:

and, 0x0D, 1 byte

or, 0x0E, 1 byte

xor, 0x0F, 1 byte

not, 0x1F, 1 byte

Is it usable yet?

No. There are many things I need to add to make it somewhat usable:

What I want Oolong to be

Oolong is made to be 8 bit only. I wouldn't really mind it being 16 bit, but I still want to focus on it being specifically 8 bit, as the Lazuli language is meant to resemble programming for 8 bit machines. So... sorry, I guess.

If you want to help develop:

If you know some C and are interested, heres the github. I update the repo usually every week or so.