problem with division in vhdl code

Status
Not open for further replies.

velu.plg

Member level 5
Joined
Jul 30, 2013
Messages
93
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Location
chennai
Activity points
1,974
this my code.


error :line 49: Operator <DIVIDE> must have constant operands or first operand must be power of 2

how can i solve.
 

The synthesis has given you the answer. Xilinx doesnt support the divide operator when it cannot create a constant value or place a bit shift (as A/2^N is a bit shift).
You need to use the divider IP core.

Also: why is a an inout? A cannot be an inout because integer is not a resolved type, so your code is illegal.
 

    V

    Points: 2
    Helpful Answer Positive Rating
there is any other method available for division without using ip core?
 

Altera quartus will accept this code I think. but it just generates an IP code with 0 pipelining.

But in xilinx, I dont think so.
 
i have only spartan kit.

how can i display integer j (ex:123) in lcd display.
this j's function is
when switch on j=j+1;

give any idea.
 

You will need an LCD driver. I suggest reading up on the datasheet for the LCD module. A reference design that may have shipped with the board should show the LCD working.
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…