real numbers or integer to binary in vhdl

H

hari

Guest
hi
i would like to know how to covert real numbers or integer to 16 bit
binary in vhdl.do we have any default funtions for that

thanks
hariprasath
 
Have a look at:
http://www.eda.org/fphdl/

Egbert Molenkamp

"hari" <hari_pro@yahoo.com> schreef in bericht
news:a4a587f1.0404230602.38ad9803@posting.google.com...
hi
i would like to know how to covert real numbers or integer to 16 bit
binary in vhdl.do we have any default funtions for that

thanks
hariprasath
 
Hi Hari,
If you numeric_std package, you could do:

my_unsigned := to_unsigned(my_integer, 16);


You can cast it to a std_logic_vector, if need be.

HTH,
Ajeetha,
http://www.noveldv.com
Co-Author: Using PSL/SUGAR for Formal and Dynamic Verification 2nd Edition.

hari_pro@yahoo.com (hari) wrote in message news:<a4a587f1.0404230602.38ad9803@posting.google.com>...
hi
i would like to know how to covert real numbers or integer to 16 bit
binary in vhdl.do we have any default funtions for that

thanks
hariprasath
 

Welcome to EDABoard.com

Sponsor

Back
Top