The problem seems to occur in the output function and the lagged y values but I can't seem to figure out why (the a/b coefs are calculating to valid non-zero floats but the bi-quad won't calculate and returns a '#IND' result).
MyCo ·
I'm not sure, but shouldn't this:
t1=tan1(t0); // t1=tan(pi*t0/2)
be translated that way:
t1=tan1(t0*0.25); // t1=tan(pi*t0/2)
t0 is in the range of 0..1 so t1 should be tan(0...pi/2) which is tan1(0..0.25)
just a guess... may be the original code could help
oddson ·
Thanks MyCo... other than that line this is the original code.
I put the comment in to make sure I hadn't introduced the problem there.
Now that I look it over it does seem wrong... but I still don't see why the output function blows up on me.. all the component values seem well behaved even if they're not correct.
MyCo ·
So the problem still exist with my change?
may be you could provide a test schematic... It's hard to understand if you can't see/hear anything 🙂
oddson ·
No... it's sorted. Thanks.
infuzion ·
Is this the Badboy from the SM WIKI?
oddson ·
No... I'm trying to use Tobybear's Filter Explorer to generate C++ code and alter that for SM use. It gets you 90% of the way there but you still have to know what you're doing and not make stupid math mistakes. 😊
Wrote something here? To have a post removed or your name hidden, write to [email protected].