i have a constant value let A:=9
now i have to convert into digital form...
as we know in digital we can write this 00000000000000000000000000001001 for 32 bit data...
another example i have A:=34
we can write this 00000000000000000000000100010
i want this type of conversion (any number into 32 bit vector form)in VHDL...
please help me out..its too urgent
yes u r right...thanks...
may be my understanding is not that good, but those who are good in any area they wont underestimate others..
i m accepting m not good in vhdl...but this is not a way to treat to beginner...
It is only possible to control the 31 lowest bits with to_unsigned() since it takes a natural as argument, and the tools normally restrict this to 31 bits.
Higher bits will be '0'.
It doesn't work with the Modelsim simulator. The maximum argument for to_unsigned() is 2147483647. This is also the expected behavior for all VHDL implementations that use 32 bits for the integer type (31 bits for type natural).
(the forum has lost all posts since yesterday, so some earlier posts in this thread has been lost)