I am working on a project that will use a piezo as emitter and receiver for ultrasonic system. I am new to electronics, just know the basis.. As you guys may know Arduino analog output can not produce the voltage our system required, the driving voltage will be around 12v to 50v so an amplifier will be used to produce the desire frequency and intensity on the piezo. I am assuming a transistor can be used to control the amplifier when creating the pulse on the piezo but how can I avoid damaging the arduino since the same piezo will be connected on the arduino analog input pins to sense the coming signal so it will get the high voltage from thr amp as well. Also, the wave coming back to the piezo (in listening mode) could make the piezo generate voltage higher than 5v which is more than the arduino analog input channel can handle. So there are two things here to over come, first the high voltage coming from the amp that will goes to the analog input and second, the voltage generated by the piezo from the coming wave.