Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
hardware_timer.h@0:716b93ab9a58, 2021-10-29 (annotated)
- Committer:
- rajathr
- Date:
- Fri Oct 29 20:56:20 2021 +0000
- Revision:
- 0:716b93ab9a58
AS ON 29TH OCT AT 5PM
Who changed what in which revision?
| User | Revision | Line number | New contents of line | 
|---|---|---|---|
| rajathr | 0:716b93ab9a58 | 1 | /* Define to prevent recursive inclusion -------------------------------------*/ | 
| rajathr | 0:716b93ab9a58 | 2 | #ifndef __HARDWARE_TIMER_H_ | 
| rajathr | 0:716b93ab9a58 | 3 | #define __HARDWARE_TIMER_H_ | 
| rajathr | 0:716b93ab9a58 | 4 | |
| rajathr | 0:716b93ab9a58 | 5 | #ifdef __cplusplus | 
| rajathr | 0:716b93ab9a58 | 6 | extern "C" { | 
| rajathr | 0:716b93ab9a58 | 7 | #endif | 
| rajathr | 0:716b93ab9a58 | 8 | |
| rajathr | 0:716b93ab9a58 | 9 | /* Includes ------------------------------------------------------------------*/ | 
| rajathr | 0:716b93ab9a58 | 10 | #include "main.h" | 
| rajathr | 0:716b93ab9a58 | 11 | |
| rajathr | 0:716b93ab9a58 | 12 | /*Function definitions---------------------------------------------------------*/ | 
| rajathr | 0:716b93ab9a58 | 13 | |
| rajathr | 0:716b93ab9a58 | 14 | /*Defining funtion that initializes Timer3 Channel3 as Output Compare*/ | 
| rajathr | 0:716b93ab9a58 | 15 | void TMR3CH3OutputCompare(void); | 
| rajathr | 0:716b93ab9a58 | 16 | |
| rajathr | 0:716b93ab9a58 | 17 | /*Defining funtion that initializes Timer3 Channel1 as Input Capture*/ | 
| rajathr | 0:716b93ab9a58 | 18 | void TMR3CH1GPIOCPin6asInputCapture(void); | 
| rajathr | 0:716b93ab9a58 | 19 | |
| rajathr | 0:716b93ab9a58 | 20 | /*Defining funtion that reads countervalue when Timer3 Channel1 as an Input Capture*/ | 
| rajathr | 0:716b93ab9a58 | 21 | uint16_t readCounterValueIfFlagIsSet(void); | 
| rajathr | 0:716b93ab9a58 | 22 | |
| rajathr | 0:716b93ab9a58 | 23 | /*Defining funtion that Initializes Timer3 Channel3 as an Output - PWM Mode 1*/ | 
| rajathr | 0:716b93ab9a58 | 24 | void TMR3CH3OutputPWMMode1(void); | 
| rajathr | 0:716b93ab9a58 | 25 | |
| rajathr | 0:716b93ab9a58 | 26 | /*Defining funtion that Initializes Timer3 Channel3 to Interrupt - Output Compare Interrupt Mode*/ | 
| rajathr | 0:716b93ab9a58 | 27 | void initTimer3ToInterrupt(void); | 
| rajathr | 0:716b93ab9a58 | 28 | |
| rajathr | 0:716b93ab9a58 | 29 | |
| rajathr | 0:716b93ab9a58 | 30 | #ifdef __cplusplus | 
| rajathr | 0:716b93ab9a58 | 31 | } | 
| rajathr | 0:716b93ab9a58 | 32 | #endif | 
| rajathr | 0:716b93ab9a58 | 33 | |
| rajathr | 0:716b93ab9a58 | 34 | #endif /*__HARDWARE_TIMER_H */ |