|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.github.croesch.micro_debug.mic1.mpc.NextMPCCalculator
public final class NextMPCCalculator
This class represents a calculator for the next micro-program-counter (MPC). It is based on the verilog code for 'calculation of MPC' in the script of the lecture 'Rechnertechnik' of Karl Stroetmann.
| Constructor Summary | |
|---|---|
NextMPCCalculator()
|
|
| Method Summary | |
|---|---|
void |
calculate()
Performs calculation of the output signals based on the current values of input signals. |
int |
getMpc()
Returns the calculated 9-bit-value. |
void |
setAddr(int newAddr)
Sets the value of the Addr (MIR[35:27]). |
void |
setJmpC(boolean jmpCValue)
Sets the value of the JMPC (MIR[26]). |
void |
setJmpN(boolean jmpNValue)
Sets the value of the JMPN (MIR[25]). |
void |
setJmpZ(boolean jmpZValue)
Sets the value of the JMPZ (MIR[24]). |
void |
setMbr(byte mbrValue)
Sets the value of the register MBR. |
void |
setN(boolean nValue)
Sets the value of the N - value fetched from the ALU. |
void |
setZ(boolean zValue)
Sets the value of the Z - value fetched from the ALU. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public NextMPCCalculator()
| Method Detail |
|---|
public void calculate()
public int getMpc()
public void setMbr(byte mbrValue)
mbrValue - the byte fetched from the register MBRpublic void setAddr(int newAddr)
newAddr - the value of the Addr fetched from the current control wordpublic void setJmpC(boolean jmpCValue)
jmpCValue - the value of JMPC fetched from the current control wordpublic void setJmpN(boolean jmpNValue)
jmpNValue - the value of JMPN fetched from the current control wordpublic void setJmpZ(boolean jmpZValue)
jmpZValue - the value of JMPZ fetched from the current control wordpublic void setN(boolean nValue)
nValue - the value of N, fetched from the ALUpublic void setZ(boolean zValue)
zValue - the value of Z, fetched from the ALU
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||