Just in case your question is still unanswered - 1'b1 is a format specified numeric with these rules: 1 is the size, 1-bit ' is the apostrophe b is the type, binary 1 is the value, which is 1 So, it means "A 1-bit, binary number, that is the value 1" Another example would be 4'b0101 (4-bits specified in binary) or 16'd255 (16-bits specified in decimal). The case statement… unique case (1'b1) state[0]: f = 0; state[1]: f = 1; state[2]: f = 2; state[3]: f = 3; endcase …means "case (binary 1)" to match against a binary 1 instead of decimal 1. It's done this way because state is a 4-bit vector defined as `input [3:0] state` above. Since it's 4-bits, each index is either on or off - 1 or 0 binary. We're just checking if each state index is on or off, the binary 1 or 0. If a state's value is 1 it matches the case and executed. I didn't mean to over-explain, I just wanted anyone to be able to read this and understand. I hope that helps!
Very precise and relevant use of technical words in explaination. Less scope for confusion. Thanks for sharing.
Great video ! Clear and well paced. Thank you very much !
very helpful... Thanks:) ... Can you upload one video teaching all the constructs?
very interesting, great contribution
what does 1'b1 means at 17:45? thanks
Just in case your question is still unanswered -
1'b1 is a format specified numeric with these rules:
1 is the size, 1-bit
' is the apostrophe
b is the type, binary
1 is the value, which is 1
So, it means "A 1-bit, binary number, that is the value 1"
Another example would be 4'b0101 (4-bits specified in binary) or 16'd255 (16-bits specified in decimal).
The case statement…
unique case (1'b1)
state[0]: f = 0;
state[1]: f = 1;
state[2]: f = 2;
state[3]: f = 3;
endcase
…means "case (binary 1)" to match against a binary 1 instead of decimal 1.
It's done this way because state is a 4-bit vector defined as `input [3:0] state` above. Since it's 4-bits, each index is either on or off - 1 or 0 binary.
We're just checking if each state index is on or off, the binary 1 or 0. If a state's value is 1 it matches the case and executed.
I didn't mean to over-explain, I just wanted anyone to be able to read this and understand. I hope that helps!
Thank You Sir! Helped a lot! :)