cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
vizziee
Participant
Participant
4,031 Views
Registered: ‎10-21-2009

Initial value for 48-bit counter on DSP48E

Hello,

 

I am trying to implement a 48-bit counter using DSP48E slice. My counter currently starts counting from zero. However, I want it to count from some other non-zero value. I couldn't find an attribute which could achieve this. I also wanted the counter to stop counting after a particular value and stay at that value till it gets reset (after the reset, it should again count from the non-zero value). Is it possible to achieve this using DSP48E slices only?

 

Regards,

 

Kumar Vijay Mishra.

Tags (2)
0 Kudos
Reply
1 Reply
ywu
Xilinx Employee
Xilinx Employee
4,013 Views
Registered: ‎11-28-2007

Take a look at the Counter example and pattern detect in UG193: http://www.xilinx.com/support/documentation/user_guides/ug193.pdf

 

You start with this simple equation P=P+C+CIN, you can create many different logic by changing the inputs:

 

To count from an initial value, first you reset the DSP48, then for the first cycle you set C=initial value, CIN=1, you then set C=0 and CIN=1 afterwards. To stop counting, you set C=0 and CIN=0.

Cheers,
Jim
0 Kudos
Reply