Close

V0.1 (branch abandoned)

A project log for Assembler for SuperconBadge

An Assembler for the Supercon 6 Badge - been done. But *ON* the badge?

michael-mllerMichael Möller 08/03/2023 at 20:320 Comments

Purpose/design

The purpose of this first fragment is to match a 3 char mnemonic to an output as (hex) instruction value.

What algorithm can match strings, if we do not have line buffer? Or should I have a "token"-buffer? Structure of lookup table? Using a jump for each instruction type exceeds number of labels available.

The input for this test is just a single line with several 3 character mnemonics. The output is just the 3 nibble instruction code. Just a few mnemonics for now: HLT (≡ JR -1), TST (≡ OR Rx,Rx) and the pseudo END. Simply halt on END. The output is hex digits. Flow control is solved by entering characters slowly enough on the terminal connected to the serial.

But ...

My intention as a purist was to hand assemble above. It is, however, a pain to enter by pushbuttons. I started using the python cross assembler. This felt like cheating. It also was going to be quite large/complete before it could be converted to its own syntax for selfassembly.

This project approach has been abandoned - the code in the file [to be uploaded] is non-functional/bug- ridden.

Discussions