Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to express 1.164 and 0.392 in Binary?

Status
Not open for further replies.

EDA_hg81

Advanced Member level 2
Advanced Member level 2
Joined
Nov 25, 2005
Messages
507
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,298
Activity points
4,808
1.164 and 0.392 are constants.

How can I express them in Binary for using in FPGA?

Thanks.
 

1.164 dec = 1.00101001111110111110011 bin
0.392 dec = 0.01100100010110100001110 bin

I did it with 23 binary digit after binary point and these binary values don´t give you the decimal number exactly (1.16399999708 and 0.39199999720).
 

    EDA_hg81

    Points: 2
    Helpful Answer Positive Rating
if you want to manipulate fixed-point values in FPGA you should check out IEEE.Fixed_Pkg from **broken link removed** it's a proposed implementation of fixed-point arithmetic for next ieee standard in VHDL, the library has some problems compiling under XST (Xilinx ISE, I don't know how 10.1 version of ISE works with this package) but works preaty nice with Precision from Mentor
 

    EDA_hg81

    Points: 2
    Helpful Answer Positive Rating
Thank your reply.

this really helped me.
 

if you doing color space conversion, I would strongly recomend google it for proper constants integer , if you are just looking at Xilinx app notes it is not enough

good lack
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top