Close

figFORTH in ROM

A project log for MIKBUG on Multicomp

MIKBUG Running on Multicomp with 6800 CPU

land-boardscomland-boards.com 04/27/2022 at 14:550 Comments

Replace SmithBUG with FigForth ROM

figFORTH can be loaded into ROM in the build instead of the SmithBUG ROM. The reset vector has to point to the FigForth COLD Start.

Memory Map

0x0000-0x0FFF - 4KB SRAM
0x1000-0x2FFF - 6K ROM (using 8KB entity, but only using 6KB)
0x3000-0x3FFF - 4KB SRAM
0x4000-0x7FFF - 16KB SRAM
0xFC00-0xFCFF - I/O Space
0xFFFE-0xFFFF - ROM start vector (physically top of the 8KB ROM)

Assemble

Assemble fig-Forth code using A68 Assembler.

"..\..\A68 6800 Assembler\a68.exe" fig-FORTH_6800.asm -l fig-FORTH_6800.lst -s fig-FORTH_6800.s

Manually delete top lines in S record file. After deleting, top lines should be:

S1131000017E1FA3017E1FD3680000000000007F43
S113101001000F300FFE0F30001F00000183018319

This matches the source:

   1000   01            ORIG    nop
   1001   7e 1f a3          jmp    CENT
                        ;**************************
                        ;*  W A R M   E N T R Y  **
                        ;**************************
   1004   01                nop
   1005   7e 1f d3          jmp    WENT    ;warm-sta a rt code, keeps current dictionary intact

Use srec_cat to shift addresses down and make Hex file:

srec_cat fig-FORTH_6800.s -offset - -minimum-addr fig-FORTH_6800.s -o fig-FORTH_6800.hex -Intel

Clone FPGA Folder

Archived M6800_MIKBUG_20220427.qar the project as it currently is since it's working well, as-is. Put into new folder and set new entity name (M6800_figForth). Tested as-is and it built/worked.

Update FPGA Entity

Bunch of stuff to do.

w_SRAMAdr_1 <= '1'     when  w_cpuAddress(15 downto 12) = x"0" else
           '0';
w_SRAMAdr_2 <= '1'     when  w_cpuAddress(15 downto 12) = x"3" else
           '0';
w_SRAMAdr_3 <= '1'     when  w_cpuAddress(15 downto 14) = "01" else
           '0';
w_ROMAdr    <= '1'    when    w_cpuAddress(15 downto 12) = x"1" else
           '1'    when    w_cpuAddress(15 downto 12) = x"2" else
           '0';

Create FPGA .jic file and Download

Runs!!!

Saved M6800_FigForth_20220427.qar archive file.

Issues

Output looks good on Serial port, but tabbed? over in VDU.

Discussions