Bringing back an old microcontroller takes more than recreating its instruction decoder: it also needs software that can make its peculiarities visible. On Hackaday.io, project creator zpekic’s Iskra EMZ1001A recreation pairs a VHDL processor with an assembler and two small demonstration programs. The result is a working FPGA-based system whose greeting and Fibonacci sequence reveal quite a lot about programming with four-bit data and very little memory.
The project describes the original EMZ1001A as a joint Iskra–AMI design, manufactured in Slovenia and known elsewhere as the AMI S2000. This recreation was created on December 12, 2022; its main implementation and documentation updates shown here are from that December, rather than a new launch.
A tiny machine with a demanding display
The processor has 64 nibbles of RAM—32 bytes in total—arranged in four banks of 16 locations. Two registers select a bank and a position within it. That memory must hold not only working values but also the data used to drive the LED display.
There are no interrupts. As zpekic explains in the Fibonacci program log, display refresh belongs in the main program loop, with other work fitted around it. A program cannot simply write a number and wander off indefinitely: it must keep returning to the refresh routine.
The Fibonacci demo makes that constraint concrete. Two RAM banks hold the preceding numbers, and a third holds their sum for display. After adding the numbers in binary-coded decimal, the program repeatedly refreshes the LEDs until it detects the one-second tick. It then moves the values into position for the next addition.
That small workload exercises arithmetic, display output, the timer, subroutine calls across pages, and eight-bit output used to send ASCII to VGA and UART. It also has a documented flaw: zpekic reports that the intended overflow detection misses the carry from the most significant digit. Instead of restarting at zero, the program continues producing the last 13 decimal digits of the sequence. It’s a useful demonstration, not evidence that every corner case has passed.
An instruction quirk becomes a space-saving tool
Before writing those tests, zpekic needed a usable assembler. In the toolchain log, the creator reports being unable to find an application listing or ROM image to run. Rather than recover the original development system, zpekic adapted an existing two-pass microcode compiler. The EMZ1001A’s fixed eight-bit instruction encoding made that a workable foundation.
The Hello World program shows why understanding the instruction set matters as much as generating its bytes. Its LAI instruction loads an immediate value into the accumulator, but only the first LAI in an uninterrupted sequence executes. Subsequent LAIs behave as no-ops until another instruction resets the internal flag.
That sounds awkward until it becomes a compact table of subroutine entry points. The greeting code places several labeled LAI instructions in a row, each loading the low nibble of a different character. A call enters at the desired label; the later loads are ignored, and execution falls through to shared output code. In the example, this saves four jump instructions.
Meanwhile, the LED greeting uses stored segment patterns, refreshes them continuously, and rotates the RAM values once per second. “Hello World” is doing double duty here: it demonstrates output while checking an unusual piece of processor state.
Turning instruction variety into compact FPGA logic
The hardware recreation uses a similar economy. In the instruction-decode log dated December 26, 2022, zpekic groups instructions by the work they share rather than assigning a separate control-state operation to every mnemonic.
The resulting control word has three fields:
Together, these 12 bits drive the ALU, skip logic, and register-update process. JMP and JMS each occupy 64 opcodes because their encodings include a six-bit address. Instead of storing the same control word 64 times for each, the decoder selects fixed control fields for those two instruction groups. Only the other half of the opcode space needs the lookup entries.
The RAM implementation also adds a useful observation path: a separate debug read lets the VGA subsystem inspect memory alongside the processor’s normal read. That makes the tiny data store visible without asking the emulated program to print it out itself.
What runs, and what remains uncertain
The project describes a Mercury FPGA system running the greeting and Fibonacci demos with VGA, UART, and seven-segment LED output. A December 26 port to the smaller BaSys2 board removed the VGA subsystem because it would not fit, while retaining the processor and ROMs. It also required remapping the display segments and changing the reset controls—a reminder that moving a CPU core is only part of moving a complete demonstration system.
There are explicit fidelity limits. In the structure and timing log, zpekic describes the implementation as cycle accurate, but lists three exceptions as of December 20, 2022: BRK behaves as a no-op because its original behavior was unclear; the KREF function is not implemented; and the original ROM-output test mode is omitted. The suggested PWM-based approach to KREF is a possibility, not a completed feature.
The overview calls the code in the project repository fairly stable and complete. The later supplied October 2, 2024 log shares a separate hardware-tester video, but zpekic explicitly says little is known about that project; it does not establish new validation of this core.
What makes this recreation useful is the connection between architecture and observable behavior. The display loop exposes scheduling constraints, the greeting exposes LAI’s hidden state, and Fibonacci exposes arithmetic and memory handling. For anyone studying the design, those are strong starting points: follow a small program through the machine, then distinguish what it exercises from what still needs a targeted test.
