Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

JustAdy

5
Posts
1
Topics
1
Following
A member registered Jan 01, 2023 · View creator page →

Creator of

Recent community posts

(1 edit)

When I build a 512B RAM, the lag was bad.

If you want at least few hundred bytes of RAM and not run the simulation at 5 FPS, then I would recomend you use the software implementation.

1: Yes, I could have done the RAM like that, but i don't thing it matters which way you make it.

2: I modded it and made the chips smaller, but then wires look large. So now I use this modded version: https://itch.io/post/8412027

Sorry for taking so long. Here you go: https://www.mediafire.com/file/b9qah9skw0kb9ng/BEPMOC.zip/file

This is my 8bit computer i've been making now and then for few week. 

Its name is BEPMOC - 8bit easily programmable multi-output computer.

Here it's in an infinite loop counting up:

The four decimal outputs display data in RAM using the display instruction. 

The first and second HEX displays show whatever is on the CPU bus and the third is current RAM address(which addres is the computer currently accessing). 

They also show you what you're coding.


BEPMOC starts executing instruction on address 0x00 when the BOOT UP pin is pressed. This , inside the CPU, activates the clock.

This is the CPU:


It has three registers(A,B,C). ALU output is stored into R_C

The ALU can: add, subtract, AND, OR, NOT, XOR, <<, >>.

 It has a register for input B and a output register, which is copied in R_C.

The FLAGS chip gets ZERO, NEG, SUB flags(also Carry which is not used anywhere). 

Inside the chip is a comparator chip which uses the flags to get new flags(ZERO,  EQUALS,  LARGER, SMALLER), which are then passed to the Control Unit.

This is the CU:


The CU uses 4bit decoders to select operations. 

Operation chips use 4bit counter to step through subinstrctions(ENBL R_A, STR R_C, etc.), when they finish they send DONE signal to the Instruction counter and the NEXT INS chip, which retrieves next instruction from RAM.

Instructions are devided into two type: RAM accessing and not. 

Instructions which don't use RAM(0x00-0x0F) use only the second nibble. 

Instructions which use RAM(0x0X-0xFX(X=address)) use the first nibble for OP Code, and second for RAM address

The RAM is only 16Bytes 


(it was pain to make)


Instruction set (X=RAM address)

0x00ADD R_A R_B0x1XJUMP
0x01SUB R_A R_B
0x2XJUMP IF 0
0x02AND R_A R_B0x3XJUMP IF ==
0x03OR R_A R_B0x4XJUMP IF >
0x04XOR R_A R_B0x5XJUMP IF <
0x05NOT R_A0x6XMOV R_A RAM
0x06<< R_A0x7XMOV R_B RAM
0x07>> R_A0x8XMOV R_C RAM
0x08COMPARE R_A R_B0x9XMOV RAM R_A
0x09MOV R_A R_B0xAXMOV RAM R_B
0x0AMOV R_A R_C0xBXMOV RAM R_C
0x0BMOV R_B R_A0xCXDISPLAY ONTO DISPLAY 0
0x0CMOV R_B R_C0xDXDISPLAY ONTO DISPLAY 1
0x0DMOV R_C R_A0xEXDISPLAY ONTO DISPLAY 2
0x0EMOV R_C R_B0xFXDISPLAY ONTO DISPLAY 3
0x0FHALT

The limitation of this computer is its small RAM.