The problem is designing gain/volume/pan/balance/crossfade/mix controls with a smooth "law" or "taper"; the rate at which the audible volume changes as you turn them. (Described in The Secret Life of Pots and Changing the Law of a Pot, for instance.)
It's easy to make controls in which the gain changes very little in the middle and then swoops up at the top, for instance, but that's no good.
So I'd like to "draw" the circuit and then plot the gain/attenuation as a function of pot position, with either log or linear pots, and be able to vary component values and quickly see the effect on the gain function, in order to speed up finding the optimal layout/resistor values.
Currently I do one of the following:
- Simulate the circuit in TINA-TI. This sucks because:
- The pots only come in linear taper
- There's no way that I know of to plot something as a function of pot position. You can set the pot as a control object and vary the position in steps from 0% to 100%, but I don't know of a way to plot the gain. I just know you can plot the frequency response at each position, read the gains from the frequency response plot, and put them in a spreadsheet, which is very tedious.
- Calculate the curve in a mathematics program like wxMaxima or Python and plot it. This sucks because:
- It requires entering the gain equation by hand, which can be tedious and error-prone for certain circuits. You can't tell by looking at a complex equation whether it's right or not, and modifying it by adding resistors in parallel to existing circuitry is difficult.
- Again, plotting for a log taper pot is difficult. You'd have to enter the taper as a separate function which feeds into the gain function, and it still wouldn't match the real world exactly.
Any other ideas?
For illustration, here's a plot I made comparing linear pot, log taper pots, and linear pot with "pull-down resistor" to approximate a log taper. I'd like something that will plot the yellow curve, for different values of the pull-down resistor, so I can make it behave as closely as possible to the other curves, without having to enter an equation manually. Of course, my real applications are more complex, but this is an example of what I want to do.
(Copied from Electronics Exchange)