Skip to main content

cpp_groupsyncread

CPP GroupSyncRead

  • Description

    Base class for simultaneous dynamixel control on reading.

  • Members

    None

  • Methods

MethodsDescription
GroupSyncReadInitializes groupSyncRead instance
~GroupSyncReadClears parameter storage
getPortHandlerReturns PortHandler instance
getPacketHandlerReturns PacketHandler instance
addParamAdds parameter storage for read
removeParamRemoves parameter on the storage
clearParamClears parameter storage
txPacketTransmits packet to the number of DYNAMIXEL's
rxPacketreceives packet from the number of DYNAMIXEL's
txRxPacketTransmits and receives packet on the number of DYNAMIXEL's
isAvailableChecks whether there is available data in the data storage
getDataGets data from received packet
  • Enumerator

    None

Method References

addParam
  • Syntax
bool addParam(UINT8_T id)
  • Parameters
ParametersDescription
idDYNAMIXEL ID
  • Detailed Description

    This function pushes id to the DYNAMIXEL ID list, and initializes the parameter storage. It returns false when the class uses Protocol 1.0 or target ID exists already in the ID list, or returns true.

removeParam
  • Syntax
void removeParam(UINT8_T id)
  • Parameters
ParametersDescription
idDYNAMIXEL ID
  • Detailed Description

    This function removes target id in the DYNAMIXEL ID list. It returns false when the class uses Protocol 1.0 or target ID does not exists in the ID list, or returns true.

clearParam
  • Syntax
void clearParam()
  • Parameters

    None

  • Detailed Description

    This function clears the DYNAMIXEL ID list. It returns false when the class uses Protocol 1.0, or returns true.

txPacket
  • Syntax
int txPacket()
  • Parameters

    None

  • Detailed Description

    This function transmits the packet by using syncReadTx() function. It returns COMM_NOT_AVAILABLE when the class uses Protocol 1.0, or returns communication result.

rxPacket
  • Syntax
int rxPacket()
  • Parameters

    None

  • Detailed Description

    This function receives the packet by using readRx() function. It returns COMM_NOT_AVAILABLE when the class uses Protocol 1.0 or there is no packet that had been received, or returns communication result.

txRxPacket
  • Syntax
int txRxPacket()
  • Parameters

    None

  • Detailed Description

    This function transmits and receives the packet by using txPacket() function and rxPacket() function. It returns COMM_NOT_AVAILABLE when the class uses Protocol 1.0 or the packet transmission had not succeeded, or returns communication result.

isAvailable
  • Syntax
bool isAvailable(uint8_t id, uint16_t address, uint16_t data_length)
  • Parameters
ParametersDescription
idDYNAMIXEL ID
addressAddress on the control table of DYNAMIXEL
dataPacket data
  • Detailed Description

    This function checks whether there is available data in the data storage. It returns false when used Protocol is 1.0 version or there is no data from target address, or returns true.

getData
  • Syntax
uint32_t getData(UINT8_T id, UINT16_T address, UINT16_T data_length)
  • Parameters
ParametersDescription
idDYNAMIXEL ID
addressAddress on the control table of DYNAMIXEL
data lengthData length
  • Detailed Description

    This function gets specific data from received packet. It returns value.