Forum Discussion
Altera_Forum
Honored Contributor
11 years agoLookUp Tables
Hello, I want to implement sine and cosine signals in vhdl to check a part of my code but i don't know how to initialize these sin and cos signals? please tell me what is the way to do it?
i have read that it is possible through LUT but i don't know what LUT is ???12 Replies
- Altera_Forum
Honored Contributor
The wave screenshot posted above already shows a different problem than what you have reported initially. The negative values are not replaced with zeros anymore, rather you seem to be missing the sign bit this time. You need to inspect the values shown in the diagram to be able to tell what's happening - for example, what is the value at the peak of the sinusoid? For 16bit signed integer, your values in the LUT/MIF should be in the [-32768;+32767] interval, are they?
- Altera_Forum
Honored Contributor
--- Quote Start --- I did it, but it didn't fix my problem. --- Quote End --- your mif file is set to unsigned radix but the data ia signed so keep it signed and change radix in mif file to signed