--- Quote Start ---
You should get as you say 1,4,12,28,64,... try use signed type instead of full width integer.
The code is direct translation of your diagram so it must work. You have some strange initial values on y1,y2...what are those?
--- Quote End ---
The strange value assigned at my debug variables is because i don't assign a standard value when i write out port..
so it assign the first value that is..-(2^32)-1, when i impose a value y1 or y2 they become these numer. At the begin i'm expected 0.. but i note that when i use for the first time alter compiler..
So i haven't use the signed type before.. what type i must use??? can you write me something example..
and you can tell me why the scale of
subtype bits11 is integer range -1023 to 1024; -- 11 bit when i define variable like...
a: bits11; if i don't impose the default value they are initializated to least value and not to zero.
so.. thank you!:rolleyes: