- #1
user101
- 207
- 0
Hi all, I have the following code:
where checkHR and checkMIN are 8 bit vectors (7 downto 0)... and SECL, SECH, MINL, MINH, HRL, and HRH are all 4 bit vectors (3 downto 0).
What I'm trying to do is check to see if the first four bits of checkHR is equal to HRH.
Can someone tell me what's wrong? I'm getting the error: Line 74. = can not have such operands in this context.
if (checkHR(7 downto 4) = HRH) and (checkHR(3 downto 0) = HRL)
and (checkMIN(7 downto 4) = MINH) and (checkMIN(3 downto 0) = MINL) then
SECL <= "0000";
SECH <= "0000";
MINL <= "1000"; -- set to 8888 to notify alarm has been set
MINH <= "1000"; -- set to 8888 to notify alarm has been set
HRL <= "1000"; -- set to 8888 to notify alarm has been set
HRH <= "1000"; -- set to 8888 to notify alarm has been set
where checkHR and checkMIN are 8 bit vectors (7 downto 0)... and SECL, SECH, MINL, MINH, HRL, and HRH are all 4 bit vectors (3 downto 0).
What I'm trying to do is check to see if the first four bits of checkHR is equal to HRH.
Can someone tell me what's wrong? I'm getting the error: Line 74. = can not have such operands in this context.