diff --git a/.clang-format b/.clang-format
new file mode 100644
index 00000000..8d8dc719
--- /dev/null
+++ b/.clang-format
@@ -0,0 +1,9 @@
+BasedOnStyle: LLVM
+IndentWidth: 4
+AccessModifierOffset: -4
+CommentPragmas: 'NOLINT'
+PackConstructorInitializers: CurrentLine
+AlignOperands: AlignAfterOperator
+AlignTrailingComments: true
+ColumnLimit: 0
+SeparateDefinitionBlocks: Always
\ No newline at end of file
diff --git a/.clang-tidy b/.clang-tidy
new file mode 100644
index 00000000..e9f4e763
--- /dev/null
+++ b/.clang-tidy
@@ -0,0 +1,10 @@
+Checks: "bugprone-*,performance-*,readability-*,modernize-*,hicpp-*,cppcoreguidelines-*,clang-analyzer-*,-readability-braces-around-statements,-hicpp-braces-around-statements,-cppcoreguidelines-non-private-member-variables-in-classes"
+WarningsAsErrors: ''
+HeaderFilterRegex: ''
+CheckOptions:
+ - key: readability-magic-numbers.IgnoredIntegerValues
+ value: '1;'
+ - key: hicpp-signed-bitwise.IgnorePositiveIntegerLiterals
+ value: 'true'
+ - key: readability-function-cognitive-complexity.IgnoreMacros
+ value: 'true'
\ No newline at end of file
diff --git a/.clangd b/.clangd
new file mode 100644
index 00000000..538f880e
--- /dev/null
+++ b/.clangd
@@ -0,0 +1,2 @@
+Diagnostics:
+ UnusedIncludes: Strict
\ No newline at end of file
diff --git a/.vscode/settings.json b/.vscode/settings.json
index f7c28a84..772e1688 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -88,5 +88,6 @@
"python.analysis.extraPaths": [
"/home/nomorenickels/Documents/WRover_Software/devel/lib/python3/dist-packages",
"/opt/ros/noetic/lib/python3/dist-packages"
- ]
+ ],
+ "cmake.sourceDirectory": "${workspaceFolder}/src"
}
\ No newline at end of file
diff --git a/src/arm_assembly/CMakeLists.txt b/src/arm_assembly/CMakeLists.txt
deleted file mode 100644
index 22bc5ed7..00000000
--- a/src/arm_assembly/CMakeLists.txt
+++ /dev/null
@@ -1,14 +0,0 @@
-cmake_minimum_required(VERSION 2.8.3)
-
-project(arm_assembly)
-
-find_package(catkin REQUIRED)
-
-catkin_package()
-
-find_package(roslaunch)
-
-foreach(dir config launch meshes urdf)
- install(DIRECTORY ${dir}/
- DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/${dir})
-endforeach(dir)
diff --git a/src/arm_assembly/config/joint_names_arm_assembly.yaml b/src/arm_assembly/config/joint_names_arm_assembly.yaml
deleted file mode 100644
index 159fc6fe..00000000
--- a/src/arm_assembly/config/joint_names_arm_assembly.yaml
+++ /dev/null
@@ -1 +0,0 @@
-controller_joint_names: ['', 'turntable', 'shoulder', 'elbow', 'forearm_roll', 'wrist_pitch', 'wrist_roll', ]
diff --git a/src/arm_assembly/export.log b/src/arm_assembly/export.log
deleted file mode 100644
index 0f28f844..00000000
--- a/src/arm_assembly/export.log
+++ /dev/null
@@ -1,566 +0,0 @@
-2022-01-28 23:47:18,488 INFO Logger.cs: 70 -
---------------------------------------------------------------------------------
-2022-01-28 23:47:18,508 INFO Logger.cs: 71 - Logging commencing for SW2URDF exporter
-2022-01-28 23:47:18,508 INFO Logger.cs: 73 - Commit version 1.6.0-4-g7f85cfe
-2022-01-28 23:47:18,509 INFO Logger.cs: 74 - Build version 1.6.7995.38578
-2022-01-28 23:47:18,510 INFO SwAddin.cs: 192 - Attempting to connect to SW
-2022-01-28 23:47:18,511 INFO SwAddin.cs: 197 - Setting up callbacks
-2022-01-28 23:47:18,511 INFO SwAddin.cs: 201 - Setting up command manager
-2022-01-28 23:47:18,512 INFO SwAddin.cs: 204 - Adding command manager
-2022-01-28 23:47:18,517 INFO SwAddin.cs: 263 - Adding Assembly export to file menu
-2022-01-28 23:47:18,517 INFO SwAddin.cs: 272 - Adding Part export to file menu
-2022-01-28 23:47:18,518 INFO SwAddin.cs: 210 - Adding event handlers
-2022-01-28 23:47:18,520 INFO SwAddin.cs: 217 - Connecting plugin to SolidWorks
-2022-01-29 04:01:04,989 INFO SwAddin.cs: 294 - Assembly export called for file ArmAssembly.SLDASM
-2022-01-29 04:01:07,687 INFO SwAddin.cs: 313 - Saving assembly
-2022-01-29 04:01:07,864 INFO SwAddin.cs: 316 - Opening property manager
-2022-01-29 04:01:07,891 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from ArmAssembly.SLDASM
-2022-01-29 04:01:07,894 INFO ExportHelperExtension.cs: 1136 - Found 44 in ArmAssembly.SLDASM
-2022-01-29 04:01:07,894 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in ArmAssembly.SLDASM
-2022-01-29 04:01:07,895 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:01:07,895 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:01:07,930 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Forarm-1
-2022-01-29 04:01:07,930 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:01:07,931 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Forarm-1
-2022-01-29 04:01:07,931 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Manipulator-1
-2022-01-29 04:01:07,931 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:01:07,932 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Manipulator-1
-2022-01-29 04:01:07,932 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Wrist-1
-2022-01-29 04:01:07,932 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:01:07,933 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Wrist-1
-2022-01-29 04:01:07,933 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from WristStructure-1
-2022-01-29 04:01:07,934 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:01:07,934 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in WristStructure-1
-2022-01-29 04:01:07,934 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from UpperArm-1
-2022-01-29 04:01:07,935 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:01:07,935 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in UpperArm-1
-2022-01-29 04:01:07,935 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from base-1
-2022-01-29 04:01:07,935 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:01:07,936 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in base-1
-2022-01-29 04:01:07,936 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Shoulder-1
-2022-01-29 04:01:07,936 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:01:07,937 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Shoulder-1
-2022-01-29 04:01:07,937 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from ArmAssembly.SLDASM
-2022-01-29 04:01:07,938 INFO ExportHelperExtension.cs: 1136 - Found 44 in ArmAssembly.SLDASM
-2022-01-29 04:01:07,938 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in ArmAssembly.SLDASM
-2022-01-29 04:01:07,938 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:01:07,938 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:01:07,939 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Forarm-1
-2022-01-29 04:01:07,939 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:01:07,939 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Forarm-1
-2022-01-29 04:01:07,940 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Manipulator-1
-2022-01-29 04:01:07,940 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:01:07,940 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Manipulator-1
-2022-01-29 04:01:07,941 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Wrist-1
-2022-01-29 04:01:07,941 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:01:07,941 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Wrist-1
-2022-01-29 04:01:07,941 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from WristStructure-1
-2022-01-29 04:01:07,942 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:01:07,942 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in WristStructure-1
-2022-01-29 04:01:07,942 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from UpperArm-1
-2022-01-29 04:01:07,943 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:01:07,943 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in UpperArm-1
-2022-01-29 04:01:07,943 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from base-1
-2022-01-29 04:01:07,944 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:01:07,944 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in base-1
-2022-01-29 04:01:07,944 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Shoulder-1
-2022-01-29 04:01:07,945 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:01:07,945 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Shoulder-1
-2022-01-29 04:01:08,306 INFO SwAddin.cs: 339 - Loading config tree
-2022-01-29 04:01:08,309 INFO ExportPropertyManagerExtension.cs: 520 - Starting new configuration
-2022-01-29 04:01:08,315 INFO SwAddin.cs: 344 - Showing property manager
-2022-01-29 04:01:36,796 INFO ExportPropertyManager.cs: 422 - Configuration saved
-2022-01-29 04:01:38,889 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from ArmAssembly.SLDASM
-2022-01-29 04:01:38,895 INFO ExportHelperExtension.cs: 1136 - Found 47 in ArmAssembly.SLDASM
-2022-01-29 04:01:38,895 INFO ExportHelperExtension.cs: 1145 - Found 1 features of type [CoordSys] in ArmAssembly.SLDASM
-2022-01-29 04:01:38,895 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:01:38,896 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:01:38,896 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Forarm-1
-2022-01-29 04:01:38,896 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:01:38,897 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Forarm-1
-2022-01-29 04:01:38,897 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Manipulator-1
-2022-01-29 04:01:38,897 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:01:38,898 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Manipulator-1
-2022-01-29 04:01:38,898 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Wrist-1
-2022-01-29 04:01:38,899 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:01:38,899 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Wrist-1
-2022-01-29 04:01:38,899 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from WristStructure-1
-2022-01-29 04:01:38,900 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:01:38,900 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in WristStructure-1
-2022-01-29 04:01:38,900 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from UpperArm-1
-2022-01-29 04:01:38,901 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:01:38,901 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in UpperArm-1
-2022-01-29 04:01:38,902 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from base-1
-2022-01-29 04:01:38,902 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:01:38,902 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in base-1
-2022-01-29 04:01:38,903 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Shoulder-1
-2022-01-29 04:01:38,903 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:01:38,903 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Shoulder-1
-2022-01-29 04:01:38,904 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from ArmAssembly.SLDASM
-2022-01-29 04:01:38,904 INFO ExportHelperExtension.cs: 1136 - Found 47 in ArmAssembly.SLDASM
-2022-01-29 04:01:38,904 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in ArmAssembly.SLDASM
-2022-01-29 04:01:38,905 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:01:38,905 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:01:38,905 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Forarm-1
-2022-01-29 04:01:38,906 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:01:38,906 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Forarm-1
-2022-01-29 04:01:38,906 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Manipulator-1
-2022-01-29 04:01:38,907 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:01:38,907 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Manipulator-1
-2022-01-29 04:01:38,907 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Wrist-1
-2022-01-29 04:01:38,907 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:01:38,908 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Wrist-1
-2022-01-29 04:01:38,908 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from WristStructure-1
-2022-01-29 04:01:38,908 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:01:38,909 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in WristStructure-1
-2022-01-29 04:01:38,909 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from UpperArm-1
-2022-01-29 04:01:38,909 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:01:38,910 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in UpperArm-1
-2022-01-29 04:01:38,910 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from base-1
-2022-01-29 04:01:38,910 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:01:38,911 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in base-1
-2022-01-29 04:01:38,911 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Shoulder-1
-2022-01-29 04:01:38,911 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:01:38,912 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Shoulder-1
-2022-01-29 04:01:38,958 INFO ExportPropertyManager.cs: 1142 - AfterClose called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:01:48,808 INFO SwAddin.cs: 294 - Assembly export called for file ArmAssembly.SLDASM
-2022-01-29 04:01:48,808 INFO SwAddin.cs: 299 - Save is required
-2022-01-29 04:01:48,809 INFO SwAddin.cs: 313 - Saving assembly
-2022-01-29 04:01:49,233 INFO SwAddin.cs: 316 - Opening property manager
-2022-01-29 04:01:49,234 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from ArmAssembly.SLDASM
-2022-01-29 04:01:49,235 INFO ExportHelperExtension.cs: 1136 - Found 47 in ArmAssembly.SLDASM
-2022-01-29 04:01:49,235 INFO ExportHelperExtension.cs: 1145 - Found 1 features of type [CoordSys] in ArmAssembly.SLDASM
-2022-01-29 04:01:49,235 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:01:49,236 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:01:49,236 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Forarm-1
-2022-01-29 04:01:49,236 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:01:49,237 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Forarm-1
-2022-01-29 04:01:49,237 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Manipulator-1
-2022-01-29 04:01:49,237 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:01:49,238 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Manipulator-1
-2022-01-29 04:01:49,238 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Wrist-1
-2022-01-29 04:01:49,238 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:01:49,239 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Wrist-1
-2022-01-29 04:01:49,239 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from WristStructure-1
-2022-01-29 04:01:49,240 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:01:49,240 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in WristStructure-1
-2022-01-29 04:01:49,240 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from UpperArm-1
-2022-01-29 04:01:49,241 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:01:49,241 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in UpperArm-1
-2022-01-29 04:01:49,241 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from base-1
-2022-01-29 04:01:49,242 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:01:49,248 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in base-1
-2022-01-29 04:01:49,248 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Shoulder-1
-2022-01-29 04:01:49,279 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:01:49,279 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Shoulder-1
-2022-01-29 04:01:49,280 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from ArmAssembly.SLDASM
-2022-01-29 04:01:49,280 INFO ExportHelperExtension.cs: 1136 - Found 47 in ArmAssembly.SLDASM
-2022-01-29 04:01:49,280 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in ArmAssembly.SLDASM
-2022-01-29 04:01:49,280 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:01:49,281 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:01:49,281 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Forarm-1
-2022-01-29 04:01:49,282 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:01:49,282 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Forarm-1
-2022-01-29 04:01:49,282 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Manipulator-1
-2022-01-29 04:01:49,283 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:01:49,283 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Manipulator-1
-2022-01-29 04:01:49,283 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Wrist-1
-2022-01-29 04:01:49,284 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:01:49,284 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Wrist-1
-2022-01-29 04:01:49,285 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from WristStructure-1
-2022-01-29 04:01:49,285 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:01:49,285 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in WristStructure-1
-2022-01-29 04:01:49,286 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from UpperArm-1
-2022-01-29 04:01:49,286 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:01:49,287 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in UpperArm-1
-2022-01-29 04:01:49,287 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from base-1
-2022-01-29 04:01:49,287 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:01:49,287 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in base-1
-2022-01-29 04:01:49,288 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Shoulder-1
-2022-01-29 04:01:49,288 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:01:49,288 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Shoulder-1
-2022-01-29 04:01:49,398 INFO SwAddin.cs: 339 - Loading config tree
-2022-01-29 04:01:49,400 INFO ConfigurationSerialization.cs: 276 - URDF Configuration found
-nametruebase_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruetypetruexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GeneratelinktruefalsesDYAAAUAAAD//v8SYgBhAHMAZQAtADEAQABBAHIAbQBBAHMAcwBlAG0AYgBsAHkABAAAABAAAAABAAAAAQAAABgAAAA=falsefalse
-2022-01-29 04:01:49,445 INFO LinkNode.cs: 35 - Building node base_link
-2022-01-29 04:01:49,446 INFO CommonSwOperations.cs: 221 - Loading SolidWorks components for base_link from E:\Robotics\WR\Tests\URDF_Assembly\ArmAssembly.SLDASM
-2022-01-29 04:01:49,447 INFO CommonSwOperations.cs: 245 - Loading component with PID ?6 ???b a s e - 1 @ A r m A s s e m b l y
-2022-01-29 04:01:49,448 INFO CommonSwOperations.cs: 254 - Successfully loaded component E:\Robotics\WR\Tests\URDF_Assembly\base.SLDPRT
-2022-01-29 04:01:49,449 INFO CommonSwOperations.cs: 230 - Loaded 1 components for link base_link
-2022-01-29 04:01:49,471 INFO SwAddin.cs: 344 - Showing property manager
-2022-01-29 04:02:15,278 INFO ExportPropertyManager.cs: 422 - Configuration saved
-2022-01-29 04:02:15,279 INFO ConfigurationSerialization.cs: 276 - URDF Configuration found
-nametruebase_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruetypetruexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GeneratelinktruefalsesDYAAAUAAAD//v8SYgBhAHMAZQAtADEAQABBAHIAbQBBAHMAcwBlAG0AYgBsAHkABAAAABAAAAABAAAAAQAAABgAAAA=falsefalse
-2022-01-29 04:02:15,425 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from ArmAssembly.SLDASM
-2022-01-29 04:02:15,426 INFO ExportHelperExtension.cs: 1136 - Found 47 in ArmAssembly.SLDASM
-2022-01-29 04:02:15,426 INFO ExportHelperExtension.cs: 1145 - Found 1 features of type [CoordSys] in ArmAssembly.SLDASM
-2022-01-29 04:02:15,427 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:02:15,427 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:02:15,427 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Forarm-1
-2022-01-29 04:02:15,428 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:02:15,428 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Forarm-1
-2022-01-29 04:02:15,428 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Manipulator-1
-2022-01-29 04:02:15,429 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:02:15,429 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Manipulator-1
-2022-01-29 04:02:15,429 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Wrist-1
-2022-01-29 04:02:15,430 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:02:15,430 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Wrist-1
-2022-01-29 04:02:15,430 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from WristStructure-1
-2022-01-29 04:02:15,430 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:02:15,431 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in WristStructure-1
-2022-01-29 04:02:15,431 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from UpperArm-1
-2022-01-29 04:02:15,431 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:02:15,432 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in UpperArm-1
-2022-01-29 04:02:15,432 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from base-1
-2022-01-29 04:02:15,432 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:02:15,433 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in base-1
-2022-01-29 04:02:15,433 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Shoulder-1
-2022-01-29 04:02:15,433 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:02:15,434 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Shoulder-1
-2022-01-29 04:02:15,434 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from ArmAssembly.SLDASM
-2022-01-29 04:02:15,434 INFO ExportHelperExtension.cs: 1136 - Found 47 in ArmAssembly.SLDASM
-2022-01-29 04:02:15,435 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in ArmAssembly.SLDASM
-2022-01-29 04:02:15,435 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:02:15,435 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:02:15,436 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Forarm-1
-2022-01-29 04:02:15,436 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:02:15,436 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Forarm-1
-2022-01-29 04:02:15,437 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Manipulator-1
-2022-01-29 04:02:15,437 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:02:15,437 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Manipulator-1
-2022-01-29 04:02:15,438 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Wrist-1
-2022-01-29 04:02:15,438 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:02:15,438 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Wrist-1
-2022-01-29 04:02:15,439 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from WristStructure-1
-2022-01-29 04:02:15,439 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:02:15,439 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in WristStructure-1
-2022-01-29 04:02:15,440 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from UpperArm-1
-2022-01-29 04:02:15,440 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:02:15,441 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in UpperArm-1
-2022-01-29 04:02:15,441 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from base-1
-2022-01-29 04:02:15,441 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:02:15,441 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in base-1
-2022-01-29 04:02:15,442 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Shoulder-1
-2022-01-29 04:02:15,442 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:02:15,443 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Shoulder-1
-2022-01-29 04:02:15,488 INFO ExportPropertyManager.cs: 1142 - AfterClose called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:03:44,437 INFO ConfigurationSerialization.cs: 276 - URDF Configuration found
-nametruebase_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruetypetruexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GeneratelinktruefalsesDYAAAUAAAD//v8SYgBhAHMAZQAtADEAQABBAHIAbQBBAHMAcwBlAG0AYgBsAHkABAAAABAAAAABAAAAAQAAABgAAAA=falsefalse
-2022-01-29 04:03:50,608 INFO SwAddin.cs: 294 - Assembly export called for file ArmAssembly.SLDASM
-2022-01-29 04:03:50,608 INFO SwAddin.cs: 299 - Save is required
-2022-01-29 04:03:50,608 INFO SwAddin.cs: 313 - Saving assembly
-2022-01-29 04:03:50,733 INFO SwAddin.cs: 316 - Opening property manager
-2022-01-29 04:03:50,733 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from ArmAssembly.SLDASM
-2022-01-29 04:03:50,734 INFO ExportHelperExtension.cs: 1136 - Found 47 in ArmAssembly.SLDASM
-2022-01-29 04:03:50,734 INFO ExportHelperExtension.cs: 1145 - Found 1 features of type [CoordSys] in ArmAssembly.SLDASM
-2022-01-29 04:03:50,734 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:03:50,735 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:03:50,735 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Forarm-1
-2022-01-29 04:03:50,736 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:03:50,736 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Forarm-1
-2022-01-29 04:03:50,736 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Manipulator-1
-2022-01-29 04:03:50,737 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:03:50,737 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Manipulator-1
-2022-01-29 04:03:50,738 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Wrist-1
-2022-01-29 04:03:50,738 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:03:50,739 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Wrist-1
-2022-01-29 04:03:50,739 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from WristStructure-1
-2022-01-29 04:03:50,740 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:03:50,740 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in WristStructure-1
-2022-01-29 04:03:50,740 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from UpperArm-1
-2022-01-29 04:03:50,741 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:03:50,741 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in UpperArm-1
-2022-01-29 04:03:50,741 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from base-1
-2022-01-29 04:03:50,742 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:03:50,743 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in base-1
-2022-01-29 04:03:50,743 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Shoulder-1
-2022-01-29 04:03:50,743 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:03:50,744 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Shoulder-1
-2022-01-29 04:03:50,744 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from ArmAssembly.SLDASM
-2022-01-29 04:03:50,745 INFO ExportHelperExtension.cs: 1136 - Found 47 in ArmAssembly.SLDASM
-2022-01-29 04:03:50,745 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in ArmAssembly.SLDASM
-2022-01-29 04:03:50,745 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:03:50,746 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:03:50,746 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Forarm-1
-2022-01-29 04:03:50,746 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:03:50,747 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Forarm-1
-2022-01-29 04:03:50,747 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Manipulator-1
-2022-01-29 04:03:50,747 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:03:50,748 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Manipulator-1
-2022-01-29 04:03:50,748 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Wrist-1
-2022-01-29 04:03:50,748 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:03:50,749 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Wrist-1
-2022-01-29 04:03:50,749 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from WristStructure-1
-2022-01-29 04:03:50,749 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:03:50,750 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in WristStructure-1
-2022-01-29 04:03:50,750 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from UpperArm-1
-2022-01-29 04:03:50,750 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:03:50,751 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in UpperArm-1
-2022-01-29 04:03:50,751 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from base-1
-2022-01-29 04:03:50,752 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:03:50,752 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in base-1
-2022-01-29 04:03:50,752 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Shoulder-1
-2022-01-29 04:03:50,753 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:03:50,753 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Shoulder-1
-2022-01-29 04:03:50,802 INFO SwAddin.cs: 339 - Loading config tree
-2022-01-29 04:03:50,803 INFO ConfigurationSerialization.cs: 276 - URDF Configuration found
-nametruebase_linkxyztrue9.1830074983591922E-190.0156064900891439551.5715252581589567E-18rpytrue000originfalsefalsevaluetrue0.93972387307473026massfalseixxtrue0.0025142902225504422ixytrue8.02209898558041E-21ixztrue-7.374852413660824E-20iyytrue0.0044229329573873041iyztrue2.2568808327940613E-20izztrue0.0021336882069818023inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruetypetruexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseOrigin_globallinktruefalsesDYAAAUAAAD//v8SYgBhAHMAZQAtADEAQABBAHIAbQBBAHMAcwBlAG0AYgBsAHkABAAAABAAAAABAAAAAQAAABgAAAA=falsefalse
-2022-01-29 04:03:50,803 INFO LinkNode.cs: 35 - Building node base_link
-2022-01-29 04:03:50,804 INFO CommonSwOperations.cs: 221 - Loading SolidWorks components for base_link from E:\Robotics\WR\Tests\URDF_Assembly\ArmAssembly.SLDASM
-2022-01-29 04:03:50,804 INFO CommonSwOperations.cs: 245 - Loading component with PID ?6 ???b a s e - 1 @ A r m A s s e m b l y
-2022-01-29 04:03:50,804 INFO CommonSwOperations.cs: 254 - Successfully loaded component E:\Robotics\WR\Tests\URDF_Assembly\base.SLDPRT
-2022-01-29 04:03:50,805 INFO CommonSwOperations.cs: 230 - Loaded 1 components for link base_link
-2022-01-29 04:03:50,813 INFO SwAddin.cs: 344 - Showing property manager
-2022-01-29 04:03:55,199 INFO ExportPropertyManager.cs: 1018 - OnComboboxSelectionChanged called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:04:02,915 INFO ExportPropertyManager.cs: 1136 - OnNumberBoxTrackingCompleted called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:04:06,718 INFO ExportPropertyManager.cs: 1136 - OnNumberBoxTrackingCompleted called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:04:08,432 INFO ExportPropertyManager.cs: 1136 - OnNumberBoxTrackingCompleted called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:07:25,776 INFO ExportPropertyManager.cs: 1018 - OnComboboxSelectionChanged called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:07:36,624 INFO ExportPropertyManager.cs: 1018 - OnComboboxSelectionChanged called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:08:34,715 INFO ExportPropertyManager.cs: 1018 - OnComboboxSelectionChanged called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:09:06,042 INFO ExportPropertyManager.cs: 1136 - OnNumberBoxTrackingCompleted called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:09:28,401 INFO ExportPropertyManager.cs: 1018 - OnComboboxSelectionChanged called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:09:33,716 INFO ExportPropertyManager.cs: 1136 - OnNumberBoxTrackingCompleted called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:10:26,057 INFO ExportPropertyManager.cs: 1018 - OnComboboxSelectionChanged called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:10:32,832 INFO ExportPropertyManager.cs: 1136 - OnNumberBoxTrackingCompleted called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:11:01,760 INFO ExportPropertyManager.cs: 1018 - OnComboboxSelectionChanged called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:11:10,262 INFO ExportPropertyManager.cs: 1136 - OnNumberBoxTrackingCompleted called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:11:32,320 INFO ExportPropertyManager.cs: 1018 - OnComboboxSelectionChanged called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:11:50,721 INFO ExportPropertyManager.cs: 422 - Configuration saved
-2022-01-29 04:11:50,723 INFO ConfigurationSerialization.cs: 276 - URDF Configuration found
-nametruebase_linkxyztrue9.1830074983591922E-190.0156064900891439551.5715252581589567E-18rpytrue000originfalsefalsevaluetrue0.93972387307473026massfalseixxtrue0.0025142902225504422ixytrue8.02209898558041E-21ixztrue-7.374852413660824E-20iyytrue0.0044229329573873041iyztrue2.2568808327940613E-20izztrue0.0021336882069818023inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruetypetruexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseOrigin_globallinktruefalsesDYAAAUAAAD//v8SYgBhAHMAZQAtADEAQABBAHIAbQBBAHMAcwBlAG0AYgBsAHkABAAAABAAAAABAAAAAQAAABgAAAA=falsefalse
-2022-01-29 04:11:50,809 INFO ExportHelperExtension.cs: 347 - Creating joint shoulderBase_link
-2022-01-29 04:11:50,815 INFO ExportHelperExtension.cs: 1397 - Fixing components for base_link
-2022-01-29 04:11:50,816 INFO ExportHelperExtension.cs: 1402 - Fixing 24
-2022-01-29 04:11:50,816 INFO ExportHelperExtension.cs: 1409 - Component 24 is already fixed
-2022-01-29 04:11:51,179 INFO : 0 - R1: 1, System.__ComObject, 1, System.Double[]
-2022-01-29 04:11:51,183 INFO ExportHelperExtension.cs: 841 - R2: 0, 0
-2022-01-29 04:11:51,183 INFO ExportHelperExtension.cs: 849 - L1: 0
-2022-01-29 04:11:51,184 INFO ExportHelperExtension.cs: 857 - L2: 0
-2022-01-29 04:11:53,156 WARN ExportHelperExtension.cs: 351 - Creating joint from parent base_link to child shoulderBase_link failed
-2022-01-29 04:11:53,162 INFO ExportHelperExtension.cs: 347 - Creating joint upperArm_link
-2022-01-29 04:11:53,163 INFO ExportHelperExtension.cs: 1397 - Fixing components for shoulderBase_link
-2022-01-29 04:11:53,163 INFO ExportHelperExtension.cs: 1402 - Fixing 25
-2022-01-29 04:11:53,163 INFO ExportHelperExtension.cs: 1402 - Fixing 24
-2022-01-29 04:11:53,164 INFO ExportHelperExtension.cs: 1409 - Component 24 is already fixed
-2022-01-29 04:11:53,382 INFO ExportHelperExtension.cs: 828 - R1: 1, System.__ComObject, 1, System.Double[]
-2022-01-29 04:11:53,383 INFO ExportHelperExtension.cs: 841 - R2: 0, 0
-2022-01-29 04:11:53,383 INFO ExportHelperExtension.cs: 849 - L1: 0
-2022-01-29 04:11:53,383 INFO ExportHelperExtension.cs: 857 - L2: 0
-2022-01-29 04:11:53,384 INFO ExportHelperExtension.cs: 1352 - Unfixing component 25
-2022-01-29 04:11:55,357 WARN ExportHelperExtension.cs: 351 - Creating joint from parent shoulderBase_link to child upperArm_link failed
-2022-01-29 04:11:55,362 INFO ExportHelperExtension.cs: 347 - Creating joint forarm_link
-2022-01-29 04:11:55,362 INFO ExportHelperExtension.cs: 1397 - Fixing components for upperArm_link
-2022-01-29 04:11:55,363 INFO ExportHelperExtension.cs: 1402 - Fixing 26
-2022-01-29 04:11:55,363 INFO ExportHelperExtension.cs: 1402 - Fixing 25
-2022-01-29 04:11:55,363 INFO ExportHelperExtension.cs: 1402 - Fixing 24
-2022-01-29 04:11:55,363 INFO ExportHelperExtension.cs: 1409 - Component 24 is already fixed
-2022-01-29 04:11:55,607 INFO ExportHelperExtension.cs: 828 - R1: 1, System.__ComObject, 1, System.Double[]
-2022-01-29 04:11:55,607 INFO ExportHelperExtension.cs: 841 - R2: 0, 0
-2022-01-29 04:11:55,607 INFO ExportHelperExtension.cs: 849 - L1: 0
-2022-01-29 04:11:55,608 INFO ExportHelperExtension.cs: 857 - L2: 0
-2022-01-29 04:11:55,608 INFO ExportHelperExtension.cs: 1352 - Unfixing component 26
-2022-01-29 04:11:55,608 INFO ExportHelperExtension.cs: 1352 - Unfixing component 25
-2022-01-29 04:11:57,637 WARN ExportHelperExtension.cs: 351 - Creating joint from parent upperArm_link to child forarm_link failed
-2022-01-29 04:11:57,644 INFO ExportHelperExtension.cs: 347 - Creating joint wirstBase_link
-2022-01-29 04:11:57,644 INFO ExportHelperExtension.cs: 1397 - Fixing components for forarm_link
-2022-01-29 04:11:57,645 INFO ExportHelperExtension.cs: 1402 - Fixing 35
-2022-01-29 04:11:57,645 INFO ExportHelperExtension.cs: 1402 - Fixing 26
-2022-01-29 04:11:57,645 INFO ExportHelperExtension.cs: 1402 - Fixing 25
-2022-01-29 04:11:57,646 INFO ExportHelperExtension.cs: 1402 - Fixing 24
-2022-01-29 04:11:57,646 INFO ExportHelperExtension.cs: 1409 - Component 24 is already fixed
-2022-01-29 04:11:57,884 INFO ExportHelperExtension.cs: 828 - R1: 1, System.__ComObject, 1, System.Double[]
-2022-01-29 04:11:57,885 INFO ExportHelperExtension.cs: 841 - R2: 0, 0
-2022-01-29 04:11:57,885 INFO ExportHelperExtension.cs: 849 - L1: 0
-2022-01-29 04:11:57,886 INFO ExportHelperExtension.cs: 857 - L2: 0
-2022-01-29 04:11:57,886 INFO ExportHelperExtension.cs: 1352 - Unfixing component 35
-2022-01-29 04:11:57,886 INFO ExportHelperExtension.cs: 1352 - Unfixing component 26
-2022-01-29 04:11:57,887 INFO ExportHelperExtension.cs: 1352 - Unfixing component 25
-2022-01-29 04:11:59,971 WARN ExportHelperExtension.cs: 351 - Creating joint from parent forarm_link to child wirstBase_link failed
-2022-01-29 04:11:59,975 INFO ExportHelperExtension.cs: 347 - Creating joint wrist_link
-2022-01-29 04:11:59,975 INFO ExportHelperExtension.cs: 1397 - Fixing components for wirstBase_link
-2022-01-29 04:11:59,976 INFO ExportHelperExtension.cs: 1402 - Fixing 40
-2022-01-29 04:11:59,976 INFO ExportHelperExtension.cs: 1402 - Fixing 35
-2022-01-29 04:11:59,976 INFO ExportHelperExtension.cs: 1402 - Fixing 26
-2022-01-29 04:11:59,977 INFO ExportHelperExtension.cs: 1402 - Fixing 25
-2022-01-29 04:11:59,977 INFO ExportHelperExtension.cs: 1402 - Fixing 24
-2022-01-29 04:11:59,977 INFO ExportHelperExtension.cs: 1409 - Component 24 is already fixed
-2022-01-29 04:12:00,240 INFO ExportHelperExtension.cs: 828 - R1: 1, System.__ComObject, 1, System.Double[]
-2022-01-29 04:12:00,241 INFO ExportHelperExtension.cs: 841 - R2: 0, 0
-2022-01-29 04:12:00,241 INFO ExportHelperExtension.cs: 849 - L1: 0
-2022-01-29 04:12:00,241 INFO ExportHelperExtension.cs: 857 - L2: 0
-2022-01-29 04:12:00,242 INFO ExportHelperExtension.cs: 1352 - Unfixing component 40
-2022-01-29 04:12:00,242 INFO ExportHelperExtension.cs: 1352 - Unfixing component 35
-2022-01-29 04:12:00,242 INFO ExportHelperExtension.cs: 1352 - Unfixing component 26
-2022-01-29 04:12:00,243 INFO ExportHelperExtension.cs: 1352 - Unfixing component 25
-2022-01-29 04:12:02,368 WARN ExportHelperExtension.cs: 351 - Creating joint from parent wirstBase_link to child wrist_link failed
-2022-01-29 04:12:02,372 INFO ExportHelperExtension.cs: 347 - Creating joint manipulator_link
-2022-01-29 04:12:02,373 INFO ExportHelperExtension.cs: 1397 - Fixing components for wrist_link
-2022-01-29 04:12:02,373 INFO ExportHelperExtension.cs: 1402 - Fixing 39
-2022-01-29 04:12:02,373 INFO ExportHelperExtension.cs: 1402 - Fixing 40
-2022-01-29 04:12:02,374 INFO ExportHelperExtension.cs: 1402 - Fixing 35
-2022-01-29 04:12:02,374 INFO ExportHelperExtension.cs: 1402 - Fixing 26
-2022-01-29 04:12:02,374 INFO ExportHelperExtension.cs: 1402 - Fixing 25
-2022-01-29 04:12:02,375 INFO ExportHelperExtension.cs: 1402 - Fixing 24
-2022-01-29 04:12:02,375 INFO ExportHelperExtension.cs: 1409 - Component 24 is already fixed
-2022-01-29 04:12:02,655 INFO ExportHelperExtension.cs: 828 - R1: 1, System.__ComObject, 1, System.Double[]
-2022-01-29 04:12:02,655 INFO ExportHelperExtension.cs: 841 - R2: 0, 0
-2022-01-29 04:12:02,656 INFO ExportHelperExtension.cs: 849 - L1: 0
-2022-01-29 04:12:02,656 INFO ExportHelperExtension.cs: 857 - L2: 0
-2022-01-29 04:12:02,698 INFO ExportHelperExtension.cs: 1352 - Unfixing component 39
-2022-01-29 04:12:02,699 INFO ExportHelperExtension.cs: 1352 - Unfixing component 40
-2022-01-29 04:12:02,699 INFO ExportHelperExtension.cs: 1352 - Unfixing component 35
-2022-01-29 04:12:02,699 INFO ExportHelperExtension.cs: 1352 - Unfixing component 26
-2022-01-29 04:12:02,700 INFO ExportHelperExtension.cs: 1352 - Unfixing component 25
-2022-01-29 04:12:04,927 WARN ExportHelperExtension.cs: 351 - Creating joint from parent wrist_link to child manipulator_link failed
-2022-01-29 04:12:05,029 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from ArmAssembly.SLDASM
-2022-01-29 04:12:05,030 INFO ExportHelperExtension.cs: 1136 - Found 59 in ArmAssembly.SLDASM
-2022-01-29 04:12:05,031 INFO ExportHelperExtension.cs: 1145 - Found 7 features of type [CoordSys] in ArmAssembly.SLDASM
-2022-01-29 04:12:05,031 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:12:05,031 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:12:05,032 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Forarm-1
-2022-01-29 04:12:05,032 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:12:05,032 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Forarm-1
-2022-01-29 04:12:05,033 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Manipulator-1
-2022-01-29 04:12:05,033 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:12:05,033 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Manipulator-1
-2022-01-29 04:12:05,034 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Wrist-1
-2022-01-29 04:12:05,034 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:12:05,035 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Wrist-1
-2022-01-29 04:12:05,035 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from WristStructure-1
-2022-01-29 04:12:05,035 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:12:05,036 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in WristStructure-1
-2022-01-29 04:12:05,036 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from UpperArm-1
-2022-01-29 04:12:05,036 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:12:05,037 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in UpperArm-1
-2022-01-29 04:12:05,037 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from base-1
-2022-01-29 04:12:05,037 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:12:05,038 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in base-1
-2022-01-29 04:12:05,038 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [CoordSys] from Shoulder-1
-2022-01-29 04:12:05,038 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:12:05,039 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [CoordSys] in Shoulder-1
-2022-01-29 04:12:05,039 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from ArmAssembly.SLDASM
-2022-01-29 04:12:05,039 INFO ExportHelperExtension.cs: 1136 - Found 59 in ArmAssembly.SLDASM
-2022-01-29 04:12:05,040 INFO ExportHelperExtension.cs: 1145 - Found 6 features of type [RefAxis] in ArmAssembly.SLDASM
-2022-01-29 04:12:05,040 INFO ExportHelperExtension.cs: 1148 - Proceeding through assembly components
-2022-01-29 04:12:05,040 INFO ExportHelperExtension.cs: 1160 - 7 components to check
-2022-01-29 04:12:05,041 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Forarm-1
-2022-01-29 04:12:05,041 INFO ExportHelperExtension.cs: 1136 - Found 35 in Forarm-1
-2022-01-29 04:12:05,041 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Forarm-1
-2022-01-29 04:12:05,042 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Manipulator-1
-2022-01-29 04:12:05,042 INFO ExportHelperExtension.cs: 1136 - Found 39 in Manipulator-1
-2022-01-29 04:12:05,042 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Manipulator-1
-2022-01-29 04:12:05,043 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Wrist-1
-2022-01-29 04:12:05,043 INFO ExportHelperExtension.cs: 1136 - Found 30 in Wrist-1
-2022-01-29 04:12:05,043 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Wrist-1
-2022-01-29 04:12:05,043 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from WristStructure-1
-2022-01-29 04:12:05,044 INFO ExportHelperExtension.cs: 1136 - Found 30 in WristStructure-1
-2022-01-29 04:12:05,044 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in WristStructure-1
-2022-01-29 04:12:05,044 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from UpperArm-1
-2022-01-29 04:12:05,045 INFO ExportHelperExtension.cs: 1136 - Found 41 in UpperArm-1
-2022-01-29 04:12:05,045 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in UpperArm-1
-2022-01-29 04:12:05,045 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from base-1
-2022-01-29 04:12:05,046 INFO ExportHelperExtension.cs: 1136 - Found 27 in base-1
-2022-01-29 04:12:05,046 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in base-1
-2022-01-29 04:12:05,046 INFO ExportHelperExtension.cs: 1125 - Retrieving features of type [RefAxis] from Shoulder-1
-2022-01-29 04:12:05,047 INFO ExportHelperExtension.cs: 1136 - Found 50 in Shoulder-1
-2022-01-29 04:12:05,047 INFO ExportHelperExtension.cs: 1145 - Found 0 features of type [RefAxis] in Shoulder-1
-2022-01-29 04:12:05,103 INFO ExportPropertyManager.cs: 1142 - AfterClose called. This method no longer throws an Exception. It just silently does nothing. Ok, except for this logging message
-2022-01-29 04:13:17,527 INFO AssemblyExportForm.cs: 253 - Completing URDF export
-2022-01-29 04:13:17,529 INFO ConfigurationSerialization.cs: 276 - URDF Configuration found
-nametruebase_linkxyztrue9.1830074983591922E-190.0156064900891439551.5715252581589567E-18rpytrue000originfalsefalsevaluetrue0.93972387307473026massfalseixxtrue0.0025142902225504422ixytrue8.02209898558041E-21ixztrue-7.374852413660824E-20iyytrue0.0044229329573873041iyztrue2.2568808327940613E-20izztrue0.0021336882069818023inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruetypetruexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GeneratelinktruenametrueshoulderBase_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametrueturntabletypetruerevolutexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GenerateAutomatically GeneratelinktruenametrueupperArm_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametrueshouldertypetruerevolutexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GenerateAutomatically Generatelinktruenametrueforarm_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametrueelbowtypetruerevolutexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GenerateAutomatically GeneratelinktruenametruewirstBase_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametrueforearm_rolltypetruerevolutexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GenerateAutomatically Generatelinktruenametruewrist_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruewrist_pitchtypetruerevolutexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GenerateAutomatically Generatelinktruenametruemanipulator_linkxyztrue000rpytrue000originfalsefalsevaluetrue0massfalseixxtrue0ixytrue0ixztrue0iyytrue0iyztrue0izztrue0inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue1111colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruewrist_rolltypetruerevolutexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAutomatically GenerateAutomatically GeneratelinktruefalsesDYAAAUAAAD//v8ZTQBhAG4AaQBwAHUAbABhAHQAbwByAC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAJAAAAA==falsefalsefalsesDYAAAUAAAD//v8TVwByAGkAcwB0AC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAJwAAAA==falsefalsefalsesDYAAAUAAAD//v8cVwByAGkAcwB0AFMAdAByAHUAYwB0AHUAcgBlAC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAKAAAAA==falsefalsefalsesDYAAAUAAAD//v8URgBvAHIAYQByAG0ALQAxAEAAQQByAG0AQQBzAHMAZQBtAGIAbAB5AAQAAAAQAAAAAQAAAAEAAAAjAAAAfalsefalsefalsesDYAAAUAAAD//v8WVQBwAHAAZQByAEEAcgBtAC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAGgAAAA==falsefalsefalsesDYAAAUAAAD//v8WUwBoAG8AdQBsAGQAZQByAC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAGQAAAA==falsefalsefalsesDYAAAUAAAD//v8SYgBhAHMAZQAtADEAQABBAHIAbQBBAHMAcwBlAG0AYgBsAHkABAAAABAAAAABAAAAAQAAABgAAAA=falsefalse
-2022-01-29 04:13:41,728 INFO AssemblyExportForm.cs: 309 - Saving URDF package to E:\Robotics\WR\Tests\URDF_Assembly\ArmAssembly.SLDASM
-2022-01-29 04:13:41,730 INFO ExportHelper.cs: 147 - Beginning the export process
-2022-01-29 04:13:41,731 INFO ExportHelper.cs: 153 - Creating package directories with name ArmAssembly.SLDASM and save path E:\Robotics\WR\Tests\URDF_Assembly
-2022-01-29 04:13:46,142 ERROR AssemblyExportForm.cs: 126 - Exception encountered in Assembly export form
-System.IO.IOException: Cannot create "E:\Robotics\WR\Tests\URDF_Assembly\ArmAssembly.SLDASM" because a file or directory with the same name already exists.
- at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
- at System.IO.Directory.InternalCreateDirectory(String fullPath, String path, Object dirSecurityObj, Boolean checkHost)
- at System.IO.Directory.InternalCreateDirectoryHelper(String path, Boolean checkHost)
- at SW2URDF.URDFExport.URDFPackage.CreateDirectories() in C:\Users\Stephen Brawner\workspace\solidworks_urdf_exporter\SW2URDF\URDFExport\URDFPackage.cs:line 78
- at SW2URDF.URDFExport.ExportHelper.ExportRobot(Boolean exportSTL) in C:\Users\Stephen Brawner\workspace\solidworks_urdf_exporter\SW2URDF\URDFExport\ExportHelper.cs:line 155
- at SW2URDF.UI.AssemblyExportForm.FinishExport(Boolean exportSTL) in C:\Users\Stephen Brawner\workspace\solidworks_urdf_exporter\SW2URDF\UI\AssemblyExportForm.cs:line 310
- at SW2URDF.UI.AssemblyExportForm.ButtonLinksFinishClick(Object sender, EventArgs e) in C:\Users\Stephen Brawner\workspace\solidworks_urdf_exporter\SW2URDF\UI\AssemblyExportForm.cs:line 243
- at System.Windows.Forms.Control.OnClick(EventArgs e)
- at System.Windows.Forms.Button.OnClick(EventArgs e)
- at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
- at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
- at System.Windows.Forms.Control.WndProc(Message& m)
- at System.Windows.Forms.ButtonBase.WndProc(Message& m)
- at System.Windows.Forms.Button.WndProc(Message& m)
- at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
-2022-01-29 04:13:53,196 INFO AssemblyExportForm.cs: 253 - Completing URDF export
-2022-01-29 04:13:53,197 INFO ConfigurationSerialization.cs: 276 - URDF Configuration found
-nametruebase_linkxyztrue1.035828411313638E-180.0156064900891439571.9357498027169635E-18rpytrue000originfalsefalsevaluetrue0.93972387307473026massfalseixxtrue0.0025142902225504418ixytrue8.6586155170563642E-21ixztrue-7.3748524136608228E-20iyytrue0.0044229329573873041iyztrue2.2771129801693437E-20izztrue0.0021336882069818023inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruetypetruexyztrue000rpytrue000originfalsefalselinktrueparenttruelinktruechildtruexyztrue000axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseOrigin_globallinktruenametrueshoulderBase_linkxyztrue-0.0122586821821900790.1285772495779757-0.0037054435004292684rpytrue000originfalsefalsevaluetrue0.99636680500272734massfalseixxtrue0.0065237009420894719ixytrue0.0010646616036528998ixztrue0.00028312700527736404iyytrue0.0050231810993567032iyztrue6.82113719161566E-05izztrue0.0086334538259584inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametrueturntabletypetruecontinuousxyztrue000.035865rpytrue1.57080-0.25129originfalsefalselinktruebase_linkparenttruelinktrueshoulderBase_linkchildtruexyztrue010axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAxis_turntableOrigin_turntablelinktruenametrueupperArm_linkxyztrue0.014397399905456463-3.2006162568792851E-050.27934838479492807rpytrue000originfalsefalsevaluetrue0.98521034391581119massfalseixxtrue0.023798222473833903ixytrue-8.87977733299251E-07ixztrue-0.0038853285623011904iyytrue0.029359472259760169iyztrue-7.1294436997127461E-06izztrue0.0062503483932010362inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametrueshouldertypetruecontinuousxyztrue00.180980.043071rpytrue-1.102100originfalsefalselinktrueshoulderBase_linkparenttruelinktrueupperArm_linkchildtruexyztrue100axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAxis_shoulderOrigin_shoulderlinktruenametrueforarm_linkxyztrue1.8457457784393227E-150.0550154986611603450.12015280303424725rpytrue000originfalsefalsevaluetrue0.51779610173045887massfalseixxtrue0.00404850874710771ixytrue2.1141942363467336E-18ixztrue-1.5487150407597627E-17iyytrue0.003755483293922739iyztrue-0.00037738536370652919izztrue0.00078832783822656164inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametrueelbowtypetruecontinuousxyztrue000.46634rpytrue2.493600originfalsefalselinktrueupperArm_linkparenttruelinktrueforarm_linkchildtruexyztrue100axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAxis_elbowOrigin_elbowlinktruenametruewirstBase_linkxyztrue-1.9428902930940239E-16-1.6653345369377348E-150.09870348455642336rpytrue000originfalsefalsevaluetrue0.30176308217533721massfalseixxtrue0.0021034428970283731ixytrue-2.7105054312137611E-19ixztrue-2.2497195079074217E-18iyytrue0.003050162507065583iyztrue1.8566962203814263E-18izztrue0.0010760910650178595inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametrueforearm_rolltypetruecontinuousxyztrue00.044450.2285rpytrue000originfalsefalselinktrueforarm_linkparenttruelinktruewirstBase_linkchildtruexyztrue001axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAxis_forearm_rollOrigin_forearm_rolllinktruenametruewrist_linkxyztrue4.3021142204224816E-16-2.7755575615628914E-170rpytrue000originfalsefalsevaluetrue0.44770711794317625massfalseixxtrue0.00036770226690479489ixytrue1.7999450129153882E-19ixztrue-7.453889935837843E-19iyytrue0.00084342708626575322iyztrue-1.3552527156068805E-20izztrue0.00084474612356065992inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruewrist_pitchtypetruecontinuousxyztrue000.23716rpytrue-1.33300originfalsefalselinktruewirstBase_linkparenttruelinktruewrist_linkchildtruexyztrue100axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAxis_wrist_pitchOrigin_wrist_pitchlinktruenametruemanipulator_linkxyztrue-0.00073032374046050341-0.000899365669252000230.049056009995342265rpytrue000originfalsefalsevaluetrue0.39742022555481077massfalseixxtrue0.0015968430526387824ixytrue-3.0724322789165625E-06ixztrue2.5323557993615128E-05iyytrue0.0016343224414687998iyztrue5.0029229087463509E-05izztrue0.00025632256399428705inertiafalseinertialfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruenametruergbatrue0.7921568627450980.819607843137254880.933333333333333351colorfalsefilenametruetexturefalsematerialfalsevisualfalsexyztrue000rpytrue000originfalsefalsefilenametruemeshfalsegeometrytruecollisionfalsenametruewrist_rolltypetruecontinuousxyztrue000rpytrue000.096862originfalsefalselinktruewrist_linkparenttruelinktruemanipulator_linkchildtruexyztrue001axisfalselowerfalseupperfalseefforttruevelocitytruelimitfalserisingfalsefallingfalsecalibrationfalsedampingfalsefrictionfalsedynamicsfalsesoft_upper_limitfalsesoft_lower_limitfalsek_positionfalsek_velocitytruesafety_controllerfalsejointtruemultiplierfalseoffsetfalsemimicfalsejointfalseAxis_wrist_rollOrigin_wrist_rolllinktruefalsesDYAAAUAAAD//v8ZTQBhAG4AaQBwAHUAbABhAHQAbwByAC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAJAAAAA==falsefalsefalsesDYAAAUAAAD//v8TVwByAGkAcwB0AC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAJwAAAA==falsefalsefalsesDYAAAUAAAD//v8cVwByAGkAcwB0AFMAdAByAHUAYwB0AHUAcgBlAC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAKAAAAA==falsefalsefalsesDYAAAUAAAD//v8URgBvAHIAYQByAG0ALQAxAEAAQQByAG0AQQBzAHMAZQBtAGIAbAB5AAQAAAAQAAAAAQAAAAEAAAAjAAAAfalsefalsefalsesDYAAAUAAAD//v8WVQBwAHAAZQByAEEAcgBtAC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAGgAAAA==falsefalsefalsesDYAAAUAAAD//v8WUwBoAG8AdQBsAGQAZQByAC0AMQBAAEEAcgBtAEEAcwBzAGUAbQBiAGwAeQAEAAAAEAAAAAEAAAABAAAAGQAAAA==falsefalsefalsesDYAAAUAAAD//v8SYgBhAHMAZQAtADEAQABBAHIAbQBBAHMAcwBlAG0AYgBsAHkABAAAABAAAAABAAAAAQAAABgAAAA=falsefalse
-2022-01-29 04:14:02,877 INFO AssemblyExportForm.cs: 309 - Saving URDF package to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM
-2022-01-29 04:14:02,877 INFO ExportHelper.cs: 147 - Beginning the export process
-2022-01-29 04:14:02,877 INFO ExportHelper.cs: 153 - Creating package directories with name ArmAssembly.SLDASM and save path E:\Robotics\WR\Tests\URDF_Assembly\URDF
-2022-01-29 04:14:04,383 INFO ExportHelper.cs: 162 - Creating CMakeLists.txt at E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\CMakeLists.txt
-2022-01-29 04:14:04,384 INFO ExportHelper.cs: 166 - Creating joint names config at E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\config\joint_names_ArmAssembly.SLDASM.yaml
-2022-01-29 04:14:04,385 INFO ExportHelper.cs: 170 - Creating package.xml at E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\package.xml
-2022-01-29 04:14:04,385 INFO PackageXMLWriter.cs: 21 - Creating package.xml at E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\package.xml
-2022-01-29 04:14:04,389 INFO ExportHelper.cs: 177 - Creating RVIZ launch file in E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\launch\
-2022-01-29 04:14:04,391 INFO ExportHelper.cs: 182 - Creating Gazebo launch file in E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\launch\
-2022-01-29 04:14:04,392 INFO ExportHelper.cs: 187 - Saving existing STL preferences
-2022-01-29 04:14:04,392 INFO ExportHelper.cs: 450 - Saving users preferences
-2022-01-29 04:14:04,393 INFO ExportHelper.cs: 190 - Modifying STL preferences
-2022-01-29 04:14:04,394 INFO ExportHelper.cs: 464 - Setting STL preferences
-2022-01-29 04:14:04,397 INFO ExportHelper.cs: 196 - Found 0 hidden components
-2022-01-29 04:14:04,398 INFO ExportHelper.cs: 197 - Hiding all components
-2022-01-29 04:14:04,618 INFO ExportHelper.cs: 204 - Beginning individual files export
-2022-01-29 04:14:04,622 INFO ExportHelper.cs: 270 - Exporting link: base_link
-2022-01-29 04:14:04,623 INFO ExportHelper.cs: 272 - Link base_link has 1 children
-2022-01-29 04:14:04,624 INFO ExportHelper.cs: 270 - Exporting link: shoulderBase_link
-2022-01-29 04:14:04,624 INFO ExportHelper.cs: 272 - Link shoulderBase_link has 1 children
-2022-01-29 04:14:04,625 INFO ExportHelper.cs: 270 - Exporting link: upperArm_link
-2022-01-29 04:14:04,625 INFO ExportHelper.cs: 272 - Link upperArm_link has 1 children
-2022-01-29 04:14:04,625 INFO ExportHelper.cs: 270 - Exporting link: forarm_link
-2022-01-29 04:14:04,626 INFO ExportHelper.cs: 272 - Link forarm_link has 1 children
-2022-01-29 04:14:04,626 INFO ExportHelper.cs: 270 - Exporting link: wirstBase_link
-2022-01-29 04:14:04,627 INFO ExportHelper.cs: 272 - Link wirstBase_link has 1 children
-2022-01-29 04:14:04,628 INFO ExportHelper.cs: 270 - Exporting link: wrist_link
-2022-01-29 04:14:04,628 INFO ExportHelper.cs: 272 - Link wrist_link has 1 children
-2022-01-29 04:14:04,629 INFO ExportHelper.cs: 270 - Exporting link: manipulator_link
-2022-01-29 04:14:04,629 INFO ExportHelper.cs: 272 - Link manipulator_link has 0 children
-2022-01-29 04:14:04,630 INFO ExportHelper.cs: 317 - manipulator_link: Exporting STL with coordinate frame Origin_wrist_roll
-2022-01-29 04:14:04,631 INFO ExportHelper.cs: 322 - manipulator_link: Reference geometry name
-2022-01-29 04:14:04,669 INFO ExportHelper.cs: 330 - Saving STL to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\meshes\manipulator_link.STL
-2022-01-29 04:14:04,785 INFO ExportHelper.cs: 405 - Removing SW header in STL file
-2022-01-29 04:14:04,785 INFO ExportHelper.cs: 317 - wrist_link: Exporting STL with coordinate frame Origin_wrist_pitch
-2022-01-29 04:14:04,786 INFO ExportHelper.cs: 322 - wrist_link: Reference geometry name
-2022-01-29 04:14:04,797 INFO ExportHelper.cs: 330 - Saving STL to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\meshes\wrist_link.STL
-2022-01-29 04:14:04,834 INFO ExportHelper.cs: 405 - Removing SW header in STL file
-2022-01-29 04:14:04,835 INFO ExportHelper.cs: 317 - wirstBase_link: Exporting STL with coordinate frame Origin_forearm_roll
-2022-01-29 04:14:04,835 INFO ExportHelper.cs: 322 - wirstBase_link: Reference geometry name
-2022-01-29 04:14:04,846 INFO ExportHelper.cs: 330 - Saving STL to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\meshes\wirstBase_link.STL
-2022-01-29 04:14:04,873 INFO ExportHelper.cs: 405 - Removing SW header in STL file
-2022-01-29 04:14:04,874 INFO ExportHelper.cs: 317 - forarm_link: Exporting STL with coordinate frame Origin_elbow
-2022-01-29 04:14:04,874 INFO ExportHelper.cs: 322 - forarm_link: Reference geometry name
-2022-01-29 04:14:04,932 INFO ExportHelper.cs: 330 - Saving STL to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\meshes\forarm_link.STL
-2022-01-29 04:14:04,986 INFO ExportHelper.cs: 405 - Removing SW header in STL file
-2022-01-29 04:14:04,987 INFO ExportHelper.cs: 317 - upperArm_link: Exporting STL with coordinate frame Origin_shoulder
-2022-01-29 04:14:04,987 INFO ExportHelper.cs: 322 - upperArm_link: Reference geometry name
-2022-01-29 04:14:05,001 INFO ExportHelper.cs: 330 - Saving STL to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\meshes\upperArm_link.STL
-2022-01-29 04:14:05,035 INFO ExportHelper.cs: 405 - Removing SW header in STL file
-2022-01-29 04:14:05,035 INFO ExportHelper.cs: 317 - shoulderBase_link: Exporting STL with coordinate frame Origin_turntable
-2022-01-29 04:14:05,036 INFO ExportHelper.cs: 322 - shoulderBase_link: Reference geometry name
-2022-01-29 04:14:05,111 INFO ExportHelper.cs: 330 - Saving STL to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\meshes\shoulderBase_link.STL
-2022-01-29 04:14:05,189 INFO ExportHelper.cs: 405 - Removing SW header in STL file
-2022-01-29 04:14:05,190 INFO ExportHelper.cs: 317 - base_link: Exporting STL with coordinate frame Origin_global
-2022-01-29 04:14:05,191 INFO ExportHelper.cs: 322 - base_link: Reference geometry name
-2022-01-29 04:14:05,235 INFO ExportHelper.cs: 330 - Saving STL to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\meshes\base_link.STL
-2022-01-29 04:14:05,274 INFO ExportHelper.cs: 405 - Removing SW header in STL file
-2022-01-29 04:14:05,275 INFO ExportHelper.cs: 145 - Showing all components except previously hidden components
-2022-01-29 04:14:05,465 INFO ExportHelper.cs: 145 - Resetting STL preferences
-2022-01-29 04:14:05,466 INFO ExportHelper.cs: 478 - Returning STL preferences to user preferences
-2022-01-29 04:14:05,466 INFO ExportHelper.cs: 228 - Writing URDF file to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\urdf\ArmAssembly.SLDASM.urdf
-2022-01-29 04:14:05,470 INFO CSVImportExport.cs: 32 - Writing CSV file E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\urdf\ArmAssembly.SLDASM.csv
-2022-01-29 04:14:05,493 ERROR CSVImportExport.cs: 130 - The following columns were not written to the CSV: Link.Joint.ChildLink.link,
-2022-01-29 04:14:05,494 ERROR CSVImportExport.cs: 130 - The following columns were not written to the CSV: Link.Joint.ChildLink.link,
-2022-01-29 04:14:05,495 ERROR CSVImportExport.cs: 130 - The following columns were not written to the CSV: Link.Joint.ChildLink.link,
-2022-01-29 04:14:05,495 ERROR CSVImportExport.cs: 130 - The following columns were not written to the CSV: Link.Joint.ChildLink.link,
-2022-01-29 04:14:05,495 ERROR CSVImportExport.cs: 130 - The following columns were not written to the CSV: Link.Joint.ChildLink.link,
-2022-01-29 04:14:05,496 ERROR CSVImportExport.cs: 130 - The following columns were not written to the CSV: Link.Joint.ChildLink.link,
-2022-01-29 04:14:05,496 ERROR CSVImportExport.cs: 130 - The following columns were not written to the CSV: Link.Joint.ChildLink.link,
-2022-01-29 04:14:05,497 INFO ExportHelper.cs: 234 - Copying log file
-2022-01-29 04:14:05,497 INFO ExportHelper.cs: 439 - Copying C:\Users\Payton Jackson\sw2urdf_logs\sw2urdf.log to E:\Robotics\WR\Tests\URDF_Assembly\URDF\ArmAssembly.SLDASM\export.log
diff --git a/src/arm_assembly/launch/display.launch b/src/arm_assembly/launch/display.launch
deleted file mode 100644
index 96a2d12e..00000000
--- a/src/arm_assembly/launch/display.launch
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/arm_assembly/launch/gazebo.launch b/src/arm_assembly/launch/gazebo.launch
deleted file mode 100644
index 57481cd1..00000000
--- a/src/arm_assembly/launch/gazebo.launch
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/arm_assembly/meshes/forarm_link.STL b/src/arm_assembly/meshes/forarm_link.STL
deleted file mode 100644
index fb511b34..00000000
Binary files a/src/arm_assembly/meshes/forarm_link.STL and /dev/null differ
diff --git a/src/arm_assembly/meshes/manipulator_link.STL b/src/arm_assembly/meshes/manipulator_link.STL
deleted file mode 100644
index 6bbdfa56..00000000
Binary files a/src/arm_assembly/meshes/manipulator_link.STL and /dev/null differ
diff --git a/src/arm_assembly/meshes/shoulderBase_link.STL b/src/arm_assembly/meshes/shoulderBase_link.STL
deleted file mode 100644
index bad98d04..00000000
Binary files a/src/arm_assembly/meshes/shoulderBase_link.STL and /dev/null differ
diff --git a/src/arm_assembly/meshes/upperArm_link.STL b/src/arm_assembly/meshes/upperArm_link.STL
deleted file mode 100644
index d111945c..00000000
Binary files a/src/arm_assembly/meshes/upperArm_link.STL and /dev/null differ
diff --git a/src/arm_assembly/meshes/wirstBase_link.STL b/src/arm_assembly/meshes/wirstBase_link.STL
deleted file mode 100644
index 0e2de135..00000000
Binary files a/src/arm_assembly/meshes/wirstBase_link.STL and /dev/null differ
diff --git a/src/arm_assembly/meshes/wrist_link.STL b/src/arm_assembly/meshes/wrist_link.STL
deleted file mode 100644
index 0e6b6ab5..00000000
Binary files a/src/arm_assembly/meshes/wrist_link.STL and /dev/null differ
diff --git a/src/arm_assembly/package.xml b/src/arm_assembly/package.xml
deleted file mode 100644
index b357a057..00000000
--- a/src/arm_assembly/package.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-
- arm_assembly
- 1.0.0
-
-
URDF Description package for arm_assembly
-
This package contains configuration data, 3D models and launch files
-for arm_assembly robot
-
- TODO
-
- BSD
- catkin
- roslaunch
- robot_state_publisher
- rviz
- joint_state_publisher_gui
- gazebo
-
-
-
-
\ No newline at end of file
diff --git a/src/arm_assembly/urdf/arm_assembly.csv b/src/arm_assembly/urdf/arm_assembly.csv
deleted file mode 100644
index 06858e24..00000000
--- a/src/arm_assembly/urdf/arm_assembly.csv
+++ /dev/null
@@ -1,8 +0,0 @@
-Link Name,Center of Mass X,Center of Mass Y,Center of Mass Z,Center of Mass Roll,Center of Mass Pitch,Center of Mass Yaw,Mass,Moment Ixx,Moment Ixy,Moment Ixz,Moment Iyy,Moment Iyz,Moment Izz,Visual X,Visual Y,Visual Z,Visual Roll,Visual Pitch,Visual Yaw,Mesh Filename,Color Red,Color Green,Color Blue,Color Alpha,Collision X,Collision Y,Collision Z,Collision Roll,Collision Pitch,Collision Yaw,Collision Mesh Filename,Material Name,SW Components,Coordinate System,Axis Name,Joint Name,Joint Type,Joint Origin X,Joint Origin Y,Joint Origin Z,Joint Origin Roll,Joint Origin Pitch,Joint Origin Yaw,Parent,Joint Axis X,Joint Axis Y,Joint Axis Z,Limit Effort,Limit Velocity,Limit Lower,Limit Upper,Calibration rising,Calibration falling,Dynamics Damping,Dynamics Friction,Safety Soft Upper,Safety Soft Lower,Safety K Position,Safety K Velocity
-base_link,1.03582841131364E-18,0.015606490089144,1.93574980271696E-18,0,0,0,0.93972387307473,0.00251429022255044,8.65861551705636E-21,-7.37485241366082E-20,0.0044229329573873,2.27711298016934E-20,0.0021336882069818,0,0,0,0,0,0,package://arm_assembly/meshes/base_link.stl,0.792156862745098,0.819607843137255,0.933333333333333,1,0,0,0,0,0,0,package://arm_assembly/meshes/base_link.stl,,base-1,Origin_global,,,,0,0,0,0,0,0,,0,0,0,,,,,,,,,,,,
-shoulderBase_link,-0.0122586821821901,0.128577249577976,-0.00370544350042927,0,0,0,0.996366805002727,0.00652370094208947,0.0010646616036529,0.000283127005277364,0.0050231810993567,6.82113719161566E-05,0.0086334538259584,0,0,0,0,0,0,package://arm_assembly/meshes/shoulderBase_link.stl,0.792156862745098,0.819607843137255,0.933333333333333,1,0,0,0,0,0,0,package://arm_assembly/meshes/shoulderBase_link.stl,,Shoulder-1,Origin_turntable,Axis_turntable,turntable,continuous,0,0,0.035865,1.5708,0,-0.25129,base_link,0,1,0,,,,,,,,,,,,
-upperArm_link,0.0143973999054565,-3.20061625687929E-05,0.279348384794928,0,0,0,0.985210343915811,0.0237982224738339,-8.87977733299251E-07,-0.00388532856230119,0.0293594722597602,-7.12944369971275E-06,0.00625034839320104,0,0,0,0,0,0,package://arm_assembly/meshes/upperArm_link.stl,0.792156862745098,0.819607843137255,0.933333333333333,1,0,0,0,0,0,0,package://arm_assembly/meshes/upperArm_link.stl,,UpperArm-1,Origin_shoulder,Axis_shoulder,shoulder,continuous,0,0.18098,0.043071,-1.1021,0,0,shoulderBase_link,1,0,0,,,,,,,,,,,,
-forarm_link,1.84574577843932E-15,0.0550154986611603,0.120152803034247,0,0,0,0.517796101730459,0.00404850874710771,2.11419423634673E-18,-1.54871504075976E-17,0.00375548329392274,-0.000377385363706529,0.000788327838226562,0,0,0,0,0,0,package://arm_assembly/meshes/forarm_link.stl,0.792156862745098,0.819607843137255,0.933333333333333,1,0,0,0,0,0,0,package://arm_assembly/meshes/forarm_link.stl,,Forarm-1,Origin_elbow,Axis_elbow,elbow,continuous,0,0,0.46634,2.4936,0,0,upperArm_link,1,0,0,,,,,,,,,,,,
-wirstBase_link,-1.94289029309402E-16,-1.66533453693773E-15,0.0987034845564234,0,0,0,0.301763082175337,0.00210344289702837,-2.71050543121376E-19,-2.24971950790742E-18,0.00305016250706558,1.85669622038143E-18,0.00107609106501786,0,0,0,0,0,0,package://arm_assembly/meshes/wirstBase_link.stl,0.792156862745098,0.819607843137255,0.933333333333333,1,0,0,0,0,0,0,package://arm_assembly/meshes/wirstBase_link.stl,,WristStructure-1,Origin_forearm_roll,Axis_forearm_roll,forearm_roll,continuous,0,0.04445,0.2285,0,0,0,forarm_link,0,0,1,,,,,,,,,,,,
-wrist_link,4.30211422042248E-16,-2.77555756156289E-17,0,0,0,0,0.447707117943176,0.000367702266904795,1.79994501291539E-19,-7.45388993583784E-19,0.000843427086265753,-1.35525271560688E-20,0.00084474612356066,0,0,0,0,0,0,package://arm_assembly/meshes/wrist_link.stl,0.792156862745098,0.819607843137255,0.933333333333333,1,0,0,0,0,0,0,package://arm_assembly/meshes/wrist_link.stl,,Wrist-1,Origin_wrist_pitch,Axis_wrist_pitch,wrist_pitch,continuous,0,0,0.23716,-1.333,0,0,wirstBase_link,1,0,0,,,,,,,,,,,,
-manipulator_link,-0.000730323740460503,-0.000899365669252,0.0490560099953423,0,0,0,0.397420225554811,0.00159684305263878,-3.07243227891656E-06,2.53235579936151E-05,0.0016343224414688,5.00292290874635E-05,0.000256322563994287,0,0,0,0,0,0,package://arm_assembly/meshes/manipulator_link.stl,0.792156862745098,0.819607843137255,0.933333333333333,1,0,0,0,0,0,0,package://arm_assembly/meshes/manipulator_link.stl,,Manipulator-1,Origin_wrist_roll,Axis_wrist_roll,wrist_roll,continuous,0,0,0,0,0,0.096862,wrist_link,0,0,1,,,,,,,,,,,,
diff --git a/src/arm_assembly/urdf/arm_assembly.urdf b/src/arm_assembly/urdf/arm_assembly.urdf
deleted file mode 100644
index 7cce560c..00000000
--- a/src/arm_assembly/urdf/arm_assembly.urdf
+++ /dev/null
@@ -1,282 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- transmission_interface/SimpleTransmission
-
- hardware_interface/EffortJointInterface
-
-
- hardware_interface/EffortJointInterface
- 1
-
-
-
- transmission_interface/SimpleTransmission
-
- hardware_interface/EffortJointInterface
-
-
- hardware_interface/EffortJointInterface
- 1
-
-
-
- transmission_interface/SimpleTransmission
-
- hardware_interface/EffortJointInterface
-
-
- hardware_interface/EffortJointInterface
- 1
-
-
-
- transmission_interface/SimpleTransmission
-
- hardware_interface/EffortJointInterface
-
-
- hardware_interface/EffortJointInterface
- 1
-
-
-
- transmission_interface/SimpleTransmission
-
- hardware_interface/EffortJointInterface
-
-
- hardware_interface/EffortJointInterface
- 1
-
-
-
- transmission_interface/SimpleTransmission
-
- hardware_interface/EffortJointInterface
-
-
- hardware_interface/EffortJointInterface
- 1
-
-
-
-
- /
-
-
-
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/CMakeLists.txt b/src/wr_control_drive_arm/CMakeLists.txt
index c9d43c92..a122dafe 100644
--- a/src/wr_control_drive_arm/CMakeLists.txt
+++ b/src/wr_control_drive_arm/CMakeLists.txt
@@ -1,12 +1,12 @@
cmake_minimum_required(VERSION 3.8)
project(wr_control_drive_arm)
-## Compile as C++11, supported in ROS Kinetic and newer
-# add_compile_options(-std=c++11)
+# # Compile as C++11, supported in ROS Kinetic and newer
+add_compile_options(-std=c++17)
-## Find catkin macros and libraries
-## if COMPONENTS list like find_package(catkin REQUIRED COMPONENTS xyz)
-## is used, also find other catkin packages
+# # Find catkin macros and libraries
+# # if COMPONENTS list like find_package(catkin REQUIRED COMPONENTS xyz)
+# # is used, also find other catkin packages
find_package(catkin REQUIRED COMPONENTS
roscpp
rospy
@@ -15,199 +15,213 @@ find_package(catkin REQUIRED COMPONENTS
sensor_msgs
)
-## System dependencies are found with CMake's conventions
+# # System dependencies are found with CMake's conventions
# find_package(Boost REQUIRED COMPONENTS system)
-
-## Uncomment this if the package has a setup.py. This macro ensures
-## modules and global scripts declared therein get installed
-## See http://ros.org/doc/api/catkin/html/user_guide/setup_dot_py.html
+# # Uncomment this if the package has a setup.py. This macro ensures
+# # modules and global scripts declared therein get installed
+# # See http://ros.org/doc/api/catkin/html/user_guide/setup_dot_py.html
# catkin_python_setup()
-################################################
-## Declare ROS messages, services and actions ##
-################################################
-
-## To declare and build messages, services or actions from within this
-## package, follow these steps:
-## * Let MSG_DEP_SET be the set of packages whose message types you use in
-## your messages/services/actions (e.g. std_msgs, actionlib_msgs, ...).
-## * In the file package.xml:
-## * add a build_depend tag for "message_generation"
-## * add a build_depend and a exec_depend tag for each package in MSG_DEP_SET
-## * If MSG_DEP_SET isn't empty the following dependency has been pulled in
-## but can be declared for certainty nonetheless:
-## * add a exec_depend tag for "message_runtime"
-## * In this file (CMakeLists.txt):
-## * add "message_generation" and every package in MSG_DEP_SET to
-## find_package(catkin REQUIRED COMPONENTS ...)
-## * add "message_runtime" and every package in MSG_DEP_SET to
-## catkin_package(CATKIN_DEPENDS ...)
-## * uncomment the add_*_files sections below as needed
-## and list every .msg/.srv/.action file to be processed
-## * uncomment the generate_messages entry below
-## * add every package in MSG_DEP_SET to generate_messages(DEPENDENCIES ...)
-
-## Generate messages in the 'msg' folder
+# ###############################################
+# # Declare ROS messages, services and actions ##
+# ###############################################
+
+# # To declare and build messages, services or actions from within this
+# # package, follow these steps:
+# # * Let MSG_DEP_SET be the set of packages whose message types you use in
+# # your messages/services/actions (e.g. std_msgs, actionlib_msgs, ...).
+# # * In the file package.xml:
+# # * add a build_depend tag for "message_generation"
+# # * add a build_depend and a exec_depend tag for each package in MSG_DEP_SET
+# # * If MSG_DEP_SET isn't empty the following dependency has been pulled in
+# # but can be declared for certainty nonetheless:
+# # * add a exec_depend tag for "message_runtime"
+# # * In this file (CMakeLists.txt):
+# # * add "message_generation" and every package in MSG_DEP_SET to
+# # find_package(catkin REQUIRED COMPONENTS ...)
+# # * add "message_runtime" and every package in MSG_DEP_SET to
+# # catkin_package(CATKIN_DEPENDS ...)
+# # * uncomment the add_*_files sections below as needed
+# # and list every .msg/.srv/.action file to be processed
+# # * uncomment the generate_messages entry below
+# # * add every package in MSG_DEP_SET to generate_messages(DEPENDENCIES ...)
+
+# # Generate messages in the 'msg' folder
# add_message_files(
-# FILES
-# Message1.msg
-# Message2.msg
+# FILES
+# Message1.msg
+# Message2.msg
# )
-## Generate services in the 'srv' folder
+# # Generate services in the 'srv' folder
# add_service_files(
-# FILES
-# Service1.srv
-# Service2.srv
+# FILES
+# Service1.srv
+# Service2.srv
# )
-## Generate actions in the 'action' folder
+# # Generate actions in the 'action' folder
# add_action_files(
-# FILES
-# Action1.action
-# Action2.action
+# FILES
+# Action1.action
+# Action2.action
# )
-## Generate added messages and services with any dependencies listed here
+# # Generate added messages and services with any dependencies listed here
# generate_messages(
-# DEPENDENCIES
-# std_msgs # Or other packages containing msgs
+# DEPENDENCIES
+# std_msgs # Or other packages containing msgs
# )
-################################################
-## Declare ROS dynamic reconfigure parameters ##
-################################################
-
-## To declare and build dynamic reconfigure parameters within this
-## package, follow these steps:
-## * In the file package.xml:
-## * add a build_depend and a exec_depend tag for "dynamic_reconfigure"
-## * In this file (CMakeLists.txt):
-## * add "dynamic_reconfigure" to
-## find_package(catkin REQUIRED COMPONENTS ...)
-## * uncomment the "generate_dynamic_reconfigure_options" section below
-## and list every .cfg file to be processed
-
-## Generate dynamic reconfigure parameters in the 'cfg' folder
+# ###############################################
+# # Declare ROS dynamic reconfigure parameters ##
+# ###############################################
+
+# # To declare and build dynamic reconfigure parameters within this
+# # package, follow these steps:
+# # * In the file package.xml:
+# # * add a build_depend and a exec_depend tag for "dynamic_reconfigure"
+# # * In this file (CMakeLists.txt):
+# # * add "dynamic_reconfigure" to
+# # find_package(catkin REQUIRED COMPONENTS ...)
+# # * uncomment the "generate_dynamic_reconfigure_options" section below
+# # and list every .cfg file to be processed
+
+# # Generate dynamic reconfigure parameters in the 'cfg' folder
# generate_dynamic_reconfigure_options(
-# cfg/DynReconf1.cfg
-# cfg/DynReconf2.cfg
+# cfg/DynReconf1.cfg
+# cfg/DynReconf2.cfg
# )
-###################################
-## catkin specific configuration ##
-###################################
-## The catkin_package macro generates cmake config files for your package
-## Declare things to be passed to dependent projects
-## INCLUDE_DIRS: uncomment this if your package contains header files
-## LIBRARIES: libraries you create in this project that dependent projects also need
-## CATKIN_DEPENDS: catkin_packages dependent projects also need
-## DEPENDS: system dependencies of this project that dependent projects also need
+# ##################################
+# # catkin specific configuration ##
+# ##################################
+# # The catkin_package macro generates cmake config files for your package
+# # Declare things to be passed to dependent projects
+# # INCLUDE_DIRS: uncomment this if your package contains header files
+# # LIBRARIES: libraries you create in this project that dependent projects also need
+# # CATKIN_DEPENDS: catkin_packages dependent projects also need
+# # DEPENDS: system dependencies of this project that dependent projects also need
catkin_package(
-# INCLUDE_DIRS include
-# LIBRARIES wr_control_drive_science
-# CATKIN_DEPENDS roscpp rospy
-# DEPENDS system_lib
+
+ # INCLUDE_DIRS include
+ # LIBRARIES wr_control_drive_science
+ # CATKIN_DEPENDS roscpp rospy
+ # DEPENDS system_lib
)
-###########
-## Build ##
-###########
+# ##########
+# # Build ##
+# ##########
-## Specify additional locations of header files
-## Your package locations should be listed before other locations
+# # Specify additional locations of header files
+# # Your package locations should be listed before other locations
include_directories(
-# include
+
+ # include
${catkin_INCLUDE_DIRS}
)
-## Declare a C++ library
- add_library( ${PROJECT_NAME}
- src/ArmMotor.cpp
- src/AbstractJoint.cpp
- src/DifferentialJoint.cpp
- src/SimpleJoint.cpp
- )
-
-## Add cmake target dependencies of the library
-## as an example, code may need to be generated before libraries
-## either from message generation or dynamic reconfigure
+# # Declare a C++ library
+add_library(${PROJECT_NAME}
+ src/DifferentialJointToMotorSpeedConverter.cpp
+ src/DirectJointToMotorSpeedConverter.cpp
+ src/Joint.cpp
+ src/MathUtil.cpp
+ src/Motor.cpp
+ src/SingleEncoderJointPositionMonitor.cpp
+)
+
+# # Add cmake target dependencies of the library
+# # as an example, code may need to be generated before libraries
+# # either from message generation or dynamic reconfigure
# add_dependencies(${PROJECT_NAME} ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS})
-## Declare a C++ executable
-## With catkin_make all packages are built within a single CMake context
-## The recommended prefix ensures that target names across packages don't collide
+# # Declare a C++ executable
+# # With catkin_make all packages are built within a single CMake context
+# # The recommended prefix ensures that target names across packages don't collide
# add_executable(${PROJECT_NAME}_node src/wr_control_drive_arm_node.cpp)
-add_executable(ArmControlSystem src/ArmControlSystem.cpp)
-target_link_libraries(ArmControlSystem ${catkin_LIBRARIES} ${PROJECT_NAME})
-
-## Rename C++ executable without prefix
-## The above recommended prefix causes long target names, the following renames the
-## target back to the shorter version for ease of user use
-## e.g. "rosrun someones_pkg node" instead of "rosrun someones_pkg someones_pkg_node"
+add_executable(ArmControlActionServer src/ArmControlActionServer.cpp)
+target_link_libraries(ArmControlActionServer ${catkin_LIBRARIES} ${PROJECT_NAME})
+add_executable(JointStatePublisher src/JointStatePublisher.cpp)
+target_link_libraries(JointStatePublisher ${catkin_LIBRARIES} ${PROJECT_NAME})
+add_executable(testDifferential src/testDifferential.cpp)
+target_link_libraries(testDifferential ${catkin_LIBRARIES} ${PROJECT_NAME})
+
+set_property(TARGET ArmControlActionServer PROPERTY CXX_STANDARD 17)
+set_property(TARGET JointStatePublisher PROPERTY CXX_STANDARD 17)
+set_property(TARGET ArmControlActionServer PROPERTY CXX_STANDARD_REQUIRED true)
+set_property(TARGET JointStatePublisher PROPERTY CXX_STANDARD_REQUIRED true)
+set_property(TARGET testDifferential PROPERTY CXX_STANDARD 17)
+set_property(TARGET testDifferential PROPERTY CXX_STANDARD_REQUIRED true)
+
+# # Rename C++ executable without prefix
+# # The above recommended prefix causes long target names, the following renames the
+# # target back to the shorter version for ease of user use
+# # e.g. "rosrun someones_pkg node" instead of "rosrun someones_pkg someones_pkg_node"
# set_target_properties(${PROJECT_NAME}_node PROPERTIES OUTPUT_NAME node PREFIX "")
-## Add cmake target dependencies of the executable
-## same as for the library above
+# # Add cmake target dependencies of the executable
+# # same as for the library above
# add_dependencies(${PROJECT_NAME}_node ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS})
-## Specify libraries to link a library or executable target against
+# # Specify libraries to link a library or executable target against
# target_link_libraries(${PROJECT_NAME}_node
-# ${catkin_LIBRARIES}
+# ${catkin_LIBRARIES}
# )
-#############
-## Install ##
-#############
+# ############
+# # Install ##
+# ############
# all install targets should use catkin DESTINATION variables
# See http://ros.org/doc/api/catkin/html/adv_user_guide/variables.html
-## Mark executable scripts (Python etc.) for installation
-## in contrast to setup.py, you can choose the destination
+# # Mark executable scripts (Python etc.) for installation
+# # in contrast to setup.py, you can choose the destination
# catkin_install_python(PROGRAMS
-# scripts/my_python_script
-# DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
+# scripts/my_python_script
+# DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
# )
-## Mark executables for installation
-## See http://docs.ros.org/melodic/api/catkin/html/howto/format1/building_executables.html
+# # Mark executables for installation
+# # See http://docs.ros.org/melodic/api/catkin/html/howto/format1/building_executables.html
# install(TARGETS ${PROJECT_NAME}_node
-# RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
+# RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
# )
-## Mark libraries for installation
-## See http://docs.ros.org/melodic/api/catkin/html/howto/format1/building_libraries.html
+# # Mark libraries for installation
+# # See http://docs.ros.org/melodic/api/catkin/html/howto/format1/building_libraries.html
# install(TARGETS ${PROJECT_NAME}
-# ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
-# LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
-# RUNTIME DESTINATION ${CATKIN_GLOBAL_BIN_DESTINATION}
+# ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
+# LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
+# RUNTIME DESTINATION ${CATKIN_GLOBAL_BIN_DESTINATION}
# )
-## Mark cpp header files for installation
+# # Mark cpp header files for installation
# install(DIRECTORY include/${PROJECT_NAME}/
-# DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION}
-# FILES_MATCHING PATTERN "*.h"
-# PATTERN ".svn" EXCLUDE
+# DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION}
+# FILES_MATCHING PATTERN "*.h"
+# PATTERN ".svn" EXCLUDE
# )
-## Mark other files for installation (e.g. launch and bag files, etc.)
+# # Mark other files for installation (e.g. launch and bag files, etc.)
# install(FILES
-# # myfile1
-# # myfile2
-# DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}
+# # myfile1
+# # myfile2
+# DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}
# )
-#############
-## Testing ##
-#############
+# ############
+# # Testing ##
+# ############
-## Add gtest based cpp test target and link libraries
+# # Add gtest based cpp test target and link libraries
# catkin_add_gtest(${PROJECT_NAME}-test test/test_wr_control_drive_science.cpp)
# if(TARGET ${PROJECT_NAME}-test)
-# target_link_libraries(${PROJECT_NAME}-test ${PROJECT_NAME})
+# target_link_libraries(${PROJECT_NAME}-test ${PROJECT_NAME})
# endif()
-## Add folders to be run by python nosetests
+# # Add folders to be run by python nosetests
# catkin_add_nosetests(test)
diff --git a/src/wr_control_drive_arm/config/arm_motor_PID.yaml b/src/wr_control_drive_arm/config/arm_motor_PID.yaml
deleted file mode 100644
index 2ac19e48..00000000
--- a/src/wr_control_drive_arm/config/arm_motor_PID.yaml
+++ /dev/null
@@ -1,64 +0,0 @@
-rate: 50
-controllers:
- - setpointTopic: "/control/arm/00/setpoint"
- feedbackTopic: "/control/arm/00/feedback"
- outputTopic: "/control/arm/00/output"
- P: 3000
- I: 0
- D: 0
- min: -1
- max: 1
-
- - setpointTopic: "/control/arm/01/setpoint"
- feedbackTopic: "/control/arm/01/feedback"
- outputTopic: "/control/arm/01/output"
- P: 3000
- I: 0
- D: 0
- min: -1
- max: 1
-
- - setpointTopic: "/control/arm/10/setpoint"
- feedbackTopic: "/control/arm/10/feedback"
- outputTopic: "/control/arm/10/output"
- P: 3000
- I: 0
- D: 0
- min: -1
- max: 1
-
- - setpointTopic: "/control/arm/11/setpoint"
- feedbackTopic: "/control/arm/11/feedback"
- outputTopic: "/control/arm/11/output"
- P: 3000
- I: 0
- D: 0
- min: -1
- max: 1
-
- - setpointTopic: "/control/arm/20/setpoint"
- feedbackTopic: "/control/arm/20/feedback"
- outputTopic: "/control/arm/20/output"
- P: 3000
- I: 0
- D: 0
- min: -1
- max: 1
-
- - setpointTopic: "/control/arm/21/setpoint"
- feedbackTopic: "/control/arm/21/feedback"
- outputTopic: "/control/arm/21/output"
- P: 3000
- I: 0
- D: 0
- min: -1
- max: 1
-
- - setpointTopic: "/control/arm/3000/setpoint"
- feedbackTopic: "/control/arm/3000/feedback"
- outputTopic: "/control/arm/3000/output"
- P: 3000
- I: 0
- D: 0
- min: -1
- max: 1
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/config/arm_motor_PID_mock.yaml b/src/wr_control_drive_arm/config/arm_motor_PID_mock.yaml
new file mode 100644
index 00000000..e59fd363
--- /dev/null
+++ b/src/wr_control_drive_arm/config/arm_motor_PID_mock.yaml
@@ -0,0 +1,55 @@
+rate: 50
+controllers:
+ - setpointTopic: "/control/arm/pid/turntable/setpoint"
+ feedbackTopic: "/control/arm/pid/turntable/feedback"
+ outputTopic: "/control/arm/pid/turntable/output"
+ P: 5
+ I: 0.5
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/shoulder/setpoint"
+ feedbackTopic: "/control/arm/pid/shoulder/feedback"
+ outputTopic: "/control/arm/pid/shoulder/output"
+ P: 5
+ I: 0.5
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/elbow/setpoint"
+ feedbackTopic: "/control/arm/pid/elbow/feedback"
+ outputTopic: "/control/arm/pid/elbow/output"
+ P: 5
+ I: 0.5
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/forearmRoll/setpoint"
+ feedbackTopic: "/control/arm/pid/forearmRoll/feedback"
+ outputTopic: "/control/arm/pid/forearmRoll/output"
+ P: 5
+ I: 0.5
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/wristPitch/setpoint"
+ feedbackTopic: "/control/arm/pid/wristPitch/feedback"
+ outputTopic: "/control/arm/pid/wristPitch/output"
+ P: 5
+ I: 0.5
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/wristRoll/setpoint"
+ feedbackTopic: "/control/arm/pid/wristRoll/feedback"
+ outputTopic: "/control/arm/pid/wristRoll/output"
+ P: 5
+ I: 0.5
+ D: 0
+ min: -1
+ max: 1
diff --git a/src/wr_control_drive_arm/config/arm_motor_PID_real.yaml b/src/wr_control_drive_arm/config/arm_motor_PID_real.yaml
new file mode 100644
index 00000000..a0da7801
--- /dev/null
+++ b/src/wr_control_drive_arm/config/arm_motor_PID_real.yaml
@@ -0,0 +1,55 @@
+rate: 50
+controllers:
+ - setpointTopic: "/control/arm/pid/turntable/setpoint"
+ feedbackTopic: "/control/arm/pid/turntable/feedback"
+ outputTopic: "/control/arm/pid/turntable/output"
+ P: 10
+ I: 0
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/shoulder/setpoint"
+ feedbackTopic: "/control/arm/pid/shoulder/feedback"
+ outputTopic: "/control/arm/pid/shoulder/output"
+ P: 10
+ I: 0
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/elbow/setpoint"
+ feedbackTopic: "/control/arm/pid/elbow/feedback"
+ outputTopic: "/control/arm/pid/elbow/output"
+ P: 10
+ I: 0
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/forearmRoll/setpoint"
+ feedbackTopic: "/control/arm/pid/forearmRoll/feedback"
+ outputTopic: "/control/arm/pid/forearmRoll/output"
+ P: 10
+ I: 0
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/wristPitch/setpoint"
+ feedbackTopic: "/control/arm/pid/wristPitch/feedback"
+ outputTopic: "/control/arm/pid/wristPitch/output"
+ P: 10
+ I: 0
+ D: 0
+ min: -1
+ max: 1
+
+ - setpointTopic: "/control/arm/pid/wristRoll/setpoint"
+ feedbackTopic: "/control/arm/pid/wristRoll/feedback"
+ outputTopic: "/control/arm/pid/wristRoll/output"
+ P: 10
+ I: 0
+ D: 0
+ min: -1
+ max: 1
diff --git a/src/wr_control_drive_arm/config/arm_parameters_mock.yaml b/src/wr_control_drive_arm/config/arm_parameters_mock.yaml
new file mode 100644
index 00000000..a8b1e10d
--- /dev/null
+++ b/src/wr_control_drive_arm/config/arm_parameters_mock.yaml
@@ -0,0 +1,37 @@
+arm_parameters:
+ elbow:
+ encoder_parameters:
+ counts_per_rotation: 1000
+ offset: 500
+ motor_parameters:
+ gear_ratio: 1
+ forearmRoll:
+ encoder_parameters:
+ counts_per_rotation: 1000
+ offset: 500
+ motor_parameters:
+ gear_ratio: 1
+ shoulder:
+ encoder_parameters:
+ counts_per_rotation: 1000
+ offset: 500
+ motor_parameters:
+ gear_ratio: 1
+ turntable:
+ encoder_parameters:
+ counts_per_rotation: 1000
+ offset: 500
+ motor_parameters:
+ gear_ratio: 1
+ wristPitch:
+ encoder_parameters:
+ counts_per_rotation: 1000
+ offset: 500
+ motor_parameters:
+ gear_ratio: 1
+ wristRoll:
+ encoder_parameters:
+ counts_per_rotation: 1000
+ offset: 500
+ motor_parameters:
+ gear_ratio: 1
diff --git a/src/wr_control_drive_arm/config/arm_parameters_real.yaml b/src/wr_control_drive_arm/config/arm_parameters_real.yaml
new file mode 100644
index 00000000..511c0c23
--- /dev/null
+++ b/src/wr_control_drive_arm/config/arm_parameters_real.yaml
@@ -0,0 +1,37 @@
+arm_parameters:
+ elbow:
+ encoder_parameters:
+ counts_per_rotation: 1850
+ offset: 546
+ motor_parameters:
+ gear_ratio: 3
+ forearmRoll:
+ encoder_parameters:
+ counts_per_rotation: -1850
+ offset: 576
+ motor_parameters:
+ gear_ratio: 3
+ shoulder:
+ encoder_parameters:
+ counts_per_rotation: 5550
+ offset: 1281
+ motor_parameters:
+ gear_ratio: 9
+ turntable:
+ encoder_parameters:
+ counts_per_rotation: 6900 #7200
+ offset: 90
+ motor_parameters:
+ gear_ratio: 3
+ wristPitch:
+ encoder_parameters:
+ counts_per_rotation: -1850
+ offset: 886
+ motor_parameters:
+ gear_ratio: 4.875
+ wristRoll:
+ encoder_parameters:
+ counts_per_rotation: -1850
+ offset: 981
+ motor_parameters:
+ gear_ratio: 4.875
diff --git a/src/wr_control_drive_arm/config/encoder_parameters.yaml b/src/wr_control_drive_arm/config/encoder_parameters.yaml
deleted file mode 100644
index 1fce6c2e..00000000
--- a/src/wr_control_drive_arm/config/encoder_parameters.yaml
+++ /dev/null
@@ -1,19 +0,0 @@
-encoder_parameters:
-# elbow
- - counts_per_rotation: -2048
- offset: 610
-# forearm_roll
- - counts_per_rotation: -2048
- offset: 540
-# shoulder
- - counts_per_rotation: -6144
- offset: 1129
-# turntable
- - counts_per_rotation: 2048
- offset: 985
-# wrist_pitch
- - counts_per_rotation: 2048
- offset: 886
-# wrist_roll
- - counts_per_rotation: 2048
- offset: 1050
diff --git a/src/wr_control_drive_arm/launch/actionserver.launch b/src/wr_control_drive_arm/launch/actionserver.launch
new file mode 100644
index 00000000..a1c5c9e0
--- /dev/null
+++ b/src/wr_control_drive_arm/launch/actionserver.launch
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/launch/jointstatepublisher.launch b/src/wr_control_drive_arm/launch/jointstatepublisher.launch
new file mode 100644
index 00000000..9b662856
--- /dev/null
+++ b/src/wr_control_drive_arm/launch/jointstatepublisher.launch
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/launch/std.launch b/src/wr_control_drive_arm/launch/std.launch
index 12c7e1a3..96c2e726 100644
--- a/src/wr_control_drive_arm/launch/std.launch
+++ b/src/wr_control_drive_arm/launch/std.launch
@@ -1,10 +1,5 @@
+
-
-
-
-
-
-
-
-
+
+
diff --git a/src/wr_control_drive_arm/launch/testDifferential.launch b/src/wr_control_drive_arm/launch/testDifferential.launch
new file mode 100644
index 00000000..b6632b1a
--- /dev/null
+++ b/src/wr_control_drive_arm/launch/testDifferential.launch
@@ -0,0 +1,3 @@
+
+
+
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/AbstractJoint.cpp b/src/wr_control_drive_arm/src/AbstractJoint.cpp
deleted file mode 100644
index e88e5afa..00000000
--- a/src/wr_control_drive_arm/src/AbstractJoint.cpp
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * @file AbstractJoint.cpp
- * @author Nichols Underwood
- * @brief Implementation of the AbstractJoint class
- * @date 2021-10-25
- */
-
-#include "AbstractJoint.hpp"
-
-AbstractJoint::AbstractJoint(ros::NodeHandle &n, int numMotors){
- this->motors.resize(numMotors);
-}
-
-auto AbstractJoint::getDegreesOfFreedom() const -> unsigned int{
- return this->motors.size();
-}
-
-auto AbstractJoint::getMotor(int motorIndex) const -> const std::unique_ptr&{
- return this->motors.at(motorIndex).motor;
-}
-
-void AbstractJoint::configSetpoint(int degreeIndex, double position, double velocity){
-
- this->motors.at(degreeIndex).position = position;
- this->motors.at(degreeIndex).velocity = velocity;
-}
-
-
-void AbstractJoint::exectute(){
- for(auto &motorHandle : motors){
- motorHandle.motor->runToTarget(motorHandle.position, motorHandle.velocity);
- }
-}
-
-void AbstractJoint::stopJoint(){
- for(auto &motorHandle : motors){
- motorHandle.motor->setPower(0.F);
- }
-}
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/AbstractJoint.hpp b/src/wr_control_drive_arm/src/AbstractJoint.hpp
deleted file mode 100644
index cf19f069..00000000
--- a/src/wr_control_drive_arm/src/AbstractJoint.hpp
+++ /dev/null
@@ -1,46 +0,0 @@
-/**
- * @file AbstractJoint.hpp
- * @author Nichols Underwood
- * @brief Header file of the AbstractJoint class
- * @date 2021-10-25
- */
-
-#ifndef ABSTRACT_JOINT_GUARD
-#define ABSTRACT_JOINT_GUARD
-
-#include "ArmMotor.hpp"
-using std::vector;
-
-class AbstractJoint {
-public:
- struct MotorHandler{
- std::unique_ptr motor;
- double position;
- double velocity;
- std::string jointTopicName;
- std::string motorTopicName;
- bool newVelocity;
- };
-
- AbstractJoint(ros::NodeHandle &n, int numMotors);
-
- // never used, need to be defined for compiler v-table
- virtual auto getMotorPositions(const vector &jointPositions) -> vector = 0;
- virtual auto getMotorVelocities(const vector &joinVelocities) -> vector = 0;
- virtual auto getJointPositions(const vector &motorPositions) -> vector = 0;
-
- auto getDegreesOfFreedom() const -> unsigned int;
-
- auto getMotor(int motorIndex) const -> const std::unique_ptr&;
-
- void configSetpoint(int degreeIndex, double position, double velocity);
-
- void exectute();
-
- void stopJoint();
-
-protected:
- vector motors;
-};
-
-#endif
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/ArmControlActionServer.cpp b/src/wr_control_drive_arm/src/ArmControlActionServer.cpp
new file mode 100644
index 00000000..7b3f6ae9
--- /dev/null
+++ b/src/wr_control_drive_arm/src/ArmControlActionServer.cpp
@@ -0,0 +1,361 @@
+/**
+ * @file ArmControlActionServer.cpp
+ * @author Ben Nowotny
+ * @brief The exeutable file to run the Arm Control Action Server
+ * @date 2022-12-05
+ */
+#include "DifferentialJointToMotorSpeedConverter.hpp"
+#include "DirectJointToMotorSpeedConverter.hpp"
+#include "Joint.hpp"
+#include "Motor.hpp"
+#include "RoboclawChannel.hpp"
+#include "SingleEncoderJointPositionMonitor.hpp"
+#include "XmlRpcValue.h"
+#include "ros/init.h"
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+
+using XmlRpc::XmlRpcValue;
+
+/**
+ * @brief Refresh rate of ros::Rate
+ */
+constexpr float CLOCK_RATE{50};
+
+constexpr double IK_WARN_RATE{1.0 / 2};
+
+constexpr double JOINT_SAFETY_MAX_SPEED{0.5};
+constexpr double JOINT_SAFETY_HOLD_SPEED{0.3};
+
+/**
+ * @brief Nessage cache size of publisher
+ */
+constexpr std::uint32_t MESSAGE_CACHE_SIZE{10};
+
+/**
+ * @brief Period between timer callback
+ */
+constexpr float TIMER_CALLBACK_DURATION{1.0 / 50.0};
+
+/**
+ * @brief Defines space for all Joint references
+ */
+std::unordered_map> namedJointMap;
+
+/**
+ * @brief Defines space for all joint position monitor references
+ */
+std::unordered_map> namedPositionMonitors;
+
+/**
+ * @brief Simplify the SimpleActionServer reference name
+ */
+using Server = actionlib::SimpleActionServer;
+
+/**
+ * @brief The service server for enabling IK
+ */
+ros::ServiceServer enableServiceServer;
+/**
+ * @brief The status of IK program
+ */
+std::atomic_bool IKEnabled{true};
+/**
+ * @brief The service client for disabling IK
+ */
+ros::ServiceClient enableServiceClient;
+
+/**
+ * @brief Perform the given action as interpreted as moving the arm joints to
+ * specified positions
+ *
+ * @param goal The goal state given
+ * @param as The Action Server this is occuring on
+ */
+void execute(const control_msgs::FollowJointTrajectoryGoalConstPtr &goal,
+ Server *server) {
+ if (!IKEnabled) {
+ server->setAborted();
+ ROS_WARN_THROTTLE( // NOLINT(hicpp-no-array-decay,hicpp,hicpp-vararg,cppcoreguidelines-pro-bounds-array-to-pointer-decay, cppcoreguidelines-pro-type-vararg)
+ IK_WARN_RATE,
+ "IK is disabled");
+ return;
+ }
+
+ for (const auto &jointName : goal->trajectory.joint_names) {
+ std::cout << jointName << "\t";
+ }
+ std::cout << std::endl;
+ for (const auto &waypoint : goal->trajectory.points) {
+ for (const auto &jointVal : waypoint.positions) {
+ std::cout << jointVal << "\t";
+ }
+ std::cout << std::endl;
+ }
+
+ for (const auto &currTargetPosition : goal->trajectory.points) {
+
+ if (!IKEnabled) {
+ server->setAborted();
+ std::cout << "Over current fault!" << std::endl;
+ return;
+ }
+
+ // Copy of the velocities received from MoveIt
+ std::vector velocityCopies{currTargetPosition.velocities};
+
+ for (uint32_t i = 0; i < goal->trajectory.joint_names.size(); ++i) {
+
+ // The joint that is currently being scaled
+ auto currJoint = goal->trajectory.joint_names.at(i);
+
+ // The position monitor whose velocity is currently being scaled
+ auto& currPosMtr = *namedPositionMonitors.at(currJoint);
+
+ // Scale by counts per rotation and gear ratio
+ velocityCopies.at(i) *= abs(currPosMtr.getCountsPerRotation()*currPosMtr.getGearRatio());
+ }
+
+ // Get the maximum velocity assigned to any joint
+ const double VELOCITY_MAX = abs(*std::max_element(
+ velocityCopies.begin(),
+ velocityCopies.end(),
+ [](double lhs, double rhs) -> bool { return abs(lhs) < abs(rhs); }));
+
+ for (uint32_t i = 0; i < goal->trajectory.joint_names.size(); ++i) {
+ // Set joint to hold speed in case the greatest velocity comes through as 0
+ auto jointVelocity{JOINT_SAFETY_HOLD_SPEED};
+
+ // Scale all velocities by the safety max speed with respect to the maximum velocity given by MoveIt
+ if (VELOCITY_MAX != 0)
+ jointVelocity = velocityCopies.at(i) / VELOCITY_MAX * JOINT_SAFETY_MAX_SPEED;
+
+ // Set the joint's velocity
+ namedJointMap.at(goal->trajectory.joint_names.at(i))->setTarget(currTargetPosition.positions.at(i), jointVelocity);
+ }
+ }
+
+ auto waypointComplete{false};
+ ros::Rate updateRate{CLOCK_RATE};
+
+ while (!waypointComplete && ros::ok() && !server->isNewGoalAvailable()) {
+
+ if (!IKEnabled) {
+ server->setAborted();
+ std::cout << "Over current fault!" << std::endl;
+ return;
+ }
+
+ waypointComplete = true;
+ for (const auto &[_, joint] : namedJointMap) {
+ waypointComplete &= joint->hasReachedTarget();
+ }
+ updateRate.sleep();
+ }
+
+ // Report preemption if it occurred
+ if (server->isNewGoalAvailable())
+ server->setPreempted();
+ // When all positions have been reached, set the current task as succeeded
+ else
+ server->setSucceeded();
+ std::cout << "Action Complete!" << std::endl;
+}
+
+auto getEncoderConfigFromParams(const XmlRpcValue ¶ms, const std::string &jointName) -> EncoderConfiguration {
+ return {.countsPerRotation = static_cast(params[jointName]["encoder_parameters"]["counts_per_rotation"]),
+ .offset = static_cast(params[jointName]["encoder_parameters"]["offset"])};
+}
+
+auto getMotorConfigFromParams(const XmlRpcValue ¶ms, const std::string &jointName) -> MotorConfiguration {
+ return {.gearRatio = static_cast(params[jointName]["motor_configurations"]["gear_ratio"])};
+}
+
+void checkOverCurrentFaults(const std::vector> &motors){
+ for(const auto& motor : motors){
+ if (motor->isOverCurrent()) {
+ IKEnabled = false;
+ std::cout << "Over current fault!" << std::endl;
+
+ for (const auto& joint : namedJointMap) {
+ joint.second->stop();
+ }
+ }
+ // TODO: arbitrate control to old arm driver
+ }
+}
+
+/**
+ * @brief The main executable method of the node. Starts the ROS node and the
+ * Action Server for processing Arm Control commands
+ *
+ * @param argc The number of program arguments
+ * @param argv The given program arguments
+ * @return int The status code on exiting the program
+ */
+auto main(int argc, char **argv) -> int {
+ std::cout << "start main" << std::endl;
+ // Initialize the current node as ArmControlSystem
+ ros::init(argc, argv, "ArmControlActionServer");
+ // Create the NodeHandle to the current ROS node
+ ros::NodeHandle n;
+ ros::NodeHandle pn{"~"};
+
+ XmlRpcValue armParams;
+ pn.getParam("arm_parameters", armParams);
+
+ // Initialize all motors with their MoveIt name, WRoboclaw initialization,
+ // and reference to the current node
+ std::cout << "init motors" << std::endl;
+
+ /**
+ * @brief The list of motors
+ */
+ std::vector> motors{};
+
+ using std::literals::string_literals::operator""s;
+
+ const auto turntableMotor{std::make_shared("aux0"s, RoboclawChannel::A, n)};
+ const auto shoulderMotor{std::make_shared("aux0"s, RoboclawChannel::B, n)};
+ const auto elbowMotor{std::make_shared("aux1"s, RoboclawChannel::A, n)};
+ const auto forearmRollMotor{std::make_shared("aux1"s, RoboclawChannel::B, n)};
+ const auto wristLeftMotor{std::make_shared("aux2"s, RoboclawChannel::A, n)};
+ const auto wristRightMotor{std::make_shared("aux2"s, RoboclawChannel::B, n)};
+
+ motors.push_back(turntableMotor);
+ motors.push_back(shoulderMotor);
+ motors.push_back(elbowMotor);
+ motors.push_back(forearmRollMotor);
+ motors.push_back(wristLeftMotor);
+ motors.push_back(wristRightMotor);
+
+ namedPositionMonitors.insert({"turntable_joint", std::make_shared(
+ "aux0"s,
+ RoboclawChannel::A,
+ getEncoderConfigFromParams(armParams, "turntable"),
+ getMotorConfigFromParams(armParams, "turntable"),
+ n)});
+
+ namedPositionMonitors.insert({"shoulder_joint", std::make_shared(
+ "aux0"s,
+ RoboclawChannel::B,
+ getEncoderConfigFromParams(armParams, "shoulder"),
+ getMotorConfigFromParams(armParams, "shoulder"),
+ n)});
+
+ namedPositionMonitors.insert({"elbowPitch_joint", std::make_shared(
+ "aux1"s,
+ RoboclawChannel::A,
+ getEncoderConfigFromParams(armParams, "elbow"),
+ getMotorConfigFromParams(armParams, "elbow"),
+ n)});
+
+ namedPositionMonitors.insert({"elbowRoll_joint", std::make_shared(
+ "aux1"s,
+ RoboclawChannel::B,
+ getEncoderConfigFromParams(armParams, "forearmRoll"),
+ getMotorConfigFromParams(armParams, "forearmRoll"),
+ n)});
+
+ namedPositionMonitors.insert({"wristPitch_joint", std::make_shared(
+ "aux2"s,
+ RoboclawChannel::A,
+ getEncoderConfigFromParams(armParams, "wristPitch"),
+ getMotorConfigFromParams(armParams, "wristPitch"),
+ n)});
+
+ namedPositionMonitors.insert({"wristRoll_link", std::make_shared(
+ "aux2"s,
+ RoboclawChannel::B,
+ getEncoderConfigFromParams(armParams, "wristRoll"),
+ getMotorConfigFromParams(armParams, "wristRoll"),
+ n)});
+
+ const auto turntableSpeedConverter{std::make_shared(turntableMotor, MotorSpeedDirection::REVERSE)};
+ const auto shoulderSpeedConverter{std::make_shared(shoulderMotor, MotorSpeedDirection::REVERSE)};
+ const auto elbowSpeedConverter{std::make_shared(elbowMotor, MotorSpeedDirection::REVERSE)};
+ const auto forearmRollSpeedConverter{std::make_shared(forearmRollMotor, MotorSpeedDirection::REVERSE)};
+ const auto differentialSpeedConverter{std::make_shared(wristLeftMotor, wristRightMotor)};
+
+ // Initialize all Joints
+
+ std::cout << "init joints" << std::endl;
+
+ namedJointMap.insert({"turntable_joint", std::make_unique(
+ "turntable"s,
+ [turntablePositionMonitor=namedPositionMonitors.at("turntable_joint")]() -> double { return (*turntablePositionMonitor)(); },
+ [turntableSpeedConverter](double speed) { (*turntableSpeedConverter)(speed); },
+ n)});
+ namedJointMap.insert({"shoulder_joint", std::make_unique(
+ "shoulder",
+ [shoulderPositionMonitor=namedPositionMonitors.at("shoulder_joint")]() -> double { return (*shoulderPositionMonitor)(); },
+ [shoulderSpeedConverter](double speed) { (*shoulderSpeedConverter)(speed); },
+ n)});
+ namedJointMap.insert({"elbowPitch_joint", std::make_unique(
+ "elbow",
+ [elbowPositionMonitor=namedPositionMonitors.at("elbowPitch_joint")]() -> double { return (*elbowPositionMonitor)(); },
+ [elbowSpeedConverter](double speed) { (*elbowSpeedConverter)(speed); },
+ n)});
+ namedJointMap.insert({"elbowRoll_joint", std::make_unique(
+ "forearmRoll",
+ [forearmRollPositionMonitor=namedPositionMonitors.at("elbowRoll_joint")]() -> double { return (*forearmRollPositionMonitor)(); },
+ [forearmRollSpeedConverter](double speed) { (*forearmRollSpeedConverter)(speed); },
+ n)});
+ namedJointMap.insert({"wristPitch_joint", std::make_unique(
+ "wristPitch",
+ [wristPitchPositionMonitor=namedPositionMonitors.at("wristPitch_joint")]() -> double { return (*wristPitchPositionMonitor)(); },
+ [converter = differentialSpeedConverter](double speed) { converter->setPitchSpeed(speed); },
+ n)});
+ namedJointMap.insert({"wristRoll_link", std::make_unique(
+ "wristRoll",
+ [wristRollPositionMonitor=namedPositionMonitors.at("wristRoll_link")]() -> double { return (*wristRollPositionMonitor)(); },
+ [converter = differentialSpeedConverter](double speed) { converter->setRollSpeed(speed); },
+ n)});
+
+ // Initialize the Action Server
+ Server server(
+ n, "/arm_controller/follow_joint_trajectory",
+ [&server](auto goal) { execute(goal, &server); }, false);
+ // Start the Action Server
+ server.start();
+ std::cout << "server started" << std::endl;
+
+ enableServiceServer = n.advertiseService(
+ "start_IK",
+ static_cast>(
+ [](std_srvs::Trigger::Request &req,
+ std_srvs::Trigger::Response &res) -> bool {
+ IKEnabled = true;
+ res.message = "Arm IK Enabled";
+ res.success = static_cast(true);
+ return true;
+ }));
+
+ enableServiceClient =
+ n.serviceClient("PLACEHOLDER_NAME");
+
+ ros::Timer currentTimer = n.createTimer(ros::Duration{TIMER_CALLBACK_DURATION}, [&motors](const ros::TimerEvent& event) { checkOverCurrentFaults(motors); });
+
+ std::cout << "entering ROS spin..." << std::endl;
+ // ROS spin for communication with other nodes
+ ros::spin();
+ // Return 0 on exit (successful exit)
+ return 0;
+}
diff --git a/src/wr_control_drive_arm/src/ArmControlSystem.cpp b/src/wr_control_drive_arm/src/ArmControlSystem.cpp
deleted file mode 100644
index 2dc5dbf9..00000000
--- a/src/wr_control_drive_arm/src/ArmControlSystem.cpp
+++ /dev/null
@@ -1,257 +0,0 @@
-/**
- * @file ArmControlSystem.cpp
- * @author Ben Nowotny
- * @brief The exeutable file to run the Arm Control Action Server
- * @date 2021-04-05
- */
-#include "XmlRpcValue.h"
-
-#include "ros/ros.h"
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include "SimpleJoint.hpp"
-#include "DifferentialJoint.hpp"
-#include "ros/console.h"
-
-using XmlRpc::XmlRpcValue;
-
-/**
- * @brief Refresh rate of ros::Rate
- */
-constexpr float CLOCK_RATE = 50;
-
-constexpr double IK_WARN_RATE = 1.0/2;
-
-constexpr double JOINT_SAFETY_MAX_SPEED = 0.3;
-constexpr double JOINT_SAFETY_HOLD_SPEED = 0.15;
-
-/**
- * @brief Nessage cache size of publisher
- */
-constexpr std::uint32_t MESSAGE_CACHE_SIZE = 1000;
-
-/**
- * @brief Period between timer callback
- */
-constexpr float TIMER_CALLBACK_DURATION = 1.0 / 50.0;
-
-/**
- * @brief Defines space for all Joint references
- */
-constexpr int NUM_JOINTS = 5;
-std::array, NUM_JOINTS> joints;
-// AbstractJoint *joints[numJoints];
-/**
- * @brief The Joint State Publisher for MoveIt
- */
-ros::Publisher jointStatePublisher;
-/**
- * @brief Simplify the SimpleActionServer reference name
- */
-typedef actionlib::SimpleActionServer Server;
-/**
- * @brief The service server for enabling IK
- */
-ros::ServiceServer enableServiceServer;
-/**
- * @brief The status of IK program
- */
-std::atomic_bool IKEnabled{true};
-/**
- * @brief The service client for disabling IK
- */
-ros::ServiceClient enableServiceClient;
-
-/**
- * @brief Perform the given action as interpreted as moving the arm joints to specified positions
- *
- * @param goal The goal state given
- * @param as The Action Server this is occuring on
- */
-void execute(const control_msgs::FollowJointTrajectoryGoalConstPtr& goal, Server* as) {
- if (!IKEnabled) {
- as->setAborted();
- ROS_WARN_THROTTLE(IK_WARN_RATE, "IK is disabled"); // NOLINT(hicpp-no-array-decay,hicpp,hicpp-vararg,cppcoreguidelines-pro-bounds-array-to-pointer-decay, cppcoreguidelines-pro-type-vararg)
- return;
- }
-
- int currPoint = 1;
-
- std::cout << "start exec: " << goal->trajectory.points.size() << std::endl;
- // For each point in the trajectory execution sequence...
- for(const auto &currTargetPosition : goal->trajectory.points){
- for(double pos : currTargetPosition.positions){
- std::cout << std::round(pos*100)/100 << " ";
- }
- std::cout << std::endl;
- }
- for(const auto &currTargetPosition : goal->trajectory.points){
- // Track whether or not the current position is done
- bool hasPositionFinished = false;
- // Keep max loop rate at 50 Hz
- ros::Rate loop{CLOCK_RATE};
-
- const double VELOCITY_MAX = abs(*std::max_element(
- currTargetPosition.velocities.begin(),
- currTargetPosition.velocities.end(),
- [](double a, double b) -> bool{ return abs(a)trajectory.points.size() << std::endl;
- currPoint++;
- for(const auto &joint : joints){
- for(int i = 0; i < joint->getDegreesOfFreedom(); i++){
- double velocity = VELOCITY_MAX == 0.F ? JOINT_SAFETY_HOLD_SPEED : currTargetPosition.velocities[currItr]/VELOCITY_MAX;
- std::cout << "config setpoint: " << currTargetPosition.positions[currItr] << ":" << velocity << std::endl;
- joint->configSetpoint(i, currTargetPosition.positions[currItr], velocity);
- currItr++;
- }
- joint->exectute();
- }
-
- // While the current position is not complete yet...
- while(!hasPositionFinished){
- // Assume the current action is done until proven otherwise
- hasPositionFinished = true;
- // Create the Joint State message for the current update cycle
-
- // For each joint specified in the currTargetPosition...
- for(const auto &joint : joints){
-
- // joint->exectute();
-
- for(int k = 0; k < joint->getDegreesOfFreedom(); k++){
-
- if (joint->getMotor(k)->getMotorState() == MotorState::STALLING) {
- IKEnabled = false;
- std_srvs::Trigger srv;
- if (enableServiceClient.call(srv)) {
- ROS_WARN("%s", (std::string{"PLACEHOLDER_NAME: "} + srv.response.message).data()); // NOLINT(cppcoreguidelines-pro-bounds-array-to-pointer-decay, cppcoreguidelines-pro-type-vararg)
- } else {
- ROS_WARN("Error: failed to call service PLACEHOLDER_NAME"); // NOLINT(cppcoreguidelines-pro-bounds-array-to-pointer-decay, cppcoreguidelines-pro-type-vararg)
- }
- } else {
- hasPositionFinished &= joint->getMotor(k)->getMotorState() == MotorState::STOP;
- }
- // DEBUGGING OUTPUT: Print each motor's name, radian position, encoder position, and power
- // std::cout<getEncoderCounts()<exectute()) {
- // IKEnabled = false;
- // std_srvs::Trigger srv;
- // if (enableServiceClient.call(srv)) {
- // ROS_WARN("%s", (std::string{"PLACEHOLDER_NAME: "} + srv.response.message).data()); // NOLINT(cppcoreguidelines-pro-bounds-array-to-pointer-decay, cppcoreguidelines-pro-type-vararg)
- // } else {
- // ROS_WARN("Error: failed to call service PLACEHOLDER_NAME"); // NOLINT(cppcoreguidelines-pro-bounds-array-to-pointer-decay, cppcoreguidelines-pro-type-vararg)
- // }
- // return;
- // }
- }
- // Sleep until the next update cycle
- loop.sleep();
- }
- }
-
- //When all positions have been reached, set the current task as succeeded
-
- as->setSucceeded();
-}
-
-/**
- * @brief publishes the arm's position
- */
-void publishJointStates(const ros::TimerEvent &event){
- std::vector names;
- std::vector positions;
- sensor_msgs::JointState js_msg;
-
- for(const auto &joint : joints){
- for(int i = 0; i < joint->getDegreesOfFreedom(); i++){
- names.push_back(joint->getMotor(i)->getMotorName());
- positions.push_back(joint->getMotor(i)->getRads());
- }
- }
-
- js_msg.name = names;
- js_msg.position = positions;
- // Publish the Joint State message
- jointStatePublisher.publish(js_msg);
-}
-
-/**
- * @brief The main executable method of the node. Starts the ROS node and the Action Server for processing Arm Control commands
- *
- * @param argc The number of program arguments
- * @param argv The given program arguments
- * @return int The status code on exiting the program
- */
-auto main(int argc, char** argv) ->int
-{
- std::cout << "start main" << std::endl;
- // Initialize the current node as ArmControlSystem
- ros::init(argc, argv, "ArmControlSystem");
- // Create the NodeHandle to the current ROS node
- ros::NodeHandle n;
- ros::NodeHandle pn{"~"};
-
- XmlRpcValue encParams;
- pn.getParam("encoder_parameters", encParams);
-
- // Initialize all motors with their MoveIt name, WRoboclaw initialization, and reference to the current node
- auto elbow = std::make_unique("elbow", 1, 0, static_cast(encParams[0]["counts_per_rotation"]), static_cast(encParams[0]["offset"]), n);
- auto forearmRoll = std::make_unique("forearm_roll", 1, 1, static_cast(encParams[1]["counts_per_rotation"]), static_cast(encParams[1]["offset"]), n);
- auto shoulder = std::make_unique("shoulder", 0, 1, static_cast(encParams[2]["counts_per_rotation"]), static_cast(encParams[2]["offset"]), n);
- auto turntable = std::make_unique("turntable", 0, 0, static_cast(encParams[3]["counts_per_rotation"]), static_cast(encParams[3]["offset"]), n);
- auto wristLeft = std::make_unique("wrist_pitch", 2, 0, static_cast(encParams[4]["counts_per_rotation"]), static_cast(encParams[4]["offset"]), n);
- auto wristRight = std::make_unique("wrist_roll", 2, 1, static_cast(encParams[5]["counts_per_rotation"]), static_cast(encParams[5]["offset"]), n);
- std::cout << "init motors" << std::endl;
-
- // Initialize all Joints
- joints.at(0) = std::make_unique(std::move(elbow), n);
- joints.at(1) = std::make_unique(std::move(forearmRoll), n);
- joints.at(2) = std::make_unique(std::move(shoulder), n);
- joints.at(3) = std::make_unique(std::move(turntable), n);
- joints.at(4) = std::make_unique(std::move(wristLeft), std::move(wristRight), n, "/control/arm/5/pitch", "/control/arm/5/roll", "/control/arm/20/", "/control/arm/21/");
- std::cout << "init joints" << std::endl;
-
- // Initialize the Joint State Data Publisher
- jointStatePublisher = n.advertise("/control/arm_joint_states", MESSAGE_CACHE_SIZE);
-
- // Initialize the Action Server
- Server server(n, "/arm_controller/follow_joint_trajectory", boost::bind(&execute, _1, &server), false);
- // Start the Action Server
- server.start();
- std::cout << "server started" << std::endl;
-
- ros::Timer timer = n.createTimer(ros::Duration(TIMER_CALLBACK_DURATION), publishJointStates);
-
- enableServiceServer = n.advertiseService("start_IK",
- static_cast>(
- [](std_srvs::Trigger::Request &req, std_srvs::Trigger::Response &res)->bool{
- IKEnabled = true;
- res.message = "Arm IK Enabled";
- res.success = static_cast(true);
- return true;
- }
- ));
-
- enableServiceClient = n.serviceClient("PLACEHOLDER_NAME");
-
- std::cout << "entering ROS spin..." << std::endl;
- // ROS spin for communication with other nodes
- ros::spin();
- // Return 0 on exit (successful exit)
- return 0;
-}
diff --git a/src/wr_control_drive_arm/src/ArmMotor.cpp b/src/wr_control_drive_arm/src/ArmMotor.cpp
deleted file mode 100644
index 60220e71..00000000
--- a/src/wr_control_drive_arm/src/ArmMotor.cpp
+++ /dev/null
@@ -1,202 +0,0 @@
-/**
- * @file ArmMotor.cpp
- * @author Ben Nowotny
- * @brief The implementation of the ArmMotor class
- * @date 2021-04-05
- */
-#include "ArmMotor.hpp"
-#include
-#include
-
-/// Allow for referencing the UInt32 message type easier
-using Std_UInt32 = std_msgs::UInt32::ConstPtr;
-using Std_Float64 = std_msgs::Float64::ConstPtr;
-using Std_Bool = std_msgs::Bool::ConstPtr;
-
-auto ArmMotor::corrMod(double i, double j) -> double {
- // Stem i%j by j, which in modular arithmetic is the same as adding 0.
- return std::fmod(std::fmod(std::abs(j)*i/j,std::abs(j))+j,std::abs(j));
-}
-
-/// Currently consistent with the rad->enc equation as specified here.
-auto ArmMotor::radToEnc(double rads) const -> uint32_t{
- return this->COUNTS_PER_ROTATION * ArmMotor::corrMod(rads, 2 * M_PI)/(2 * M_PI) + this->ENCODER_OFFSET;
-}
-
-auto ArmMotor::encToRad(uint32_t enc) const -> double{
- return ArmMotor::corrMod(static_cast(enc - this->ENCODER_OFFSET) / static_cast(this->COUNTS_PER_ROTATION) * 2 * M_PI + M_PI, 2 * M_PI) - M_PI;
-}
-
-/// Currently consistent with the enc->rad equation as specified here.
-auto ArmMotor::getRads() const -> double{
- return ArmMotor::encToRad(this->getEncoderCounts());
-}
-
-void ArmMotor::storeEncoderVals(const Std_UInt32 &msg){
- // Store the message value in this ArmMotor's encoderVal variable
- this->encoderVal = msg->data;
-
- // Send feedback
- std_msgs::Float64 feedbackMsg;
- feedbackMsg.data = ArmMotor::encToRad(msg->data);
- this->feedbackPub.publish(feedbackMsg);
-
- if(this->currState == MotorState::RUN_TO_TARGET){
- std::cout << "[2] " << (hasReachedTarget(this->target) ? "at target " : "not at target ") << this->target << ":" << this->encoderVal << std::endl;
- if(hasReachedTarget(this->target)){
- std::cout << "[1] stop motor" << std::endl;
- this->setPower(0.F, MotorState::STOP);
- }
- }
-}
-
-void ArmMotor::redirectPowerOutput(const Std_Float64 &msg){
- // Set the speed to be the contained data
- if(this->getMotorState() == MotorState::RUN_TO_TARGET) this->setPower(static_cast(msg->data) * this->maxPower, MotorState::RUN_TO_TARGET);
-}
-
-void ArmMotor::storeStallStatus(const Std_Bool &msg) {
- if (static_cast(msg->data)) {
- if ((ros::Time::now() - beginStallTime).toSec() >= STALL_THRESHOLD_TIME) {
- this->setPower(0.0F, MotorState::STALLING);
- }
- } else {
- beginStallTime = ros::Time::now();
- }
-}
-
-/// controllerID is constrained between [0,3]
-/// motorID is constrained between [0,1]
-ArmMotor::ArmMotor(
- std::string motor_name,
- unsigned int controllerID,
- unsigned int motorID,
- int64_t countsPerRotation,
- int64_t offset,
- ros::NodeHandle &n
-) : COUNTS_PER_ROTATION{countsPerRotation},
- ENCODER_BOUNDS{0, std::abs(countsPerRotation)},
- ENCODER_OFFSET{offset},
- motorName{std::move(motor_name)},
- controllerID{controllerID},
- motorID{motorID},
- currState{MotorState::STOP},
- power{0.F},
- maxPower{0.F},
- encoderVal{static_cast(offset)} {
-
- // Check validity of WRoboclaw and motor IDs
- if(controllerID > 3) throw std::invalid_argument{std::string{"Controller ID "} + std::to_string(controllerID) + "is only valid on [0,3]"};
- if(motorID > 1) throw std::invalid_argument{std::string{"Motor ID "} + std::to_string(motorID) + " is only valid on [0,1]"};
-
- // Create the topic string prefix for WRoboclaw controllers
- std::string tpString = std::string{"/hsi/roboclaw/aux"} + std::to_string(controllerID);
- std::string controlString = "/control/arm/" + std::to_string(controllerID) + std::to_string(motorID);
-
- // Create the appropriate encoder-reading and speed-publishing subscribers and advertisers, respectfully
- this->encRead = n.subscribe(tpString + "/enc/" + (motorID == 0 ? "left" : "right"), ArmMotor::MESSAGE_CACHE_SIZE, &ArmMotor::storeEncoderVals, this);
- this->speedPub = n.advertise(tpString + "/cmd/" + (motorID == 0 ? "left" : "right"), ArmMotor::MESSAGE_CACHE_SIZE);
- this->targetPub = n.advertise(controlString + "/setpoint", ArmMotor::MESSAGE_CACHE_SIZE);
- this->feedbackPub = n.advertise(controlString + "/feedback", ArmMotor::MESSAGE_CACHE_SIZE);
- this->outputRead = n.subscribe(controlString + "/output", ArmMotor::MESSAGE_CACHE_SIZE, &ArmMotor::redirectPowerOutput, this);
- this->stallRead = n.subscribe(tpString + "/curr/over_lim/" + (motorID == 0 ? "left" : "right"), ArmMotor::MESSAGE_CACHE_SIZE, &ArmMotor::storeStallStatus, this);
-
- std::cout << this->motorName << ": " << this->COUNTS_PER_ROTATION << std::endl;
-}
-
-auto ArmMotor::getEncoderCounts() const -> uint32_t{
- return this->encoderVal;
-}
-
-void ArmMotor::runToTarget(uint32_t targetCounts, float power){
- std::cout << "run to enc: " << targetCounts << std::endl;
- this->runToTarget(targetCounts, power, false);
-}
-
-auto ArmMotor::hasReachedTarget(uint32_t targetCounts, uint32_t tolerance) const -> bool{
- // Compute the upper and lower bounds in the finite encoder space
- uint32_t lBound = ArmMotor::corrMod(static_cast(targetCounts - tolerance), static_cast(ArmMotor::ENCODER_BOUNDS[1]));
- uint32_t uBound = ArmMotor::corrMod(static_cast(targetCounts + tolerance), static_cast(ArmMotor::ENCODER_BOUNDS[1]));
- // If the computed lower bound is lower than the upper bound, perform the computation normally
- if(lBound < uBound)
- return this->getEncoderCounts() <= uBound && this->getEncoderCounts() >=lBound;
- // Otherwise, check if the value is outside either bound and negate the response
- return this->getEncoderCounts() <= uBound || this->getEncoderCounts() >= lBound;
-}
-
-/// Current tolerance is ±0.1 degree w.r.t. the current number of counts per rotation
-auto ArmMotor::hasReachedTarget(uint32_t targetCounts) const -> bool{
- return ArmMotor::hasReachedTarget(targetCounts, ArmMotor::TOLERANCE_RATIO * static_cast(std::abs(this->COUNTS_PER_ROTATION)));
-}
-
-auto ArmMotor::getMotorState() const -> MotorState{
- return this->currState;
-}
-
-void ArmMotor::setPower(float power){
- this->setPower(power, power == 0.F ? MotorState::STOP : MotorState::MOVING);
-}
-
-/// This method auto-publishes the speed command to the WRoboclaws
-void ArmMotor::setPower(float power, MotorState state){
- // Check the bounds of the parameter
- if(abs(power) > 1) throw std::invalid_argument{std::string{"Power "} + std::to_string(power) + " is not on the interval [-1, 1]"};
-
- // Set up and send the speed message
- this->power = power;
- this->powerMsg.data = power * INT16_MAX;
- this->speedPub.publish(this->powerMsg);
- // Update the cur.nt motor state based on the power command input
- this->currState = state;
-}
-
-void ArmMotor::runToTarget(uint32_t targetCounts, float power, bool block){
- this->target = targetCounts;
- this->maxPower = power;
- // If we are not at our target...
- if(!this->hasReachedTarget(targetCounts)){
- // std::cout << "has not reached target" << std::endl;
- // Set the power in the correct direction and continue running to the target
- this->currState = MotorState::RUN_TO_TARGET;
- std_msgs::Float64 setpointMsg;
- setpointMsg.data = ArmMotor::encToRad(targetCounts);
- this->targetPub.publish(setpointMsg);
-
- // long int direction = targetCounts - this->getEncoderCounts();
- // power = abs(power) * (corrMod(direction, ((long int)this->COUNTS_PER_ROTATION)) < corrMod(-direction, ((long int)this->COUNTS_PER_ROTATION)) ? 1 : -1);
- this->setPower(power, MotorState::RUN_TO_TARGET);
-
- // Otherwise, stop the motor
- } else {
- // std::cout << "has reached target" << std::endl;
- this->setPower(0.F, MotorState::STOP);
- }
- // If this is a blocking call...
- if(block){
- // Wait until the motor has reached the target, then stop
- while(!this->hasReachedTarget(targetCounts));
- this->setPower(0.F, MotorState::RUN_TO_TARGET);
- }
-}
-
-void ArmMotor::runToTarget(double rads, float power){
- // std::cout << "run to target: " << rads << ":" << this->radToEnc(rads) << ":" << this->getEncoderCounts() << std::endl;
-
- runToTarget(this->radToEnc(rads), power, false);
-}
-
-auto ArmMotor::getMotorName() const -> std::string{
- return this->motorName;
-}
-
-auto ArmMotor::getMotorID() const -> unsigned int{
- return this->motorID;
-}
-
-auto ArmMotor::getControllerID() const -> unsigned int{
- return this->controllerID;
-}
-
-auto ArmMotor::getPower() const -> float{
- return this->power;
-}
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/ArmMotor.hpp b/src/wr_control_drive_arm/src/ArmMotor.hpp
deleted file mode 100644
index ba4d2120..00000000
--- a/src/wr_control_drive_arm/src/ArmMotor.hpp
+++ /dev/null
@@ -1,242 +0,0 @@
-/**
- * @file ArmMotor.hpp
- * @author Ben Nowotny
- * @brief Header file of the ArmMotor class
- * @date 2021-04-05
- */
-
-#include
-#include "ros/ros.h"
-#include "std_msgs/UInt32.h"
-#include "std_msgs/Int16.h"
-#include "std_msgs/Float64.h"
-#include "std_msgs/Bool.h"
-#include
-#include
-
-/**
- * @brief An enumeration of states for a motor to be in.
- */
-enum class MotorState{
- /// A Motor is stopped (not moving, 0 power command)
- STOP,
- /// A Motor is moving (non-0 power command)
- MOVING,
- /// A Motor is running to a given target
- RUN_TO_TARGET,
- /// A Motor is stalling (over safety current limit)
- STALLING
-};
-/**
- * @brief A way to control arm motors with WRoboclaw
- */
-class ArmMotor{
- private:
- /// Time tolerance of over-current detection before a stall fault is triggered
- static constexpr float STALL_THRESHOLD_TIME = 0.5;
- /// Tolerance ratio w.r.t the counts per rotation for encoder run-to-position motion
- static constexpr double TOLERANCE_RATIO = 0.1/360;
- /// Size of ROS Topic message caches
- static constexpr uint32_t MESSAGE_CACHE_SIZE = 10;
- /// The number of encoder counts per rotation
- int64_t const COUNTS_PER_ROTATION;
- /// The upper and lower bounds of encoder rotation for absolute encoders (index 0 is lower, index 1 is upper)
- std::array const ENCODER_BOUNDS;
- /// zero position of motor
- int64_t const ENCODER_OFFSET;
- /// The current state of the motor
- std::atomic currState;
- /// The joint name of the current motor
- std::string motorName;
- /// The ID of the WRoboclaw controller
- unsigned int controllerID;
- /// The ID of the motor within the WRoboclaw controller
- unsigned int motorID;
- /// The current encoder value
- uint32_t encoderVal;
- /// Target encoder counts for run to target
- uint32_t target;
- /// The ROS Subscriber that reads the encoders
- ros::Subscriber encRead;
- /// The ROS Publisher that sets the encoder targets
- ros::Publisher targetPub;
- /// The ROS Publisher that sets encoder feedback data
- ros::Publisher feedbackPub;
- /// The ROS Subscriber that reads controlled output data
- ros::Subscriber outputRead;
- /// The ROS Publisher that publishes motor speed commands
- ros::Publisher speedPub;
- /// The most recent power message sent
- std_msgs::Int16 powerMsg;
- /// The ROS Subscriber that reads stall status data
- ros::Subscriber stallRead;
- /// The time when the motor began stalling
- ros::Time beginStallTime;
- /// Motor power
- float power;
- /// Maximum absolute motor power in RUN_TO_POSITION mode.
- std::atomic maxPower;
-
- /**
- * @brief A static conversion from radians to encoder counts
- *
- * @param rad The input number of radians
- * @return uint32_t The corresponding encoder count bounded by ENCODER_BOUNDS
- */
- auto radToEnc(double rad) const -> uint32_t;
-
- /**
- * @brief A static conversion from encoder counts to radians
- *
- * @param enc The input number of encoder counts
- * @return double The corresponding radian measure
- */
- auto encToRad(uint32_t enc) const -> double;
-
- /**
- * @brief Subscriber callback for encRead, captures the encoder value of the current motor
- *
- * @param msg The encoder value message as captured by encRead
- */
- void storeEncoderVals(const std_msgs::UInt32::ConstPtr& msg);
-
- /**
- * @brief Subscriber callback for outputRead, captures the PID output and sets the speed directly
- *
- * @param msg The PID output as captured by outputRead
- */
- void redirectPowerOutput(const std_msgs::Float64::ConstPtr& msg);
-
- /**
- * @brief Subscriber callback for stallRead, captures the stall status of the current motor
- *
- * @param msg The stall status of the current motor
- */
- void storeStallStatus(const std_msgs::Bool::ConstPtr& msg);
-
- void setPower(float power, MotorState state);
-
- /**
- * @brief Performs Euclidean correct modulus between two inputs of the same type
- *
- * @param i The dividend of the modulus
- * @param j The divisor of the modulus
- * @return double The Euclidean-correct remainder bounded on [0, j)
- */
- static auto corrMod(double i, double j) -> double;
-
- public:
- /**
- * @brief Constructs a new ArmMotor
- *
- * @param motorName The joint name of the motor
- * @param controllerID The WRoboclaw controller ID for this motor
- * @param motorID The motor ID within its WRoboclaw controller
- * @param n A NodeHandle reference to the constructing Node
- */
- ArmMotor(std::string motorName, unsigned int controllerID, unsigned int motorID, int64_t countsPerRotation, int64_t offset, ros::NodeHandle &n);
-
- /**
- * @brief Gets the encoder value of the motor
- *
- * @return uint32_t The current encoder value of the motor
- */
- auto getEncoderCounts() const -> uint32_t;
-
- /**
- * @brief Sends the motor to run to a target encoder value at a given power without blocking
- *
- * @param targetCounts The target encoder value for the motor
- * @param power The power to move the motor at (Bounded between [-1, 1])
- */
- void runToTarget(uint32_t targetCounts, float power);
-
- /**
- * @brief Sends the motor to run to a target encoder value at a given power
- *
- * @param targetCounts The target encoder value for the motor
- * @param power The power to move the motor at (Bounded between [-1, 1])
- * @param block Specifies whether or not this action should block until it is complete
- * @return True if the motor had stalled, and false otherwise
- */
- void runToTarget(uint32_t targetCounts, float power, bool block);
-
- /**
- * @brief Sends the motor to run to a specified position at a given power
- *
- * @param rads The position to send the motor to (specified in radians)
- * @param power The power to move the motor at (Bounded between [-1, 1])
- * @return True if the motor had stalled, and false otherwise
- */
- void runToTarget(double rads, float power);
-
- /**
- * @brief Get the current state of the ArmMotor
- *
- * @return MotorState The current state of the ArmMotor
- */
- auto getMotorState() const -> MotorState;
-
- /**
- * @brief Set the motor power
- *
- * @param power The power to set the motor at (Bounded between [-1, 1])
- */
- void setPower(float power);
-
- /**
- * @brief Get the radian measure of the current motor
- *
- * @return double The radian measure of the current motor's position
- */
- auto getRads() const -> double;
-
- /**
- * @brief Get the name of the ArmMotor
- *
- * @return std::string The name of the ArmMotor
- */
- auto getMotorName() const -> std::string;
-
- /**
- * @brief Get the name of the ArmMotor
- *
- * @return std::string The controller ID of the ArmMotor
- */
- auto getControllerID() const -> unsigned int;
-
- /**
- * @brief Get the name of the ArmMotor
- *
- * @return std::string The motor ID of the ArmMotor
- */
- auto getMotorID() const -> unsigned int;
-
-
- /**
- * @brief Checks if the motor is currently within a pre-specified tolerance of a target
- *
- * @param targetCounts The target to test against
- * @return true The motor was within the target tolerance
- * @return false The motor was outside of the target tolerance
- */
- auto hasReachedTarget(uint32_t targetCounts) const -> bool;
-
- /**
- * @brief Checks if the motor is currently within a given tolerance of a target
- *
- * @param targetCounts The target to test against
- * @param tolerance The tolerance to give when testing the target
- * @return true The motor was within the target tolerance
- * @return false The motor was outside the target tolerance
- */
- auto hasReachedTarget(uint32_t targetCounts, uint32_t tolerance) const -> bool;
-
- /**
- * @brief Get the most recently set motor power
- *
- * @return float Last motor power setting
- */
- auto getPower() const -> float;
-};
-
diff --git a/src/wr_control_drive_arm/src/DifferentialJoint.cpp b/src/wr_control_drive_arm/src/DifferentialJoint.cpp
deleted file mode 100644
index 85c3c1c7..00000000
--- a/src/wr_control_drive_arm/src/DifferentialJoint.cpp
+++ /dev/null
@@ -1,128 +0,0 @@
-/**
- * @file DifferentialJoint.cpp
- * @author Nicholas Underwood
- * @brief Header file of the DifferentialJoint class
- * @date 2021-10-25
- */
-
-#include "DifferentialJoint.hpp"
-#include
-using std::vector;
-
-constexpr std::array, 2> DifferentialJoint::MOTOR_TO_JOINT_MATRIX;
-constexpr std::array, 2> DifferentialJoint::JOINT_TO_MOTOR_MATRIX;
-
-DifferentialJoint::DifferentialJoint(std::unique_ptr leftMotor, std::unique_ptr rightMotor, ros::NodeHandle &n,
- const std::string &pitchTopicName, const std::string &rollTopicName,
- const std::string &leftTopicName, const std::string &rightTopicName)
- : AbstractJoint(n, DEGREES_OF_FREEDOM) {
- this->motors.at(0) = {std::move(leftMotor), 0, 0, "", "", false};
- this->motors.at(1) = {std::move(rightMotor), 0, 0, "", "", false};
-
- this->pitchOutputSubscriber = n.subscribe(pitchTopicName + "/output", MESSAGE_CACHE_SIZE, &DifferentialJoint::handoffPitchOutput, this);
- this->rollOutputSubscriber = n.subscribe(rollTopicName + "/output", MESSAGE_CACHE_SIZE, &DifferentialJoint::handoffRollOutput, this);
- this->leftOutputPublisher = n.advertise(leftTopicName + "/output", MESSAGE_CACHE_SIZE);
- this->rightOutputPublisher = n.advertise(rightTopicName + "/output", MESSAGE_CACHE_SIZE);
- this->leftFeedbackSubscriber = n.subscribe(leftTopicName + "/feeback", MESSAGE_CACHE_SIZE, &DifferentialJoint::handoffLeftFeedback, this);
- this->rightFeedbackSubscriber = n.subscribe(rightTopicName + "/feeback", MESSAGE_CACHE_SIZE, &DifferentialJoint::handoffRightFeedback, this);
- this->pitchFeedbackPublisher = n.advertise(pitchTopicName + "/feedback", MESSAGE_CACHE_SIZE);
- this->rollFeedbackPublisher = n.advertise(rollTopicName + "/feedback", MESSAGE_CACHE_SIZE);
-}
-
-auto DifferentialJoint::getJointPositions(const vector &motorPositions) -> vector{
- // vector positions;
- // target->reserve(2);
-
- double pitch = motorPositions.at(0) * MOTOR_TO_JOINT_MATRIX.at(0).at(0) + motorPositions.at(1) * MOTOR_TO_JOINT_MATRIX.at(0).at(1);
- double roll = motorPositions.at(0) * MOTOR_TO_JOINT_MATRIX.at(1).at(0) + motorPositions.at(1) * MOTOR_TO_JOINT_MATRIX.at(1).at(1);
-
- //TODO: Why not return a new vector? Wouldn't this constant resizing be more inefficient than just making/returning a new vector via copy ellision?
- return {pitch, roll};
-
- // return positions;
-}
-
-auto DifferentialJoint::getMotorPositions(const vector &jointPositions) -> vector{
-
- // std::unique_ptr> positions = std::make_unique>(2);
- // target->reserve(2);
-
- double left = jointPositions.at(0) * JOINT_TO_MOTOR_MATRIX.at(0).at(0) + jointPositions.at(1) * JOINT_TO_MOTOR_MATRIX.at(0).at(1);
- double right = jointPositions.at(0) * JOINT_TO_MOTOR_MATRIX.at(1).at(0) + jointPositions.at(1) * JOINT_TO_MOTOR_MATRIX.at(1).at(1);
-
- return {left, right};
-
- // return std::move(positions);
-}
-
-auto DifferentialJoint::getMotorVelocities(const vector &jointPositions) -> vector{
- return getMotorPositions(jointPositions); //deritivate of linear transformation is itself
-}
-
-void DifferentialJoint::handoffPitchOutput(const std_msgs::Float64::ConstPtr &msg){
- this->cachedPitchOutput = msg->data;
- this->hasNewPitchOutput = true;
- handOffAllOutput();
-}
-void DifferentialJoint::handoffRollOutput(const std_msgs::Float64::ConstPtr &msg){
- this->cachedRollOutput = msg->data;
- this->hasNewRollOutput = true;
- handOffAllOutput();
-}
-
-// TODO: Do these ouputs need to be synced? We're just referring to the motors individually, maybe we can transform and send the data right away
-void DifferentialJoint::handOffAllOutput(){
- if(!this->hasNewPitchOutput || !this->hasNewRollOutput){ return; }
-
- vector outputs;
- outputs.resize(2);
- outputs.at(0) = this->cachedPitchOutput;
- outputs.at(1) = this->cachedRollOutput;
- //TODO: Still confused as to the purpose of this family of functions
- outputs = getMotorVelocities(outputs);
-
- std_msgs::Float64 msg1;
- std_msgs::Float64 msg2;
- msg1.data = outputs.at(0);
- msg2.data = outputs.at(1);
- pitchFeedbackPublisher.publish(msg1);
- rollFeedbackPublisher.publish(msg2);
-
- leftOutputPublisher.publish(msg1);
- rightOutputPublisher.publish(msg2);
-
- this->hasNewPitchOutput = false;
- this->hasNewRollOutput = false;
-
-}
-
-void DifferentialJoint::handoffRightFeedback(const std_msgs::Float64::ConstPtr &msg){
- this->cachedRightFeedback = msg->data;
- this->hasNewRightFeedback = true;
- handOffAllFeedback();
-}
-void DifferentialJoint::handoffLeftFeedback(const std_msgs::Float64::ConstPtr &msg){
- this->cachedLeftFeedback = msg->data;
- this->hasNewLeftFeedback = true;
- handOffAllFeedback();
-}
-
-void DifferentialJoint::handOffAllFeedback(){
- if(!this->hasNewLeftFeedback || !this->hasNewRightFeedback){ return; }
-
- vector outputs;
- outputs.at(0) = this->cachedLeftFeedback;
- outputs.at(1) = this->cachedRightFeedback;
- outputs = getMotorVelocities(outputs);
-
- std_msgs::Float64 msg1;
- std_msgs::Float64 msg2;
- msg1.data = outputs.at(0);
- msg2.data = outputs.at(1);
- pitchFeedbackPublisher.publish(msg1);
- rollFeedbackPublisher.publish(msg2);
-
- this->hasNewLeftFeedback = false;
- this->hasNewRightFeedback = false;
-
-}
diff --git a/src/wr_control_drive_arm/src/DifferentialJoint.hpp b/src/wr_control_drive_arm/src/DifferentialJoint.hpp
deleted file mode 100644
index 7bfaec4f..00000000
--- a/src/wr_control_drive_arm/src/DifferentialJoint.hpp
+++ /dev/null
@@ -1,56 +0,0 @@
-/**
- * @file DifferentialJoint.hpp
- * @author Nichols Underwood
- * @brief Header file of the DifferentialJoint class
- * @date 2021-10-25
- */
-
-#include "AbstractJoint.hpp"
-
-class DifferentialJoint : public AbstractJoint {
- public:
- DifferentialJoint(std::unique_ptr leftMotor, std::unique_ptr rightMotor, ros::NodeHandle &n,
- const std::string &pitchTopicName, const std::string &rollTopicName,
- const std::string &leftTopicName, const std::string &rightTopicName);
-
- auto getMotorPositions(const vector &jointPositions) -> vector override;
- auto getMotorVelocities(const vector &jointVelocities) -> vector override;
- auto getJointPositions(const vector &motorPositions) -> vector override;
-
- private:
- static constexpr uint32_t DEGREES_OF_FREEDOM = 2;
- static constexpr uint32_t MESSAGE_CACHE_SIZE = 10;
- // linear transformations works for position and velocity
- // [0.5 0.5] [left motor ] [pitch]
- // [ -1 1 ] * [right motor] = [roll ]
- // double motorToJointMatrix[2][2] = {{0.5, 0.5}, {-1, 1}};
- static constexpr std::array, 2> MOTOR_TO_JOINT_MATRIX{{{1, 0}, {0, 1}}};
- // [1 -0.5] [pitch] [left motor ]
- // [1 0.5] * [roll ] = [right motor]
- // double jointToMotorMatrix[2][2] = {{1, 0.5}, {1, -0.5}};
- static constexpr std::array, 2> JOINT_TO_MOTOR_MATRIX{{{1, 0}, {0, 1}}};
-
- void handoffPitchOutput(const std_msgs::Float64::ConstPtr&);
- void handoffRollOutput(const std_msgs::Float64::ConstPtr&);
- void handOffAllOutput();
- ros::Subscriber pitchOutputSubscriber;
- ros::Subscriber rollOutputSubscriber;
- ros::Publisher leftOutputPublisher;
- ros::Publisher rightOutputPublisher;
- float cachedPitchOutput = 0.0;
- float cachedRollOutput = 0.0;
- bool hasNewPitchOutput = false;
- bool hasNewRollOutput = false;
-
- void handoffLeftFeedback(const std_msgs::Float64::ConstPtr&);
- void handoffRightFeedback(const std_msgs::Float64::ConstPtr&);
- void handOffAllFeedback();
- ros::Subscriber leftFeedbackSubscriber;
- ros::Subscriber rightFeedbackSubscriber;
- ros::Publisher pitchFeedbackPublisher;
- ros::Publisher rollFeedbackPublisher;
- float cachedLeftFeedback = 0.0;
- float cachedRightFeedback = 0.0;
- bool hasNewLeftFeedback = false;
- bool hasNewRightFeedback = false;
-};
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/DifferentialJointToMotorSpeedConverter.cpp b/src/wr_control_drive_arm/src/DifferentialJointToMotorSpeedConverter.cpp
new file mode 100644
index 00000000..dfe28450
--- /dev/null
+++ b/src/wr_control_drive_arm/src/DifferentialJointToMotorSpeedConverter.cpp
@@ -0,0 +1,43 @@
+#include "DifferentialJointToMotorSpeedConverter.hpp"
+#include
+
+DifferentialJointToMotorSpeedConverter::DifferentialJointToMotorSpeedConverter(
+ std::shared_ptr leftMotor,
+ std::shared_ptr rightMotor)
+ : cachedPitchSpeed{0},
+ cachedRollSpeed{0},
+ leftMotor{std::move(leftMotor)},
+ rightMotor{std::move(rightMotor)} {}
+
+DifferentialJointToMotorSpeedConverter::DifferentialJointToMotorSpeedConverter(
+ const DifferentialJointToMotorSpeedConverter &other)
+ : cachedPitchSpeed{other.cachedPitchSpeed.load()},
+ cachedRollSpeed{other.cachedRollSpeed.load()},
+ leftMotor{other.leftMotor},
+ rightMotor{other.rightMotor} {}
+
+DifferentialJointToMotorSpeedConverter::DifferentialJointToMotorSpeedConverter(
+ DifferentialJointToMotorSpeedConverter &&other) noexcept
+ : cachedPitchSpeed{other.cachedPitchSpeed.load()},
+ cachedRollSpeed{other.cachedRollSpeed.load()},
+ leftMotor{other.leftMotor},
+ rightMotor{other.rightMotor} {}
+
+void DifferentialJointToMotorSpeedConverter::setPitchSpeed(double speed) {
+ cachedPitchSpeed = speed;
+ dispatchDifferentialSpeed();
+}
+
+void DifferentialJointToMotorSpeedConverter::setRollSpeed(double speed) {
+ cachedRollSpeed = speed;
+ dispatchDifferentialSpeed();
+}
+
+void DifferentialJointToMotorSpeedConverter::dispatchDifferentialSpeed() {
+ // const std::lock_guard guard{mutex};
+ auto m1Speed{-cachedPitchSpeed + (cachedRollSpeed * AVERAGE_SCALING_FACTOR)};
+ auto m2Speed{-cachedPitchSpeed - (cachedRollSpeed * AVERAGE_SCALING_FACTOR)};
+ leftMotor->setSpeed(m1Speed);
+ rightMotor->setSpeed(m2Speed);
+ // std::cout << "ptch: " << cachedPitchSpeed.load() << "\troll: " << cachedRollSpeed.load() << "\tlspd: " << m1Speed << "\trspd: " << m2Speed << std::endl;
+}
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/DifferentialJointToMotorSpeedConverter.hpp b/src/wr_control_drive_arm/src/DifferentialJointToMotorSpeedConverter.hpp
new file mode 100644
index 00000000..5d096add
--- /dev/null
+++ b/src/wr_control_drive_arm/src/DifferentialJointToMotorSpeedConverter.hpp
@@ -0,0 +1,31 @@
+#ifndef DIFFERENTIAL_JOINT_TO_MOTOR_SPEED_CONVERTER_H
+#define DIFFERENTIAL_JOINT_TO_MOTOR_SPEED_CONVERTER_H
+
+#include "Motor.hpp"
+
+class DifferentialJointToMotorSpeedConverter {
+public:
+ DifferentialJointToMotorSpeedConverter(std::shared_ptr leftMotor, std::shared_ptr rightMotor);
+ void setPitchSpeed(double speed);
+ void setRollSpeed(double speed);
+
+ DifferentialJointToMotorSpeedConverter(const DifferentialJointToMotorSpeedConverter &);
+ auto operator=(const DifferentialJointToMotorSpeedConverter &) -> DifferentialJointToMotorSpeedConverter & = delete;
+ DifferentialJointToMotorSpeedConverter(DifferentialJointToMotorSpeedConverter &&) noexcept;
+ auto operator=(DifferentialJointToMotorSpeedConverter &&) -> DifferentialJointToMotorSpeedConverter & = delete;
+ ~DifferentialJointToMotorSpeedConverter() = default;
+
+private:
+ std::atomic cachedPitchSpeed;
+ std::atomic cachedRollSpeed;
+ std::recursive_mutex mutex;
+
+ const std::shared_ptr leftMotor;
+ const std::shared_ptr rightMotor;
+
+ static constexpr double AVERAGE_SCALING_FACTOR{1};
+
+ void dispatchDifferentialSpeed();
+};
+
+#endif
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/DirectJointToMotorSpeedConverter.cpp b/src/wr_control_drive_arm/src/DirectJointToMotorSpeedConverter.cpp
new file mode 100644
index 00000000..67fd0568
--- /dev/null
+++ b/src/wr_control_drive_arm/src/DirectJointToMotorSpeedConverter.cpp
@@ -0,0 +1,18 @@
+#include "DirectJointToMotorSpeedConverter.hpp"
+
+DirectJointToMotorSpeedConverter::DirectJointToMotorSpeedConverter(std::shared_ptr outputMotor, MotorSpeedDirection direction)
+ : outputMotor{std::move(outputMotor)},
+ direction{direction} {}
+
+void DirectJointToMotorSpeedConverter::operator()(double speed) {
+ double actualSpeed{0}; // In event of enum error, stop the motor
+ switch (direction) {
+ case MotorSpeedDirection::FORWARD:
+ actualSpeed = speed;
+ break;
+ case MotorSpeedDirection::REVERSE:
+ actualSpeed = -speed;
+ break;
+ }
+ outputMotor->setSpeed(actualSpeed);
+}
diff --git a/src/wr_control_drive_arm/src/DirectJointToMotorSpeedConverter.hpp b/src/wr_control_drive_arm/src/DirectJointToMotorSpeedConverter.hpp
new file mode 100644
index 00000000..6a117435
--- /dev/null
+++ b/src/wr_control_drive_arm/src/DirectJointToMotorSpeedConverter.hpp
@@ -0,0 +1,28 @@
+#ifndef DIRECT_JOINT_TO_MOTOR_SPEED_CONVERTER_H
+#define DIRECT_JOINT_TO_MOTOR_SPEED_CONVERTER_H
+
+#include "Motor.hpp"
+#include
+
+enum class MotorSpeedDirection {
+ FORWARD,
+ REVERSE
+};
+
+class DirectJointToMotorSpeedConverter {
+public:
+ DirectJointToMotorSpeedConverter(std::shared_ptr outputMotor, MotorSpeedDirection direction);
+ void operator()(double speed);
+
+ DirectJointToMotorSpeedConverter(const DirectJointToMotorSpeedConverter &) = default;
+ auto operator=(const DirectJointToMotorSpeedConverter &) -> DirectJointToMotorSpeedConverter & = delete;
+ DirectJointToMotorSpeedConverter(DirectJointToMotorSpeedConverter &&) = default;
+ auto operator=(DirectJointToMotorSpeedConverter &&) -> DirectJointToMotorSpeedConverter & = delete;
+ ~DirectJointToMotorSpeedConverter() = default;
+
+private:
+ const MotorSpeedDirection direction;
+ const std::shared_ptr outputMotor;
+};
+
+#endif
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/Joint.cpp b/src/wr_control_drive_arm/src/Joint.cpp
new file mode 100644
index 00000000..08b7c8a3
--- /dev/null
+++ b/src/wr_control_drive_arm/src/Joint.cpp
@@ -0,0 +1,72 @@
+#include "Joint.hpp"
+#include "MathUtil.hpp"
+#include
+#include
+
+using std::literals::string_literals::operator""s;
+using MathUtil::RADIANS_PER_ROTATION;
+
+Joint::Joint(std::string name,
+ std::function positionMonitor,
+ std::function motorSpeedDispatcher,
+ ros::NodeHandle node)
+ : name{std::move(name)},
+ positionMonitor{std::move(positionMonitor)},
+ motorSpeedDispatcher{std::move(motorSpeedDispatcher)},
+ executeMotion{false},
+ controlLoopUpdateTimer{node.createTimer(ros::Rate{FEEDBACK_UPDATE_FREQUENCY_HZ}, &Joint::onFeedbackUpdateEvent, this, false, false)},
+ controlLoopOutputSubscriber{node.subscribe("/control/arm/pid/"s + this->name + "/output", 1, &Joint::onControlLoopOutput, this)},
+ controlLoopSetpointPublisher{node.advertise("/control/arm/pid/"s + this->name + "/setpoint", 1)},
+ controlLoopFeedbackPublisher{node.advertise("/control/arm/pid/"s + this->name + "/feedback", 1)} {}
+
+void Joint::setTarget(double target, double maxSpeed) {
+ this->target = target;
+ this->maxSpeed = maxSpeed;
+ executeMotion = true;
+ controlLoopUpdateTimer.start();
+}
+
+auto Joint::hasReachedTarget() const -> bool {
+ // Copy-on-read to avoid inconsistencies on asynchronous change
+ auto currentTarget = target.load();
+
+ // Compute the upper and lower bounds in the finite encoder space
+ auto lBound = MathUtil::corrMod(currentTarget - JOINT_TOLERANCE_RADIANS, RADIANS_PER_ROTATION);
+ auto uBound = MathUtil::corrMod(currentTarget + JOINT_TOLERANCE_RADIANS, RADIANS_PER_ROTATION);
+ auto position = MathUtil::corrMod(positionMonitor(), RADIANS_PER_ROTATION);
+ // If the computed lower bound is lower than the upper bound, perform the computation normally
+ if (lBound < uBound)
+ return position <= uBound && position >= lBound;
+ // Otherwise, check if the value is outside either bound and negate the response
+ return position <= uBound || position >= lBound;
+}
+
+auto Joint::getName() const -> std::string {
+ return name;
+}
+
+void Joint::stop() {
+ executeMotion = false;
+ controlLoopUpdateTimer.stop();
+ motorSpeedDispatcher(0);
+}
+
+void Joint::onControlLoopOutput(const std_msgs::Float64::ConstPtr &msg) {
+ auto cappedPowerUnsigned{std::min(std::abs(msg->data), std::abs(maxSpeed))};
+ double cappedPower{0};
+ if (msg->data != 0)
+ cappedPower = (std::abs(msg->data) / msg->data) * cappedPowerUnsigned;
+ motorSpeedDispatcher(executeMotion ? cappedPower : 0);
+}
+
+void Joint::onFeedbackUpdateEvent(const ros::TimerEvent &event) {
+ // Setpoint
+ std_msgs::Float64 setpointMsg;
+ setpointMsg.data = target;
+ controlLoopSetpointPublisher.publish(setpointMsg);
+
+ // Feedback
+ std_msgs::Float64 feedbackMsg;
+ feedbackMsg.data = positionMonitor();
+ controlLoopFeedbackPublisher.publish(feedbackMsg);
+}
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/Joint.hpp b/src/wr_control_drive_arm/src/Joint.hpp
new file mode 100644
index 00000000..659a4f98
--- /dev/null
+++ b/src/wr_control_drive_arm/src/Joint.hpp
@@ -0,0 +1,39 @@
+#ifndef JOINT_H
+#define JOINT_H
+
+#include "ros/publisher.h"
+#include "ros/subscriber.h"
+#include "ros/timer.h"
+#include "std_msgs/Float64.h"
+#include
+#include
+
+class Joint {
+public:
+ explicit Joint(std::string name, std::function positionMonitor, std::function motorSpeedDispatcher, ros::NodeHandle node);
+ void setTarget(double target, double maxSpeed);
+ [[nodiscard]] auto hasReachedTarget() const -> bool;
+ [[nodiscard]] auto getName() const -> std::string;
+ void stop();
+
+private:
+ static constexpr double FEEDBACK_UPDATE_FREQUENCY_HZ{50};
+ static constexpr double JOINT_TOLERANCE_RADIANS{3 * M_PI / 180};
+
+ const std::string name;
+ const std::function positionMonitor;
+ const std::function motorSpeedDispatcher;
+
+ void onControlLoopOutput(const std_msgs::Float64::ConstPtr &msg);
+ void onFeedbackUpdateEvent(const ros::TimerEvent &event);
+
+ std::atomic target;
+ std::atomic maxSpeed;
+ std::atomic executeMotion;
+ ros::Timer controlLoopUpdateTimer;
+ ros::Subscriber controlLoopOutputSubscriber;
+ ros::Publisher controlLoopSetpointPublisher;
+ ros::Publisher controlLoopFeedbackPublisher;
+};
+
+#endif
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/JointStatePublisher.cpp b/src/wr_control_drive_arm/src/JointStatePublisher.cpp
new file mode 100644
index 00000000..3a602563
--- /dev/null
+++ b/src/wr_control_drive_arm/src/JointStatePublisher.cpp
@@ -0,0 +1,140 @@
+/**
+ * @file JointStatePublisher.cpp
+ * @author Ben Nowotny
+ * @author Jack Zautner
+ * @brief The executable file to run the joint state publisher
+ * @date 2022-12-05
+ */
+
+#include "SingleEncoderJointPositionMonitor.hpp"
+#include "XmlRpcValue.h"
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+
+using XmlRpc::XmlRpcValue;
+
+/**
+ * @brief Nessage cache size of publisher
+ */
+constexpr std::uint32_t MESSAGE_CACHE_SIZE = 1;
+
+/**
+ * @brief Period between timer callback
+ */
+constexpr float TIMER_CALLBACK_DURATION = 1.0 / 50.0;
+
+/**
+ * @brief The joint state publisher for MoveIt
+ */
+ros::Publisher jointStatePublisher;
+
+std::map namedJointPositionMonitors;
+
+void publishJointStates(const ros::TimerEvent &event) {
+ std::vector names;
+ std::vector positions;
+ sensor_msgs::JointState js_msg;
+
+ for (auto &[name, monitor] : namedJointPositionMonitors) {
+ names.push_back(name);
+ positions.push_back(monitor());
+ }
+
+ js_msg.name = names;
+ js_msg.position = positions;
+ js_msg.header.stamp = ros::Time::now();
+ // Publish the Joint State message
+ jointStatePublisher.publish(js_msg);
+}
+
+auto getEncoderConfigFromParams(const XmlRpcValue ¶ms, const std::string &jointName) -> EncoderConfiguration {
+ return {.countsPerRotation = static_cast(params[jointName]["encoder_parameters"]["counts_per_rotation"]),
+ .offset = static_cast(params[jointName]["encoder_parameters"]["offset"])};
+}
+
+auto getMotorConfigFromParams(const XmlRpcValue ¶ms, const std::string &jointName) -> MotorConfiguration {
+ return {.gearRatio = static_cast(params[jointName]["motor_configurations"]["gear_ratio"])};
+}
+
+/**
+ * @brief The main executable method of the node. Starts the ROS node
+ *
+ * @param argc The number of program arguments
+ * @param argv The given program arguments
+ * @return int The status code on exiting the program
+ */
+auto main(int argc, char **argv) -> int {
+
+ std::cout << "start main" << std::endl;
+ // // Initialize the current node as JointStatePublisherApplication
+ ros::init(argc, argv, "JointStatePublisher");
+ // // Create the NodeHandle to the current ROS node
+ ros::NodeHandle n;
+ ros::NodeHandle pn{"~"};
+
+ XmlRpcValue armParams;
+ pn.getParam("arm_parameters", armParams);
+
+ namedJointPositionMonitors.try_emplace("elbowPitch_joint",
+
+ "aux1",
+ RoboclawChannel::A,
+ getEncoderConfigFromParams(armParams, "elbow"),
+ getMotorConfigFromParams(armParams, "elbow"),
+ n);
+ namedJointPositionMonitors.try_emplace("elbowRoll_joint",
+
+ "aux1",
+ RoboclawChannel::B,
+ getEncoderConfigFromParams(armParams, "forearmRoll"),
+ getMotorConfigFromParams(armParams, "forearmRoll"),
+ n);
+ namedJointPositionMonitors.try_emplace("shoulder_joint",
+
+ "aux0",
+ RoboclawChannel::B,
+ getEncoderConfigFromParams(armParams, "shoulder"),
+ getMotorConfigFromParams(armParams, "shoulder"),
+ n);
+ namedJointPositionMonitors.try_emplace("turntable_joint",
+
+ "aux0",
+ RoboclawChannel::A,
+ getEncoderConfigFromParams(armParams, "turntable"),
+ getMotorConfigFromParams(armParams, "turntable"),
+ n);
+ namedJointPositionMonitors.try_emplace("wristPitch_joint",
+
+ "aux2",
+ RoboclawChannel::A,
+ getEncoderConfigFromParams(armParams, "wristPitch"),
+ getMotorConfigFromParams(armParams, "wristPitch"),
+ n);
+ namedJointPositionMonitors.try_emplace("wristRoll_link",
+ "aux2",
+ RoboclawChannel::B,
+ getEncoderConfigFromParams(armParams, "wristRoll"),
+ getMotorConfigFromParams(armParams, "wristRoll"),
+ n);
+
+ // Initialize the Joint State Data Publisher
+ jointStatePublisher = n.advertise("/joint_states", MESSAGE_CACHE_SIZE);
+
+ // Timer that will call publishJointStates periodically
+ ros::Timer timer = n.createTimer(ros::Duration(TIMER_CALLBACK_DURATION), publishJointStates);
+
+ // Enter ROS spin
+ ros::spin();
+
+ return 0;
+}
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/MathUtil.cpp b/src/wr_control_drive_arm/src/MathUtil.cpp
new file mode 100644
index 00000000..682b0bad
--- /dev/null
+++ b/src/wr_control_drive_arm/src/MathUtil.cpp
@@ -0,0 +1,8 @@
+#include "MathUtil.hpp"
+#include
+
+namespace MathUtil {
+auto corrMod(double dividend, double divisor) -> double {
+ return std::fmod(std::fmod(dividend, divisor) + divisor, std::abs(divisor));
+}
+} // namespace MathUtil
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/MathUtil.hpp b/src/wr_control_drive_arm/src/MathUtil.hpp
new file mode 100644
index 00000000..07e7b0d0
--- /dev/null
+++ b/src/wr_control_drive_arm/src/MathUtil.hpp
@@ -0,0 +1,11 @@
+#ifndef MATH_UTIL_H
+#define MATH_UTIL_H
+
+#include
+
+namespace MathUtil {
+auto corrMod(double dividend, double divisor) -> double;
+static constexpr double RADIANS_PER_ROTATION{2 * M_PI};
+} // namespace MathUtil
+
+#endif
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/Motor.cpp b/src/wr_control_drive_arm/src/Motor.cpp
new file mode 100644
index 00000000..bc96cd0f
--- /dev/null
+++ b/src/wr_control_drive_arm/src/Motor.cpp
@@ -0,0 +1,45 @@
+#include "Motor.hpp"
+#include "RoboclawChannel.hpp"
+#include "ros/node_handle.h"
+#include "ros/time.h"
+#include "std_msgs/Int16.h"
+#include
+#include
+#include
+#include
+
+using std::literals::string_literals::operator""s;
+
+Motor::Motor(const std::string &controllerName, RoboclawChannel channel, ros::NodeHandle node)
+ : motorSpeedPublisher{
+ node.advertise(
+ "/hsi/roboclaw/"s + controllerName + "/cmd/"s + (channel == RoboclawChannel::A ? "left" : "right"),
+ 1)},
+ currentOverLimitSubscriber{
+ node.subscribe("/hsi/roboclaw/"s + controllerName + "/curr/over_lim/" + (channel == RoboclawChannel::A ? "left" : "right"),
+ OVER_CURRENT_QUEUE_SIZE, &Motor::setCurrentStatus, this)} {}
+
+void Motor::setSpeed(double speed) {
+ if (abs(speed) > 1)
+ throw std::invalid_argument("speed must be between -1 and 1");
+
+ std_msgs::Int16 powerMsg{};
+ powerMsg.data = static_cast(speed * INT16_MAX);
+ motorSpeedPublisher.publish(powerMsg);
+}
+
+void Motor::setCurrentStatus(const std_msgs::Bool::ConstPtr &msg) {
+ bool overCurrent = static_cast(msg->data);
+ if (overCurrent && !this->beginStallTime.has_value()) {
+ this->beginStallTime = ros::Time::now();
+ } else if (!overCurrent && this->beginStallTime.has_value()) {
+ this->beginStallTime = std::nullopt;
+ }
+}
+
+auto Motor::isOverCurrent() const -> bool {
+ if (this->beginStallTime.has_value()) {
+ return static_cast((ros::Time::now() - this->beginStallTime.value()).toSec() >= STALL_THRESHOLD_TIME);
+ }
+ return false;
+}
diff --git a/src/wr_control_drive_arm/src/Motor.hpp b/src/wr_control_drive_arm/src/Motor.hpp
new file mode 100644
index 00000000..ff3a6174
--- /dev/null
+++ b/src/wr_control_drive_arm/src/Motor.hpp
@@ -0,0 +1,30 @@
+#ifndef MOTOR_H
+#define MOTOR_H
+
+#include "RoboclawChannel.hpp"
+#include "ros/publisher.h"
+#include "ros/subscriber.h"
+#include "std_msgs/Bool.h"
+#include
+#include
+
+class Motor {
+public:
+ Motor(const std::string &controllerName, RoboclawChannel channel, ros::NodeHandle node);
+ void setSpeed(double speed);
+ auto isOverCurrent() const -> bool;
+
+private:
+
+ static constexpr float STALL_THRESHOLD_TIME{0.5F};
+ static constexpr int OVER_CURRENT_QUEUE_SIZE{25};
+
+
+ void setCurrentStatus(const std_msgs::Bool::ConstPtr &msg);
+
+ ros::Publisher motorSpeedPublisher;
+ ros::Subscriber currentOverLimitSubscriber;
+ std::optional beginStallTime;
+};
+
+#endif
diff --git a/src/wr_control_drive_arm/src/RoboclawChannel.hpp b/src/wr_control_drive_arm/src/RoboclawChannel.hpp
new file mode 100644
index 00000000..fbf7de00
--- /dev/null
+++ b/src/wr_control_drive_arm/src/RoboclawChannel.hpp
@@ -0,0 +1,6 @@
+#ifndef ROBOCLAW_CHANNEL_H
+#define ROBOCLAW_CHANNEL_H
+
+enum class RoboclawChannel { A, B };
+
+#endif
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/SimpleJoint.cpp b/src/wr_control_drive_arm/src/SimpleJoint.cpp
deleted file mode 100644
index d7ca2ee2..00000000
--- a/src/wr_control_drive_arm/src/SimpleJoint.cpp
+++ /dev/null
@@ -1,24 +0,0 @@
-/**
- * @file SimpleJoint.cpp
- * @author Nichols Underwood
- * @brief Implementation of the SimpleJoint class
- * @date 2021-10-25
- */
-
-#include "SimpleJoint.hpp"
-
-SimpleJoint::SimpleJoint(std::unique_ptr motor, ros::NodeHandle &n) : AbstractJoint(n, 1) {
- this->motors.at(0) = MotorHandler{std::move(motor), 0, 0, "", "", false};
-}
-
-auto SimpleJoint::getMotorPositions(const vector &jointPositions) -> vector {
- return {jointPositions[0]};
-}
-
-auto SimpleJoint::getMotorVelocities(const vector &jointVelocities) -> vector {
- return {jointVelocities[0]};
-}
-
-auto SimpleJoint::getJointPositions(const vector &jointPositions) -> vector {
- return {jointPositions[0]};
-}
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/SimpleJoint.hpp b/src/wr_control_drive_arm/src/SimpleJoint.hpp
deleted file mode 100644
index 2c1bf76b..00000000
--- a/src/wr_control_drive_arm/src/SimpleJoint.hpp
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- * @file SimpleJoint.hpp
- * @author Nichols Underwood
- * @brief Header file of the SimpleJoint class
- * @date 2021-10-25
- */
-
-#include "AbstractJoint.hpp"
-
-using std::vector;
-
-class SimpleJoint : public AbstractJoint {
- public:
- SimpleJoint(std::unique_ptr motor, ros::NodeHandle& n);
- auto getMotorPositions(const vector &jointPositions) -> vector override;
- auto getMotorVelocities(const vector &joinVelocities) -> vector override;
- auto getJointPositions(const vector &motorPositions) -> vector override;
-};
diff --git a/src/wr_control_drive_arm/src/SingleEncoderJointPositionMonitor.cpp b/src/wr_control_drive_arm/src/SingleEncoderJointPositionMonitor.cpp
new file mode 100644
index 00000000..d657f1c8
--- /dev/null
+++ b/src/wr_control_drive_arm/src/SingleEncoderJointPositionMonitor.cpp
@@ -0,0 +1,59 @@
+#include "SingleEncoderJointPositionMonitor.hpp"
+#include "MathUtil.hpp"
+#include "RoboclawChannel.hpp"
+#include "ros/node_handle.h"
+#include
+
+using std::literals::string_literals::operator""s;
+using MathUtil::RADIANS_PER_ROTATION;
+
+SingleEncoderJointPositionMonitor::SingleEncoderJointPositionMonitor(
+ const std::string &controllerName,
+ RoboclawChannel channel,
+ EncoderConfiguration eConfig,
+ MotorConfiguration mConfig,
+ ros::NodeHandle node)
+ : countsPerRotation{eConfig.countsPerRotation},
+ offset{eConfig.offset},
+ gearRatio{mConfig.gearRatio},
+ position{0},
+ encoderSubscriber{
+ std::make_shared(node.subscribe(
+ "/hsi/roboclaw/"s + controllerName + "/enc/" + (channel == RoboclawChannel::A ? "left" : "right"),
+ 1,
+ &SingleEncoderJointPositionMonitor::onEncoderReceived,
+ this))} {}
+
+SingleEncoderJointPositionMonitor::SingleEncoderJointPositionMonitor(
+ const SingleEncoderJointPositionMonitor &other)
+ : countsPerRotation(other.countsPerRotation),
+ offset(other.offset),
+ gearRatio{other.getGearRatio()},
+ encoderSubscriber{other.encoderSubscriber},
+ position{other.position.load()} {}
+
+SingleEncoderJointPositionMonitor::SingleEncoderJointPositionMonitor(
+ SingleEncoderJointPositionMonitor &&other) noexcept
+ : countsPerRotation(other.countsPerRotation),
+ offset(other.offset),
+ gearRatio(other.getGearRatio()),
+ encoderSubscriber{std::move(other.encoderSubscriber)},
+ position{other.position.load()} {}
+
+auto SingleEncoderJointPositionMonitor::operator()() -> double {
+ return position;
+}
+
+void SingleEncoderJointPositionMonitor::onEncoderReceived(const std_msgs::UInt32::ConstPtr &msg) {
+ auto enc = static_cast(msg->data);
+ auto rotations = MathUtil::corrMod(enc - offset, countsPerRotation) / countsPerRotation;
+ position = MathUtil::corrMod(rotations * RADIANS_PER_ROTATION + M_PI, RADIANS_PER_ROTATION) - M_PI;
+}
+
+auto SingleEncoderJointPositionMonitor::getCountsPerRotation() const -> int32_t {
+ return this->countsPerRotation;
+}
+
+auto SingleEncoderJointPositionMonitor::getGearRatio() const -> double {
+ return this->gearRatio;
+}
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/SingleEncoderJointPositionMonitor.hpp b/src/wr_control_drive_arm/src/SingleEncoderJointPositionMonitor.hpp
new file mode 100644
index 00000000..e57437b1
--- /dev/null
+++ b/src/wr_control_drive_arm/src/SingleEncoderJointPositionMonitor.hpp
@@ -0,0 +1,44 @@
+#ifndef SINGLE_ENCODER_JOINT_POSITION_MONITOR_H
+#define SINGLE_ENCODER_JOINT_POSITION_MONITOR_H
+
+#include "RoboclawChannel.hpp"
+#include
+#include
+#include
+#include
+#include
+
+struct EncoderConfiguration {
+ int32_t countsPerRotation;
+ int32_t offset;
+};
+
+struct MotorConfiguration {
+ double gearRatio;
+};
+
+class SingleEncoderJointPositionMonitor {
+public:
+ SingleEncoderJointPositionMonitor(const std::string &controllerName, RoboclawChannel channel, EncoderConfiguration eConfig, MotorConfiguration mConfig, ros::NodeHandle node);
+ auto operator()() -> double;
+
+ SingleEncoderJointPositionMonitor(const SingleEncoderJointPositionMonitor &);
+ auto operator=(const SingleEncoderJointPositionMonitor &) -> SingleEncoderJointPositionMonitor & = delete;
+ SingleEncoderJointPositionMonitor(SingleEncoderJointPositionMonitor &&) noexcept;
+ auto operator=(SingleEncoderJointPositionMonitor &&) -> SingleEncoderJointPositionMonitor & = delete;
+ ~SingleEncoderJointPositionMonitor() = default;
+
+ [[nodiscard]] auto getCountsPerRotation() const -> int32_t;
+ [[nodiscard]] auto getGearRatio() const -> double;
+
+private:
+ void onEncoderReceived(const std_msgs::UInt32::ConstPtr &msg);
+
+ std::atomic position;
+ std::shared_ptr encoderSubscriber;
+ const int32_t countsPerRotation;
+ const int32_t offset;
+ const double gearRatio;
+};
+
+#endif
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/src/testDifferential.cpp b/src/wr_control_drive_arm/src/testDifferential.cpp
new file mode 100644
index 00000000..5b2d31a6
--- /dev/null
+++ b/src/wr_control_drive_arm/src/testDifferential.cpp
@@ -0,0 +1,26 @@
+#include
+#include "Motor.hpp"
+#include "DifferentialJointToMotorSpeedConverter.hpp"
+#include "ros/init.h"
+#include
+
+auto main(int32_t argc, char** argv) -> int32_t{
+ ros::init(argc, argv, "testNode");
+
+ ros::NodeHandle n{};
+ using std::literals::string_literals::operator""s;
+
+ const auto wristLeftMotor{std::make_shared("aux2"s, RoboclawChannel::A, n)};
+ const auto wristRightMotor{std::make_shared("aux2"s, RoboclawChannel::B, n)};
+
+ const auto differentialSpeedConverter{std::make_shared(wristLeftMotor, wristRightMotor)};
+
+ ros::Rate loopRate{50};
+ while(ros::ok()){
+ differentialSpeedConverter->setPitchSpeed(0.3);
+ differentialSpeedConverter->setRollSpeed(0);
+ loopRate.sleep();
+ }
+
+ return 0;
+}
\ No newline at end of file
diff --git a/src/wr_control_drive_arm/structure.wsd b/src/wr_control_drive_arm/structure.wsd
new file mode 100755
index 00000000..ef4f1a40
--- /dev/null
+++ b/src/wr_control_drive_arm/structure.wsd
@@ -0,0 +1,99 @@
+@startuml Structure
+enum RoboclawChannel{
+ + A
+ + B
+}
+
+note right of RoboclawChannel::A
+ Analogous to 'LEFT'
+end note
+
+note right of RoboclawChannel::B
+ Analogous to 'RIGHT'
+end note
+
+class Motor{
+ - powerPublisher : ros::Publisher
+
+ + Motor(string controllerName, RoboclawChannel channel)
+ + void setPower(double power)
+ + bool getOverCurrentStatus()
+}
+
+Motor --> RoboclawChannel
+
+class EncoderJointPositionMonitor {
+ - encoderSubscriber : ros::Subscriber
+ - countsPerRotation : const int
+ - offset : const int
+
+ + EncoderJointPositionMonitor(string controllerName, RoboclawChannel channel, int countsPerRotation, int offset)
+ - void encoderCallback(std_msgs::Int32)
+}
+
+EncoderJointPositionMonitor --> RoboclawChannel
+
+class DirectJointToMotorSpeedConverter {
+ + DirectJointToMotorSpeedConverter(Motor motor)
+ + void operator()(double)
+}
+
+DirectJointToMotorSpeedConverter "1" --> "1" Motor
+
+class DifferentialJointToMotorSpeedConverter {
+ + void setPitchSpeed(double)
+ + void setRollSpeed(double)
+}
+
+DifferentialJointToMotorSpeedConverter "1" --> "2" Motor
+
+class Joint{
+ + Joint(String name)
+ + void setTarget(double target)
+ + bool hasReachedTarget()
+ + void stop()
+}
+
+Joint --> EncoderJointPositionMonitor : via function parameter
+<> speedConversion
+Joint --> speedConversion : via function parameter
+speedConversion --> DirectJointToMotorSpeedConverter : as functor
+speedConversion --> DifferentialJointToMotorSpeedConverter::setPitchSpeed : as function pointer
+speedConversion --> DifferentialJointToMotorSpeedConverter::setRollSpeed : as function pointer
+
+@enduml
+
+@startuml seq
+ participant ROS
+ MoveIt -> ActionServer : Sends a motion path
+ loop For each waypoint in the motion
+ loop For each joint in the arm
+ ActionServer -> Joint : Set the next setpoint per joint
+ Joint -> Joint : Start the execution loop
+ end
+ loop While some joint has not reached its setpoint
+ note over ActionServer : Wait
+ ROS -> Joint : Kicks off Timer Event
+ activate Joint
+ Joint -> "PID Loop" : Feed the setpoint
+ Joint -> JointPositionMonitor : Ask for the joint position
+ activate JointPositionMonitor
+ JointPositionMonitor --> Joint : Sends back joint position
+ deactivate JointPositionMonitor
+ Joint -> "PID Loop" : Feed the feedback
+ deactivate Joint
+
+ note left of Joint : Happens asynchonously
+ "PID Loop" -> Joint : New output available
+ activate Joint
+ Joint -> JointToMotorSpeedConverter : Dispatch new speed
+ activate JointToMotorSpeedConverter
+ JointToMotorSpeedConverter -> JointToMotorSpeedConverter : Determine hardware speeds
+ JointToMotorSpeedConverter -> "Motor(s)" : Dispatch hardware speeds
+ deactivate JointToMotorSpeedConverter
+ deactivate Joint
+ end
+ end
+ ActionServer -> MoveIt : Report motion as complete
+
+@enduml
diff --git a/src/wr_entry_point/launch/comp/comp_init.launch b/src/wr_entry_point/launch/comp/comp_init.launch
index ea3bb01d..36f80295 100644
--- a/src/wr_entry_point/launch/comp/comp_init.launch
+++ b/src/wr_entry_point/launch/comp/comp_init.launch
@@ -4,9 +4,9 @@
-
+
-
+