ASS #1

Eric Wei (ewei@physics.ubc.ca) Sun, 30 Jan 2000 02:41:52 -0800


From: "Eric Wei" <ewei@physics.ubc.ca>
Subject: ASS #1
Date: Sun, 30 Jan 2000 02:41:52 -0800


Nice to know someone is having a headache over this =) I'll try my best to answer some of your question. > Why is the button 10-bits when the numbers 0 to 9 only need 4-bits? We are assuming that it's a keypad with 10 buttons each linked to a pin on the Altera chip. We can, however, build a decoder that decodes the input into a 4 bit representation but I think there is more hassle doing it that way. I rather work with the 10 bit input. > Also, the last test case says two buttons are pushed at exactly the same > time. What kind of input will this create. Can you give an example? ie. > input 5 = "0000000101" and 6 = "0000000110" at the same time gives what > for the 10-bit button? Say for my last number, I pushed 7 and 4 at the same time. The output I'll get is "0010010000". Each bit that is "high" represents the paticular being pushed. In my example, I am assuming that the MSB is 9 and LSB is 0. Or "9876543210" corresponds to each bit in the 10-bit vector. > How do you tell when the a number is entered? The button is a 10-bit > vector that represents the number but how do you tell when it is entered > if entry doesn't happen once per clock cycle. Shouldn't there be a input > signal bit equivalent to the 224H port in the second lab? How do you > tell the difference between entering 2 equal numbers, one after the > other, without this? say, when 9 is entered, you'll get "1000000000" (assuming 9 is the MSB in the bit vector). When 5 is entered, you'll get "0000100000". As for clocking, I am just as confused as you are... can't say much about it. ----- Original Message ----- From: "Shawn O'Neill" <Shawn_ONeill@telus.net> To: <eece379@casas2.ece.ubc.ca> Sent: Sunday, January 30, 2000 2:41 AM Subject: Ass#1