code: def frame_generator(self):
          
          if self.input_rate == self.RATE_PROCESS:
              while True:
                  yield self.read()
          else:
              while True:
                  yield self.read_resampled()
docs: Generator that yields all audio frames from microphone.