Guest
Hi all,
I am using float package of David Bishop.
I want to see value of -1.5129E-15 i.e. (-1.5129)*10^(-15).
I have written the program mentioned below.
Modelsim is returning error saying :
"Negative exponents not allowed with integers." at the line
z <= to_float((-1.5129)*10**(-15)) ;
What is the mistake I am making ?
Thanks
Ravinder Chaudhry
library IEEE,WORK;
use IEEE.STD_LOGIC_1164.all;
use IEEE.NUMERIC_STD.all;
use work.float_pkg.all;
entity value_test1 is
port(
a,b : in float(5 downto -10);
c : out float(5 downto -10)
);
end entity;
architecture behv of value_test1 is
signal z : float32;
begin
z <= to_float((-1.5129)*10**(-15)) ;
end behv;
-- A6DA0829
I am using float package of David Bishop.
I want to see value of -1.5129E-15 i.e. (-1.5129)*10^(-15).
I have written the program mentioned below.
Modelsim is returning error saying :
"Negative exponents not allowed with integers." at the line
z <= to_float((-1.5129)*10**(-15)) ;
What is the mistake I am making ?
Thanks
Ravinder Chaudhry
library IEEE,WORK;
use IEEE.STD_LOGIC_1164.all;
use IEEE.NUMERIC_STD.all;
use work.float_pkg.all;
entity value_test1 is
port(
a,b : in float(5 downto -10);
c : out float(5 downto -10)
);
end entity;
architecture behv of value_test1 is
signal z : float32;
begin
z <= to_float((-1.5129)*10**(-15)) ;
end behv;
-- A6DA0829