#include "rfm0_cpri_timer.h"
#include "ucp_drv_common.h"
#include "ucp_cpri.h"
#include "ucp_param.h"
#include "mtimer_com.h"
#include "ucp_printf.h"
#include "ucp_utility.h"
#include "phy_para.h"
#include "rfm0_mtimer.h"
#include "inter_vector.h"

extern stPhyScsPara* phyPara;
extern stSfnPara gCellSfnPara[2];

void set_cpri_timer_rfm0_int(void)
{
    int32_t apeId = get_core_id();

    // tx slot
    uint32_t intNum = APC_CPRI_TMR_INTR0 + MTMR_INT_RFM0_SLOT;
    int32_t ret = smart_irq_request(intNum, isr_cpri_rfm0_symbol);
    if (0 != ret)
    {
        UCP_PRINT_EMPTY("attach int num: 0x%x error. errno = 0x%x. \r\n", intNum, ret);
        debug_write(DBG_DDR_ERR_IDX(apeId, 6), ret);
    }
}

void isr_cpri_rfm0_symbol(void)
{
	mtimer_rfm0_symbol_callback(MTIMER_CPRI_ID);
}


