1 // Copyright 2020 Espressif Systems (Shanghai) PTE LTD
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 //     http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 
15 #include "soc/i2s_periph.h"
16 #include "soc/gpio_sig_map.h"
17 
18 /*
19  Bunch of constants for every I2S peripheral: GPIO signals, irqs, hw addr of registers etc
20 */
21 const i2s_signal_conn_t i2s_periph_signal[SOC_I2S_NUM] = {
22     {
23         .mck_out_sig  = CLK_I2S_MUX_IDX,
24 
25         .m_tx_bck_sig = I2S0O_BCK_OUT_IDX,
26         .m_rx_bck_sig = I2S0I_BCK_OUT_IDX,
27         .m_tx_ws_sig  = I2S0O_WS_OUT_IDX,
28         .m_rx_ws_sig  = I2S0I_WS_OUT_IDX,
29 
30         .s_tx_bck_sig = I2S0O_BCK_IN_IDX,
31         .s_rx_bck_sig = I2S0I_BCK_IN_IDX,
32         .s_tx_ws_sig  = I2S0O_WS_IN_IDX,
33         .s_rx_ws_sig  = I2S0I_WS_IN_IDX,
34 
35         .data_out_sig = I2S0O_DATA_OUT23_IDX,
36         .data_in_sig  = I2S0I_DATA_IN15_IDX,
37 
38         .irq          = ETS_I2S0_INTR_SOURCE,
39         .module       = PERIPH_I2S0_MODULE,
40     }
41 };
42