An oscillator is an electronic circuit, which generates alternating voltage. In an oscillator the output power is returned back to the input, in phase with the starting power (i.e., as a positive feedback). Oscillator works on the principle of positive feedback.