|  | Dual Active Bridge Development Board (Part-No. ) |
Content |  |  |  |  |  |

Loading...
Searching...
No Matches
timer_interface.h
1
16/*
17© [2024] Microchip Technology Inc. and its subsidiaries.
18
19 Subject to your compliance with these terms, you may use Microchip
20 software and any derivatives exclusively with Microchip products.
21 You are responsible for complying with 3rd party license terms
22 applicable to your use of 3rd party software (including open source
23 software) that may accompany Microchip software. SOFTWARE IS ?AS IS.?
24 NO WARRANTIES, WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS
25 SOFTWARE, INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT,
26 MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT
27 WILL MICROCHIP BE LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE,
28 INCIDENTAL OR CONSEQUENTIAL LOSS, DAMAGE, COST OR EXPENSE OF ANY
29 KIND WHATSOEVER RELATED TO THE SOFTWARE, HOWEVER CAUSED, EVEN IF
30 MICROCHIP HAS BEEN ADVISED OF THE POSSIBILITY OR THE DAMAGES ARE
31 FORESEEABLE. TO THE FULLEST EXTENT ALLOWED BY LAW, MICROCHIP?S
32 TOTAL LIABILITY ON ALL CLAIMS RELATED TO THE SOFTWARE WILL NOT
33 EXCEED AMOUNT OF FEES, IF ANY, YOU PAID DIRECTLY TO MICROCHIP FOR
34 THIS SOFTWARE.
35*/
36
37#ifndef TIMER_INTERFACE_H
38#define TIMER_INTERFACE_H
39
40// Section: Included Files
41#include <stddef.h>
42#include <stdint.h>
43#include <stdbool.h>
44#include "../system/interrupt_types.h"
45
46// Section: Data Type Definitions
47
53#define TIMER_PERIODCOUNTSET_API_SUPPORT false
54
60 struct TIMER_INTERFACE
61{
62 void (*Initialize)(void);
64
65 void (*Deinitialize)(void);
67
68 void (*Start)(void);
70
71 void (*Stop)(void);
73
74 #if TIMER_PERIODCOUNTSET_API_SUPPORT
75 void (*PeriodCountSet)(size_t count);
77 #endif
78
79 void (*PeriodSet)(uint32_t count);
81
82 uint32_t (*PeriodGet)(void);
84
85 uint32_t (*CounterGet)(void);
87
88 void (*InterruptPrioritySet)(enum INTERRUPT_PRIORITY priority);
90
91 void (*TimeoutCallbackRegister)(void (*CallbackHandler)(void));
93
94 void (*Tasks)(void);
96};
97
98#endif // TIMER_INTERFACE_H
99
TIMER_INTERFACE
Structure containing the function pointers of TIMER driver.
Definition timer_interface.h:61
TIMER_INTERFACE::TimeoutCallbackRegister
void(* TimeoutCallbackRegister)(void(*CallbackHandler)(void))
Pointer to MCCPx_TimeoutCallbackRegister or SCCPx_TimeoutCallbackRegister or TMRx_TimeoutCallbackRegi...
Definition timer_interface.h:91
TIMER_INTERFACE::Tasks
void(* Tasks)(void)
Pointer to MCCPx_Timer_Tasks or SCCPx_Timer_Tasks or TMRx_Tasks e.g. SCCP1_Timer_Tasks or TMR1_Tasks ...
Definition timer_interface.h:94
TIMER_INTERFACE::CounterGet
uint32_t(* CounterGet)(void)
Pointer to MCCPx_Timer_CounterGet or SCCPx_Timer_CounterGet or TMRx_CounterGet e.g....
Definition timer_interface.h:85
TIMER_INTERFACE::InterruptPrioritySet
void(* InterruptPrioritySet)(enum INTERRUPT_PRIORITY priority)
Pointer to MCCPx_Timer_InterruptPrioritySet or SCCPx_Timer_InterruptPrioritySet or TMRx_InterruptPrio...
Definition timer_interface.h:88
TIMER_INTERFACE::Start
void(* Start)(void)
Pointer to MCCPx_Timer_Start or SCCPx_Timer_Start or TMRx_Start e.g. SCCP1_Timer_Start or TMR1_Start.
Definition timer_interface.h:68
TIMER_INTERFACE::Stop
void(* Stop)(void)
Pointer to MCCPx_Timer_Stop or SCCPx_Timer_Stop or TMRx_Stop e.g. SCCP1_Timer_Stop or TMR1_Stop.
Definition timer_interface.h:71
TIMER_INTERFACE::PeriodSet
void(* PeriodSet)(uint32_t count)
Pointer to MCCPx_Timer_PeriodSet or SCCPx_Timer_PeriodSet or TMRx_PeriodSet e.g. SCCP1_Timer_PeriodSe...
Definition timer_interface.h:79
TIMER_INTERFACE::PeriodGet
uint32_t(* PeriodGet)(void)
Pointer to MCCPx_Timer_PeriodGet or SCCPx_Timer_PeriodGet or TMRx_PeriodGet e.g. SCCP1_Timer_PeriodGe...
Definition timer_interface.h:82
TIMER_INTERFACE::Deinitialize
void(* Deinitialize)(void)
Pointer to MCCPx_Timer_Deinitialize or SCCPx_Timer_Deinitialize or TMRx_Deinitialize e....
Definition timer_interface.h:65
TIMER_INTERFACE::Initialize
void(* Initialize)(void)
Pointer to MCCPx_Timer_Initialize or SCCPx_Timer_Initialize or TMRx_Initialize e.g....
Definition timer_interface.h:62