/*!
 * @file        user_I2C_config.h
 *
 * @brief       I2C configurations
 *
 * @version     V1.0.0
 *
 * @date        2026-03-25
 *
 * @attention
 *
 *  Copyright (C) 2026 Geehy Semiconductor
 *
 *  You may not use this file except in compliance with the
 *  GEEHY COPYRIGHT NOTICE (Geehy Semiconductor Software License Agreement).
 *
 *  The program is only for reference, which is distributed in the hope
 *  that it will be useful and instructional for customers to develop
 *  their software. Unless required by applicable law or agreed to in
 *  writing, the program is distributed on an "AS IS" BASIS, WITHOUT
 *  ANY WARRANTY OR CONDITIONS OF ANY KIND, either express or implied.
 *  See the Geehy Semiconductor Software License Agreement for the governing permissions
 *  and limitations under the License.
 */

/*
* MISRA-C:2012 compliance checks
*
*       g32a10xx_gpio_i2c_h_MISRA_REF1
*          Breaks the required Rule-8.5 of MISRA 2012 guidelines,
*          An external object or function shall be declared once in one and only one file
*/

#ifndef USER_I2C_CONFIG_H
#define USER_I2C_CONFIG_H

#ifdef __cplusplus
extern "C" {
#endif

/* Includes */
#include "g32a10xx_gpio.h"


/** @addtogroup Examples
  @{
  */

/** @addtogroup I2C_Examples
  @{
  */

/** @addtogroup GPIO_I2C
  @{
  */

/** @defgroup GPIO_I2C_Macros Macros
  @{
  */
#define I2C_SDA_PIN    GPIO_PIN_7
#define I2C_SDA_PORT   GPIOB
#define I2C_SDA_CLK    RCM_AHB_PERIPH_GPIOB

#define I2C_SCL_PIN    GPIO_PIN_6
#define I2C_SCL_PORT   GPIOB
#define I2C_SCL_CLK    RCM_AHB_PERIPH_GPIOB

#define I2C_WP_PIN     GPIO_PIN_10
#define I2C_WP_PORT    GPIOB
#define I2C_WP_CLK     RCM_AHB_PERIPH_GPIOB


/* I2C clock rate */
#define I2C_CLK_RATE    I2C_CLK_10KHz

/**@} end of group GPIO_I2C_Macros */

/** @defgroup GPIO_I2C_Variables
  @{
  */

/* I2C user configuration */

/*** @warning g32a10xx_gpio_i2c_h_MISRA_REF1 Multiple declarations of external object or function. */
/*** @warning g32a10xx_gpio_i2c_h_MISRA_REF1 The global identifier 'g_sdaGpioConfig' has been declared in more than one file. */
extern Gpio_ConfigType g_sdaGpioConfig;
/*** @warning g32a10xx_gpio_i2c_h_MISRA_REF1 Multiple declarations of external object or function. */
/*** @warning g32a10xx_gpio_i2c_h_MISRA_REF1 The global identifier 'g_sclGpioConfig' has been declared in more than one file. */
extern Gpio_ConfigType g_sclGpioConfig;
/*** @warning g32a10xx_gpio_i2c_h_MISRA_REF1 Multiple declarations of external object or function. */
/*** @warning g32a10xx_gpio_i2c_h_MISRA_REF1 The global identifier 'g_wpGpioConfig' has been declared in more than one file. */
extern Gpio_ConfigType g_wpGpioConfig;
/**@} end of group GPIO_I2C_Variables */

#ifdef __cplusplus
}
#endif

#endif /* USER_I2C_CONFIG_H */

/**@} end of group GPIO_I2C */
/**@} end of group I2C_Examples */
/**@} end of group Examples */
