VHDL

Using SIGNED & UNSIGNED Types



SIGNED and UNSIGNED types are provided in the std_logic_arith, numeric_std, and numeric_bit packages in the ieee library.

UNSIGNED types represent unsigned numerical values, which can be positive or zero only. The Compiler interprets each UNSIGNED type as a binary number, with the digit on the left as the MSB. Example

SIGNED types represent signed numerical values, which can be positive, zero, or negative. The Compiler interprets each SIGNED type as a two's complement binary representation; the leftmost bit indicates whether the value is positive or negative. Example


Back to Top

- PLDWorld -

 

Created by chm2web html help conversion utility.