Doly C++ SDK v1.00
Loading...
Searching...
No Matches
ArmControl.h
Go to the documentation of this file.
1#pragma once
2#include <cstdint>
3#include <vector>
4#include "ArmEvent.h"
5
20
24struct ArmData
25{
28
34 float angle;
35};
36
37namespace ArmControl
38{
52 int8_t init();
53
61 int8_t dispose();
62
67 bool isActive();
68
76 void Abort(ArmSide side);
77
82 uint16_t getMaxAngle();
83
106 int8_t setAngle(uint16_t id, ArmSide side, uint8_t speed, uint16_t angle, bool with_brake = false);
107
114
121 std::vector<ArmData> getCurrentAngle(ArmSide side);
122
130 float getVersion();
131
132} // namespace ArmControl
Event dispatcher API for the Doly ArmControl subsystem.
ArmState
High-level state of an arm operation.
Definition ArmEventListener.h:55
ArmSide
Which arm side an operation or event relates to.
Definition ArmEventListener.h:40
Definition ArmControl.h:38
std::vector< ArmData > getCurrentAngle(ArmSide side)
Get the current angle(s) for the requested side(s).
int8_t setAngle(uint16_t id, ArmSide side, uint8_t speed, uint16_t angle, bool with_brake=false)
Command the arm to move to an angle.
bool isActive()
Check whether the subsystem is active (initialized and running).
int8_t dispose()
Dispose/stop the arm subsystem and release resources.
int8_t init()
Initialize the arm subsystem.
void Abort(ArmSide side)
Abort the current operation for a given side.
float getVersion()
Get SDK/library version.
uint16_t getMaxAngle()
Get maximum allowed angle for the arm.
ArmState getState(ArmSide side)
Get current operation state for a side.
Current arm angle data for one side.
Definition ArmControl.h:25
ArmSide side
Definition ArmControl.h:27
float angle
Angle in degrees.
Definition ArmControl.h:34