rec::robotino::api2 C interface
Motor.h
Go to the documentation of this file.
1 // Copyright (C) 2004-2008, Robotics Equipment Corporation GmbH
2 
3 #ifndef _REC_ROBOTINO_API2_C_MOTOR_H_
4 #define _REC_ROBOTINO_API2_C_MOTOR_H_
5 
6 #include "rec/robotino/api2/c/globals.h"
8 
17 typedef int MotorId;
18 
20 #define INVALID_MOTORID -1
21 
27 DLLEXPORT MotorId Motor_construct( unsigned int number );
28 
34 DLLEXPORT BOOL Motor_destroy( MotorId id );
35 
40 DLLEXPORT BOOL Motor_setComId( MotorId id, ComId comId );
41 
49 DLLEXPORT BOOL Motor_setMotorNumber( MotorId id, unsigned int number );
50 
54 DLLEXPORT unsigned int numMotors();
55 
62 DLLEXPORT BOOL Motor_setSetPointSpeed( MotorId id, float speed );
63 
69 DLLEXPORT BOOL Motor_resetPosition( MotorId id );
70 
77 DLLEXPORT BOOL Motor_setBrake( MotorId id, BOOL brake );
78 
87 DLLEXPORT BOOL Motor_setPID( MotorId id, float kp, float ki, float kd );
88 
95 DLLEXPORT float Motor_actualSpeed( MotorId id );
96 
102 DLLEXPORT int Motor_actualPosition( MotorId id );
103 
109 DLLEXPORT float Motor_motorCurrent( MotorId id );
110 
116 DLLEXPORT float Motor_rawCurrentMeasurment( MotorId id );
117 
118 #endif //_REC_ROBOTINO_API2_C_MOTOR_H_
DLLEXPORT BOOL Motor_setMotorNumber(MotorId id, unsigned int number)
DLLEXPORT BOOL Motor_destroy(MotorId id)
DLLEXPORT unsigned int numMotors()
DLLEXPORT float Motor_rawCurrentMeasurment(MotorId id)
DLLEXPORT float Motor_motorCurrent(MotorId id)
DLLEXPORT BOOL Motor_setPID(MotorId id, float kp, float ki, float kd)
DLLEXPORT float Motor_actualSpeed(MotorId id)
DLLEXPORT MotorId Motor_construct(unsigned int number)
DLLEXPORT int Motor_actualPosition(MotorId id)
DLLEXPORT BOOL Motor_resetPosition(MotorId id)
In "rec/robotino/api2/c/Com.h" you can find functions for manipulating the communication interface to...
DLLEXPORT BOOL Motor_setComId(MotorId id, ComId comId)
DLLEXPORT BOOL Motor_setBrake(MotorId id, BOOL brake)
int ComId
Definition: Com.h:50
int MotorId
Definition: Motor.h:17
DLLEXPORT BOOL Motor_setSetPointSpeed(MotorId id, float speed)