microphone:
  - platform: i2s_audio
    id: mic_id_external
    i2s_din_pin: ${i2s_din_pin1}
    adc_type: external
    pdm: false
    mclk_multiple: 384
    correct_dc_offset: true
    on_data:
      - if:
          condition:
            - microphone.is_muted:
                id: mic_id_external
          then:
            - microphone.unmute:
                id: mic_id_external
          else:
            - microphone.mute:
                id: mic_id_external
  - platform: i2s_audio
    id: mic_id_pdm
    i2s_din_pin: ${i2s_din_pin2}
    adc_type: external
    pdm: true
    pdm_dsr: 16
