In the case of a C-instruction, the single a-bit determines whether the ALU will operate on the A register input or on the M input, and the six c-bits determine which function the ALU will compute.
I'm looking at the computer nemonic table fig 4.3 and you have one column, a=0, with computations such as D-A , D+A. And another column on the right, a=1, with computations such as D+M, D&M.
This has me a little confused because I would've though that if a=1, then the ALU will operate on the A register. But judging from the mnemonic table, it seems like the ALU operates on the A register if a=0.
Look at the CPU diagram. The ALU 'x' input (first argument) is D and the 'y' input (second argument) is the output of a Mux that selects between A and M. That Mux is what the 'a' bit in C-instructions controls.
Since you posted the diagram Cadet, I got another unrelated question about the A-register.
From what I understand, the A-register either reads the current value in the A register or writes the output of the MUX of Instruction and ALU output into the A register.
If that's the case, what would the control bit for the A register represent then? Would it also be the a-bit (i.e. instruction)? Because if a=0, then it means that you want to utilise the A register?
The 'a' bit only has meaning in c-instructions that read from M. It has noting to do with writing to M or writing to the A Register.
Remember the Register you wrote in project 3. It has 2 inputs: 'in' and 'load'. As you wrote, the multiplexor output is connected to the A Register input, so the control signal must be the A Register's 'load'.
The D Register's 'load' signal is simple, it needs to be true only during c-instructions that have the "D" dest bit set.
The A Register is trickier. Its 'load' needs to be true during c-instructions that have the "A" dest bit set, but 'load' also needs to be true during a-instructions so that the data in the instruction will be loaded into the A Register.
The "@1234" instruction needs to route the 1234 from 'instruction' through the left mux to the A Register input. C-instructions with "A=" need to route the ALU output through the left mux to the A Register input.
It does not hurt for the ALU output to go to the A Register input during c-instructions that don't write to A Register, so that simplifies to routing the ALU output to A Register during c-instructions.
The control signal (sel) for the left mux is just instruction, with instruction and ALUout connected appropriately to the mux's a and b inputs.
[It's past 2300 here and I need to be up around 0530, so I'm going to disappear for awhile...zzzz]