No announcement yet.

Control multiple A/R circuits with one potentiometer set

  • Filter
  • Time
  • Show
Clear All
new posts

  • Control multiple A/R circuits with one potentiometer set

    Dear everyone,

    This is my first post in the forum, so I hope I'm doing it right.

    I have managed to get an A/R (Attack / Release) circuit working (credit to synthnerd ) in which I input a square wave, can control the attack with one potentiometer and the release with another one and get the more or less expected shaped wave. This works fine:
    Click image for larger version

Name:	circuit1.jpg
Views:	207
Size:	62.1 KB
ID:	912769

    My question is: is there any way I can use the same 2 potentiometers to shape multiple waves? I could just replicate the same circuit for each wave, but I would like the same Attack values to apply all the waves as well as the Release ones. In that case, with one pot for Attack and one for Release I could shape 4 or 5 waves. Combining the waves into one is not an option as I later need to process them separately.

    Thank you very much in advance!

  • #2
    You could use Pulse Width control. Start with a triangle wave oscillator of 0-5V at maybe 10KHz, feeding 2 comparators the other inputs are from 0-5V pots. The comparator outputs control 2 analog switches.
    I can make a more detailed schematic if you want, but that is the general idea.

    Click image for larger version

Name:	AR-PWM.gif
Views:	238
Size:	35.2 KB
ID:	912773


    • #3
      Wow, thank you very much for this great info. There are a few new concepts for me here and I've been researching a bit on them.

      I've been trying to follow the logic and there are obviously things I cannot yet see. Using a 5v single rail power supply I'll create a virtual ground and feed the comparators with +2.5v and -2.5:
      - comparator will output -2.5v for a certain period of time (depending on the pot shaft's position). Then it will output +2.5v. This would happen for both pots, sometimes they can overlap (+2.5v out from both comparators) and sometimes not.
      - switch will sometimes receive +2.5v (ON) and sometimes -2.5V (OFF) which will let the square signal flow or not.

      This logic takes me nowhere, so I'm sure I'm not understanding

      Could you explain a little bit further and / or show how & where 2 or more square input signals would be hooked and controlled only by 2 pots (Attack & Release)?
      Thanks a lot and apologies for my noobness, I'm very much learning.



      • #4
        The comparators have on one input a 10KHz triangle wave, on the other a voltage from the pot.
        The output of the comparators is a 10 KHz variable pulse width wave, the width dependent on the position of the pot.
        When controlling an analog switch it creates a virtual resistor.
        What is the voltage range you want at the A/R output?

        I've added limiting resistors, R1 would be 100 ohms and R2 is 1M. The short pulse on the left would create a high value resistor, the long
        pulse on the right a low value. A square wave would be half way between R1 and R2 or 500K.

        Click image for larger version

Name:	analog switch.gif
Views:	212
Size:	16.4 KB
ID:	912956


        • #5
          Thanks for your answer once again,
          I am currently receiving 1V - 5V out from the A/R (depending on the position of the pots), so that would be more or less the expected value from each of the 4 waves.

          I'm still trying to follow your logic so I tried to put together a diagram to double check if I'm getting it (I apologize for this, I'm very amateur, self taught).
          Is the triangle wave combined with the pot, then sent to the 4 control pins of the 4066 to open and close and somehow work as resistances? So all the 4 switches within the 4066 would act as resistors (with the value specified by the pot)?
          I'll go and buy some 4066 and start putting it all together; I hope I can use TL072 op amps (as they are dual so I can use one chip for both A & R).
          Click image for larger version

Name:	circuit2.jpg
Views:	144
Size:	167.8 KB
ID:	913068


          • #6
            I am also self-taught starting at age 10, 54 years ago.
            Your diagram looks correct. Pin 7 of the 4066 would go to ground, pin 14 to +5v.

            The comparators in the first circuit would need to be 393 (dual) or 339 (quad) with pull-up resistors on the outputs.
            The triangle wave goes to the inputs of the comparators. When the wave goes above the pot voltage the output goes high (+5V),
            when it goes below the output goes to 0.

            Here is a easier way of generating a pulse wave using a 555 timer. Build two of these, one each for A and R

            Click image for larger version

Name:	555pwm.gif
Views:	207
Size:	28.5 KB
ID:	913082


            • #7
              Thank you very much for your help, you definitely have a lot of experience in the field! I have started "learning" a bit more seriously only a few years ago (3 or 4 aprox.) and I'm 37...!

              I have tried the circuit with only one 555 (sending the square wave to both comparators) and it didn't work. Later I realized that you instructed to make two 555, so this is something that I still have to test. Unfortunately at the moment I am going thru hard personal issues and I'm being uncapable of working on it, but I will get back with an answer as soon as I can. Thanks again!



              • #8
                Dear dmeek,

                I'm back on the road again! Apologies for the long wait.
                I put the circuit together. I get two square waves from both 555s. I feed the LM393N with these waves (1IN- and 2IN-) or (1IN+ and 2IN+) and I also input the pots.

                I send the LM393N output to CD4066B CONTROL INPUT pin, being this what happens when I spin one of the pots:

                and the wave INPUT into CD4066B are just pulses:
                Click image for larger version

Name:	CD4066B - IN.png
Views:	88
Size:	51.2 KB
ID:	919547

                This creates an output of... nothing.
                Unfortunately I get nothing out of the 4066.
                Does anything come to your mind that I may be doing wrong?

                I'm using B200k pots (tried with B10K / A10K but the change in the CONTROL signal is too sudden, I guess because of low resolution). Also the pot is making this change (from the video) within a very short range of the full pot values.

                Thanks a lot,



                • #9
                  Dear Dmeek and everyone,

                  Good news!!

                  After reading thru the posts, I noticed I was feeding the comparator square waves instead of triangles, so I've now added one low pass filter to each 555 and feed the triangle to the comparator. I've included the pull-up resistors in the comparator's outputs. The result now is one square wave coming out of each output of the comparator, being their widths controlled by each assigned potentiometer:

                  So I believe I am getting now a proper Attack and Release! (have to play a bit with potentiometer values and with limiting resistors, but all in all it seems to be good).

                  I have tested it with only one wave so far, but I'm quite positive it will work for more. As soon as I get another protoboard I'm gonna add a second wave, come back here and report the results.

                  Thank you very much for your invaluable help!!!


                  • #10
                    I didn't describe it clearly enough. The 555 circuit is an alternative to the comparator circuit. A disadvantage is that the A and R are not voltage controlled, though that may or may not not matter in your case.

                    All chips need a higher power supply voltage than your AR output, can be up to +15V
                    Click image for larger version

Name:	ar.gif
Views:	125
Size:	39.2 KB
ID:	920569


                    • #11
                      Yes, you are right. I removed the comparator and added the pots to the 555 and it works
                      Voltage control for A and R was not in my mind, so for the moment I'm not going to worry about it.
                      Thanks again, I'll come back with the results when I add another wave!



                      • #12
                        Added a second wave and it works
                        A and R can be controlled for both waves with only one pot (one for A and one for R).
                        Success!!! Thank you very much DMeek, a lot learned and a lot more to be learned