blob: 37eade5c4a864ba7bbd84f564c6891e0ed2920ab (
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
|
/************************************************************
* Utils.h
* general module of system utility functions
**************************************************************/
#ifndef COMMON_UTILS_H_
#define COMMON_UTILS_H_
#include <stdbool.h>
#include <stdint.h>
//digital read of the potentiometer limits
#define DANSER_POS_MIN 1300
#define DANSER_POS_MAX 3500
typedef enum
{
Winder = 0,
Pooler
}Danser_t;
void utilsInit(uint32_t ui32SysClock);
uint32_t UsersysTickGet (void);
bool DanserCheckPosition(uint16_t position , Danser_t danser, bool test);
void InitWatchdog(uint32_t clock);
uint16_t ConvertSpeed2Pps(uint16_t milimeterPerSecond);
uint16_t ConvertPpsToSpeed(uint16_t Pps);
void UtilsSetCommunicationOk(void);
#endif /* COMMON_UTILS_H_ */
|