-
Notifications
You must be signed in to change notification settings - Fork 0
module.h
Lukáš Dršman edited this page May 14, 2022
·
2 revisions
Contains functions for module driving. Depends on shifter.
void moduleAsyncDrive(shifter s, int target, int id);
- drives module at
id
asynchronously totarget
angle - Parameters:
-
shifter s
- shifter object -
int target
- target angle at the driver motor -
int id
- module locator (possible values for 90° offset:0
,1
,2
,3
)
-
void moduleAwaitDrive(shifter s);
- pauses thread from executing following calls until module finishes its action
- Parameters:
-
shifter s
- shifter object
-
#define moduleDrive(s, target, id) \
({ moduleAsyncDrive(s, target, id); \
moduleAwaitDrive(s); })
- drives module at
id
synchronously totarget
angle - Parameters:
-
shifter s
- shifter object -
int target
- target angle at the driver motor -
int id
- module locator (possible values for 90° offset:0
,1
,2
,3
)
-