Searched Projects

Tags: Test Computer

project.name
2 Stars     363 Views

Computer Exponential Code Demo

Computer Exponential Code Demo

A Computer. Kind of.

The 256-Series, my new collection of simulated computers: https://circuitverse.org/users/4699/projects/256-series

This version is setup to demonstrate a program that puts input A to the power of input B This version has been specifically modified to make demonstrating the program easier. This was done by making operand A for the first two instructions depend on user input, which allows the user to easily test the program with different values. Note: X^0 does not work due to the fact the the output value (address 5) is never written to. 

The code is as follows:

00: LOAD Input A into Address 00

01: LOAD Input B into Address 01

02: LOAD1F into Address 02

03: XOR Addresses 00 and 02

04: LOAD XOR Result into Address 03

05: XOR Addresses 01 and 02

06: LOAD XOR Result into Address 04

07: LOAD 01 into 00

08: LOAD 00 into 08

09: LOAD 01 into 02

0A: LOAD 01 into 06

0B: ADD 04 and 06

0C: IF ADD Result = 00, GOTO 1B, ELSE GOTO 0D

0D: LOAD 00 into 05

0E: LOAD 01 into 07

0F: ADD Addresses 03 and 07

10: IF ADD Result = 00, GOTO 16, ELSE GOTO 11

11: ADD Addresses 00 and 05

12: LOAD ADD Result into 05

13: ADD 02 and 07

14: LOAD ADD Result into 07

15: GOTO 0F

16: ADD 02 and 06

17: LOAD ADD Result into 06

18: ADD 05 and 08

19: LOAD ADD Result into 00

1A: GOTO 0C

1B: RETURN Address 05

Features:

32-Bits of 5-bit RAM,

32 Lines for Instructions,

ADD, AND and XOR Functions.

Go To Functionality

Can do IF = Statements

OP Codes:

0000 = Nothing

0001 VVVVV AAAAA = LOAD VVVVV into address AAAAA

0010 AAAAA 00000 = LOAD Add result into address AAAAA

0011 DDDDD VVVVV = ADD DDDDD and VVVVV together

0100 AAAAA BBBBB = ADD address AAAAA and address BBBBB together

0101 DDDDD VVVVV = AND DDDDD and VVVVV together

0110 AAAAA BBBBB = AND address AAAAA and address BBBBB together

0111 DDDDD VVVVV = XOR DDDDD and VVVVV together

1000 AAAAA BBBBB = XOR address AAAAA and BBBBB together

1001 AAAAA 00000 = LOAD AND result into address AAAAA

1010 AAAAA 00000 = LOAD XOR result into address AAAAA

1011 AAAAA 00000 = GOTO address AAAAA (in instruction memory) 

1100 AAAAA BBBBB = If add result = 0 (ignoring carry), GOTO address AAAAA else go to address BBBBB (in instruction memory)

1101 VVVVV 00000 = Return VVVVV (Stops the program)

1110 AAAAA 00000 = Return the value at address AAAAA (Stops the program)

1111 = Nothing


project.name
0 Stars     173 Views

Computer Add Auto

Computer Add Auto

A Computer. Kind of.

The 256-Series, my new collection of simulated computers: https://circuitverse.org/users/4699/projects/256-series

This version is setup to demonstrate a program that adds two numbers together. This version has been specifically modified to make demonstrating the program easier. This was done by making operand A for the first two instructions depend on user input, which allows the user to easily test the program with different values. 

The code is as follows:

00: LOAD Input A into Address 00

01: LOAD Input B into Address 01

02: ADD Addresses 00 and 01

03: LOAD ADD Result into 02

04: RETURN Address 02

Features:

32-Bits of 5-bit RAM,

32 Lines for Instructions,

ADD, AND and XOR Functions.

Go To Functionality

Can do IF = Statements

OP Codes:

0000 = Nothing

0001 VVVVV AAAAA = LOAD VVVVV into address AAAAA

0010 AAAAA 00000 = LOAD Add result into address AAAAA

0011 DDDDD VVVVV = ADD DDDDD and VVVVV together

0100 AAAAA BBBBB = ADD address AAAAA and address BBBBB together

0101 DDDDD VVVVV = AND DDDDD and VVVVV together

0110 AAAAA BBBBB = AND address AAAAA and address BBBBB together

0111 DDDDD VVVVV = XOR DDDDD and VVVVV together

1000 AAAAA BBBBB = XOR address AAAAA and BBBBB together

1001 AAAAA 00000 = LOAD AND result into address AAAAA

1010 AAAAA 00000 = LOAD XOR result into address AAAAA

1011 AAAAA 00000 = GOTO address AAAAA (in instruction memory) 

1100 AAAAA BBBBB = If add result = 0 (ignoring carry), GOTO address AAAAA else go to address BBBBB (in instruction memory)

1101 VVVVV 00000 = Return VVVVV (Stops the program)

1110 AAAAA 00000 = Return the value at address AAAAA (Stops the program)

1111 = Nothing


project.name
1 Stars     307 Views

Test Computer

Test Computer

A Computer. Kind of.

The 256-Series, my new collection of simulated computers: https://circuitverse.org/users/4699/projects/256-series

Note: It is causes lag, particularly the 14-Bit Instruction Memory.

Features:

32-Bits of 5-bit RAM,

32-Bits of 12-bit instruction RAM (able to write 32 instructions in a program),

ADD, AND and XOR Functions.

The Run button is near the Clock on the left of main, the Output is on the far right.

OP Codes:

0000 = Nothing

0001 VVVVV AAAAA = LOAD VVVVV into address AAAAA

0010 AAAAA 00000 = LOAD Add result into address AAAAA

0011 DDDDD VVVVV = ADD DDDDD and VVVVV together

0100 AAAAA BBBBB = ADD address AAAAA and address BBBBB together

0101 DDDDD VVVVV = AND DDDDD and VVVVV together

0110 AAAAA BBBBB = AND address AAAAA and address BBBBB together

0111 DDDDD VVVVV = XOR DDDDD and VVVVV together

1000 AAAAA BBBBB = XOR address AAAAA and BBBBB together

1001 AAAAA 00000 = LOAD AND result into address AAAAA

1010 AAAAA 00000 = LOAD XOR result into address AAAAA

1011 AAAAA 00000 = GOTO address AAAAA (in instruction memory) 

1100 AAAAA BBBBB = If add result = 0 (ignoring carry), GOTO address AAAAA else go to address BBBBB (in instruction memory)

1101 VVVVV 00000 = Return VVVVV (Stops the program)

1110 AAAAA 00000 = Return the value at address AAAAA (Stops the program)

1111 = Nothing


project.name
0 Stars     321 Views

Computer Multiply Code Demo

Computer Multiply Code Demo

A Computer. Kind of.

The 256-Series, my new collection of simulated computers: https://circuitverse.org/users/4699/projects/256-series

This version is setup to demonstrate a program that multiplies two numbers together. This version has been specifically modified to make demonstrating the program easier. This was done by making operand A for the first two instructions depend on user input, which allows the user to easily test the program with different values. 

The code is as follows:

00: LOAD Input A into Address 00

01: LOAD Input B into Address 01

02: LOAD 1F into Address 02

03: XOR Addresses 01 and 02

04: LOAD XOR Result into Address 01

05: LOAD 01 into Address 02

06: ADD Addresses 01 and 02

07: LOAD ADD Result into 01

08: LOAD 00 into Address 03

09: LOAD 00 into Address 04

0A: ADD 01 and 04

0B: IF ADD Result = 00, Go To 12, ELSE GOTO 0C

0C: ADD Addresses 00 and 03

0D: LOAD ADD Result into Address 03

0E: ADD Addresses 02 and 04

0F: LOAD ADD Result into Address 04

10: ADD Addresses 01 and 04

11: GOTO 0B

12: RETURN Address 03

Features:

32-Bits of 5-bit RAM,

32 Lines for Instructions,

ADD, AND and XOR Functions.

Go To Functionality

Can do IF = Statements

OP Codes:

0000 = Nothing

0001 VVVVV AAAAA = LOAD VVVVV into address AAAAA

0010 AAAAA 00000 = LOAD Add result into address AAAAA

0011 DDDDD VVVVV = ADD DDDDD and VVVVV together

0100 AAAAA BBBBB = ADD address AAAAA and address BBBBB together

0101 DDDDD VVVVV = AND DDDDD and VVVVV together

0110 AAAAA BBBBB = AND address AAAAA and address BBBBB together

0111 DDDDD VVVVV = XOR DDDDD and VVVVV together

1000 AAAAA BBBBB = XOR address AAAAA and BBBBB together

1001 AAAAA 00000 = LOAD AND result into address AAAAA

1010 AAAAA 00000 = LOAD XOR result into address AAAAA

1011 AAAAA 00000 = GOTO address AAAAA (in instruction memory) 

1100 AAAAA BBBBB = If add result = 0 (ignoring carry), GOTO address AAAAA else go to address BBBBB (in instruction memory)

1101 VVVVV 00000 = Return VVVVV (Stops the program)

1110 AAAAA 00000 = Return the value at address AAAAA (Stops the program)

1111 = Nothing