[sdiy] Help with math, please

Tom Wiltshire tom at electricdruid.net
Tue Aug 9 23:54:39 CEST 2011


Sorry, didn't see your reply there, Veronica.

T.

On 9 Aug 2011, at 21:50, Veronica Merryfield wrote:

> You could take a look at how Tom Wiltshire implemented his VCADSR..
> 
> http://www.electricdruid.net/index.php?page=projects.envgen7
> 
> 
> 
> On 2011-08-09, at 9:18 AM, Tim Ressel wrote:
> 
>> Hi,
>> 
>> Okay, I admit it: math is not my strong suit, and I need help with a problem. I am trying to program a cv envelope generator with exponential and linear curves. The linear part works just fine, but I am having a real hard time wrapping my neurons around the exponential part.
>> 
>> The way I've implemented the code is this: there is an accumulator that values get added or subtracted to at each time slice, which is 1ms currently. An ADC value adjusts the amount that gets added. In the case of the exponential curve I am trying to use the RC time constant equation to calculate the value to add to the accumulator. The thing is, the RC time constant formula calculates from time zero, and I need an incremental value. So given the current accumulator value (analogous to voltage on the cap) and the current ADC value (the RC value) I need an equation that gives an increment value to add to the accumulator.
>> 
>> Any math whizzes out there that can help?
>> 
>> Thanks in advance,
>> 
>> --TimR
>> 
>> _______________________________________________
>> Synth-diy mailing list
>> Synth-diy at dropmix.xs4all.nl
>> http://dropmix.xs4all.nl/mailman/listinfo/synth-diy
>> 
> 
> _______________________________________________
> Synth-diy mailing list
> Synth-diy at dropmix.xs4all.nl
> http://dropmix.xs4all.nl/mailman/listinfo/synth-diy




More information about the Synth-diy mailing list