signed(12 downto 0) to signed (8 downto 0)

Joined
Oct 14, 2007
Messages
3
Reaction score
0
Hi!

In my code i have register which is std_logic_vector(12 downto 0). The register contains signed result which i need to divide by 2 so it can be fidded to std_logic_vector(8 downto 0). I mean that i make the resolution worse and take only the the higher bits of register(and copy the MSB-bit to needed places to fulfill 2´compliment). That kind of code is really easy to make working in simulators but there other thing is to make it work in design vision for making ASIC. Now i am looking for ready-function from libraries to make it happen. Is there a function which skips as many bits as i want and copys sign-bit all necessery places??
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top