10 #include "NotifyListener.h"
11 #include "hal/Types.h"
17 void HALSIM_ResetEncoderData(int32_t index);
18 int32_t HALSIM_GetEncoderDigitalChannelA(int32_t index);
19 int32_t HALSIM_GetEncoderDigitalChannelB(int32_t index);
20 int32_t HALSIM_RegisterEncoderInitializedCallback(int32_t index,
21 HAL_NotifyCallback callback,
23 HAL_Bool initialNotify);
24 void HALSIM_CancelEncoderInitializedCallback(int32_t index, int32_t uid);
25 HAL_Bool HALSIM_GetEncoderInitialized(int32_t index);
26 void HALSIM_SetEncoderInitialized(int32_t index, HAL_Bool initialized);
28 HAL_SimDeviceHandle HALSIM_GetEncoderSimDevice(int32_t index);
30 int32_t HALSIM_RegisterEncoderCountCallback(int32_t index,
31 HAL_NotifyCallback callback,
33 HAL_Bool initialNotify);
34 void HALSIM_CancelEncoderCountCallback(int32_t index, int32_t uid);
35 int32_t HALSIM_GetEncoderCount(int32_t index);
36 void HALSIM_SetEncoderCount(int32_t index, int32_t count);
38 int32_t HALSIM_RegisterEncoderPeriodCallback(int32_t index,
39 HAL_NotifyCallback callback,
41 HAL_Bool initialNotify);
42 void HALSIM_CancelEncoderPeriodCallback(int32_t index, int32_t uid);
43 double HALSIM_GetEncoderPeriod(int32_t index);
44 void HALSIM_SetEncoderPeriod(int32_t index,
double period);
46 int32_t HALSIM_RegisterEncoderResetCallback(int32_t index,
47 HAL_NotifyCallback callback,
49 HAL_Bool initialNotify);
50 void HALSIM_CancelEncoderResetCallback(int32_t index, int32_t uid);
51 HAL_Bool HALSIM_GetEncoderReset(int32_t index);
52 void HALSIM_SetEncoderReset(int32_t index, HAL_Bool reset);
54 int32_t HALSIM_RegisterEncoderMaxPeriodCallback(int32_t index,
55 HAL_NotifyCallback callback,
57 HAL_Bool initialNotify);
58 void HALSIM_CancelEncoderMaxPeriodCallback(int32_t index, int32_t uid);
59 double HALSIM_GetEncoderMaxPeriod(int32_t index);
60 void HALSIM_SetEncoderMaxPeriod(int32_t index,
double maxPeriod);
62 int32_t HALSIM_RegisterEncoderDirectionCallback(int32_t index,
63 HAL_NotifyCallback callback,
65 HAL_Bool initialNotify);
66 void HALSIM_CancelEncoderDirectionCallback(int32_t index, int32_t uid);
67 HAL_Bool HALSIM_GetEncoderDirection(int32_t index);
68 void HALSIM_SetEncoderDirection(int32_t index, HAL_Bool direction);
70 int32_t HALSIM_RegisterEncoderReverseDirectionCallback(
71 int32_t index, HAL_NotifyCallback callback,
void* param,
72 HAL_Bool initialNotify);
73 void HALSIM_CancelEncoderReverseDirectionCallback(int32_t index, int32_t uid);
74 HAL_Bool HALSIM_GetEncoderReverseDirection(int32_t index);
75 void HALSIM_SetEncoderReverseDirection(int32_t index,
76 HAL_Bool reverseDirection);
78 int32_t HALSIM_RegisterEncoderSamplesToAverageCallback(
79 int32_t index, HAL_NotifyCallback callback,
void* param,
80 HAL_Bool initialNotify);
81 void HALSIM_CancelEncoderSamplesToAverageCallback(int32_t index, int32_t uid);
82 int32_t HALSIM_GetEncoderSamplesToAverage(int32_t index);
83 void HALSIM_SetEncoderSamplesToAverage(int32_t index, int32_t samplesToAverage);
85 int32_t HALSIM_RegisterEncoderDistancePerPulseCallback(
86 int32_t index, HAL_NotifyCallback callback,
void* param,
87 HAL_Bool initialNotify);
88 void HALSIM_CancelEncoderDistancePerPulseCallback(int32_t index, int32_t uid);
89 double HALSIM_GetEncoderDistancePerPulse(int32_t index);
90 void HALSIM_SetEncoderDistancePerPulse(int32_t index,
double distancePerPulse);
92 void HALSIM_RegisterEncoderAllCallbacks(int32_t index,
93 HAL_NotifyCallback callback,
94 void* param, HAL_Bool initialNotify);