-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtimer.h
More file actions
30 lines (24 loc) · 789 Bytes
/
Copy pathtimer.h
File metadata and controls
30 lines (24 loc) · 789 Bytes
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
/*
* timer.h
*
* Created: 20/10/2017 10:29:38 AM
* Author: Fiona
*/
#ifndef TIMER_H_
#define TIMER_H_
/////////////[Defines]//////////////////////////////////////////////////////////////////////////////
#define TIMER_INTS_PER_MS 72 //Number of interrupts per ms
//////////////[Type Definitions]////////////////////////////////////////////////////////////////////
//typedef enum DelayStates {DLY_START, DLY_WAIT, DLY_STOP} DelayStates;
//
//typedef struct DelayInstance
//{
//uint32_t startTime;
//uint32_t timeToWait;
//DelayStates state;
//} DelayInstance;
/////////////[Functions]////////////////////////////////////////////////////////////////////////////
void timerInit(void);
void timerDelayMs(uint16_t timeMs);
uint32_t timerGetTimestamp(void);
#endif /* TIMER_H_ */