Entradas

Mostrando las entradas de diciembre, 2019

Using real data types in VHDL

Imagen
Using real data types in VHDL    Apart from the standard types like integer and std_logic_vector's VHDL also offer  real  data types. But a real data type has a big disadvantage. It is not synthesis-able. It can be used only for simulation purposes. This disadvantage limits its use to a large extend, but there are plenty of projects where we look only for simulation results.   Before starting the coding part of a VHDL project,one has to decide whether the project to be implemented on a real FPGA or just a computer simulation is required. If it has to be ran on FPGA, then forget about the real package and use only synthesis-able data types like std_logic,integer etc... Otherwise you can reduce the time and complexity of your project by using real data types. The real data type is defined in the library called  MATH_REAL . So you have to include the following line before the entity declaration in the code: use ieee.math_real.all; The math_real package also offers some elemen