4BoD: Difference between revisions

From Fantasy Console Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 13: Line 13:
Instructions set (from)
Instructions set (from)


<code>
    OP  |A  |B  |Description
OP  |A  |B  |Description
    0000          - NOP
0000          - NOP
    0001 AAAA      - Sets the accumulator to the value stored at memory position A
 
    0010 AAAA      - Sets memory position A to the value stored in the accumulator
0001 AAAA      - Sets the accumulator to the value stored at memory position A
    0011 AAAA      - Sets the accumulator to A
0010 AAAA      - Sets memory position A to the value stored in the accumulator
    0100          - Sets the accumulator to the buttons that have been pressed
0011 AAAA      - Sets the accumulator to A
              - Ones place = left button
0100          - Sets the accumulator to the buttons that have been pressed
              - Twos place = right button
          - Ones place = left button
              - Fours place = up button
          - Twos place = right button
              - Eights place = down button
          - Fours place = up button
    0101          - Increments the accumulator (Do this 15 times to make a subtraction by overflow)
          - Eights place = down button
    0110          - Clears the screen
0101          - Increments the accumulator (Do this 15 times to make a subtraction by overflow)
    0111          - Shifts the accumulator left
 
    1000          - Shifts the accumulator right
0110          - Clears the screen
    1001 AAAA BBBB - Sets the accumulator to pixel position memory A, memory B
0111          - Shifts the accumulator left
    1010 AAAA BBBB - Flips pixel position memory A, memory B
1000          - Shifts the accumulator right
    1011 AAAA      - Sets a flag called A (Flag 15 is reserved, if you jump to it the program ends)
1001 AAAA BBBB - Sets the accumulator to pixel position memory A, memory B
    1100 AAAA      - Jumps to flag memory position A
1010 AAAA BBBB - Flips pixel position memory A, memory B
    1101 AAAA      - Only perform next action if memory position A is equal to the accumulator
 
    1110 AAAA      - Only perform next action if memory position A is greater than the accumulator
1011 AAAA      - Sets a flag called A (Flag 15 is reserved, if you jump to it the program ends)
    1111 AAAA      - Only perform next action if memory position A is less than the accumulator
1100 AAAA      - Jumps to flag memory position A
 
1101 AAAA      - Only perform next action if memory position A is equal to the accumulator
1110 AAAA      - Only perform next action if memory position A is greater than the accumulator
1111 AAAA      - Only perform next action if memory position A is less than the accumulator
</code>


[[Category:Fantasy consoles]]
[[Category:Fantasy consoles]]
[[Category:4 bit consoles]]
[[Category:4 bit consoles]]

Revision as of 06:23, 19 March 2023

Logo

4BoD (4 Bits of DOOM) is a hyper-minimalist fantasy console inspired by Milton Bradley Microvision. It was created as an entry for FC Dev jam by puarsliburf games in 2017.

Capabilities

Program memory: 3072b (256 12-bit instructions).
RAM: 16 nibbles (64b).
Screen: 16x16 (1:1) 1-bit.
Instruction set: 16 instructions.
Sounds: no.

Instruction Set

Instructions set (from)

   OP  |A   |B   |Description
   0000           - NOP
   0001 AAAA      - Sets the accumulator to the value stored at memory position A
   0010 AAAA      - Sets memory position A to the value stored in the accumulator
   0011 AAAA      - Sets the accumulator to A
   0100           - Sets the accumulator to the buttons that have been pressed
   	          - Ones place = left button
   	          - Twos place = right button
   	          - Fours place = up button
   	          - Eights place = down button
   0101           - Increments the accumulator (Do this 15 times to make a subtraction by overflow)
   0110           - Clears the screen
   0111           - Shifts the accumulator left
   1000           - Shifts the accumulator right
   1001 AAAA BBBB - Sets the accumulator to pixel position memory A, memory B
   1010 AAAA BBBB - Flips pixel position memory A, memory B
   1011 AAAA      - Sets a flag called A (Flag 15 is reserved, if you jump to it the program ends)
   1100 AAAA      - Jumps to flag memory position A
   1101 AAAA      - Only perform next action if memory position A is equal to the accumulator
   1110 AAAA      - Only perform next action if memory position A is greater than the accumulator
   1111 AAAA      - Only perform next action if memory position A is less than the accumulator