I know that don't cares mean that it doesn't matter whether it is a 0 or a 1 and when don't cares are just outputs I can kind of understand how they work. But I am having a really hard time understanding how they work when they are inputs.
I have read that when an input is a don't care the whole input doesn't count. But if one or more of the inputs no longer count then how do you make a k-map? Don't k-maps use the first two and latter two in a longitude latitude sort of way when you mark down the outputs?
Here is what I am currently working on:
inputs outputs A B C D | Q R S 0 0 0 0 | x x 0 0 0 0 1 | 0 0 1 0 0 1 x | 0 1 1 0 1 x x | 1 0 1 1 x x x | 1 1 1
my first attempt at making a k-map:
00 01 1X 0 X 0 0 0 1 1 0 X X 1 1 X
Then I was theorizing that if they don't count that means that the bit length is either shortened or the don't cares count as 1's or zeros if it is shortened I was thinking it is like this:
1XXX=1'b1 = 1 01XX=2'b01=1
but if that is true wouldn't
0 1 x x | 1 0 1 1 x x x | 1 1 1
not be like that and instead the out puts would be identical?
Or perhaps it is what I first thought and it's like:
0 1 x x | 1 0 1 means put an output in 5,6, and 7? Or maybe just 7?
Finally how do you mark things as don't care in the test bench? Do you even mark them at all? Is there a specific mark?