Table des matières

TNY-360 Documentation

Motor

Motor module of the TNY-360 API (code 0x06).

This module contains actions related to the motor management of the robot.


List of actions

Here's a list of all the actions available in the motor module:

0x06 - 0x00

motor.setDutyCycle

Sets the duty cycle of a motor.


Arguments

  • joint_iduint8

    -

    ID of the joint to set the duty cycle for.

  • duty_cyclefloat32

    -

    Duty cycle to set in ms (between 0.0 and 5.0).


No return values

0x06 - 0x01

motor.getDutyCycle

Gets the current duty cycle of a motor.


Arguments

  • joint_iduint8

    -

    ID of the joint to get the duty cycle for.


Return Values

  • duty_cyclefloat32

    -

    Current duty cycle in ms (between 0.0 and 5.0).

0x06 - 0x02

motor.getCalibrationState

Gets the current calibration state of a motor.


Arguments

  • joint_iduint8

    -

    ID of the joint to get the calibration state for.


Return Values

  • calib_stateuint8

    -

    Current calibration state (0 = Not Calibrated, 1 = Calibrating, 2 = Calibrated).

0x06 - 0x03

motor.getCalibrationData

Gets the calibration data of a motor.


Arguments

  • joint_iduint8

    -

    ID of the joint to get the calibration data for.


Return Values

0x06 - 0x04

motor.setCalibrationData

Sets the calibration data of a motor.


Arguments


No return values

0x06 - 0x05

motor.deleteCalibrationData

Deletes the calibration data of a motor.


Arguments

  • joint_iduint8

    -

    ID of the joint to delete the calibration data for.


No return values

0x06 - 0x06

motor.startCalibration

Starts the calibration process for a motor.


Arguments

  • joint_iduint8

    -

    ID of the joint to start the calibration for.


No return values

0x06 - 0x07

motor.stopCalibration

Stops the calibration process for a motor.


Arguments

  • joint_iduint8

    -

    ID of the joint to stop the calibration for.


No return values

0x06 - 0x08

motor.getCalibrationProgress

Gets the progress of the calibration process for a motor.


Arguments

  • joint_iduint8

    -

    ID of the joint to get the calibration progress for.


Return Values

  • progressfloat32

    -

    Current calibration progress (0.0 to 1.0).

List of types

Here's a list of all the types used in the motor module:

MotorController::CalibrationData

Calibration data for the motor controller.


Fields

  • dc_minfloat32

    -

    Minimum Duty Cycle value corresponding to the minimum physical position of the motor.

  • dc_maxfloat32

    -

    Maximum Duty Cycle value corresponding to the maximum physical position of the motor.

  • dc_deadbandfloat32

    -

    Deadband width in Duty Cycle unit.

  • feedback_minfloat32

    -

    Feedback value corresponding to the minimum physical position of the motor.

  • feedback_maxfloat32

    -

    Feedback value corresponding to the maximum physical position of the motor.

  • feedback_noisefloat32

    -

    Feedback noise level in Volt (standard deviation).

  • feedback_latency_msfloat32

    -

    Latency between command and movement in ms.

  • feedback_invertedbool

    -

    Flag indicating whether the feedback is inverted or not.

  • max_speedfloat32

    -

    Maximum speed of the motor in range/s (range = [max bound - min bound]).