/*
 * SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
 *
 * SPDX-License-Identifier: Apache-2.0
 */

// This file defines GPIO lookup macros for available UART IO_MUX pins on ESP32P4.

#pragma once

//UART0 channels
#define UART_GPIO37_DIRECT_CHANNEL      UART_NUM_0
#define UART_NUM_0_TXD_DIRECT_GPIO_NUM  37
#define UART_GPIO38_DIRECT_CHANNEL      UART_NUM_0
#define UART_NUM_0_RXD_DIRECT_GPIO_NUM  38
#define UART_GPIO8_DIRECT_CHANNEL      UART_NUM_0
#define UART_NUM_0_RTS_DIRECT_GPIO_NUM  8
#define UART_GPIO9_DIRECT_CHANNEL      UART_NUM_0
#define UART_NUM_0_CTS_DIRECT_GPIO_NUM  9

#define UART_TXD_GPIO37_DIRECT_CHANNEL  UART_GPIO38_DIRECT_CHANNEL
#define UART_RXD_GPIO38_DIRECT_CHANNEL  UART_GPIO38_DIRECT_CHANNEL
#define UART_RTS_GPIO8_DIRECT_CHANNEL   UART_GPIO8_DIRECT_CHANNEL
#define UART_CTS_GPIO9_DIRECT_CHANNEL   UART_GPIO9_DIRECT_CHANNEL

//UART1 channels
#define UART_GPIO10_DIRECT_CHANNEL      UART_NUM_1
#define UART_NUM_1_TXD_DIRECT_GPIO_NUM  10
#define UART_GPIO11_DIRECT_CHANNEL      UART_NUM_1
#define UART_NUM_1_RXD_DIRECT_GPIO_NUM  11
#define UART_GPIO12_DIRECT_CHANNEL      UART_NUM_1
#define UART_NUM_1_RTS_DIRECT_GPIO_NUM  12
#define UART_GPIO13_DIRECT_CHANNEL      UART_NUM_1
#define UART_NUM_1_CTS_DIRECT_GPIO_NUM  13

#define UART_TXD_GPIO10_DIRECT_CHANNEL  UART_GPIO10_DIRECT_CHANNEL
#define UART_RXD_GPIO11_DIRECT_CHANNEL  UART_GPIO11_DIRECT_CHANNEL
#define UART_RTS_GPIO12_DIRECT_CHANNEL  UART_GPIO12_DIRECT_CHANNEL
#define UART_CTS_GPIO13_DIRECT_CHANNEL  UART_GPIO13_DIRECT_CHANNEL
