/*!
 * @file        user_tmr_config.c
 *
 * @brief       TMR PWM Input configuration
 *
 * @version     V1.0.0
 *
 * @date        2026-03-27
 *
 * @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).
 */

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

/** @addtogroup Examples
  @{
*/

/** @addtogroup TMR_Examples
@{
*/

/** @addtogroup TMR_PWMInput
  @{
*/

/** @defgroup TMR_PWMInput_Variables Variables
  @{
*/

Gpio_ConfigType g_tmr3_Ch2GpioConfig = {
    .pin = (uint16_t)TMR3_CH2_PIN,
    .mode = GPIO_MODE_AF,
    .speed = GPIO_SPEED_50MHz,
    .outtype = GPIO_OUT_TYPE_PP,
    .pupd = GPIO_PUPD_PU
};

Tmr_IcConfigType g_tmr3_PWMInputConfig = {
    .channel = TMR_CHANNEL_2,
    .ICpolarity = TMR_IC_POLARITY_RISING,
    .ICselection = TMR_IC_SELECTION_DIRECT_TI,
    .ICprescaler = TMR_ICPSC_DIV1,
    .ICfilter = 0x00
};

Tmr_TimeBaseType g_tmr1_BaseConfig = {
    .clockDivision = TMR_CKD_DIV1,
    .counterMode = TMR_COUNTER_MODE_UP,
    .div = 63,
    .period = 999,
    .repetitionCounter = 0
};

/**@} end of group TMR_PWMInput_Variables */
/**@} end of group TMR_PWMInput */
/**@} end of group TMR_Examples */
/**@} end of group Examples */
