正在加载图片...
优先级:not的优先级最高,其它6个逻辑运算符的优先级相同 VHDL中左右没有优先级差别。 q<= a and b or not c and d 应为:q<=( a and b)or( notc and d; 注意: 使用逻辑运算符时允许在一个表达式中出现两个或两个以上and运算符而不加括号; 0r、xOr、nor的规定与and相同; 不允许一个表达式中出现两个或连个以上nand和xnor而不加括号 例 g<=a and b and c and d; g<= a or b or c or d; q<= a xor b xor c xor d; g<= a nand b and c and d;优先级:not的优先级最高,其它6个逻辑运算符的优先级相同; q <= a and b or not c and d; 应为: q <= (a and b) or (not c and d); VHDL中左右没有优先级差别。 注意: 使用逻辑运算符时允许在一个表达式中出现两个或两个以上and运算符而不加括号; or、xor、nor的规定与and相同; 不允许一个表达式中出现两个或连个以上nand和xnor而不加括号。 例: q<= a and b and c and d; q<= a or b or c or d; q<= a xor b xor c xor d; q<= a nand b and c and d;
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有