Forum Discussion
Altera_Forum
Honored Contributor
14 years agocomparator with memory
Hello, I'm starting with vhdl, and i'm try to write any kind of comaprator with memory of the out signal. Can anyboidy help me.. Program have to check state of input from keypad (ps2) and chec...
Altera_Forum
Honored Contributor
14 years ago --- Quote Start --- when the input signal isn't signal of keypad i have 0 ont the out... --- Quote End --- That's correct. The process you wrote indeed makes this. Infact every time the process runs (when 'in' changes), you assign li1 := "00000000"; li2 := "00000000"; then, whenever the 'if' condition is not fulfilled (namely when signal is not from keypad) your output keeps this zero status. If your code is supposed to hold the last keypad code on 'out' as long as a non-keypad code is received, simply remove these 2 lines.