questions about outM

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

questions about outM

becauseof86
CPU.cmp
|time| inM  |  instruction   |reset| outM  |writeM |addre| pc  |DRegiste|
|0+  |     0|0011000000111001|  0  |*******|   0   |    0|    0|      0 |
|1   |     0|0011000000111001|  0  |*******|   0   |12345|    1|      0 |
|1+  |     0|1110110000010000|  0  |*******|   0   |12345|    1|  12345 |
|2   |     0|1110110000010000|  0  |*******|   0   |12345|    2|  12345 |
|2+  |     0|0101101110100000|  0  |*******|   0   |12345|    2|  12345 |
|3   |     0|0101101110100000|  0  |*******|   0   |23456|    3|  12345 |
|3+  |     0|1110000111010000|  0  |*******|   0   |23456|    3|  11111 |
|4   |     0|1110000111010000|  0  |*******|   0   |23456|    4|  11111 |
|4+  |     0|0000001111101000|  0  |*******|   0   |23456|    4|  11111 |
|5   |     0|0000001111101000|  0  |*******|   0   | 1000|    5|  11111 |

my CPU.out
|time| inM  |  instruction   |reset| outM  |writeM |addre| pc  |DRegiste|
|0+  |     0|0011000000111001|  0  |      0|   0   |    0|    0|      0 |
|1   |     0|0011000000111001|  0  |      0|   0   |12345|    1|      0 |
|1+  |     0|1110110000010000|  0  |  12345|   0   |12345|    1|  12345 |
|2   |     0|1110110000010000|  0  |  12345|   0   |12345|    2|  12345 |
|2+  |     0|0101101110100000|  0  |  12345|   0   |12345|    2|  12345 |
|3   |     0|0101101110100000|  0  |   4128|   0   |23456|    3|  12345 |
|3+  |     0|1110000111010000|  0  |  11111|   0   |23456|    3|  11111 |
|4   |     0|1110000111010000|  0  |  12345|   0   |23456|    4|  11111 |
|4+  |     0|0000001111101000|  0  |   2848|   0   |23456|    4|  11111 |
|5   |     0|0000001111101000|  0  |    864|   0   | 1000|    5|  11111 |

the outM are different
when the writeM is 0,the outM should be *******
but I just connect the outM to ALU output.I just do not know how to make the outM ********
somebody helps me,thanks
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: questions about outM

cadet1620
Administrator
"***" in the .cmp file means "don't care". The HardwareSimulator ignores your outM value when writeM is 0.

The reason that outM needs to be ignored when writeM is 0 is that the output of the ALU is connected directly to writeM in most students' CPUs, but the ALU control signals are undefined during A-instructions.

--Mark
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: questions about outM

becauseof86
thanks, I get it
Loading...