First, I am not an expert in the electrical field:)
In a real-time control system (in LabVIEW), for actuating a piezoelectric, I use the generated signal (sine signal 20khz and 10<V<100 Vpp) from a function generator.
Since I need a fast response of sending the signal to piezoelectric, I usually set the function generator with the specific frequency and amplitude and then I trigger it by LabVIEW (on-off by sending digital signals from LabVIEW, I can send digital and analog signals by National Instruments USB-6002 DAQmx.)
Now I need to change the voltage in real-time.
Is there any way that I can change the amplitude electrically? I've seen it is possible for DC by using PNP or NPN, but what about AC? Is there any solution?