Edit on GitHub

Library Setup <C++ Linux>

This section provides instructions on building the SDK.

Install requirements

  • The DYNAMIXEL SDK requires GNU gcc ver. 5.4.0 20160609 or higher
  • To check the version of your gcc compiler
    $ gcc -v
    
  • Download the requirements
    $ sudo apt-get install gcc
    $ sudo apt-get install build-essential
    $ sudo apt-get install gcc-multilib g++-multilib # For cross-compiling
    

Build the SDK

  • Check your system architecture
    $ uname -m
    
  • Enter the appropriate build folder depending on your system and build the SDK
    $ cd DynamixelSDK/c++/build/linux64 # for 64-bit systems
    $ sudo make install
    
  • make sure to enter the correct folder according to your system architecture.
    • linux64 for 64-bit systems
    • linux32 for 32-bit systems
    • linux_sbc for ARM-based SBCs like Raspberry Pi
  • If the build completes successfully, you should see the .so file generated inside the build folder.
    $ ls
    libdxl_x86_cpp.so Makefile
    
  • Grant permission to access the port
    $ sudo chmod 666 /dev/ttyUSB0
    


  • Common make commands for building the SDK
    $ make              # Compile the source code and generate binaries
    $ make install      # Install the library files to the system
    $ make clean        # Remove all build files and reset the build environment
    $ make uninstall    # Remove files installed by 'make install' from the system
    $ make reinstall    # Reinstall by cleaning, rebuilding, and installing again
    

Library Setup <C++ Windows>

This section provides instructions on building the SDK.

Install requirements

Build the SDK

NOTE: This instruction assumes a 64-bit Windows system. If you are using 32-bit Windows, simply follow the same steps using the 32-bit version instead.

  • Open the project solution file (dxl_x64_cpp.sln) located in the [DynamixelSDK folder]/c++/build/win64 directory.

  • If below dialog appears, select OK. This will adjust the toolset settings depending on your version of Visual Studio and Windows.

  • In the Solution Explorer on the right side, right-click the dxl_x64_cpp solution and select Build.


  • The SDK build is complete.
  • If the build was successful, the compiled library file will be saved at : [DynamixelSDK folder]/c++/build/[win64]/output/dxl_x64_cpp.dll

Check Build Properties

  • You can check or change the build properties through right-clicking on the project in the Solution Explorer and selecting Properties.

  • Build properties is shown as below

    • Output Directory: $(SolutionDir)output\
    • Intermediate Directory: $(Configuration)\
    • Platform Toolset: Visual Studio 20XX (v000)
    • Configuration Type: Dynamic Library (.dll)

    • Additional Include Directories: ..\..\..\include\dynamixel_sdk

WARNING: If the library file needs to be built in a lower or higher version of Visual Studio, change the Platform Toolset into the needed value. (ex: To use the DynamixelSDK c ver. library file in the MATLAB 2010 or LabVIEW 2010, the Platform Toolset should be changed to Visual Studio 2009 lower.)

Library Setup <C++ macOS>

Maintenance is in progress. We apologize for your inconvenience. The manual is available in the near future.