blob: c0cf8976824fc26f195601481ac1f651e02e4e3e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
/*
* Copyright (c) 2006-2022, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
* Change Logs:
* Date Author Notes
* 2022-10-19 Nations first version
*/
#ifndef __DRV_CLOCK_TIMER__
#define __DRV_CLOCK_TIMER__
#include <rtthread.h>
#include <rtdevice.h>
#include <rthw.h>
#include <board.h>
#ifdef __cplusplus
extern "C" {
#endif
/* n32 config class */
struct n32_clock_timer_config
{
const char *name;
TIM_Module* timer_periph;
IRQn_Type irqn;
};
struct n32_clock_timer
{
rt_clock_timer_t time_device;
struct n32_clock_timer_config *config;
};
int rt_clock_timer_init(void);
#ifdef __cplusplus
}
#endif
#endif /* __DRV_CLOCK_TIMER__ */
|