Did some renaming and added some more functionality to ALU

This commit is contained in:
2022-05-04 11:46:38 +02:00
parent b41f999323
commit 66cb839f87
3 changed files with 86 additions and 40 deletions

View File

@ -2,7 +2,7 @@ module PC.Types exposing (..)
import Array exposing (Array)
pcModelVersion = "3"
pcModelVersion = "4"
type alias PC_Model =
{ pc : PC
@ -26,21 +26,29 @@ type alias UCode =
, label : String
}
-- UActions that can be used in µCode
type UAction
= UA_Accumulator2DataBus
| UA_AccumulatorDecrement
| UA_AccumulatorIncrement
= UA_ALU_Accumulator2DataBus
| UA_ALU_AccumulatorDecrement
| UA_ALU_AccumulatorIncrement
| UA_ALU_AccumulatorShiftLeftByDataBus
| UA_ALU_AccumulatorShiftRightByDataBus
| UA_ALU_AccumulatorAddByDataBus
| UA_ALU_AccumulatorSubtractByDataBus
| UA_ALU_AccumulatorMultiplyByDataBus
| UA_ALU_AccumulatorDivideByDataBus
| UA_CU_InstructionReg2AddressBus
| UA_CU_InstructionReg2DataBus
| UA_CU_InstructionReg2ProgrammCounter
| UA_CU_InstructionReg2UCounter
| UA_CU_ProgrammCounterIncrement
| UA_CU_InstructionReg2ProgrammCounterIfAccEq0
| UA_CU_ProgrammCounter2AddressBus
| UA_CU_ResetUCounter
| UA_DataBus2Accumulator
| UA_DataBus2InstructionReg
| UA_DataBus2Ram
| UA_InstructionReg2AddressBus
| UA_InstructionReg2ProgrammCounter
| UA_InstructionReg2UCounter
| UA_ProgrammCounterIncrement
| UA_InstructionReg2ProgrammCounterIfAccEq0
| UA_Ram2DataBus
| UA_ResetUCounter
| UA_ProgrammCounter2AddressBus
| UA_AlertUser
| UA_Nothing