Compare commits
4 Commits
master
...
hongyang_d
Author | SHA1 | Date |
---|---|---|
|
6a455c09c5 | 2 years ago |
|
7e4bf8d123 | 2 years ago |
|
f9d33b4d1a | 2 years ago |
|
a74de4d5b4 | 2 years ago |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,143 @@
|
||||
#ifndef SQLITE_H
|
||||
#define SQLITE_H
|
||||
|
||||
#include <QSqlDatabase>
|
||||
#include <QSqlQuery>
|
||||
#include <QSqlError>
|
||||
#include <QSqlQueryModel>
|
||||
#include <QDebug>
|
||||
#include <vector>
|
||||
#include <string>
|
||||
|
||||
namespace database
|
||||
{
|
||||
|
||||
class sqlite
|
||||
{
|
||||
public:
|
||||
|
||||
sqlite();
|
||||
|
||||
~sqlite();
|
||||
|
||||
QSqlDatabase db;//建立和qt和数据库连接
|
||||
QSqlQueryModel model;//保存和遍历select结果
|
||||
|
||||
int createDB();
|
||||
|
||||
int createMissionTable();
|
||||
|
||||
int createRobortTable();
|
||||
|
||||
int addMission(std::string name, int type);
|
||||
|
||||
std::vector<std::string> queryMissionROBORT(std::string name)
|
||||
{
|
||||
std::vector<std::string> RobortList;
|
||||
QString select_sql = "select name, mission from Robort";
|
||||
QSqlQuery query;
|
||||
if(!query.exec(select_sql))
|
||||
{
|
||||
qDebug()<<query.lastError();
|
||||
}
|
||||
else
|
||||
{
|
||||
while(query.next())
|
||||
{
|
||||
QString NAME = query.value(0).toString();
|
||||
QString MISSION = query.value(1).toString();
|
||||
|
||||
if(name == MISSION.toStdString())
|
||||
{
|
||||
RobortList.push_back(NAME.toStdString());
|
||||
}
|
||||
//qDebug()<<QString("id:%1 name:%2").arg(id).arg(name);
|
||||
}
|
||||
|
||||
qDebug()<<QString("not found name");
|
||||
}
|
||||
return RobortList;
|
||||
}
|
||||
|
||||
int addRobort(std::string name, int type, std::string ip, std::string mission);
|
||||
|
||||
int modifyMission();
|
||||
|
||||
int modifyRobort();
|
||||
|
||||
int deleteMission();
|
||||
|
||||
int deleteRobort(std::string name, int type, std::string ip, std::string mission );
|
||||
|
||||
std::vector<std::string> traverseMission();
|
||||
|
||||
void queryMission(std::string name, int &id, int &type, std::vector<std::string> &robort)
|
||||
{
|
||||
QString select_sql = "select id, name, type from Mission";
|
||||
QSqlQuery query;
|
||||
if(!query.exec(select_sql))
|
||||
{
|
||||
qDebug()<<query.lastError();
|
||||
}
|
||||
else
|
||||
{
|
||||
while(query.next())
|
||||
{
|
||||
int ID = query.value(0).toInt();
|
||||
QString NAME = query.value(1).toString();
|
||||
int TYPE = query.value(2).toInt();
|
||||
|
||||
if(name == NAME.toStdString())
|
||||
{
|
||||
id = ID;
|
||||
type = TYPE;
|
||||
robort = queryMissionROBORT(name);
|
||||
return;
|
||||
}
|
||||
//qDebug()<<QString("id:%1 name:%2").arg(id).arg(name);
|
||||
}
|
||||
qDebug()<<QString("not found id:%1").arg(id);
|
||||
}
|
||||
}
|
||||
|
||||
void queryRobort(std::string name, int &id, int &type, std::string &ip)
|
||||
{
|
||||
QString select_sql = "select id, name, type, ip from Robort";
|
||||
QSqlQuery query;
|
||||
if(!query.exec(select_sql))
|
||||
{
|
||||
qDebug()<<query.lastError();
|
||||
}
|
||||
else
|
||||
{
|
||||
while(query.next())
|
||||
{
|
||||
int ID = query.value(0).toInt();
|
||||
QString NAME = query.value(1).toString();
|
||||
int TYPE = query.value(2).toInt();
|
||||
QString IP = query.value(3).toString();
|
||||
|
||||
if(name == NAME.toStdString())
|
||||
{
|
||||
id = ID;
|
||||
type = TYPE;
|
||||
ip = IP.toStdString();
|
||||
return;
|
||||
}
|
||||
//qDebug()<<QString("id:%1 name:%2").arg(id).arg(name);
|
||||
}
|
||||
qDebug()<<QString("not found id:%1").arg(id);
|
||||
}
|
||||
}
|
||||
|
||||
int test;
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif
|
@ -1 +0,0 @@
|
||||
# This file currently only serves to mark the location of a catkin workspace for tool integration
|
@ -1,23 +0,0 @@
|
||||
{
|
||||
"configurations": [
|
||||
{
|
||||
"browse": {
|
||||
"databaseFilename": "${default}",
|
||||
"limitSymbolsToIncludedHeaders": false
|
||||
},
|
||||
"includePath": [
|
||||
"/home/chinhan/Joint_Rescue_development/devel/include/**",
|
||||
"/opt/ros/kinetic/include/**",
|
||||
"/home/chinhan/Joint_Rescue_development/src/udp_port/include/**",
|
||||
"/home/chinhan/Joint_Rescue_development/src/unitree_ros_to_real-3.2.1/unitree_legged_real/include/**",
|
||||
"/usr/include/**"
|
||||
],
|
||||
"name": "ROS",
|
||||
"intelliSenseMode": "gcc-x64",
|
||||
"compilerPath": "/usr/bin/gcc",
|
||||
"cStandard": "gnu11",
|
||||
"cppStandard": "c++14"
|
||||
}
|
||||
],
|
||||
"version": 4
|
||||
}
|
@ -1,88 +0,0 @@
|
||||
{
|
||||
"python.autoComplete.extraPaths": [
|
||||
"/home/chinhan/Joint_Rescue_development/devel/lib/python2.7/dist-packages",
|
||||
"/opt/ros/kinetic/lib/python2.7/dist-packages"
|
||||
],
|
||||
"python.analysis.extraPaths": [
|
||||
"/home/chinhan/Joint_Rescue_development/devel/lib/python2.7/dist-packages",
|
||||
"/opt/ros/kinetic/lib/python2.7/dist-packages"
|
||||
],
|
||||
"files.associations": {
|
||||
"cctype": "cpp",
|
||||
"clocale": "cpp",
|
||||
"cmath": "cpp",
|
||||
"csignal": "cpp",
|
||||
"cstdarg": "cpp",
|
||||
"cstddef": "cpp",
|
||||
"cstdio": "cpp",
|
||||
"cstdlib": "cpp",
|
||||
"cstring": "cpp",
|
||||
"ctime": "cpp",
|
||||
"cwchar": "cpp",
|
||||
"cwctype": "cpp",
|
||||
"array": "cpp",
|
||||
"atomic": "cpp",
|
||||
"strstream": "cpp",
|
||||
"*.tcc": "cpp",
|
||||
"bitset": "cpp",
|
||||
"chrono": "cpp",
|
||||
"codecvt": "cpp",
|
||||
"complex": "cpp",
|
||||
"cstdint": "cpp",
|
||||
"deque": "cpp",
|
||||
"forward_list": "cpp",
|
||||
"list": "cpp",
|
||||
"unordered_map": "cpp",
|
||||
"unordered_set": "cpp",
|
||||
"vector": "cpp",
|
||||
"exception": "cpp",
|
||||
"algorithm": "cpp",
|
||||
"any": "cpp",
|
||||
"filesystem": "cpp",
|
||||
"functional": "cpp",
|
||||
"optional": "cpp",
|
||||
"ratio": "cpp",
|
||||
"string_view": "cpp",
|
||||
"system_error": "cpp",
|
||||
"tuple": "cpp",
|
||||
"type_traits": "cpp",
|
||||
"hash_map": "cpp",
|
||||
"hash_set": "cpp",
|
||||
"fstream": "cpp",
|
||||
"initializer_list": "cpp",
|
||||
"iomanip": "cpp",
|
||||
"iosfwd": "cpp",
|
||||
"iostream": "cpp",
|
||||
"istream": "cpp",
|
||||
"limits": "cpp",
|
||||
"memory": "cpp",
|
||||
"new": "cpp",
|
||||
"ostream": "cpp",
|
||||
"numeric": "cpp",
|
||||
"sstream": "cpp",
|
||||
"stdexcept": "cpp",
|
||||
"streambuf": "cpp",
|
||||
"thread": "cpp",
|
||||
"cfenv": "cpp",
|
||||
"cinttypes": "cpp",
|
||||
"utility": "cpp",
|
||||
"typeindex": "cpp",
|
||||
"typeinfo": "cpp",
|
||||
"valarray": "cpp",
|
||||
"bit": "cpp",
|
||||
"map": "cpp",
|
||||
"set": "cpp",
|
||||
"iterator": "cpp",
|
||||
"memory_resource": "cpp",
|
||||
"random": "cpp",
|
||||
"string": "cpp",
|
||||
"qpushbutton": "cpp",
|
||||
"qvariant": "cpp",
|
||||
"qlineedit": "cpp",
|
||||
"qlabel": "cpp",
|
||||
"qapplication": "cpp",
|
||||
"qtabwidget": "cpp",
|
||||
"qdebug": "cpp",
|
||||
"qcombobox": "cpp"
|
||||
}
|
||||
}
|
Binary file not shown.
@ -1,8 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<Workspace>
|
||||
<Distribution name="kinetic"/>
|
||||
<DefaultBuildSystem value="0"/>
|
||||
<WatchDirectories>
|
||||
<Directory>src</Directory>
|
||||
</WatchDirectories>
|
||||
</Workspace>
|
@ -1,527 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE QtCreatorProject>
|
||||
<!-- Written by QtCreator 4.5.1, 2023-06-27T19:57:13. -->
|
||||
<qtcreator>
|
||||
<data>
|
||||
<variable>EnvironmentId</variable>
|
||||
<value type="QByteArray">{bdc6160a-3a85-46c4-999c-e5232f05a4e6}</value>
|
||||
</data>
|
||||
<data>
|
||||
<variable>ProjectExplorer.Project.ActiveTarget</variable>
|
||||
<value type="int">0</value>
|
||||
</data>
|
||||
<data>
|
||||
<variable>ProjectExplorer.Project.EditorSettings</variable>
|
||||
<valuemap type="QVariantMap">
|
||||
<value type="bool" key="EditorConfiguration.AutoIndent">true</value>
|
||||
<value type="bool" key="EditorConfiguration.AutoSpacesForTabs">false</value>
|
||||
<value type="bool" key="EditorConfiguration.CamelCaseNavigation">true</value>
|
||||
<valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.0">
|
||||
<value type="QString" key="language">Cpp</value>
|
||||
<valuemap type="QVariantMap" key="value">
|
||||
<value type="QByteArray" key="CurrentPreferences">ROSProject.CppCodeStyle</value>
|
||||
</valuemap>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.1">
|
||||
<value type="QString" key="language">QmlJS</value>
|
||||
<valuemap type="QVariantMap" key="value">
|
||||
<value type="QByteArray" key="CurrentPreferences">QmlJSGlobal</value>
|
||||
</valuemap>
|
||||
</valuemap>
|
||||
<value type="int" key="EditorConfiguration.CodeStyle.Count">2</value>
|
||||
<value type="QByteArray" key="EditorConfiguration.Codec">UTF-8</value>
|
||||
<value type="bool" key="EditorConfiguration.ConstrainTooltips">false</value>
|
||||
<value type="int" key="EditorConfiguration.IndentSize">4</value>
|
||||
<value type="bool" key="EditorConfiguration.KeyboardTooltips">false</value>
|
||||
<value type="int" key="EditorConfiguration.MarginColumn">80</value>
|
||||
<value type="bool" key="EditorConfiguration.MouseHiding">true</value>
|
||||
<value type="bool" key="EditorConfiguration.MouseNavigation">true</value>
|
||||
<value type="int" key="EditorConfiguration.PaddingMode">1</value>
|
||||
<value type="bool" key="EditorConfiguration.ScrollWheelZooming">true</value>
|
||||
<value type="bool" key="EditorConfiguration.ShowMargin">false</value>
|
||||
<value type="int" key="EditorConfiguration.SmartBackspaceBehavior">0</value>
|
||||
<value type="bool" key="EditorConfiguration.SmartSelectionChanging">true</value>
|
||||
<value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
|
||||
<value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
|
||||
<value type="int" key="EditorConfiguration.TabSize">8</value>
|
||||
<value type="bool" key="EditorConfiguration.UseGlobal">true</value>
|
||||
<value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
|
||||
<value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
|
||||
<value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
|
||||
<value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
|
||||
<value type="bool" key="EditorConfiguration.inEntireDocument">false</value>
|
||||
</valuemap>
|
||||
</data>
|
||||
<data>
|
||||
<variable>ProjectExplorer.Project.PluginSettings</variable>
|
||||
<valuemap type="QVariantMap"/>
|
||||
</data>
|
||||
<data>
|
||||
<variable>ProjectExplorer.Project.Target.0</variable>
|
||||
<valuemap type="QVariantMap">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">桌面</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">桌面</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">{a4f990a9-c569-46c6-89f2-8c30821eb9e4}</value>
|
||||
<value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">1</value>
|
||||
<value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
|
||||
<value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
|
||||
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory"></value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">0</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">构建</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">1</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">清理</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
|
||||
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
|
||||
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges">
|
||||
<value type="QString">CMAKE_PREFIX_PATH=/home/chinhan/Joint_Rescue_development/devel:/opt/ros/kinetic</value>
|
||||
<value type="QString">LD_LIBRARY_PATH=/home/chinhan/Joint_Rescue_development/devel/lib:/opt/ros/kinetic/lib:/opt/ros/kinetic/lib/x86_64-linux-gnu</value>
|
||||
<value type="QString">PATH=/opt/ros/kinetic/bin:/home/chinhan/bin:/home/chinhan/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin</value>
|
||||
<value type="QString">PKG_CONFIG_PATH=/home/chinhan/Joint_Rescue_development/devel/lib/pkgconfig:/opt/ros/kinetic/lib/pkgconfig:/opt/ros/kinetic/lib/x86_64-linux-gnu/pkgconfig</value>
|
||||
<value type="QString">PWD=/home/chinhan/Joint_Rescue_development</value>
|
||||
<value type="QString">PYTHONPATH=/home/chinhan/Joint_Rescue_development/devel/lib/python2.7/dist-packages:/opt/ros/kinetic/lib/python2.7/dist-packages</value>
|
||||
<value type="QString">QTDIR</value>
|
||||
<value type="QString">ROSLISP_PACKAGE_DIRECTORIES=/home/chinhan/Joint_Rescue_development/devel/share/common-lisp</value>
|
||||
<value type="QString">ROS_DISTRO=kinetic</value>
|
||||
<value type="QString">ROS_ETC_DIR=/opt/ros/kinetic/etc/ros</value>
|
||||
<value type="QString">ROS_MASTER_URI=http://localhost:11311</value>
|
||||
<value type="QString">ROS_PACKAGE_PATH=/home/chinhan/Joint_Rescue_development/src:/opt/ros/kinetic/share</value>
|
||||
<value type="QString">ROS_PYTHON_VERSION=2</value>
|
||||
<value type="QString">ROS_ROOT=/opt/ros/kinetic/share/ros</value>
|
||||
<value type="QString">ROS_VERSION=1</value>
|
||||
<value type="QString">SHLVL=2</value>
|
||||
<value type="QString">TERM=xterm</value>
|
||||
<value type="QString">_=/usr/bin/env</value>
|
||||
</valuelist>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Debug</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Debug</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSBuildConfiguration</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.BuildSystem">0</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.CMakeBuildType">0</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
|
||||
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory"></value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">0</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">构建</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">1</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">清理</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
|
||||
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
|
||||
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges">
|
||||
<value type="QString">CMAKE_PREFIX_PATH=/home/chinhan/Joint_Rescue_development/devel:/opt/ros/kinetic</value>
|
||||
<value type="QString">LD_LIBRARY_PATH=/home/chinhan/Joint_Rescue_development/devel/lib:/opt/ros/kinetic/lib:/opt/ros/kinetic/lib/x86_64-linux-gnu</value>
|
||||
<value type="QString">PATH=/opt/ros/kinetic/bin:/home/chinhan/bin:/home/chinhan/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin</value>
|
||||
<value type="QString">PKG_CONFIG_PATH=/home/chinhan/Joint_Rescue_development/devel/lib/pkgconfig:/opt/ros/kinetic/lib/pkgconfig:/opt/ros/kinetic/lib/x86_64-linux-gnu/pkgconfig</value>
|
||||
<value type="QString">PWD=/home/chinhan/Joint_Rescue_development</value>
|
||||
<value type="QString">PYTHONPATH=/home/chinhan/Joint_Rescue_development/devel/lib/python2.7/dist-packages:/opt/ros/kinetic/lib/python2.7/dist-packages</value>
|
||||
<value type="QString">QTDIR</value>
|
||||
<value type="QString">ROSLISP_PACKAGE_DIRECTORIES=/home/chinhan/Joint_Rescue_development/devel/share/common-lisp</value>
|
||||
<value type="QString">ROS_DISTRO=kinetic</value>
|
||||
<value type="QString">ROS_ETC_DIR=/opt/ros/kinetic/etc/ros</value>
|
||||
<value type="QString">ROS_MASTER_URI=http://localhost:11311</value>
|
||||
<value type="QString">ROS_PACKAGE_PATH=/home/chinhan/Joint_Rescue_development/src:/opt/ros/kinetic/share</value>
|
||||
<value type="QString">ROS_PYTHON_VERSION=2</value>
|
||||
<value type="QString">ROS_ROOT=/opt/ros/kinetic/share/ros</value>
|
||||
<value type="QString">ROS_VERSION=1</value>
|
||||
<value type="QString">SHLVL=2</value>
|
||||
<value type="QString">TERM=xterm</value>
|
||||
<value type="QString">_=/usr/bin/env</value>
|
||||
</valuelist>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Release</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Release</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSBuildConfiguration</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.BuildSystem">0</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.CMakeBuildType">1</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
|
||||
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory"></value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">0</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">构建</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">1</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">清理</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
|
||||
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
|
||||
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Release with Debug Information</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Release with Debug Information</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSBuildConfiguration</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.BuildSystem">0</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.CMakeBuildType">2</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.3">
|
||||
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory"></value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">0</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">构建</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">1</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">清理</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
|
||||
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
|
||||
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Minimum Size Release</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Minimum Size Release</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSBuildConfiguration</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.BuildSystem">0</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.CMakeBuildType">3</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.4">
|
||||
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory"></value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">0</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">构建</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
||||
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">CatkinMake Step</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSCatkinMakeStep</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.CatkinMakeArguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSCatkinMakeStep.MakeArguments"></value>
|
||||
<value type="int" key="ROSProjectManager.ROSCatkinMakeStep.Target">1</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">清理</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
|
||||
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
|
||||
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">User Defined</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">User Defined</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSBuildConfiguration</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.BuildSystem">0</value>
|
||||
<value type="int" key="ROSProjectManager.ROSBuildConfiguration.CMakeBuildType">4</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">5</value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
|
||||
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">0</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">部署</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">在本地部署</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.DefaultDeployConfiguration</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
|
||||
<value type="bool" key="Analyzer.QmlProfiler.AggregateTraces">false</value>
|
||||
<value type="bool" key="Analyzer.QmlProfiler.FlushEnabled">false</value>
|
||||
<value type="uint" key="Analyzer.QmlProfiler.FlushInterval">1000</value>
|
||||
<value type="QString" key="Analyzer.QmlProfiler.LastTraceFile"></value>
|
||||
<value type="bool" key="Analyzer.QmlProfiler.Settings.UseGlobalSettings">true</value>
|
||||
<valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
|
||||
<value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
|
||||
<value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
|
||||
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
|
||||
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
|
||||
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
|
||||
<value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
|
||||
<value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
|
||||
<value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
|
||||
<value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
|
||||
<value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
|
||||
<valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
|
||||
<value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
|
||||
<value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
|
||||
<value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
|
||||
<value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
|
||||
<value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
|
||||
<valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
|
||||
<value type="int">0</value>
|
||||
<value type="int">1</value>
|
||||
<value type="int">2</value>
|
||||
<value type="int">3</value>
|
||||
<value type="int">4</value>
|
||||
<value type="int">5</value>
|
||||
<value type="int">6</value>
|
||||
<value type="int">7</value>
|
||||
<value type="int">8</value>
|
||||
<value type="int">9</value>
|
||||
<value type="int">10</value>
|
||||
<value type="int">11</value>
|
||||
<value type="int">12</value>
|
||||
<value type="int">13</value>
|
||||
<value type="int">14</value>
|
||||
</valuelist>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">ROS Run Configuration</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunConfiguration</value>
|
||||
<valuemap type="QVariantMap" key="ROSProjectManager.ROSRunConfiguration.RunStepList">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Run</value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunConfiguration.RunStepList</value>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.0">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSLaunchStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">roslaunch</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">unitree_legged_real</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">real.launch</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/home/chinhan/Joint_Rescue_development/src/app_dep/unitree_ros_to_real-3.2.1/unitree_legged_real/launch/real.launch</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.1">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">unitree_legged_real</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">direct_control</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/home/chinhan/Joint_Rescue_development/devel/lib/unitree_legged_real/direct_control</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.2">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">librviz_tutorial</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">myviz</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/home/chinhan/Joint_Rescue_development/devel/lib/librviz_tutorial/myviz</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.3">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">true</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">qt_app</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">qt_app_node</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/home/chinhan/Joint_Rescue_development/devel/lib/qt_app/qt_app_node</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.4">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">rqt_graph</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">rqt_graph</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/opt/ros/kinetic/lib/rqt_graph/rqt_graph</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.5">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">qt_app_ros</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">direct_control_send_node</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/home/chinhan/Joint_Rescue_development/devel/lib/qt_app_ros/direct_control_send_node</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.6">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">qt_app_ros</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">mappublish</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/home/chinhan/Joint_Rescue_development/devel/lib/qt_app_ros/mappublish</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.7">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">qt_app_ros</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath"></value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.8">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">qt_app_ros</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">tcp_port_send_node</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/home/chinhan/Joint_Rescue_development/devel/lib/qt_app_ros/tcp_port_send_node</value>
|
||||
</valuemap>
|
||||
<valuemap type="QVariantMap" key="ProjectExplorer.RunStepList.Step.9">
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
||||
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ROSProjectManager.ROSRunStep</value>
|
||||
<value type="bool" key="ProjectExplorer.RunStep.Enabled">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Arguments"></value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Command">rosrun</value>
|
||||
<value type="bool" key="ROSProjectManager.ROSGenericStep.DebugContinueOnAttach">false</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Package">qt_app_ros</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.Target">tcp_port_receive_node</value>
|
||||
<value type="QString" key="ROSProjectManager.ROSGenericStep.TargetPath">/home/chinhan/Joint_Rescue_development/devel/lib/qt_app_ros/tcp_port_receive_node</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.RunStepList.StepsCount">10</value>
|
||||
</valuemap>
|
||||
<value type="uint" key="RunConfiguration.QmlDebugServerPort">3768</value>
|
||||
<value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
|
||||
<value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
|
||||
<value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
|
||||
<value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
|
||||
<value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
|
||||
</valuemap>
|
||||
<value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
|
||||
</valuemap>
|
||||
</data>
|
||||
<data>
|
||||
<variable>ProjectExplorer.Project.TargetCount</variable>
|
||||
<value type="int">1</value>
|
||||
</data>
|
||||
<data>
|
||||
<variable>ProjectExplorer.Project.Updater.FileVersion</variable>
|
||||
<value type="int">18</value>
|
||||
</data>
|
||||
<data>
|
||||
<variable>Version</variable>
|
||||
<value type="int">18</value>
|
||||
</data>
|
||||
</qtcreator>
|
@ -1 +0,0 @@
|
||||
catkin_make
|
@ -1 +0,0 @@
|
||||
/home/chinhan/Joint_Rescue_development/src
|
@ -1,2 +0,0 @@
|
||||
- setup-file:
|
||||
local-name: /home/chinhan/Joint_Rescue_development/devel/setup.sh
|
@ -1,304 +0,0 @@
|
||||
#!/usr/bin/python2
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Software License Agreement (BSD License)
|
||||
#
|
||||
# Copyright (c) 2012, Willow Garage, Inc.
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above
|
||||
# copyright notice, this list of conditions and the following
|
||||
# disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of Willow Garage, Inc. nor the names of its
|
||||
# contributors may be used to endorse or promote products derived
|
||||
# from this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
|
||||
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
"""This file generates shell code for the setup.SHELL scripts to set environment variables."""
|
||||
|
||||
from __future__ import print_function
|
||||
|
||||
import argparse
|
||||
import copy
|
||||
import errno
|
||||
import os
|
||||
import platform
|
||||
import sys
|
||||
|
||||
CATKIN_MARKER_FILE = '.catkin'
|
||||
|
||||
system = platform.system()
|
||||
IS_DARWIN = (system == 'Darwin')
|
||||
IS_WINDOWS = (system == 'Windows')
|
||||
|
||||
PATH_TO_ADD_SUFFIX = ['bin']
|
||||
if IS_WINDOWS:
|
||||
# while catkin recommends putting dll's into bin, 3rd party packages often put dll's into lib
|
||||
# since Windows finds dll's via the PATH variable, prepend it with path to lib
|
||||
PATH_TO_ADD_SUFFIX.extend([['lib', os.path.join('lib', 'x86_64-linux-gnu')]])
|
||||
|
||||
# subfolder of workspace prepended to CMAKE_PREFIX_PATH
|
||||
ENV_VAR_SUBFOLDERS = {
|
||||
'CMAKE_PREFIX_PATH': '',
|
||||
'LD_LIBRARY_PATH' if not IS_DARWIN else 'DYLD_LIBRARY_PATH': ['lib', os.path.join('lib', 'x86_64-linux-gnu')],
|
||||
'PATH': PATH_TO_ADD_SUFFIX,
|
||||
'PKG_CONFIG_PATH': [os.path.join('lib', 'pkgconfig'), os.path.join('lib', 'x86_64-linux-gnu', 'pkgconfig')],
|
||||
'PYTHONPATH': 'lib/python2.7/dist-packages',
|
||||
}
|
||||
|
||||
|
||||
def rollback_env_variables(environ, env_var_subfolders):
|
||||
"""
|
||||
Generate shell code to reset environment variables.
|
||||
|
||||
by unrolling modifications based on all workspaces in CMAKE_PREFIX_PATH.
|
||||
This does not cover modifications performed by environment hooks.
|
||||
"""
|
||||
lines = []
|
||||
unmodified_environ = copy.copy(environ)
|
||||
for key in sorted(env_var_subfolders.keys()):
|
||||
subfolders = env_var_subfolders[key]
|
||||
if not isinstance(subfolders, list):
|
||||
subfolders = [subfolders]
|
||||
value = _rollback_env_variable(unmodified_environ, key, subfolders)
|
||||
if value is not None:
|
||||
environ[key] = value
|
||||
lines.append(assignment(key, value))
|
||||
if lines:
|
||||
lines.insert(0, comment('reset environment variables by unrolling modifications based on all workspaces in CMAKE_PREFIX_PATH'))
|
||||
return lines
|
||||
|
||||
|
||||
def _rollback_env_variable(environ, name, subfolders):
|
||||
"""
|
||||
For each catkin workspace in CMAKE_PREFIX_PATH remove the first entry from env[NAME] matching workspace + subfolder.
|
||||
|
||||
:param subfolders: list of str '' or subfoldername that may start with '/'
|
||||
:returns: the updated value of the environment variable.
|
||||
"""
|
||||
value = environ[name] if name in environ else ''
|
||||
env_paths = [path for path in value.split(os.pathsep) if path]
|
||||
value_modified = False
|
||||
for subfolder in subfolders:
|
||||
if subfolder:
|
||||
if subfolder.startswith(os.path.sep) or (os.path.altsep and subfolder.startswith(os.path.altsep)):
|
||||
subfolder = subfolder[1:]
|
||||
if subfolder.endswith(os.path.sep) or (os.path.altsep and subfolder.endswith(os.path.altsep)):
|
||||
subfolder = subfolder[:-1]
|
||||
for ws_path in _get_workspaces(environ, include_fuerte=True, include_non_existing=True):
|
||||
path_to_find = os.path.join(ws_path, subfolder) if subfolder else ws_path
|
||||
path_to_remove = None
|
||||
for env_path in env_paths:
|
||||
env_path_clean = env_path[:-1] if env_path and env_path[-1] in [os.path.sep, os.path.altsep] else env_path
|
||||
if env_path_clean == path_to_find:
|
||||
path_to_remove = env_path
|
||||
break
|
||||
if path_to_remove:
|
||||
env_paths.remove(path_to_remove)
|
||||
value_modified = True
|
||||
new_value = os.pathsep.join(env_paths)
|
||||
return new_value if value_modified else None
|
||||
|
||||
|
||||
def _get_workspaces(environ, include_fuerte=False, include_non_existing=False):
|
||||
"""
|
||||
Based on CMAKE_PREFIX_PATH return all catkin workspaces.
|
||||
|
||||
:param include_fuerte: The flag if paths starting with '/opt/ros/fuerte' should be considered workspaces, ``bool``
|
||||
"""
|
||||
# get all cmake prefix paths
|
||||
env_name = 'CMAKE_PREFIX_PATH'
|
||||
value = environ[env_name] if env_name in environ else ''
|
||||
paths = [path for path in value.split(os.pathsep) if path]
|
||||
# remove non-workspace paths
|
||||
workspaces = [path for path in paths if os.path.isfile(os.path.join(path, CATKIN_MARKER_FILE)) or (include_fuerte and path.startswith('/opt/ros/fuerte')) or (include_non_existing and not os.path.exists(path))]
|
||||
return workspaces
|
||||
|
||||
|
||||
def prepend_env_variables(environ, env_var_subfolders, workspaces):
|
||||
"""Generate shell code to prepend environment variables for the all workspaces."""
|
||||
lines = []
|
||||
lines.append(comment('prepend folders of workspaces to environment variables'))
|
||||
|
||||
paths = [path for path in workspaces.split(os.pathsep) if path]
|
||||
|
||||
prefix = _prefix_env_variable(environ, 'CMAKE_PREFIX_PATH', paths, '')
|
||||
lines.append(prepend(environ, 'CMAKE_PREFIX_PATH', prefix))
|
||||
|
||||
for key in sorted(key for key in env_var_subfolders.keys() if key != 'CMAKE_PREFIX_PATH'):
|
||||
subfolder = env_var_subfolders[key]
|
||||
prefix = _prefix_env_variable(environ, key, paths, subfolder)
|
||||
lines.append(prepend(environ, key, prefix))
|
||||
return lines
|
||||
|
||||
|
||||
def _prefix_env_variable(environ, name, paths, subfolders):
|
||||
"""
|
||||
Return the prefix to prepend to the environment variable NAME.
|
||||
|
||||
Adding any path in NEW_PATHS_STR without creating duplicate or empty items.
|
||||
"""
|
||||
value = environ[name] if name in environ else ''
|
||||
environ_paths = [path for path in value.split(os.pathsep) if path]
|
||||
checked_paths = []
|
||||
for path in paths:
|
||||
if not isinstance(subfolders, list):
|
||||
subfolders = [subfolders]
|
||||
for subfolder in subfolders:
|
||||
path_tmp = path
|
||||
if subfolder:
|
||||
path_tmp = os.path.join(path_tmp, subfolder)
|
||||
# skip nonexistent paths
|
||||
if not os.path.exists(path_tmp):
|
||||
continue
|
||||
# exclude any path already in env and any path we already added
|
||||
if path_tmp not in environ_paths and path_tmp not in checked_paths:
|
||||
checked_paths.append(path_tmp)
|
||||
prefix_str = os.pathsep.join(checked_paths)
|
||||
if prefix_str != '' and environ_paths:
|
||||
prefix_str += os.pathsep
|
||||
return prefix_str
|
||||
|
||||
|
||||
def assignment(key, value):
|
||||
if not IS_WINDOWS:
|
||||
return 'export %s="%s"' % (key, value)
|
||||
else:
|
||||
return 'set %s=%s' % (key, value)
|
||||
|
||||
|
||||
def comment(msg):
|
||||
if not IS_WINDOWS:
|
||||
return '# %s' % msg
|
||||
else:
|
||||
return 'REM %s' % msg
|
||||
|
||||
|
||||
def prepend(environ, key, prefix):
|
||||
if key not in environ or not environ[key]:
|
||||
return assignment(key, prefix)
|
||||
if not IS_WINDOWS:
|
||||
return 'export %s="%s$%s"' % (key, prefix, key)
|
||||
else:
|
||||
return 'set %s=%s%%%s%%' % (key, prefix, key)
|
||||
|
||||
|
||||
def find_env_hooks(environ, cmake_prefix_path):
|
||||
"""Generate shell code with found environment hooks for the all workspaces."""
|
||||
lines = []
|
||||
lines.append(comment('found environment hooks in workspaces'))
|
||||
|
||||
generic_env_hooks = []
|
||||
generic_env_hooks_workspace = []
|
||||
specific_env_hooks = []
|
||||
specific_env_hooks_workspace = []
|
||||
generic_env_hooks_by_filename = {}
|
||||
specific_env_hooks_by_filename = {}
|
||||
generic_env_hook_ext = 'bat' if IS_WINDOWS else 'sh'
|
||||
specific_env_hook_ext = environ['CATKIN_SHELL'] if not IS_WINDOWS and 'CATKIN_SHELL' in environ and environ['CATKIN_SHELL'] else None
|
||||
# remove non-workspace paths
|
||||
workspaces = [path for path in cmake_prefix_path.split(os.pathsep) if path and os.path.isfile(os.path.join(path, CATKIN_MARKER_FILE))]
|
||||
for workspace in reversed(workspaces):
|
||||
env_hook_dir = os.path.join(workspace, 'etc', 'catkin', 'profile.d')
|
||||
if os.path.isdir(env_hook_dir):
|
||||
for filename in sorted(os.listdir(env_hook_dir)):
|
||||
if filename.endswith('.%s' % generic_env_hook_ext):
|
||||
# remove previous env hook with same name if present
|
||||
if filename in generic_env_hooks_by_filename:
|
||||
i = generic_env_hooks.index(generic_env_hooks_by_filename[filename])
|
||||
generic_env_hooks.pop(i)
|
||||
generic_env_hooks_workspace.pop(i)
|
||||
# append env hook
|
||||
generic_env_hooks.append(os.path.join(env_hook_dir, filename))
|
||||
generic_env_hooks_workspace.append(workspace)
|
||||
generic_env_hooks_by_filename[filename] = generic_env_hooks[-1]
|
||||
elif specific_env_hook_ext is not None and filename.endswith('.%s' % specific_env_hook_ext):
|
||||
# remove previous env hook with same name if present
|
||||
if filename in specific_env_hooks_by_filename:
|
||||
i = specific_env_hooks.index(specific_env_hooks_by_filename[filename])
|
||||
specific_env_hooks.pop(i)
|
||||
specific_env_hooks_workspace.pop(i)
|
||||
# append env hook
|
||||
specific_env_hooks.append(os.path.join(env_hook_dir, filename))
|
||||
specific_env_hooks_workspace.append(workspace)
|
||||
specific_env_hooks_by_filename[filename] = specific_env_hooks[-1]
|
||||
env_hooks = generic_env_hooks + specific_env_hooks
|
||||
env_hooks_workspace = generic_env_hooks_workspace + specific_env_hooks_workspace
|
||||
count = len(env_hooks)
|
||||
lines.append(assignment('_CATKIN_ENVIRONMENT_HOOKS_COUNT', count))
|
||||
for i in range(count):
|
||||
lines.append(assignment('_CATKIN_ENVIRONMENT_HOOKS_%d' % i, env_hooks[i]))
|
||||
lines.append(assignment('_CATKIN_ENVIRONMENT_HOOKS_%d_WORKSPACE' % i, env_hooks_workspace[i]))
|
||||
return lines
|
||||
|
||||
|
||||
def _parse_arguments(args=None):
|
||||
parser = argparse.ArgumentParser(description='Generates code blocks for the setup.SHELL script.')
|
||||
parser.add_argument('--extend', action='store_true', help='Skip unsetting previous environment variables to extend context')
|
||||
parser.add_argument('--local', action='store_true', help='Only consider this prefix path and ignore other prefix path in the environment')
|
||||
return parser.parse_known_args(args=args)[0]
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
try:
|
||||
try:
|
||||
args = _parse_arguments()
|
||||
except Exception as e:
|
||||
print(e, file=sys.stderr)
|
||||
sys.exit(1)
|
||||
|
||||
if not args.local:
|
||||
# environment at generation time
|
||||
CMAKE_PREFIX_PATH = r'/home/chinhan/Joint_Rescue_development/devel;/opt/ros/kinetic'.split(';')
|
||||
else:
|
||||
# don't consider any other prefix path than this one
|
||||
CMAKE_PREFIX_PATH = []
|
||||
# prepend current workspace if not already part of CPP
|
||||
base_path = os.path.dirname(__file__)
|
||||
# CMAKE_PREFIX_PATH uses forward slash on all platforms, but __file__ is platform dependent
|
||||
# base_path on Windows contains backward slashes, need to be converted to forward slashes before comparison
|
||||
if os.path.sep != '/':
|
||||
base_path = base_path.replace(os.path.sep, '/')
|
||||
|
||||
if base_path not in CMAKE_PREFIX_PATH:
|
||||
CMAKE_PREFIX_PATH.insert(0, base_path)
|
||||
CMAKE_PREFIX_PATH = os.pathsep.join(CMAKE_PREFIX_PATH)
|
||||
|
||||
environ = dict(os.environ)
|
||||
lines = []
|
||||
if not args.extend:
|
||||
lines += rollback_env_variables(environ, ENV_VAR_SUBFOLDERS)
|
||||
lines += prepend_env_variables(environ, ENV_VAR_SUBFOLDERS, CMAKE_PREFIX_PATH)
|
||||
lines += find_env_hooks(environ, CMAKE_PREFIX_PATH)
|
||||
print('\n'.join(lines))
|
||||
|
||||
# need to explicitly flush the output
|
||||
sys.stdout.flush()
|
||||
except IOError as e:
|
||||
# and catch potential "broken pipe" if stdout is not writable
|
||||
# which can happen when piping the output to a file but the disk is full
|
||||
if e.errno == errno.EPIPE:
|
||||
print(e, file=sys.stderr)
|
||||
sys.exit(2)
|
||||
raise
|
||||
|
||||
sys.exit(0)
|
@ -1,16 +0,0 @@
|
||||
#!/usr/bin/env sh
|
||||
# generated from catkin/cmake/templates/env.sh.in
|
||||
|
||||
if [ $# -eq 0 ] ; then
|
||||
/bin/echo "Usage: env.sh COMMANDS"
|
||||
/bin/echo "Calling env.sh without arguments is not supported anymore. Instead spawn a subshell and source a setup file manually."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# ensure to not use different shell type which was set before
|
||||
CATKIN_SHELL=sh
|
||||
|
||||
# source setup.sh from same directory as this file
|
||||
_CATKIN_SETUP_DIR=$(cd "`dirname "$0"`" > /dev/null && pwd)
|
||||
. "$_CATKIN_SETUP_DIR/setup.sh"
|
||||
exec "$@"
|
@ -1,205 +0,0 @@
|
||||
// Generated by gencpp from file unitree_legged_msgs/Cartesian.msg
|
||||
// DO NOT EDIT!
|
||||
|
||||
|
||||
#ifndef UNITREE_LEGGED_MSGS_MESSAGE_CARTESIAN_H
|
||||
#define UNITREE_LEGGED_MSGS_MESSAGE_CARTESIAN_H
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
#include <ros/types.h>
|
||||
#include <ros/serialization.h>
|
||||
#include <ros/builtin_message_traits.h>
|
||||
#include <ros/message_operations.h>
|
||||
|
||||
|
||||
namespace unitree_legged_msgs
|
||||
{
|
||||
template <class ContainerAllocator>
|
||||
struct Cartesian_
|
||||
{
|
||||
typedef Cartesian_<ContainerAllocator> Type;
|
||||
|
||||
Cartesian_()
|
||||
: x(0.0)
|
||||
, y(0.0)
|
||||
, z(0.0) {
|
||||
}
|
||||
Cartesian_(const ContainerAllocator& _alloc)
|
||||
: x(0.0)
|
||||
, y(0.0)
|
||||
, z(0.0) {
|
||||
(void)_alloc;
|
||||
}
|
||||
|
||||
|
||||
|
||||
typedef float _x_type;
|
||||
_x_type x;
|
||||
|
||||
typedef float _y_type;
|
||||
_y_type y;
|
||||
|
||||
typedef float _z_type;
|
||||
_z_type z;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> > Ptr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> const> ConstPtr;
|
||||
|
||||
}; // struct Cartesian_
|
||||
|
||||
typedef ::unitree_legged_msgs::Cartesian_<std::allocator<void> > Cartesian;
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::Cartesian > CartesianPtr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::Cartesian const> CartesianConstPtr;
|
||||
|
||||
// constants requiring out of line definition
|
||||
|
||||
|
||||
|
||||
template<typename ContainerAllocator>
|
||||
std::ostream& operator<<(std::ostream& s, const ::unitree_legged_msgs::Cartesian_<ContainerAllocator> & v)
|
||||
{
|
||||
ros::message_operations::Printer< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >::stream(s, "", v);
|
||||
return s;
|
||||
}
|
||||
|
||||
} // namespace unitree_legged_msgs
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_traits
|
||||
{
|
||||
|
||||
|
||||
|
||||
// BOOLTRAITS {'IsFixedSize': True, 'IsMessage': True, 'HasHeader': False}
|
||||
// {'sensor_msgs': ['/opt/ros/kinetic/share/sensor_msgs/cmake/../msg'], 'geometry_msgs': ['/opt/ros/kinetic/share/geometry_msgs/cmake/../msg'], 'std_msgs': ['/opt/ros/kinetic/share/std_msgs/cmake/../msg'], 'unitree_legged_msgs': ['/home/chinhan/Joint_Rescue_development/src/unitree_ros_to_real-3.2.1/unitree_legged_msgs/msg']}
|
||||
|
||||
// !!!!!!!!!!! ['__class__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__getattribute__', '__hash__', '__init__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_parsed_fields', 'constants', 'fields', 'full_name', 'has_header', 'header_present', 'names', 'package', 'parsed_fields', 'short_name', 'text', 'types']
|
||||
|
||||
|
||||
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> const>
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct MD5Sum< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "cc153912f1453b708d221682bc23d9ac";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::Cartesian_<ContainerAllocator>&) { return value(); }
|
||||
static const uint64_t static_value1 = 0xcc153912f1453b70ULL;
|
||||
static const uint64_t static_value2 = 0x8d221682bc23d9acULL;
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct DataType< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "unitree_legged_msgs/Cartesian";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::Cartesian_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Definition< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "float32 x\n\
|
||||
float32 y\n\
|
||||
float32 z\n\
|
||||
";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::Cartesian_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
} // namespace message_traits
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace serialization
|
||||
{
|
||||
|
||||
template<class ContainerAllocator> struct Serializer< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
|
||||
{
|
||||
stream.next(m.x);
|
||||
stream.next(m.y);
|
||||
stream.next(m.z);
|
||||
}
|
||||
|
||||
ROS_DECLARE_ALLINONE_SERIALIZER
|
||||
}; // struct Cartesian_
|
||||
|
||||
} // namespace serialization
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_operations
|
||||
{
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Printer< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::unitree_legged_msgs::Cartesian_<ContainerAllocator>& v)
|
||||
{
|
||||
s << indent << "x: ";
|
||||
Printer<float>::stream(s, indent + " ", v.x);
|
||||
s << indent << "y: ";
|
||||
Printer<float>::stream(s, indent + " ", v.y);
|
||||
s << indent << "z: ";
|
||||
Printer<float>::stream(s, indent + " ", v.z);
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace message_operations
|
||||
} // namespace ros
|
||||
|
||||
#endif // UNITREE_LEGGED_MSGS_MESSAGE_CARTESIAN_H
|
@ -1,377 +0,0 @@
|
||||
// Generated by gencpp from file unitree_legged_msgs/HighCmd.msg
|
||||
// DO NOT EDIT!
|
||||
|
||||
|
||||
#ifndef UNITREE_LEGGED_MSGS_MESSAGE_HIGHCMD_H
|
||||
#define UNITREE_LEGGED_MSGS_MESSAGE_HIGHCMD_H
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
#include <ros/types.h>
|
||||
#include <ros/serialization.h>
|
||||
#include <ros/builtin_message_traits.h>
|
||||
#include <ros/message_operations.h>
|
||||
|
||||
#include <unitree_legged_msgs/LED.h>
|
||||
|
||||
namespace unitree_legged_msgs
|
||||
{
|
||||
template <class ContainerAllocator>
|
||||
struct HighCmd_
|
||||
{
|
||||
typedef HighCmd_<ContainerAllocator> Type;
|
||||
|
||||
HighCmd_()
|
||||
: levelFlag(0)
|
||||
, commVersion(0)
|
||||
, robotID(0)
|
||||
, SN(0)
|
||||
, bandWidth(0)
|
||||
, mode(0)
|
||||
, forwardSpeed(0.0)
|
||||
, sideSpeed(0.0)
|
||||
, rotateSpeed(0.0)
|
||||
, bodyHeight(0.0)
|
||||
, footRaiseHeight(0.0)
|
||||
, yaw(0.0)
|
||||
, pitch(0.0)
|
||||
, roll(0.0)
|
||||
, led()
|
||||
, wirelessRemote()
|
||||
, AppRemote()
|
||||
, reserve(0)
|
||||
, crc(0) {
|
||||
wirelessRemote.assign(0);
|
||||
|
||||
AppRemote.assign(0);
|
||||
}
|
||||
HighCmd_(const ContainerAllocator& _alloc)
|
||||
: levelFlag(0)
|
||||
, commVersion(0)
|
||||
, robotID(0)
|
||||
, SN(0)
|
||||
, bandWidth(0)
|
||||
, mode(0)
|
||||
, forwardSpeed(0.0)
|
||||
, sideSpeed(0.0)
|
||||
, rotateSpeed(0.0)
|
||||
, bodyHeight(0.0)
|
||||
, footRaiseHeight(0.0)
|
||||
, yaw(0.0)
|
||||
, pitch(0.0)
|
||||
, roll(0.0)
|
||||
, led()
|
||||
, wirelessRemote()
|
||||
, AppRemote()
|
||||
, reserve(0)
|
||||
, crc(0) {
|
||||
(void)_alloc;
|
||||
led.assign( ::unitree_legged_msgs::LED_<ContainerAllocator> (_alloc));
|
||||
|
||||
wirelessRemote.assign(0);
|
||||
|
||||
AppRemote.assign(0);
|
||||
}
|
||||
|
||||
|
||||
|
||||
typedef uint8_t _levelFlag_type;
|
||||
_levelFlag_type levelFlag;
|
||||
|
||||
typedef uint16_t _commVersion_type;
|
||||
_commVersion_type commVersion;
|
||||
|
||||
typedef uint16_t _robotID_type;
|
||||
_robotID_type robotID;
|
||||
|
||||
typedef uint32_t _SN_type;
|
||||
_SN_type SN;
|
||||
|
||||
typedef uint8_t _bandWidth_type;
|
||||
_bandWidth_type bandWidth;
|
||||
|
||||
typedef uint8_t _mode_type;
|
||||
_mode_type mode;
|
||||
|
||||
typedef float _forwardSpeed_type;
|
||||
_forwardSpeed_type forwardSpeed;
|
||||
|
||||
typedef float _sideSpeed_type;
|
||||
_sideSpeed_type sideSpeed;
|
||||
|
||||
typedef float _rotateSpeed_type;
|
||||
_rotateSpeed_type rotateSpeed;
|
||||
|
||||
typedef float _bodyHeight_type;
|
||||
_bodyHeight_type bodyHeight;
|
||||
|
||||
typedef float _footRaiseHeight_type;
|
||||
_footRaiseHeight_type footRaiseHeight;
|
||||
|
||||
typedef float _yaw_type;
|
||||
_yaw_type yaw;
|
||||
|
||||
typedef float _pitch_type;
|
||||
_pitch_type pitch;
|
||||
|
||||
typedef float _roll_type;
|
||||
_roll_type roll;
|
||||
|
||||
typedef boost::array< ::unitree_legged_msgs::LED_<ContainerAllocator> , 4> _led_type;
|
||||
_led_type led;
|
||||
|
||||
typedef boost::array<uint8_t, 40> _wirelessRemote_type;
|
||||
_wirelessRemote_type wirelessRemote;
|
||||
|
||||
typedef boost::array<uint8_t, 40> _AppRemote_type;
|
||||
_AppRemote_type AppRemote;
|
||||
|
||||
typedef uint32_t _reserve_type;
|
||||
_reserve_type reserve;
|
||||
|
||||
typedef int32_t _crc_type;
|
||||
_crc_type crc;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> > Ptr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> const> ConstPtr;
|
||||
|
||||
}; // struct HighCmd_
|
||||
|
||||
typedef ::unitree_legged_msgs::HighCmd_<std::allocator<void> > HighCmd;
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::HighCmd > HighCmdPtr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::HighCmd const> HighCmdConstPtr;
|
||||
|
||||
// constants requiring out of line definition
|
||||
|
||||
|
||||
|
||||
template<typename ContainerAllocator>
|
||||
std::ostream& operator<<(std::ostream& s, const ::unitree_legged_msgs::HighCmd_<ContainerAllocator> & v)
|
||||
{
|
||||
ros::message_operations::Printer< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >::stream(s, "", v);
|
||||
return s;
|
||||
}
|
||||
|
||||
} // namespace unitree_legged_msgs
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_traits
|
||||
{
|
||||
|
||||
|
||||
|
||||
// BOOLTRAITS {'IsFixedSize': True, 'IsMessage': True, 'HasHeader': False}
|
||||
// {'sensor_msgs': ['/opt/ros/kinetic/share/sensor_msgs/cmake/../msg'], 'geometry_msgs': ['/opt/ros/kinetic/share/geometry_msgs/cmake/../msg'], 'std_msgs': ['/opt/ros/kinetic/share/std_msgs/cmake/../msg'], 'unitree_legged_msgs': ['/home/chinhan/Joint_Rescue_development/src/unitree_ros_to_real-3.2.1/unitree_legged_msgs/msg']}
|
||||
|
||||
// !!!!!!!!!!! ['__class__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__getattribute__', '__hash__', '__init__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_parsed_fields', 'constants', 'fields', 'full_name', 'has_header', 'header_present', 'names', 'package', 'parsed_fields', 'short_name', 'text', 'types']
|
||||
|
||||
|
||||
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> const>
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct MD5Sum< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "1a655499a3f64905db59ceed65ca774a";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::HighCmd_<ContainerAllocator>&) { return value(); }
|
||||
static const uint64_t static_value1 = 0x1a655499a3f64905ULL;
|
||||
static const uint64_t static_value2 = 0xdb59ceed65ca774aULL;
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct DataType< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "unitree_legged_msgs/HighCmd";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::HighCmd_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Definition< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "uint8 levelFlag\n\
|
||||
uint16 commVersion # Old version Aliengo does not have\n\
|
||||
uint16 robotID # Old version Aliengo does not have\n\
|
||||
uint32 SN # Old version Aliengo does not have\n\
|
||||
uint8 bandWidth # Old version Aliengo does not have\n\
|
||||
uint8 mode\n\
|
||||
float32 forwardSpeed\n\
|
||||
float32 sideSpeed\n\
|
||||
float32 rotateSpeed \n\
|
||||
float32 bodyHeight\n\
|
||||
float32 footRaiseHeight\n\
|
||||
float32 yaw\n\
|
||||
float32 pitch\n\
|
||||
float32 roll\n\
|
||||
LED[4] led\n\
|
||||
uint8[40] wirelessRemote\n\
|
||||
uint8[40] AppRemote # Old version Aliengo does not have\n\
|
||||
uint32 reserve # Old version Aliengo does not have\n\
|
||||
int32 crc\n\
|
||||
================================================================================\n\
|
||||
MSG: unitree_legged_msgs/LED\n\
|
||||
uint8 r\n\
|
||||
uint8 g\n\
|
||||
uint8 b\n\
|
||||
";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::HighCmd_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
} // namespace message_traits
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace serialization
|
||||
{
|
||||
|
||||
template<class ContainerAllocator> struct Serializer< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
|
||||
{
|
||||
stream.next(m.levelFlag);
|
||||
stream.next(m.commVersion);
|
||||
stream.next(m.robotID);
|
||||
stream.next(m.SN);
|
||||
stream.next(m.bandWidth);
|
||||
stream.next(m.mode);
|
||||
stream.next(m.forwardSpeed);
|
||||
stream.next(m.sideSpeed);
|
||||
stream.next(m.rotateSpeed);
|
||||
stream.next(m.bodyHeight);
|
||||
stream.next(m.footRaiseHeight);
|
||||
stream.next(m.yaw);
|
||||
stream.next(m.pitch);
|
||||
stream.next(m.roll);
|
||||
stream.next(m.led);
|
||||
stream.next(m.wirelessRemote);
|
||||
stream.next(m.AppRemote);
|
||||
stream.next(m.reserve);
|
||||
stream.next(m.crc);
|
||||
}
|
||||
|
||||
ROS_DECLARE_ALLINONE_SERIALIZER
|
||||
}; // struct HighCmd_
|
||||
|
||||
} // namespace serialization
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_operations
|
||||
{
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Printer< ::unitree_legged_msgs::HighCmd_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::unitree_legged_msgs::HighCmd_<ContainerAllocator>& v)
|
||||
{
|
||||
s << indent << "levelFlag: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.levelFlag);
|
||||
s << indent << "commVersion: ";
|
||||
Printer<uint16_t>::stream(s, indent + " ", v.commVersion);
|
||||
s << indent << "robotID: ";
|
||||
Printer<uint16_t>::stream(s, indent + " ", v.robotID);
|
||||
s << indent << "SN: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.SN);
|
||||
s << indent << "bandWidth: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.bandWidth);
|
||||
s << indent << "mode: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.mode);
|
||||
s << indent << "forwardSpeed: ";
|
||||
Printer<float>::stream(s, indent + " ", v.forwardSpeed);
|
||||
s << indent << "sideSpeed: ";
|
||||
Printer<float>::stream(s, indent + " ", v.sideSpeed);
|
||||
s << indent << "rotateSpeed: ";
|
||||
Printer<float>::stream(s, indent + " ", v.rotateSpeed);
|
||||
s << indent << "bodyHeight: ";
|
||||
Printer<float>::stream(s, indent + " ", v.bodyHeight);
|
||||
s << indent << "footRaiseHeight: ";
|
||||
Printer<float>::stream(s, indent + " ", v.footRaiseHeight);
|
||||
s << indent << "yaw: ";
|
||||
Printer<float>::stream(s, indent + " ", v.yaw);
|
||||
s << indent << "pitch: ";
|
||||
Printer<float>::stream(s, indent + " ", v.pitch);
|
||||
s << indent << "roll: ";
|
||||
Printer<float>::stream(s, indent + " ", v.roll);
|
||||
s << indent << "led[]" << std::endl;
|
||||
for (size_t i = 0; i < v.led.size(); ++i)
|
||||
{
|
||||
s << indent << " led[" << i << "]: ";
|
||||
s << std::endl;
|
||||
s << indent;
|
||||
Printer< ::unitree_legged_msgs::LED_<ContainerAllocator> >::stream(s, indent + " ", v.led[i]);
|
||||
}
|
||||
s << indent << "wirelessRemote[]" << std::endl;
|
||||
for (size_t i = 0; i < v.wirelessRemote.size(); ++i)
|
||||
{
|
||||
s << indent << " wirelessRemote[" << i << "]: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.wirelessRemote[i]);
|
||||
}
|
||||
s << indent << "AppRemote[]" << std::endl;
|
||||
for (size_t i = 0; i < v.AppRemote.size(); ++i)
|
||||
{
|
||||
s << indent << " AppRemote[" << i << "]: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.AppRemote[i]);
|
||||
}
|
||||
s << indent << "reserve: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.reserve);
|
||||
s << indent << "crc: ";
|
||||
Printer<int32_t>::stream(s, indent + " ", v.crc);
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace message_operations
|
||||
} // namespace ros
|
||||
|
||||
#endif // UNITREE_LEGGED_MSGS_MESSAGE_HIGHCMD_H
|
@ -1,466 +0,0 @@
|
||||
// Generated by gencpp from file unitree_legged_msgs/HighState.msg
|
||||
// DO NOT EDIT!
|
||||
|
||||
|
||||
#ifndef UNITREE_LEGGED_MSGS_MESSAGE_HIGHSTATE_H
|
||||
#define UNITREE_LEGGED_MSGS_MESSAGE_HIGHSTATE_H
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
#include <ros/types.h>
|
||||
#include <ros/serialization.h>
|
||||
#include <ros/builtin_message_traits.h>
|
||||
#include <ros/message_operations.h>
|
||||
|
||||
#include <unitree_legged_msgs/IMU.h>
|
||||
#include <unitree_legged_msgs/Cartesian.h>
|
||||
#include <unitree_legged_msgs/Cartesian.h>
|
||||
#include <unitree_legged_msgs/Cartesian.h>
|
||||
|
||||
namespace unitree_legged_msgs
|
||||
{
|
||||
template <class ContainerAllocator>
|
||||
struct HighState_
|
||||
{
|
||||
typedef HighState_<ContainerAllocator> Type;
|
||||
|
||||
HighState_()
|
||||
: levelFlag(0)
|
||||
, commVersion(0)
|
||||
, robotID(0)
|
||||
, SN(0)
|
||||
, bandWidth(0)
|
||||
, mode(0)
|
||||
, imu()
|
||||
, forwardSpeed(0.0)
|
||||
, sideSpeed(0.0)
|
||||
, rotateSpeed(0.0)
|
||||
, bodyHeight(0.0)
|
||||
, updownSpeed(0.0)
|
||||
, forwardPosition(0.0)
|
||||
, sidePosition(0.0)
|
||||
, footPosition2Body()
|
||||
, footSpeed2Body()
|
||||
, footForce()
|
||||
, footForceEst()
|
||||
, tick(0)
|
||||
, wirelessRemote()
|
||||
, reserve(0)
|
||||
, crc(0)
|
||||
, eeForce()
|
||||
, jointP() {
|
||||
footForce.assign(0);
|
||||
|
||||
footForceEst.assign(0);
|
||||
|
||||
wirelessRemote.assign(0);
|
||||
|
||||
jointP.assign(0.0);
|
||||
}
|
||||
HighState_(const ContainerAllocator& _alloc)
|
||||
: levelFlag(0)
|
||||
, commVersion(0)
|
||||
, robotID(0)
|
||||
, SN(0)
|
||||
, bandWidth(0)
|
||||
, mode(0)
|
||||
, imu(_alloc)
|
||||
, forwardSpeed(0.0)
|
||||
, sideSpeed(0.0)
|
||||
, rotateSpeed(0.0)
|
||||
, bodyHeight(0.0)
|
||||
, updownSpeed(0.0)
|
||||
, forwardPosition(0.0)
|
||||
, sidePosition(0.0)
|
||||
, footPosition2Body()
|
||||
, footSpeed2Body()
|
||||
, footForce()
|
||||
, footForceEst()
|
||||
, tick(0)
|
||||
, wirelessRemote()
|
||||
, reserve(0)
|
||||
, crc(0)
|
||||
, eeForce()
|
||||
, jointP() {
|
||||
(void)_alloc;
|
||||
footPosition2Body.assign( ::unitree_legged_msgs::Cartesian_<ContainerAllocator> (_alloc));
|
||||
|
||||
footSpeed2Body.assign( ::unitree_legged_msgs::Cartesian_<ContainerAllocator> (_alloc));
|
||||
|
||||
footForce.assign(0);
|
||||
|
||||
footForceEst.assign(0);
|
||||
|
||||
wirelessRemote.assign(0);
|
||||
|
||||
eeForce.assign( ::unitree_legged_msgs::Cartesian_<ContainerAllocator> (_alloc));
|
||||
|
||||
jointP.assign(0.0);
|
||||
}
|
||||
|
||||
|
||||
|
||||
typedef uint8_t _levelFlag_type;
|
||||
_levelFlag_type levelFlag;
|
||||
|
||||
typedef uint16_t _commVersion_type;
|
||||
_commVersion_type commVersion;
|
||||
|
||||
typedef uint16_t _robotID_type;
|
||||
_robotID_type robotID;
|
||||
|
||||
typedef uint32_t _SN_type;
|
||||
_SN_type SN;
|
||||
|
||||
typedef uint8_t _bandWidth_type;
|
||||
_bandWidth_type bandWidth;
|
||||
|
||||
typedef uint8_t _mode_type;
|
||||
_mode_type mode;
|
||||
|
||||
typedef ::unitree_legged_msgs::IMU_<ContainerAllocator> _imu_type;
|
||||
_imu_type imu;
|
||||
|
||||
typedef float _forwardSpeed_type;
|
||||
_forwardSpeed_type forwardSpeed;
|
||||
|
||||
typedef float _sideSpeed_type;
|
||||
_sideSpeed_type sideSpeed;
|
||||
|
||||
typedef float _rotateSpeed_type;
|
||||
_rotateSpeed_type rotateSpeed;
|
||||
|
||||
typedef float _bodyHeight_type;
|
||||
_bodyHeight_type bodyHeight;
|
||||
|
||||
typedef float _updownSpeed_type;
|
||||
_updownSpeed_type updownSpeed;
|
||||
|
||||
typedef float _forwardPosition_type;
|
||||
_forwardPosition_type forwardPosition;
|
||||
|
||||
typedef float _sidePosition_type;
|
||||
_sidePosition_type sidePosition;
|
||||
|
||||
typedef boost::array< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> , 4> _footPosition2Body_type;
|
||||
_footPosition2Body_type footPosition2Body;
|
||||
|
||||
typedef boost::array< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> , 4> _footSpeed2Body_type;
|
||||
_footSpeed2Body_type footSpeed2Body;
|
||||
|
||||
typedef boost::array<int16_t, 4> _footForce_type;
|
||||
_footForce_type footForce;
|
||||
|
||||
typedef boost::array<int16_t, 4> _footForceEst_type;
|
||||
_footForceEst_type footForceEst;
|
||||
|
||||
typedef uint32_t _tick_type;
|
||||
_tick_type tick;
|
||||
|
||||
typedef boost::array<uint8_t, 40> _wirelessRemote_type;
|
||||
_wirelessRemote_type wirelessRemote;
|
||||
|
||||
typedef uint32_t _reserve_type;
|
||||
_reserve_type reserve;
|
||||
|
||||
typedef uint32_t _crc_type;
|
||||
_crc_type crc;
|
||||
|
||||
typedef boost::array< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> , 4> _eeForce_type;
|
||||
_eeForce_type eeForce;
|
||||
|
||||
typedef boost::array<float, 12> _jointP_type;
|
||||
_jointP_type jointP;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::HighState_<ContainerAllocator> > Ptr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::HighState_<ContainerAllocator> const> ConstPtr;
|
||||
|
||||
}; // struct HighState_
|
||||
|
||||
typedef ::unitree_legged_msgs::HighState_<std::allocator<void> > HighState;
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::HighState > HighStatePtr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::HighState const> HighStateConstPtr;
|
||||
|
||||
// constants requiring out of line definition
|
||||
|
||||
|
||||
|
||||
template<typename ContainerAllocator>
|
||||
std::ostream& operator<<(std::ostream& s, const ::unitree_legged_msgs::HighState_<ContainerAllocator> & v)
|
||||
{
|
||||
ros::message_operations::Printer< ::unitree_legged_msgs::HighState_<ContainerAllocator> >::stream(s, "", v);
|
||||
return s;
|
||||
}
|
||||
|
||||
} // namespace unitree_legged_msgs
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_traits
|
||||
{
|
||||
|
||||
|
||||
|
||||
// BOOLTRAITS {'IsFixedSize': True, 'IsMessage': True, 'HasHeader': False}
|
||||
// {'sensor_msgs': ['/opt/ros/kinetic/share/sensor_msgs/cmake/../msg'], 'geometry_msgs': ['/opt/ros/kinetic/share/geometry_msgs/cmake/../msg'], 'std_msgs': ['/opt/ros/kinetic/share/std_msgs/cmake/../msg'], 'unitree_legged_msgs': ['/home/chinhan/Joint_Rescue_development/src/unitree_ros_to_real-3.2.1/unitree_legged_msgs/msg']}
|
||||
|
||||
// !!!!!!!!!!! ['__class__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__getattribute__', '__hash__', '__init__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_parsed_fields', 'constants', 'fields', 'full_name', 'has_header', 'header_present', 'names', 'package', 'parsed_fields', 'short_name', 'text', 'types']
|
||||
|
||||
|
||||
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::HighState_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::HighState_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::HighState_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::HighState_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::HighState_<ContainerAllocator> >
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::HighState_<ContainerAllocator> const>
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct MD5Sum< ::unitree_legged_msgs::HighState_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "a12e8b22df896c82203810ec6d521dad";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::HighState_<ContainerAllocator>&) { return value(); }
|
||||
static const uint64_t static_value1 = 0xa12e8b22df896c82ULL;
|
||||
static const uint64_t static_value2 = 0x203810ec6d521dadULL;
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct DataType< ::unitree_legged_msgs::HighState_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "unitree_legged_msgs/HighState";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::HighState_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Definition< ::unitree_legged_msgs::HighState_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "uint8 levelFlag\n\
|
||||
uint16 commVersion # Old version Aliengo does not have\n\
|
||||
uint16 robotID # Old version Aliengo does not have\n\
|
||||
uint32 SN # Old version Aliengo does not have\n\
|
||||
uint8 bandWidth # Old version Aliengo does not have\n\
|
||||
uint8 mode\n\
|
||||
IMU imu\n\
|
||||
float32 forwardSpeed\n\
|
||||
float32 sideSpeed\n\
|
||||
float32 rotateSpeed\n\
|
||||
float32 bodyHeight\n\
|
||||
float32 updownSpeed\n\
|
||||
float32 forwardPosition # (will be float type next version) # Old version Aliengo is different\n\
|
||||
float32 sidePosition # (will be float type next version) # Old version Aliengo is different\n\
|
||||
Cartesian[4] footPosition2Body\n\
|
||||
Cartesian[4] footSpeed2Body\n\
|
||||
int16[4] footForce # Old version Aliengo is different\n\
|
||||
int16[4] footForceEst # Old version Aliengo does not have\n\
|
||||
uint32 tick \n\
|
||||
uint8[40] wirelessRemote\n\
|
||||
uint32 reserve # Old version Aliengo does not have\n\
|
||||
uint32 crc\n\
|
||||
\n\
|
||||
# Under are not defined in SDK yet. # Old version Aliengo does not have\n\
|
||||
Cartesian[4] eeForce # It's a 1-DOF force in real robot, but 3-DOF is better for visualization.\n\
|
||||
float32[12] jointP # for visualization\n\
|
||||
================================================================================\n\
|
||||
MSG: unitree_legged_msgs/IMU\n\
|
||||
float32[4] quaternion\n\
|
||||
float32[3] gyroscope\n\
|
||||
float32[3] accelerometer\n\
|
||||
int8 temperature\n\
|
||||
================================================================================\n\
|
||||
MSG: unitree_legged_msgs/Cartesian\n\
|
||||
float32 x\n\
|
||||
float32 y\n\
|
||||
float32 z\n\
|
||||
";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::HighState_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
} // namespace message_traits
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace serialization
|
||||
{
|
||||
|
||||
template<class ContainerAllocator> struct Serializer< ::unitree_legged_msgs::HighState_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
|
||||
{
|
||||
stream.next(m.levelFlag);
|
||||
stream.next(m.commVersion);
|
||||
stream.next(m.robotID);
|
||||
stream.next(m.SN);
|
||||
stream.next(m.bandWidth);
|
||||
stream.next(m.mode);
|
||||
stream.next(m.imu);
|
||||
stream.next(m.forwardSpeed);
|
||||
stream.next(m.sideSpeed);
|
||||
stream.next(m.rotateSpeed);
|
||||
stream.next(m.bodyHeight);
|
||||
stream.next(m.updownSpeed);
|
||||
stream.next(m.forwardPosition);
|
||||
stream.next(m.sidePosition);
|
||||
stream.next(m.footPosition2Body);
|
||||
stream.next(m.footSpeed2Body);
|
||||
stream.next(m.footForce);
|
||||
stream.next(m.footForceEst);
|
||||
stream.next(m.tick);
|
||||
stream.next(m.wirelessRemote);
|
||||
stream.next(m.reserve);
|
||||
stream.next(m.crc);
|
||||
stream.next(m.eeForce);
|
||||
stream.next(m.jointP);
|
||||
}
|
||||
|
||||
ROS_DECLARE_ALLINONE_SERIALIZER
|
||||
}; // struct HighState_
|
||||
|
||||
} // namespace serialization
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_operations
|
||||
{
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Printer< ::unitree_legged_msgs::HighState_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::unitree_legged_msgs::HighState_<ContainerAllocator>& v)
|
||||
{
|
||||
s << indent << "levelFlag: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.levelFlag);
|
||||
s << indent << "commVersion: ";
|
||||
Printer<uint16_t>::stream(s, indent + " ", v.commVersion);
|
||||
s << indent << "robotID: ";
|
||||
Printer<uint16_t>::stream(s, indent + " ", v.robotID);
|
||||
s << indent << "SN: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.SN);
|
||||
s << indent << "bandWidth: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.bandWidth);
|
||||
s << indent << "mode: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.mode);
|
||||
s << indent << "imu: ";
|
||||
s << std::endl;
|
||||
Printer< ::unitree_legged_msgs::IMU_<ContainerAllocator> >::stream(s, indent + " ", v.imu);
|
||||
s << indent << "forwardSpeed: ";
|
||||
Printer<float>::stream(s, indent + " ", v.forwardSpeed);
|
||||
s << indent << "sideSpeed: ";
|
||||
Printer<float>::stream(s, indent + " ", v.sideSpeed);
|
||||
s << indent << "rotateSpeed: ";
|
||||
Printer<float>::stream(s, indent + " ", v.rotateSpeed);
|
||||
s << indent << "bodyHeight: ";
|
||||
Printer<float>::stream(s, indent + " ", v.bodyHeight);
|
||||
s << indent << "updownSpeed: ";
|
||||
Printer<float>::stream(s, indent + " ", v.updownSpeed);
|
||||
s << indent << "forwardPosition: ";
|
||||
Printer<float>::stream(s, indent + " ", v.forwardPosition);
|
||||
s << indent << "sidePosition: ";
|
||||
Printer<float>::stream(s, indent + " ", v.sidePosition);
|
||||
s << indent << "footPosition2Body[]" << std::endl;
|
||||
for (size_t i = 0; i < v.footPosition2Body.size(); ++i)
|
||||
{
|
||||
s << indent << " footPosition2Body[" << i << "]: ";
|
||||
s << std::endl;
|
||||
s << indent;
|
||||
Printer< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >::stream(s, indent + " ", v.footPosition2Body[i]);
|
||||
}
|
||||
s << indent << "footSpeed2Body[]" << std::endl;
|
||||
for (size_t i = 0; i < v.footSpeed2Body.size(); ++i)
|
||||
{
|
||||
s << indent << " footSpeed2Body[" << i << "]: ";
|
||||
s << std::endl;
|
||||
s << indent;
|
||||
Printer< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >::stream(s, indent + " ", v.footSpeed2Body[i]);
|
||||
}
|
||||
s << indent << "footForce[]" << std::endl;
|
||||
for (size_t i = 0; i < v.footForce.size(); ++i)
|
||||
{
|
||||
s << indent << " footForce[" << i << "]: ";
|
||||
Printer<int16_t>::stream(s, indent + " ", v.footForce[i]);
|
||||
}
|
||||
s << indent << "footForceEst[]" << std::endl;
|
||||
for (size_t i = 0; i < v.footForceEst.size(); ++i)
|
||||
{
|
||||
s << indent << " footForceEst[" << i << "]: ";
|
||||
Printer<int16_t>::stream(s, indent + " ", v.footForceEst[i]);
|
||||
}
|
||||
s << indent << "tick: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.tick);
|
||||
s << indent << "wirelessRemote[]" << std::endl;
|
||||
for (size_t i = 0; i < v.wirelessRemote.size(); ++i)
|
||||
{
|
||||
s << indent << " wirelessRemote[" << i << "]: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.wirelessRemote[i]);
|
||||
}
|
||||
s << indent << "reserve: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.reserve);
|
||||
s << indent << "crc: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.crc);
|
||||
s << indent << "eeForce[]" << std::endl;
|
||||
for (size_t i = 0; i < v.eeForce.size(); ++i)
|
||||
{
|
||||
s << indent << " eeForce[" << i << "]: ";
|
||||
s << std::endl;
|
||||
s << indent;
|
||||
Printer< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >::stream(s, indent + " ", v.eeForce[i]);
|
||||
}
|
||||
s << indent << "jointP[]" << std::endl;
|
||||
for (size_t i = 0; i < v.jointP.size(); ++i)
|
||||
{
|
||||
s << indent << " jointP[" << i << "]: ";
|
||||
Printer<float>::stream(s, indent + " ", v.jointP[i]);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace message_operations
|
||||
} // namespace ros
|
||||
|
||||
#endif // UNITREE_LEGGED_MSGS_MESSAGE_HIGHSTATE_H
|
@ -1,236 +0,0 @@
|
||||
// Generated by gencpp from file unitree_legged_msgs/IMU.msg
|
||||
// DO NOT EDIT!
|
||||
|
||||
|
||||
#ifndef UNITREE_LEGGED_MSGS_MESSAGE_IMU_H
|
||||
#define UNITREE_LEGGED_MSGS_MESSAGE_IMU_H
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
#include <ros/types.h>
|
||||
#include <ros/serialization.h>
|
||||
#include <ros/builtin_message_traits.h>
|
||||
#include <ros/message_operations.h>
|
||||
|
||||
|
||||
namespace unitree_legged_msgs
|
||||
{
|
||||
template <class ContainerAllocator>
|
||||
struct IMU_
|
||||
{
|
||||
typedef IMU_<ContainerAllocator> Type;
|
||||
|
||||
IMU_()
|
||||
: quaternion()
|
||||
, gyroscope()
|
||||
, accelerometer()
|
||||
, temperature(0) {
|
||||
quaternion.assign(0.0);
|
||||
|
||||
gyroscope.assign(0.0);
|
||||
|
||||
accelerometer.assign(0.0);
|
||||
}
|
||||
IMU_(const ContainerAllocator& _alloc)
|
||||
: quaternion()
|
||||
, gyroscope()
|
||||
, accelerometer()
|
||||
, temperature(0) {
|
||||
(void)_alloc;
|
||||
quaternion.assign(0.0);
|
||||
|
||||
gyroscope.assign(0.0);
|
||||
|
||||
accelerometer.assign(0.0);
|
||||
}
|
||||
|
||||
|
||||
|
||||
typedef boost::array<float, 4> _quaternion_type;
|
||||
_quaternion_type quaternion;
|
||||
|
||||
typedef boost::array<float, 3> _gyroscope_type;
|
||||
_gyroscope_type gyroscope;
|
||||
|
||||
typedef boost::array<float, 3> _accelerometer_type;
|
||||
_accelerometer_type accelerometer;
|
||||
|
||||
typedef int8_t _temperature_type;
|
||||
_temperature_type temperature;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::IMU_<ContainerAllocator> > Ptr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::IMU_<ContainerAllocator> const> ConstPtr;
|
||||
|
||||
}; // struct IMU_
|
||||
|
||||
typedef ::unitree_legged_msgs::IMU_<std::allocator<void> > IMU;
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::IMU > IMUPtr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::IMU const> IMUConstPtr;
|
||||
|
||||
// constants requiring out of line definition
|
||||
|
||||
|
||||
|
||||
template<typename ContainerAllocator>
|
||||
std::ostream& operator<<(std::ostream& s, const ::unitree_legged_msgs::IMU_<ContainerAllocator> & v)
|
||||
{
|
||||
ros::message_operations::Printer< ::unitree_legged_msgs::IMU_<ContainerAllocator> >::stream(s, "", v);
|
||||
return s;
|
||||
}
|
||||
|
||||
} // namespace unitree_legged_msgs
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_traits
|
||||
{
|
||||
|
||||
|
||||
|
||||
// BOOLTRAITS {'IsFixedSize': True, 'IsMessage': True, 'HasHeader': False}
|
||||
// {'sensor_msgs': ['/opt/ros/kinetic/share/sensor_msgs/cmake/../msg'], 'geometry_msgs': ['/opt/ros/kinetic/share/geometry_msgs/cmake/../msg'], 'std_msgs': ['/opt/ros/kinetic/share/std_msgs/cmake/../msg'], 'unitree_legged_msgs': ['/home/chinhan/Joint_Rescue_development/src/unitree_ros_to_real-3.2.1/unitree_legged_msgs/msg']}
|
||||
|
||||
// !!!!!!!!!!! ['__class__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__getattribute__', '__hash__', '__init__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_parsed_fields', 'constants', 'fields', 'full_name', 'has_header', 'header_present', 'names', 'package', 'parsed_fields', 'short_name', 'text', 'types']
|
||||
|
||||
|
||||
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::IMU_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::IMU_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::IMU_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::IMU_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::IMU_<ContainerAllocator> >
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::IMU_<ContainerAllocator> const>
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct MD5Sum< ::unitree_legged_msgs::IMU_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "dd4bb4e42aa2f15aa1fb1b6a3c3752cb";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::IMU_<ContainerAllocator>&) { return value(); }
|
||||
static const uint64_t static_value1 = 0xdd4bb4e42aa2f15aULL;
|
||||
static const uint64_t static_value2 = 0xa1fb1b6a3c3752cbULL;
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct DataType< ::unitree_legged_msgs::IMU_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "unitree_legged_msgs/IMU";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::IMU_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Definition< ::unitree_legged_msgs::IMU_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "float32[4] quaternion\n\
|
||||
float32[3] gyroscope\n\
|
||||
float32[3] accelerometer\n\
|
||||
int8 temperature\n\
|
||||
";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::IMU_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
} // namespace message_traits
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace serialization
|
||||
{
|
||||
|
||||
template<class ContainerAllocator> struct Serializer< ::unitree_legged_msgs::IMU_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
|
||||
{
|
||||
stream.next(m.quaternion);
|
||||
stream.next(m.gyroscope);
|
||||
stream.next(m.accelerometer);
|
||||
stream.next(m.temperature);
|
||||
}
|
||||
|
||||
ROS_DECLARE_ALLINONE_SERIALIZER
|
||||
}; // struct IMU_
|
||||
|
||||
} // namespace serialization
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_operations
|
||||
{
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Printer< ::unitree_legged_msgs::IMU_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::unitree_legged_msgs::IMU_<ContainerAllocator>& v)
|
||||
{
|
||||
s << indent << "quaternion[]" << std::endl;
|
||||
for (size_t i = 0; i < v.quaternion.size(); ++i)
|
||||
{
|
||||
s << indent << " quaternion[" << i << "]: ";
|
||||
Printer<float>::stream(s, indent + " ", v.quaternion[i]);
|
||||
}
|
||||
s << indent << "gyroscope[]" << std::endl;
|
||||
for (size_t i = 0; i < v.gyroscope.size(); ++i)
|
||||
{
|
||||
s << indent << " gyroscope[" << i << "]: ";
|
||||
Printer<float>::stream(s, indent + " ", v.gyroscope[i]);
|
||||
}
|
||||
s << indent << "accelerometer[]" << std::endl;
|
||||
for (size_t i = 0; i < v.accelerometer.size(); ++i)
|
||||
{
|
||||
s << indent << " accelerometer[" << i << "]: ";
|
||||
Printer<float>::stream(s, indent + " ", v.accelerometer[i]);
|
||||
}
|
||||
s << indent << "temperature: ";
|
||||
Printer<int8_t>::stream(s, indent + " ", v.temperature);
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace message_operations
|
||||
} // namespace ros
|
||||
|
||||
#endif // UNITREE_LEGGED_MSGS_MESSAGE_IMU_H
|
@ -1,205 +0,0 @@
|
||||
// Generated by gencpp from file unitree_legged_msgs/LED.msg
|
||||
// DO NOT EDIT!
|
||||
|
||||
|
||||
#ifndef UNITREE_LEGGED_MSGS_MESSAGE_LED_H
|
||||
#define UNITREE_LEGGED_MSGS_MESSAGE_LED_H
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
#include <ros/types.h>
|
||||
#include <ros/serialization.h>
|
||||
#include <ros/builtin_message_traits.h>
|
||||
#include <ros/message_operations.h>
|
||||
|
||||
|
||||
namespace unitree_legged_msgs
|
||||
{
|
||||
template <class ContainerAllocator>
|
||||
struct LED_
|
||||
{
|
||||
typedef LED_<ContainerAllocator> Type;
|
||||
|
||||
LED_()
|
||||
: r(0)
|
||||
, g(0)
|
||||
, b(0) {
|
||||
}
|
||||
LED_(const ContainerAllocator& _alloc)
|
||||
: r(0)
|
||||
, g(0)
|
||||
, b(0) {
|
||||
(void)_alloc;
|
||||
}
|
||||
|
||||
|
||||
|
||||
typedef uint8_t _r_type;
|
||||
_r_type r;
|
||||
|
||||
typedef uint8_t _g_type;
|
||||
_g_type g;
|
||||
|
||||
typedef uint8_t _b_type;
|
||||
_b_type b;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::LED_<ContainerAllocator> > Ptr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::LED_<ContainerAllocator> const> ConstPtr;
|
||||
|
||||
}; // struct LED_
|
||||
|
||||
typedef ::unitree_legged_msgs::LED_<std::allocator<void> > LED;
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::LED > LEDPtr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::LED const> LEDConstPtr;
|
||||
|
||||
// constants requiring out of line definition
|
||||
|
||||
|
||||
|
||||
template<typename ContainerAllocator>
|
||||
std::ostream& operator<<(std::ostream& s, const ::unitree_legged_msgs::LED_<ContainerAllocator> & v)
|
||||
{
|
||||
ros::message_operations::Printer< ::unitree_legged_msgs::LED_<ContainerAllocator> >::stream(s, "", v);
|
||||
return s;
|
||||
}
|
||||
|
||||
} // namespace unitree_legged_msgs
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_traits
|
||||
{
|
||||
|
||||
|
||||
|
||||
// BOOLTRAITS {'IsFixedSize': True, 'IsMessage': True, 'HasHeader': False}
|
||||
// {'sensor_msgs': ['/opt/ros/kinetic/share/sensor_msgs/cmake/../msg'], 'geometry_msgs': ['/opt/ros/kinetic/share/geometry_msgs/cmake/../msg'], 'std_msgs': ['/opt/ros/kinetic/share/std_msgs/cmake/../msg'], 'unitree_legged_msgs': ['/home/chinhan/Joint_Rescue_development/src/unitree_ros_to_real-3.2.1/unitree_legged_msgs/msg']}
|
||||
|
||||
// !!!!!!!!!!! ['__class__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__getattribute__', '__hash__', '__init__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_parsed_fields', 'constants', 'fields', 'full_name', 'has_header', 'header_present', 'names', 'package', 'parsed_fields', 'short_name', 'text', 'types']
|
||||
|
||||
|
||||
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::LED_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::LED_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::LED_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::LED_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::LED_<ContainerAllocator> >
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::LED_<ContainerAllocator> const>
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct MD5Sum< ::unitree_legged_msgs::LED_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "353891e354491c51aabe32df673fb446";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::LED_<ContainerAllocator>&) { return value(); }
|
||||
static const uint64_t static_value1 = 0x353891e354491c51ULL;
|
||||
static const uint64_t static_value2 = 0xaabe32df673fb446ULL;
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct DataType< ::unitree_legged_msgs::LED_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "unitree_legged_msgs/LED";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::LED_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Definition< ::unitree_legged_msgs::LED_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "uint8 r\n\
|
||||
uint8 g\n\
|
||||
uint8 b\n\
|
||||
";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::LED_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
} // namespace message_traits
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace serialization
|
||||
{
|
||||
|
||||
template<class ContainerAllocator> struct Serializer< ::unitree_legged_msgs::LED_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
|
||||
{
|
||||
stream.next(m.r);
|
||||
stream.next(m.g);
|
||||
stream.next(m.b);
|
||||
}
|
||||
|
||||
ROS_DECLARE_ALLINONE_SERIALIZER
|
||||
}; // struct LED_
|
||||
|
||||
} // namespace serialization
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_operations
|
||||
{
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Printer< ::unitree_legged_msgs::LED_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::unitree_legged_msgs::LED_<ContainerAllocator>& v)
|
||||
{
|
||||
s << indent << "r: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.r);
|
||||
s << indent << "g: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.g);
|
||||
s << indent << "b: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.b);
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace message_operations
|
||||
} // namespace ros
|
||||
|
||||
#endif // UNITREE_LEGGED_MSGS_MESSAGE_LED_H
|
@ -1,330 +0,0 @@
|
||||
// Generated by gencpp from file unitree_legged_msgs/LowCmd.msg
|
||||
// DO NOT EDIT!
|
||||
|
||||
|
||||
#ifndef UNITREE_LEGGED_MSGS_MESSAGE_LOWCMD_H
|
||||
#define UNITREE_LEGGED_MSGS_MESSAGE_LOWCMD_H
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
#include <ros/types.h>
|
||||
#include <ros/serialization.h>
|
||||
#include <ros/builtin_message_traits.h>
|
||||
#include <ros/message_operations.h>
|
||||
|
||||
#include <unitree_legged_msgs/MotorCmd.h>
|
||||
#include <unitree_legged_msgs/LED.h>
|
||||
#include <unitree_legged_msgs/Cartesian.h>
|
||||
|
||||
namespace unitree_legged_msgs
|
||||
{
|
||||
template <class ContainerAllocator>
|
||||
struct LowCmd_
|
||||
{
|
||||
typedef LowCmd_<ContainerAllocator> Type;
|
||||
|
||||
LowCmd_()
|
||||
: levelFlag(0)
|
||||
, commVersion(0)
|
||||
, robotID(0)
|
||||
, SN(0)
|
||||
, bandWidth(0)
|
||||
, motorCmd()
|
||||
, led()
|
||||
, wirelessRemote()
|
||||
, reserve(0)
|
||||
, crc(0)
|
||||
, ff() {
|
||||
wirelessRemote.assign(0);
|
||||
}
|
||||
LowCmd_(const ContainerAllocator& _alloc)
|
||||
: levelFlag(0)
|
||||
, commVersion(0)
|
||||
, robotID(0)
|
||||
, SN(0)
|
||||
, bandWidth(0)
|
||||
, motorCmd()
|
||||
, led()
|
||||
, wirelessRemote()
|
||||
, reserve(0)
|
||||
, crc(0)
|
||||
, ff() {
|
||||
(void)_alloc;
|
||||
motorCmd.assign( ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> (_alloc));
|
||||
|
||||
led.assign( ::unitree_legged_msgs::LED_<ContainerAllocator> (_alloc));
|
||||
|
||||
wirelessRemote.assign(0);
|
||||
|
||||
ff.assign( ::unitree_legged_msgs::Cartesian_<ContainerAllocator> (_alloc));
|
||||
}
|
||||
|
||||
|
||||
|
||||
typedef uint8_t _levelFlag_type;
|
||||
_levelFlag_type levelFlag;
|
||||
|
||||
typedef uint16_t _commVersion_type;
|
||||
_commVersion_type commVersion;
|
||||
|
||||
typedef uint16_t _robotID_type;
|
||||
_robotID_type robotID;
|
||||
|
||||
typedef uint32_t _SN_type;
|
||||
_SN_type SN;
|
||||
|
||||
typedef uint8_t _bandWidth_type;
|
||||
_bandWidth_type bandWidth;
|
||||
|
||||
typedef boost::array< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> , 20> _motorCmd_type;
|
||||
_motorCmd_type motorCmd;
|
||||
|
||||
typedef boost::array< ::unitree_legged_msgs::LED_<ContainerAllocator> , 4> _led_type;
|
||||
_led_type led;
|
||||
|
||||
typedef boost::array<uint8_t, 40> _wirelessRemote_type;
|
||||
_wirelessRemote_type wirelessRemote;
|
||||
|
||||
typedef uint32_t _reserve_type;
|
||||
_reserve_type reserve;
|
||||
|
||||
typedef uint32_t _crc_type;
|
||||
_crc_type crc;
|
||||
|
||||
typedef boost::array< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> , 4> _ff_type;
|
||||
_ff_type ff;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> > Ptr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> const> ConstPtr;
|
||||
|
||||
}; // struct LowCmd_
|
||||
|
||||
typedef ::unitree_legged_msgs::LowCmd_<std::allocator<void> > LowCmd;
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::LowCmd > LowCmdPtr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::LowCmd const> LowCmdConstPtr;
|
||||
|
||||
// constants requiring out of line definition
|
||||
|
||||
|
||||
|
||||
template<typename ContainerAllocator>
|
||||
std::ostream& operator<<(std::ostream& s, const ::unitree_legged_msgs::LowCmd_<ContainerAllocator> & v)
|
||||
{
|
||||
ros::message_operations::Printer< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >::stream(s, "", v);
|
||||
return s;
|
||||
}
|
||||
|
||||
} // namespace unitree_legged_msgs
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_traits
|
||||
{
|
||||
|
||||
|
||||
|
||||
// BOOLTRAITS {'IsFixedSize': True, 'IsMessage': True, 'HasHeader': False}
|
||||
// {'sensor_msgs': ['/opt/ros/kinetic/share/sensor_msgs/cmake/../msg'], 'geometry_msgs': ['/opt/ros/kinetic/share/geometry_msgs/cmake/../msg'], 'std_msgs': ['/opt/ros/kinetic/share/std_msgs/cmake/../msg'], 'unitree_legged_msgs': ['/home/chinhan/Joint_Rescue_development/src/unitree_ros_to_real-3.2.1/unitree_legged_msgs/msg']}
|
||||
|
||||
// !!!!!!!!!!! ['__class__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__getattribute__', '__hash__', '__init__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_parsed_fields', 'constants', 'fields', 'full_name', 'has_header', 'header_present', 'names', 'package', 'parsed_fields', 'short_name', 'text', 'types']
|
||||
|
||||
|
||||
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> const>
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct MD5Sum< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "357432b2562edd0a8e89b9c9f5fc4821";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::LowCmd_<ContainerAllocator>&) { return value(); }
|
||||
static const uint64_t static_value1 = 0x357432b2562edd0aULL;
|
||||
static const uint64_t static_value2 = 0x8e89b9c9f5fc4821ULL;
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct DataType< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "unitree_legged_msgs/LowCmd";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::LowCmd_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Definition< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "uint8 levelFlag \n\
|
||||
uint16 commVersion # Old version Aliengo does not have\n\
|
||||
uint16 robotID # Old version Aliengo does not have\n\
|
||||
uint32 SN # Old version Aliengo does not have\n\
|
||||
uint8 bandWidth # Old version Aliengo does not have\n\
|
||||
MotorCmd[20] motorCmd\n\
|
||||
LED[4] led\n\
|
||||
uint8[40] wirelessRemote\n\
|
||||
uint32 reserve # Old version Aliengo does not have\n\
|
||||
uint32 crc\n\
|
||||
\n\
|
||||
Cartesian[4] ff # will delete # Old version Aliengo does not have\n\
|
||||
================================================================================\n\
|
||||
MSG: unitree_legged_msgs/MotorCmd\n\
|
||||
uint8 mode # motor target mode\n\
|
||||
float32 q # motor target position\n\
|
||||
float32 dq # motor target velocity\n\
|
||||
float32 tau # motor target torque\n\
|
||||
float32 Kp # motor spring stiffness coefficient\n\
|
||||
float32 Kd # motor damper coefficient\n\
|
||||
uint32[3] reserve # motor target torque\n\
|
||||
================================================================================\n\
|
||||
MSG: unitree_legged_msgs/LED\n\
|
||||
uint8 r\n\
|
||||
uint8 g\n\
|
||||
uint8 b\n\
|
||||
================================================================================\n\
|
||||
MSG: unitree_legged_msgs/Cartesian\n\
|
||||
float32 x\n\
|
||||
float32 y\n\
|
||||
float32 z\n\
|
||||
";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::LowCmd_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
} // namespace message_traits
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace serialization
|
||||
{
|
||||
|
||||
template<class ContainerAllocator> struct Serializer< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
|
||||
{
|
||||
stream.next(m.levelFlag);
|
||||
stream.next(m.commVersion);
|
||||
stream.next(m.robotID);
|
||||
stream.next(m.SN);
|
||||
stream.next(m.bandWidth);
|
||||
stream.next(m.motorCmd);
|
||||
stream.next(m.led);
|
||||
stream.next(m.wirelessRemote);
|
||||
stream.next(m.reserve);
|
||||
stream.next(m.crc);
|
||||
stream.next(m.ff);
|
||||
}
|
||||
|
||||
ROS_DECLARE_ALLINONE_SERIALIZER
|
||||
}; // struct LowCmd_
|
||||
|
||||
} // namespace serialization
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_operations
|
||||
{
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Printer< ::unitree_legged_msgs::LowCmd_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::unitree_legged_msgs::LowCmd_<ContainerAllocator>& v)
|
||||
{
|
||||
s << indent << "levelFlag: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.levelFlag);
|
||||
s << indent << "commVersion: ";
|
||||
Printer<uint16_t>::stream(s, indent + " ", v.commVersion);
|
||||
s << indent << "robotID: ";
|
||||
Printer<uint16_t>::stream(s, indent + " ", v.robotID);
|
||||
s << indent << "SN: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.SN);
|
||||
s << indent << "bandWidth: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.bandWidth);
|
||||
s << indent << "motorCmd[]" << std::endl;
|
||||
for (size_t i = 0; i < v.motorCmd.size(); ++i)
|
||||
{
|
||||
s << indent << " motorCmd[" << i << "]: ";
|
||||
s << std::endl;
|
||||
s << indent;
|
||||
Printer< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >::stream(s, indent + " ", v.motorCmd[i]);
|
||||
}
|
||||
s << indent << "led[]" << std::endl;
|
||||
for (size_t i = 0; i < v.led.size(); ++i)
|
||||
{
|
||||
s << indent << " led[" << i << "]: ";
|
||||
s << std::endl;
|
||||
s << indent;
|
||||
Printer< ::unitree_legged_msgs::LED_<ContainerAllocator> >::stream(s, indent + " ", v.led[i]);
|
||||
}
|
||||
s << indent << "wirelessRemote[]" << std::endl;
|
||||
for (size_t i = 0; i < v.wirelessRemote.size(); ++i)
|
||||
{
|
||||
s << indent << " wirelessRemote[" << i << "]: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.wirelessRemote[i]);
|
||||
}
|
||||
s << indent << "reserve: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.reserve);
|
||||
s << indent << "crc: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.crc);
|
||||
s << indent << "ff[]" << std::endl;
|
||||
for (size_t i = 0; i < v.ff.size(); ++i)
|
||||
{
|
||||
s << indent << " ff[" << i << "]: ";
|
||||
s << std::endl;
|
||||
s << indent;
|
||||
Printer< ::unitree_legged_msgs::Cartesian_<ContainerAllocator> >::stream(s, indent + " ", v.ff[i]);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace message_operations
|
||||
} // namespace ros
|
||||
|
||||
#endif // UNITREE_LEGGED_MSGS_MESSAGE_LOWCMD_H
|
@ -1,247 +0,0 @@
|
||||
// Generated by gencpp from file unitree_legged_msgs/MotorCmd.msg
|
||||
// DO NOT EDIT!
|
||||
|
||||
|
||||
#ifndef UNITREE_LEGGED_MSGS_MESSAGE_MOTORCMD_H
|
||||
#define UNITREE_LEGGED_MSGS_MESSAGE_MOTORCMD_H
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
#include <ros/types.h>
|
||||
#include <ros/serialization.h>
|
||||
#include <ros/builtin_message_traits.h>
|
||||
#include <ros/message_operations.h>
|
||||
|
||||
|
||||
namespace unitree_legged_msgs
|
||||
{
|
||||
template <class ContainerAllocator>
|
||||
struct MotorCmd_
|
||||
{
|
||||
typedef MotorCmd_<ContainerAllocator> Type;
|
||||
|
||||
MotorCmd_()
|
||||
: mode(0)
|
||||
, q(0.0)
|
||||
, dq(0.0)
|
||||
, tau(0.0)
|
||||
, Kp(0.0)
|
||||
, Kd(0.0)
|
||||
, reserve() {
|
||||
reserve.assign(0);
|
||||
}
|
||||
MotorCmd_(const ContainerAllocator& _alloc)
|
||||
: mode(0)
|
||||
, q(0.0)
|
||||
, dq(0.0)
|
||||
, tau(0.0)
|
||||
, Kp(0.0)
|
||||
, Kd(0.0)
|
||||
, reserve() {
|
||||
(void)_alloc;
|
||||
reserve.assign(0);
|
||||
}
|
||||
|
||||
|
||||
|
||||
typedef uint8_t _mode_type;
|
||||
_mode_type mode;
|
||||
|
||||
typedef float _q_type;
|
||||
_q_type q;
|
||||
|
||||
typedef float _dq_type;
|
||||
_dq_type dq;
|
||||
|
||||
typedef float _tau_type;
|
||||
_tau_type tau;
|
||||
|
||||
typedef float _Kp_type;
|
||||
_Kp_type Kp;
|
||||
|
||||
typedef float _Kd_type;
|
||||
_Kd_type Kd;
|
||||
|
||||
typedef boost::array<uint32_t, 3> _reserve_type;
|
||||
_reserve_type reserve;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> > Ptr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> const> ConstPtr;
|
||||
|
||||
}; // struct MotorCmd_
|
||||
|
||||
typedef ::unitree_legged_msgs::MotorCmd_<std::allocator<void> > MotorCmd;
|
||||
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::MotorCmd > MotorCmdPtr;
|
||||
typedef boost::shared_ptr< ::unitree_legged_msgs::MotorCmd const> MotorCmdConstPtr;
|
||||
|
||||
// constants requiring out of line definition
|
||||
|
||||
|
||||
|
||||
template<typename ContainerAllocator>
|
||||
std::ostream& operator<<(std::ostream& s, const ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> & v)
|
||||
{
|
||||
ros::message_operations::Printer< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >::stream(s, "", v);
|
||||
return s;
|
||||
}
|
||||
|
||||
} // namespace unitree_legged_msgs
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_traits
|
||||
{
|
||||
|
||||
|
||||
|
||||
// BOOLTRAITS {'IsFixedSize': True, 'IsMessage': True, 'HasHeader': False}
|
||||
// {'sensor_msgs': ['/opt/ros/kinetic/share/sensor_msgs/cmake/../msg'], 'geometry_msgs': ['/opt/ros/kinetic/share/geometry_msgs/cmake/../msg'], 'std_msgs': ['/opt/ros/kinetic/share/std_msgs/cmake/../msg'], 'unitree_legged_msgs': ['/home/chinhan/Joint_Rescue_development/src/unitree_ros_to_real-3.2.1/unitree_legged_msgs/msg']}
|
||||
|
||||
// !!!!!!!!!!! ['__class__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__getattribute__', '__hash__', '__init__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_parsed_fields', 'constants', 'fields', 'full_name', 'has_header', 'header_present', 'names', 'package', 'parsed_fields', 'short_name', 'text', 'types']
|
||||
|
||||
|
||||
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsFixedSize< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct IsMessage< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> const>
|
||||
: TrueType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
template <class ContainerAllocator>
|
||||
struct HasHeader< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> const>
|
||||
: FalseType
|
||||
{ };
|
||||
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct MD5Sum< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "bbb3b7d91319c3a1b99055f0149ba221";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::MotorCmd_<ContainerAllocator>&) { return value(); }
|
||||
static const uint64_t static_value1 = 0xbbb3b7d91319c3a1ULL;
|
||||
static const uint64_t static_value2 = 0xb99055f0149ba221ULL;
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct DataType< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "unitree_legged_msgs/MotorCmd";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::MotorCmd_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Definition< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >
|
||||
{
|
||||
static const char* value()
|
||||
{
|
||||
return "uint8 mode # motor target mode\n\
|
||||
float32 q # motor target position\n\
|
||||
float32 dq # motor target velocity\n\
|
||||
float32 tau # motor target torque\n\
|
||||
float32 Kp # motor spring stiffness coefficient\n\
|
||||
float32 Kd # motor damper coefficient\n\
|
||||
uint32[3] reserve # motor target torque\n\
|
||||
";
|
||||
}
|
||||
|
||||
static const char* value(const ::unitree_legged_msgs::MotorCmd_<ContainerAllocator>&) { return value(); }
|
||||
};
|
||||
|
||||
} // namespace message_traits
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace serialization
|
||||
{
|
||||
|
||||
template<class ContainerAllocator> struct Serializer< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
|
||||
{
|
||||
stream.next(m.mode);
|
||||
stream.next(m.q);
|
||||
stream.next(m.dq);
|
||||
stream.next(m.tau);
|
||||
stream.next(m.Kp);
|
||||
stream.next(m.Kd);
|
||||
stream.next(m.reserve);
|
||||
}
|
||||
|
||||
ROS_DECLARE_ALLINONE_SERIALIZER
|
||||
}; // struct MotorCmd_
|
||||
|
||||
} // namespace serialization
|
||||
} // namespace ros
|
||||
|
||||
namespace ros
|
||||
{
|
||||
namespace message_operations
|
||||
{
|
||||
|
||||
template<class ContainerAllocator>
|
||||
struct Printer< ::unitree_legged_msgs::MotorCmd_<ContainerAllocator> >
|
||||
{
|
||||
template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::unitree_legged_msgs::MotorCmd_<ContainerAllocator>& v)
|
||||
{
|
||||
s << indent << "mode: ";
|
||||
Printer<uint8_t>::stream(s, indent + " ", v.mode);
|
||||
s << indent << "q: ";
|
||||
Printer<float>::stream(s, indent + " ", v.q);
|
||||
s << indent << "dq: ";
|
||||
Printer<float>::stream(s, indent + " ", v.dq);
|
||||
s << indent << "tau: ";
|
||||
Printer<float>::stream(s, indent + " ", v.tau);
|
||||
s << indent << "Kp: ";
|
||||
Printer<float>::stream(s, indent + " ", v.Kp);
|
||||
s << indent << "Kd: ";
|
||||
Printer<float>::stream(s, indent + " ", v.Kd);
|
||||
s << indent << "reserve[]" << std::endl;
|
||||
for (size_t i = 0; i < v.reserve.size(); ++i)
|
||||
{
|
||||
s << indent << " reserve[" << i << "]: ";
|
||||
Printer<uint32_t>::stream(s, indent + " ", v.reserve[i]);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace message_operations
|
||||
} // namespace ros
|
||||
|
||||
#endif // UNITREE_LEGGED_MSGS_MESSAGE_MOTORCMD_H
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,8 +0,0 @@
|
||||
prefix=/home/chinhan/Joint_Rescue_development/devel
|
||||
|
||||
Name: librviz_tutorial
|
||||
Description: Description of librviz_tutorial
|
||||
Version: 0.11.0
|
||||
Cflags:
|
||||
Libs: -L${prefix}/lib
|
||||
Requires:
|
@ -1,8 +0,0 @@
|
||||
prefix=/home/chinhan/Joint_Rescue_development/devel
|
||||
|
||||
Name: qt_app
|
||||
Description: Description of qt_app
|
||||
Version: 0.0.1
|
||||
Cflags:
|
||||
Libs: -L${prefix}/lib
|
||||
Requires:
|
@ -1,8 +0,0 @@
|
||||
prefix=/home/chinhan/Joint_Rescue_development/devel
|
||||
|
||||
Name: qt_app_ros
|
||||
Description: Description of qt_app_ros
|
||||
Version: 0.0.1
|
||||
Cflags:
|
||||
Libs: -L${prefix}/lib
|
||||
Requires: roscpp std_msgs message_generation message_runtime
|
@ -1,8 +0,0 @@
|
||||
prefix=/home/chinhan/Joint_Rescue_development/devel
|
||||
|
||||
Name: udp_port
|
||||
Description: Description of udp_port
|
||||
Version: 0.0.1
|
||||
Cflags:
|
||||
Libs: -L${prefix}/lib
|
||||
Requires: roscpp std_msgs message_generation message_runtime
|
@ -1,8 +0,0 @@
|
||||
prefix=/home/chinhan/Joint_Rescue_development/devel
|
||||
|
||||
Name: unitree_legged_msgs
|
||||
Description: Description of unitree_legged_msgs
|
||||
Version: 0.0.0
|
||||
Cflags: -I/home/chinhan/Joint_Rescue_development/devel/include
|
||||
Libs: -L${prefix}/lib
|
||||
Requires: message_runtime std_msgs geometry_msgs sensor_msgs
|
@ -1,8 +0,0 @@
|
||||
prefix=/home/chinhan/Joint_Rescue_development/devel
|
||||
|
||||
Name: unitree_legged_real
|
||||
Description: Description of unitree_legged_real
|
||||
Version: 0.0.0
|
||||
Cflags:
|
||||
Libs: -L${prefix}/lib
|
||||
Requires:
|
@ -1,8 +0,0 @@
|
||||
prefix=/home/chinhan/Joint_Rescue_development/devel
|
||||
|
||||
Name: unitree_ros
|
||||
Description: Description of unitree_ros
|
||||
Version: 0.0.1
|
||||
Cflags:
|
||||
Libs: -L${prefix}/lib
|
||||
Requires: roscpp std_msgs message_generation message_runtime
|
@ -1,120 +0,0 @@
|
||||
# This Python file uses the following encoding: utf-8
|
||||
"""autogenerated by genpy from unitree_legged_msgs/Cartesian.msg. Do not edit."""
|
||||
import codecs
|
||||
import sys
|
||||
python3 = True if sys.hexversion > 0x03000000 else False
|
||||
import genpy
|
||||
import struct
|
||||
|
||||
|
||||
class Cartesian(genpy.Message):
|
||||
_md5sum = "cc153912f1453b708d221682bc23d9ac"
|
||||
_type = "unitree_legged_msgs/Cartesian"
|
||||
_has_header = False # flag to mark the presence of a Header object
|
||||
_full_text = """float32 x
|
||||
float32 y
|
||||
float32 z"""
|
||||
__slots__ = ['x','y','z']
|
||||
_slot_types = ['float32','float32','float32']
|
||||
|
||||
def __init__(self, *args, **kwds):
|
||||
"""
|
||||
Constructor. Any message fields that are implicitly/explicitly
|
||||
set to None will be assigned a default value. The recommend
|
||||
use is keyword arguments as this is more robust to future message
|
||||
changes. You cannot mix in-order arguments and keyword arguments.
|
||||
|
||||
The available fields are:
|
||||
x,y,z
|
||||
|
||||
:param args: complete set of field values, in .msg order
|
||||
:param kwds: use keyword arguments corresponding to message field names
|
||||
to set specific fields.
|
||||
"""
|
||||
if args or kwds:
|
||||
super(Cartesian, self).__init__(*args, **kwds)
|
||||
# message fields cannot be None, assign default values for those that are
|
||||
if self.x is None:
|
||||
self.x = 0.
|
||||
if self.y is None:
|
||||
self.y = 0.
|
||||
if self.z is None:
|
||||
self.z = 0.
|
||||
else:
|
||||
self.x = 0.
|
||||
self.y = 0.
|
||||
self.z = 0.
|
||||
|
||||
def _get_types(self):
|
||||
"""
|
||||
internal API method
|
||||
"""
|
||||
return self._slot_types
|
||||
|
||||
def serialize(self, buff):
|
||||
"""
|
||||
serialize message into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize(self, str):
|
||||
"""
|
||||
unpack serialized message in str into this message instance
|
||||
:param str: byte array of serialized message, ``str``
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
|
||||
def serialize_numpy(self, buff, numpy):
|
||||
"""
|
||||
serialize message with numpy array types into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize_numpy(self, str, numpy):
|
||||
"""
|
||||
unpack serialized message in str into this message instance using numpy for array types
|
||||
:param str: byte array of serialized message, ``str``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
_struct_I = genpy.struct_I
|
||||
def _get_struct_I():
|
||||
global _struct_I
|
||||
return _struct_I
|
||||
_struct_3f = None
|
||||
def _get_struct_3f():
|
||||
global _struct_3f
|
||||
if _struct_3f is None:
|
||||
_struct_3f = struct.Struct("<3f")
|
||||
return _struct_3f
|
@ -1,292 +0,0 @@
|
||||
# This Python file uses the following encoding: utf-8
|
||||
"""autogenerated by genpy from unitree_legged_msgs/HighCmd.msg. Do not edit."""
|
||||
import codecs
|
||||
import sys
|
||||
python3 = True if sys.hexversion > 0x03000000 else False
|
||||
import genpy
|
||||
import struct
|
||||
|
||||
import unitree_legged_msgs.msg
|
||||
|
||||
class HighCmd(genpy.Message):
|
||||
_md5sum = "1a655499a3f64905db59ceed65ca774a"
|
||||
_type = "unitree_legged_msgs/HighCmd"
|
||||
_has_header = False # flag to mark the presence of a Header object
|
||||
_full_text = """uint8 levelFlag
|
||||
uint16 commVersion # Old version Aliengo does not have
|
||||
uint16 robotID # Old version Aliengo does not have
|
||||
uint32 SN # Old version Aliengo does not have
|
||||
uint8 bandWidth # Old version Aliengo does not have
|
||||
uint8 mode
|
||||
float32 forwardSpeed
|
||||
float32 sideSpeed
|
||||
float32 rotateSpeed
|
||||
float32 bodyHeight
|
||||
float32 footRaiseHeight
|
||||
float32 yaw
|
||||
float32 pitch
|
||||
float32 roll
|
||||
LED[4] led
|
||||
uint8[40] wirelessRemote
|
||||
uint8[40] AppRemote # Old version Aliengo does not have
|
||||
uint32 reserve # Old version Aliengo does not have
|
||||
int32 crc
|
||||
================================================================================
|
||||
MSG: unitree_legged_msgs/LED
|
||||
uint8 r
|
||||
uint8 g
|
||||
uint8 b"""
|
||||
__slots__ = ['levelFlag','commVersion','robotID','SN','bandWidth','mode','forwardSpeed','sideSpeed','rotateSpeed','bodyHeight','footRaiseHeight','yaw','pitch','roll','led','wirelessRemote','AppRemote','reserve','crc']
|
||||
_slot_types = ['uint8','uint16','uint16','uint32','uint8','uint8','float32','float32','float32','float32','float32','float32','float32','float32','unitree_legged_msgs/LED[4]','uint8[40]','uint8[40]','uint32','int32']
|
||||
|
||||
def __init__(self, *args, **kwds):
|
||||
"""
|
||||
Constructor. Any message fields that are implicitly/explicitly
|
||||
set to None will be assigned a default value. The recommend
|
||||
use is keyword arguments as this is more robust to future message
|
||||
changes. You cannot mix in-order arguments and keyword arguments.
|
||||
|
||||
The available fields are:
|
||||
levelFlag,commVersion,robotID,SN,bandWidth,mode,forwardSpeed,sideSpeed,rotateSpeed,bodyHeight,footRaiseHeight,yaw,pitch,roll,led,wirelessRemote,AppRemote,reserve,crc
|
||||
|
||||
:param args: complete set of field values, in .msg order
|
||||
:param kwds: use keyword arguments corresponding to message field names
|
||||
to set specific fields.
|
||||
"""
|
||||
if args or kwds:
|
||||
super(HighCmd, self).__init__(*args, **kwds)
|
||||
# message fields cannot be None, assign default values for those that are
|
||||
if self.levelFlag is None:
|
||||
self.levelFlag = 0
|
||||
if self.commVersion is None:
|
||||
self.commVersion = 0
|
||||
if self.robotID is None:
|
||||
self.robotID = 0
|
||||
if self.SN is None:
|
||||
self.SN = 0
|
||||
if self.bandWidth is None:
|
||||
self.bandWidth = 0
|
||||
if self.mode is None:
|
||||
self.mode = 0
|
||||
if self.forwardSpeed is None:
|
||||
self.forwardSpeed = 0.
|
||||
if self.sideSpeed is None:
|
||||
self.sideSpeed = 0.
|
||||
if self.rotateSpeed is None:
|
||||
self.rotateSpeed = 0.
|
||||
if self.bodyHeight is None:
|
||||
self.bodyHeight = 0.
|
||||
if self.footRaiseHeight is None:
|
||||
self.footRaiseHeight = 0.
|
||||
if self.yaw is None:
|
||||
self.yaw = 0.
|
||||
if self.pitch is None:
|
||||
self.pitch = 0.
|
||||
if self.roll is None:
|
||||
self.roll = 0.
|
||||
if self.led is None:
|
||||
self.led = [unitree_legged_msgs.msg.LED() for _ in range(4)]
|
||||
if self.wirelessRemote is None:
|
||||
self.wirelessRemote = b'\0'*40
|
||||
if self.AppRemote is None:
|
||||
self.AppRemote = b'\0'*40
|
||||
if self.reserve is None:
|
||||
self.reserve = 0
|
||||
if self.crc is None:
|
||||
self.crc = 0
|
||||
else:
|
||||
self.levelFlag = 0
|
||||
self.commVersion = 0
|
||||
self.robotID = 0
|
||||
self.SN = 0
|
||||
self.bandWidth = 0
|
||||
self.mode = 0
|
||||
self.forwardSpeed = 0.
|
||||
self.sideSpeed = 0.
|
||||
self.rotateSpeed = 0.
|
||||
self.bodyHeight = 0.
|
||||
self.footRaiseHeight = 0.
|
||||
self.yaw = 0.
|
||||
self.pitch = 0.
|
||||
self.roll = 0.
|
||||
self.led = [unitree_legged_msgs.msg.LED() for _ in range(4)]
|
||||
self.wirelessRemote = b'\0'*40
|
||||
self.AppRemote = b'\0'*40
|
||||
self.reserve = 0
|
||||
self.crc = 0
|
||||
|
||||
def _get_types(self):
|
||||
"""
|
||||
internal API method
|
||||
"""
|
||||
return self._slot_types
|
||||
|
||||
def serialize(self, buff):
|
||||
"""
|
||||
serialize message into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_B2HI2B8f().pack(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth, _x.mode, _x.forwardSpeed, _x.sideSpeed, _x.rotateSpeed, _x.bodyHeight, _x.footRaiseHeight, _x.yaw, _x.pitch, _x.roll))
|
||||
if len(self.led) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.led), 'self.led')))
|
||||
for val1 in self.led:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3B().pack(_x.r, _x.g, _x.b))
|
||||
_x = self.wirelessRemote
|
||||
# - if encoded as a list instead, serialize as bytes instead of string
|
||||
if type(_x) in [list, tuple]:
|
||||
buff.write(_get_struct_40B().pack(*_x))
|
||||
else:
|
||||
buff.write(_get_struct_40s().pack(_x))
|
||||
_x = self.AppRemote
|
||||
# - if encoded as a list instead, serialize as bytes instead of string
|
||||
if type(_x) in [list, tuple]:
|
||||
buff.write(_get_struct_40B().pack(*_x))
|
||||
else:
|
||||
buff.write(_get_struct_40s().pack(_x))
|
||||
_x = self
|
||||
buff.write(_get_struct_Ii().pack(_x.reserve, _x.crc))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize(self, str):
|
||||
"""
|
||||
unpack serialized message in str into this message instance
|
||||
:param str: byte array of serialized message, ``str``
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
if self.led is None:
|
||||
self.led = None
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 43
|
||||
(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth, _x.mode, _x.forwardSpeed, _x.sideSpeed, _x.rotateSpeed, _x.bodyHeight, _x.footRaiseHeight, _x.yaw, _x.pitch, _x.roll,) = _get_struct_B2HI2B8f().unpack(str[start:end])
|
||||
self.led = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.LED()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 3
|
||||
(_x.r, _x.g, _x.b,) = _get_struct_3B().unpack(str[start:end])
|
||||
self.led.append(val1)
|
||||
start = end
|
||||
end += 40
|
||||
self.wirelessRemote = str[start:end]
|
||||
start = end
|
||||
end += 40
|
||||
self.AppRemote = str[start:end]
|
||||
_x = self
|
||||
start = end
|
||||
end += 8
|
||||
(_x.reserve, _x.crc,) = _get_struct_Ii().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
|
||||
def serialize_numpy(self, buff, numpy):
|
||||
"""
|
||||
serialize message with numpy array types into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_B2HI2B8f().pack(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth, _x.mode, _x.forwardSpeed, _x.sideSpeed, _x.rotateSpeed, _x.bodyHeight, _x.footRaiseHeight, _x.yaw, _x.pitch, _x.roll))
|
||||
if len(self.led) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.led), 'self.led')))
|
||||
for val1 in self.led:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3B().pack(_x.r, _x.g, _x.b))
|
||||
_x = self.wirelessRemote
|
||||
# - if encoded as a list instead, serialize as bytes instead of string
|
||||
if type(_x) in [list, tuple]:
|
||||
buff.write(_get_struct_40B().pack(*_x))
|
||||
else:
|
||||
buff.write(_get_struct_40s().pack(_x))
|
||||
_x = self.AppRemote
|
||||
# - if encoded as a list instead, serialize as bytes instead of string
|
||||
if type(_x) in [list, tuple]:
|
||||
buff.write(_get_struct_40B().pack(*_x))
|
||||
else:
|
||||
buff.write(_get_struct_40s().pack(_x))
|
||||
_x = self
|
||||
buff.write(_get_struct_Ii().pack(_x.reserve, _x.crc))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize_numpy(self, str, numpy):
|
||||
"""
|
||||
unpack serialized message in str into this message instance using numpy for array types
|
||||
:param str: byte array of serialized message, ``str``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
if self.led is None:
|
||||
self.led = None
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 43
|
||||
(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth, _x.mode, _x.forwardSpeed, _x.sideSpeed, _x.rotateSpeed, _x.bodyHeight, _x.footRaiseHeight, _x.yaw, _x.pitch, _x.roll,) = _get_struct_B2HI2B8f().unpack(str[start:end])
|
||||
self.led = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.LED()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 3
|
||||
(_x.r, _x.g, _x.b,) = _get_struct_3B().unpack(str[start:end])
|
||||
self.led.append(val1)
|
||||
start = end
|
||||
end += 40
|
||||
self.wirelessRemote = str[start:end]
|
||||
start = end
|
||||
end += 40
|
||||
self.AppRemote = str[start:end]
|
||||
_x = self
|
||||
start = end
|
||||
end += 8
|
||||
(_x.reserve, _x.crc,) = _get_struct_Ii().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
_struct_I = genpy.struct_I
|
||||
def _get_struct_I():
|
||||
global _struct_I
|
||||
return _struct_I
|
||||
_struct_3B = None
|
||||
def _get_struct_3B():
|
||||
global _struct_3B
|
||||
if _struct_3B is None:
|
||||
_struct_3B = struct.Struct("<3B")
|
||||
return _struct_3B
|
||||
_struct_40B = None
|
||||
def _get_struct_40B():
|
||||
global _struct_40B
|
||||
if _struct_40B is None:
|
||||
_struct_40B = struct.Struct("<40B")
|
||||
return _struct_40B
|
||||
_struct_40s = None
|
||||
def _get_struct_40s():
|
||||
global _struct_40s
|
||||
if _struct_40s is None:
|
||||
_struct_40s = struct.Struct("<40s")
|
||||
return _struct_40s
|
||||
_struct_B2HI2B8f = None
|
||||
def _get_struct_B2HI2B8f():
|
||||
global _struct_B2HI2B8f
|
||||
if _struct_B2HI2B8f is None:
|
||||
_struct_B2HI2B8f = struct.Struct("<B2HI2B8f")
|
||||
return _struct_B2HI2B8f
|
||||
_struct_Ii = None
|
||||
def _get_struct_Ii():
|
||||
global _struct_Ii
|
||||
if _struct_Ii is None:
|
||||
_struct_Ii = struct.Struct("<Ii")
|
||||
return _struct_Ii
|
@ -1,460 +0,0 @@
|
||||
# This Python file uses the following encoding: utf-8
|
||||
"""autogenerated by genpy from unitree_legged_msgs/HighState.msg. Do not edit."""
|
||||
import codecs
|
||||
import sys
|
||||
python3 = True if sys.hexversion > 0x03000000 else False
|
||||
import genpy
|
||||
import struct
|
||||
|
||||
import unitree_legged_msgs.msg
|
||||
|
||||
class HighState(genpy.Message):
|
||||
_md5sum = "a12e8b22df896c82203810ec6d521dad"
|
||||
_type = "unitree_legged_msgs/HighState"
|
||||
_has_header = False # flag to mark the presence of a Header object
|
||||
_full_text = """uint8 levelFlag
|
||||
uint16 commVersion # Old version Aliengo does not have
|
||||
uint16 robotID # Old version Aliengo does not have
|
||||
uint32 SN # Old version Aliengo does not have
|
||||
uint8 bandWidth # Old version Aliengo does not have
|
||||
uint8 mode
|
||||
IMU imu
|
||||
float32 forwardSpeed
|
||||
float32 sideSpeed
|
||||
float32 rotateSpeed
|
||||
float32 bodyHeight
|
||||
float32 updownSpeed
|
||||
float32 forwardPosition # (will be float type next version) # Old version Aliengo is different
|
||||
float32 sidePosition # (will be float type next version) # Old version Aliengo is different
|
||||
Cartesian[4] footPosition2Body
|
||||
Cartesian[4] footSpeed2Body
|
||||
int16[4] footForce # Old version Aliengo is different
|
||||
int16[4] footForceEst # Old version Aliengo does not have
|
||||
uint32 tick
|
||||
uint8[40] wirelessRemote
|
||||
uint32 reserve # Old version Aliengo does not have
|
||||
uint32 crc
|
||||
|
||||
# Under are not defined in SDK yet. # Old version Aliengo does not have
|
||||
Cartesian[4] eeForce # It's a 1-DOF force in real robot, but 3-DOF is better for visualization.
|
||||
float32[12] jointP # for visualization
|
||||
================================================================================
|
||||
MSG: unitree_legged_msgs/IMU
|
||||
float32[4] quaternion
|
||||
float32[3] gyroscope
|
||||
float32[3] accelerometer
|
||||
int8 temperature
|
||||
================================================================================
|
||||
MSG: unitree_legged_msgs/Cartesian
|
||||
float32 x
|
||||
float32 y
|
||||
float32 z"""
|
||||
__slots__ = ['levelFlag','commVersion','robotID','SN','bandWidth','mode','imu','forwardSpeed','sideSpeed','rotateSpeed','bodyHeight','updownSpeed','forwardPosition','sidePosition','footPosition2Body','footSpeed2Body','footForce','footForceEst','tick','wirelessRemote','reserve','crc','eeForce','jointP']
|
||||
_slot_types = ['uint8','uint16','uint16','uint32','uint8','uint8','unitree_legged_msgs/IMU','float32','float32','float32','float32','float32','float32','float32','unitree_legged_msgs/Cartesian[4]','unitree_legged_msgs/Cartesian[4]','int16[4]','int16[4]','uint32','uint8[40]','uint32','uint32','unitree_legged_msgs/Cartesian[4]','float32[12]']
|
||||
|
||||
def __init__(self, *args, **kwds):
|
||||
"""
|
||||
Constructor. Any message fields that are implicitly/explicitly
|
||||
set to None will be assigned a default value. The recommend
|
||||
use is keyword arguments as this is more robust to future message
|
||||
changes. You cannot mix in-order arguments and keyword arguments.
|
||||
|
||||
The available fields are:
|
||||
levelFlag,commVersion,robotID,SN,bandWidth,mode,imu,forwardSpeed,sideSpeed,rotateSpeed,bodyHeight,updownSpeed,forwardPosition,sidePosition,footPosition2Body,footSpeed2Body,footForce,footForceEst,tick,wirelessRemote,reserve,crc,eeForce,jointP
|
||||
|
||||
:param args: complete set of field values, in .msg order
|
||||
:param kwds: use keyword arguments corresponding to message field names
|
||||
to set specific fields.
|
||||
"""
|
||||
if args or kwds:
|
||||
super(HighState, self).__init__(*args, **kwds)
|
||||
# message fields cannot be None, assign default values for those that are
|
||||
if self.levelFlag is None:
|
||||
self.levelFlag = 0
|
||||
if self.commVersion is None:
|
||||
self.commVersion = 0
|
||||
if self.robotID is None:
|
||||
self.robotID = 0
|
||||
if self.SN is None:
|
||||
self.SN = 0
|
||||
if self.bandWidth is None:
|
||||
self.bandWidth = 0
|
||||
if self.mode is None:
|
||||
self.mode = 0
|
||||
if self.imu is None:
|
||||
self.imu = unitree_legged_msgs.msg.IMU()
|
||||
if self.forwardSpeed is None:
|
||||
self.forwardSpeed = 0.
|
||||
if self.sideSpeed is None:
|
||||
self.sideSpeed = 0.
|
||||
if self.rotateSpeed is None:
|
||||
self.rotateSpeed = 0.
|
||||
if self.bodyHeight is None:
|
||||
self.bodyHeight = 0.
|
||||
if self.updownSpeed is None:
|
||||
self.updownSpeed = 0.
|
||||
if self.forwardPosition is None:
|
||||
self.forwardPosition = 0.
|
||||
if self.sidePosition is None:
|
||||
self.sidePosition = 0.
|
||||
if self.footPosition2Body is None:
|
||||
self.footPosition2Body = [unitree_legged_msgs.msg.Cartesian() for _ in range(4)]
|
||||
if self.footSpeed2Body is None:
|
||||
self.footSpeed2Body = [unitree_legged_msgs.msg.Cartesian() for _ in range(4)]
|
||||
if self.footForce is None:
|
||||
self.footForce = [0] * 4
|
||||
if self.footForceEst is None:
|
||||
self.footForceEst = [0] * 4
|
||||
if self.tick is None:
|
||||
self.tick = 0
|
||||
if self.wirelessRemote is None:
|
||||
self.wirelessRemote = b'\0'*40
|
||||
if self.reserve is None:
|
||||
self.reserve = 0
|
||||
if self.crc is None:
|
||||
self.crc = 0
|
||||
if self.eeForce is None:
|
||||
self.eeForce = [unitree_legged_msgs.msg.Cartesian() for _ in range(4)]
|
||||
if self.jointP is None:
|
||||
self.jointP = [0.] * 12
|
||||
else:
|
||||
self.levelFlag = 0
|
||||
self.commVersion = 0
|
||||
self.robotID = 0
|
||||
self.SN = 0
|
||||
self.bandWidth = 0
|
||||
self.mode = 0
|
||||
self.imu = unitree_legged_msgs.msg.IMU()
|
||||
self.forwardSpeed = 0.
|
||||
self.sideSpeed = 0.
|
||||
self.rotateSpeed = 0.
|
||||
self.bodyHeight = 0.
|
||||
self.updownSpeed = 0.
|
||||
self.forwardPosition = 0.
|
||||
self.sidePosition = 0.
|
||||
self.footPosition2Body = [unitree_legged_msgs.msg.Cartesian() for _ in range(4)]
|
||||
self.footSpeed2Body = [unitree_legged_msgs.msg.Cartesian() for _ in range(4)]
|
||||
self.footForce = [0] * 4
|
||||
self.footForceEst = [0] * 4
|
||||
self.tick = 0
|
||||
self.wirelessRemote = b'\0'*40
|
||||
self.reserve = 0
|
||||
self.crc = 0
|
||||
self.eeForce = [unitree_legged_msgs.msg.Cartesian() for _ in range(4)]
|
||||
self.jointP = [0.] * 12
|
||||
|
||||
def _get_types(self):
|
||||
"""
|
||||
internal API method
|
||||
"""
|
||||
return self._slot_types
|
||||
|
||||
def serialize(self, buff):
|
||||
"""
|
||||
serialize message into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_B2HI2B().pack(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth, _x.mode))
|
||||
buff.write(_get_struct_4f().pack(*self.imu.quaternion))
|
||||
buff.write(_get_struct_3f().pack(*self.imu.gyroscope))
|
||||
buff.write(_get_struct_3f().pack(*self.imu.accelerometer))
|
||||
_x = self
|
||||
buff.write(_get_struct_b7f().pack(_x.imu.temperature, _x.forwardSpeed, _x.sideSpeed, _x.rotateSpeed, _x.bodyHeight, _x.updownSpeed, _x.forwardPosition, _x.sidePosition))
|
||||
if len(self.footPosition2Body) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.footPosition2Body), 'self.footPosition2Body')))
|
||||
for val1 in self.footPosition2Body:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
if len(self.footSpeed2Body) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.footSpeed2Body), 'self.footSpeed2Body')))
|
||||
for val1 in self.footSpeed2Body:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
buff.write(_get_struct_4h().pack(*self.footForce))
|
||||
buff.write(_get_struct_4h().pack(*self.footForceEst))
|
||||
_x = self.tick
|
||||
buff.write(_get_struct_I().pack(_x))
|
||||
_x = self.wirelessRemote
|
||||
# - if encoded as a list instead, serialize as bytes instead of string
|
||||
if type(_x) in [list, tuple]:
|
||||
buff.write(_get_struct_40B().pack(*_x))
|
||||
else:
|
||||
buff.write(_get_struct_40s().pack(_x))
|
||||
_x = self
|
||||
buff.write(_get_struct_2I().pack(_x.reserve, _x.crc))
|
||||
if len(self.eeForce) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.eeForce), 'self.eeForce')))
|
||||
for val1 in self.eeForce:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
buff.write(_get_struct_12f().pack(*self.jointP))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize(self, str):
|
||||
"""
|
||||
unpack serialized message in str into this message instance
|
||||
:param str: byte array of serialized message, ``str``
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
if self.imu is None:
|
||||
self.imu = unitree_legged_msgs.msg.IMU()
|
||||
if self.footPosition2Body is None:
|
||||
self.footPosition2Body = None
|
||||
if self.footSpeed2Body is None:
|
||||
self.footSpeed2Body = None
|
||||
if self.eeForce is None:
|
||||
self.eeForce = None
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 11
|
||||
(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth, _x.mode,) = _get_struct_B2HI2B().unpack(str[start:end])
|
||||
start = end
|
||||
end += 16
|
||||
self.imu.quaternion = _get_struct_4f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 12
|
||||
self.imu.gyroscope = _get_struct_3f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 12
|
||||
self.imu.accelerometer = _get_struct_3f().unpack(str[start:end])
|
||||
_x = self
|
||||
start = end
|
||||
end += 29
|
||||
(_x.imu.temperature, _x.forwardSpeed, _x.sideSpeed, _x.rotateSpeed, _x.bodyHeight, _x.updownSpeed, _x.forwardPosition, _x.sidePosition,) = _get_struct_b7f().unpack(str[start:end])
|
||||
self.footPosition2Body = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.Cartesian()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
self.footPosition2Body.append(val1)
|
||||
self.footSpeed2Body = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.Cartesian()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
self.footSpeed2Body.append(val1)
|
||||
start = end
|
||||
end += 8
|
||||
self.footForce = _get_struct_4h().unpack(str[start:end])
|
||||
start = end
|
||||
end += 8
|
||||
self.footForceEst = _get_struct_4h().unpack(str[start:end])
|
||||
start = end
|
||||
end += 4
|
||||
(self.tick,) = _get_struct_I().unpack(str[start:end])
|
||||
start = end
|
||||
end += 40
|
||||
self.wirelessRemote = str[start:end]
|
||||
_x = self
|
||||
start = end
|
||||
end += 8
|
||||
(_x.reserve, _x.crc,) = _get_struct_2I().unpack(str[start:end])
|
||||
self.eeForce = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.Cartesian()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
self.eeForce.append(val1)
|
||||
start = end
|
||||
end += 48
|
||||
self.jointP = _get_struct_12f().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
|
||||
def serialize_numpy(self, buff, numpy):
|
||||
"""
|
||||
serialize message with numpy array types into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_B2HI2B().pack(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth, _x.mode))
|
||||
buff.write(self.imu.quaternion.tostring())
|
||||
buff.write(self.imu.gyroscope.tostring())
|
||||
buff.write(self.imu.accelerometer.tostring())
|
||||
_x = self
|
||||
buff.write(_get_struct_b7f().pack(_x.imu.temperature, _x.forwardSpeed, _x.sideSpeed, _x.rotateSpeed, _x.bodyHeight, _x.updownSpeed, _x.forwardPosition, _x.sidePosition))
|
||||
if len(self.footPosition2Body) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.footPosition2Body), 'self.footPosition2Body')))
|
||||
for val1 in self.footPosition2Body:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
if len(self.footSpeed2Body) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.footSpeed2Body), 'self.footSpeed2Body')))
|
||||
for val1 in self.footSpeed2Body:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
buff.write(self.footForce.tostring())
|
||||
buff.write(self.footForceEst.tostring())
|
||||
_x = self.tick
|
||||
buff.write(_get_struct_I().pack(_x))
|
||||
_x = self.wirelessRemote
|
||||
# - if encoded as a list instead, serialize as bytes instead of string
|
||||
if type(_x) in [list, tuple]:
|
||||
buff.write(_get_struct_40B().pack(*_x))
|
||||
else:
|
||||
buff.write(_get_struct_40s().pack(_x))
|
||||
_x = self
|
||||
buff.write(_get_struct_2I().pack(_x.reserve, _x.crc))
|
||||
if len(self.eeForce) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.eeForce), 'self.eeForce')))
|
||||
for val1 in self.eeForce:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
buff.write(self.jointP.tostring())
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize_numpy(self, str, numpy):
|
||||
"""
|
||||
unpack serialized message in str into this message instance using numpy for array types
|
||||
:param str: byte array of serialized message, ``str``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
if self.imu is None:
|
||||
self.imu = unitree_legged_msgs.msg.IMU()
|
||||
if self.footPosition2Body is None:
|
||||
self.footPosition2Body = None
|
||||
if self.footSpeed2Body is None:
|
||||
self.footSpeed2Body = None
|
||||
if self.eeForce is None:
|
||||
self.eeForce = None
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 11
|
||||
(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth, _x.mode,) = _get_struct_B2HI2B().unpack(str[start:end])
|
||||
start = end
|
||||
end += 16
|
||||
self.imu.quaternion = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=4)
|
||||
start = end
|
||||
end += 12
|
||||
self.imu.gyroscope = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=3)
|
||||
start = end
|
||||
end += 12
|
||||
self.imu.accelerometer = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=3)
|
||||
_x = self
|
||||
start = end
|
||||
end += 29
|
||||
(_x.imu.temperature, _x.forwardSpeed, _x.sideSpeed, _x.rotateSpeed, _x.bodyHeight, _x.updownSpeed, _x.forwardPosition, _x.sidePosition,) = _get_struct_b7f().unpack(str[start:end])
|
||||
self.footPosition2Body = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.Cartesian()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
self.footPosition2Body.append(val1)
|
||||
self.footSpeed2Body = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.Cartesian()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
self.footSpeed2Body.append(val1)
|
||||
start = end
|
||||
end += 8
|
||||
self.footForce = numpy.frombuffer(str[start:end], dtype=numpy.int16, count=4)
|
||||
start = end
|
||||
end += 8
|
||||
self.footForceEst = numpy.frombuffer(str[start:end], dtype=numpy.int16, count=4)
|
||||
start = end
|
||||
end += 4
|
||||
(self.tick,) = _get_struct_I().unpack(str[start:end])
|
||||
start = end
|
||||
end += 40
|
||||
self.wirelessRemote = str[start:end]
|
||||
_x = self
|
||||
start = end
|
||||
end += 8
|
||||
(_x.reserve, _x.crc,) = _get_struct_2I().unpack(str[start:end])
|
||||
self.eeForce = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.Cartesian()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
self.eeForce.append(val1)
|
||||
start = end
|
||||
end += 48
|
||||
self.jointP = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=12)
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
_struct_I = genpy.struct_I
|
||||
def _get_struct_I():
|
||||
global _struct_I
|
||||
return _struct_I
|
||||
_struct_12f = None
|
||||
def _get_struct_12f():
|
||||
global _struct_12f
|
||||
if _struct_12f is None:
|
||||
_struct_12f = struct.Struct("<12f")
|
||||
return _struct_12f
|
||||
_struct_2I = None
|
||||
def _get_struct_2I():
|
||||
global _struct_2I
|
||||
if _struct_2I is None:
|
||||
_struct_2I = struct.Struct("<2I")
|
||||
return _struct_2I
|
||||
_struct_3f = None
|
||||
def _get_struct_3f():
|
||||
global _struct_3f
|
||||
if _struct_3f is None:
|
||||
_struct_3f = struct.Struct("<3f")
|
||||
return _struct_3f
|
||||
_struct_40B = None
|
||||
def _get_struct_40B():
|
||||
global _struct_40B
|
||||
if _struct_40B is None:
|
||||
_struct_40B = struct.Struct("<40B")
|
||||
return _struct_40B
|
||||
_struct_40s = None
|
||||
def _get_struct_40s():
|
||||
global _struct_40s
|
||||
if _struct_40s is None:
|
||||
_struct_40s = struct.Struct("<40s")
|
||||
return _struct_40s
|
||||
_struct_4f = None
|
||||
def _get_struct_4f():
|
||||
global _struct_4f
|
||||
if _struct_4f is None:
|
||||
_struct_4f = struct.Struct("<4f")
|
||||
return _struct_4f
|
||||
_struct_4h = None
|
||||
def _get_struct_4h():
|
||||
global _struct_4h
|
||||
if _struct_4h is None:
|
||||
_struct_4h = struct.Struct("<4h")
|
||||
return _struct_4h
|
||||
_struct_B2HI2B = None
|
||||
def _get_struct_B2HI2B():
|
||||
global _struct_B2HI2B
|
||||
if _struct_B2HI2B is None:
|
||||
_struct_B2HI2B = struct.Struct("<B2HI2B")
|
||||
return _struct_B2HI2B
|
||||
_struct_b7f = None
|
||||
def _get_struct_b7f():
|
||||
global _struct_b7f
|
||||
if _struct_b7f is None:
|
||||
_struct_b7f = struct.Struct("<b7f")
|
||||
return _struct_b7f
|
@ -1,158 +0,0 @@
|
||||
# This Python file uses the following encoding: utf-8
|
||||
"""autogenerated by genpy from unitree_legged_msgs/IMU.msg. Do not edit."""
|
||||
import codecs
|
||||
import sys
|
||||
python3 = True if sys.hexversion > 0x03000000 else False
|
||||
import genpy
|
||||
import struct
|
||||
|
||||
|
||||
class IMU(genpy.Message):
|
||||
_md5sum = "dd4bb4e42aa2f15aa1fb1b6a3c3752cb"
|
||||
_type = "unitree_legged_msgs/IMU"
|
||||
_has_header = False # flag to mark the presence of a Header object
|
||||
_full_text = """float32[4] quaternion
|
||||
float32[3] gyroscope
|
||||
float32[3] accelerometer
|
||||
int8 temperature"""
|
||||
__slots__ = ['quaternion','gyroscope','accelerometer','temperature']
|
||||
_slot_types = ['float32[4]','float32[3]','float32[3]','int8']
|
||||
|
||||
def __init__(self, *args, **kwds):
|
||||
"""
|
||||
Constructor. Any message fields that are implicitly/explicitly
|
||||
set to None will be assigned a default value. The recommend
|
||||
use is keyword arguments as this is more robust to future message
|
||||
changes. You cannot mix in-order arguments and keyword arguments.
|
||||
|
||||
The available fields are:
|
||||
quaternion,gyroscope,accelerometer,temperature
|
||||
|
||||
:param args: complete set of field values, in .msg order
|
||||
:param kwds: use keyword arguments corresponding to message field names
|
||||
to set specific fields.
|
||||
"""
|
||||
if args or kwds:
|
||||
super(IMU, self).__init__(*args, **kwds)
|
||||
# message fields cannot be None, assign default values for those that are
|
||||
if self.quaternion is None:
|
||||
self.quaternion = [0.] * 4
|
||||
if self.gyroscope is None:
|
||||
self.gyroscope = [0.] * 3
|
||||
if self.accelerometer is None:
|
||||
self.accelerometer = [0.] * 3
|
||||
if self.temperature is None:
|
||||
self.temperature = 0
|
||||
else:
|
||||
self.quaternion = [0.] * 4
|
||||
self.gyroscope = [0.] * 3
|
||||
self.accelerometer = [0.] * 3
|
||||
self.temperature = 0
|
||||
|
||||
def _get_types(self):
|
||||
"""
|
||||
internal API method
|
||||
"""
|
||||
return self._slot_types
|
||||
|
||||
def serialize(self, buff):
|
||||
"""
|
||||
serialize message into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
"""
|
||||
try:
|
||||
buff.write(_get_struct_4f().pack(*self.quaternion))
|
||||
buff.write(_get_struct_3f().pack(*self.gyroscope))
|
||||
buff.write(_get_struct_3f().pack(*self.accelerometer))
|
||||
_x = self.temperature
|
||||
buff.write(_get_struct_b().pack(_x))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize(self, str):
|
||||
"""
|
||||
unpack serialized message in str into this message instance
|
||||
:param str: byte array of serialized message, ``str``
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
end = 0
|
||||
start = end
|
||||
end += 16
|
||||
self.quaternion = _get_struct_4f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 12
|
||||
self.gyroscope = _get_struct_3f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 12
|
||||
self.accelerometer = _get_struct_3f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 1
|
||||
(self.temperature,) = _get_struct_b().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
|
||||
def serialize_numpy(self, buff, numpy):
|
||||
"""
|
||||
serialize message with numpy array types into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
try:
|
||||
buff.write(self.quaternion.tostring())
|
||||
buff.write(self.gyroscope.tostring())
|
||||
buff.write(self.accelerometer.tostring())
|
||||
_x = self.temperature
|
||||
buff.write(_get_struct_b().pack(_x))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize_numpy(self, str, numpy):
|
||||
"""
|
||||
unpack serialized message in str into this message instance using numpy for array types
|
||||
:param str: byte array of serialized message, ``str``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
end = 0
|
||||
start = end
|
||||
end += 16
|
||||
self.quaternion = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=4)
|
||||
start = end
|
||||
end += 12
|
||||
self.gyroscope = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=3)
|
||||
start = end
|
||||
end += 12
|
||||
self.accelerometer = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=3)
|
||||
start = end
|
||||
end += 1
|
||||
(self.temperature,) = _get_struct_b().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
_struct_I = genpy.struct_I
|
||||
def _get_struct_I():
|
||||
global _struct_I
|
||||
return _struct_I
|
||||
_struct_3f = None
|
||||
def _get_struct_3f():
|
||||
global _struct_3f
|
||||
if _struct_3f is None:
|
||||
_struct_3f = struct.Struct("<3f")
|
||||
return _struct_3f
|
||||
_struct_4f = None
|
||||
def _get_struct_4f():
|
||||
global _struct_4f
|
||||
if _struct_4f is None:
|
||||
_struct_4f = struct.Struct("<4f")
|
||||
return _struct_4f
|
||||
_struct_b = None
|
||||
def _get_struct_b():
|
||||
global _struct_b
|
||||
if _struct_b is None:
|
||||
_struct_b = struct.Struct("<b")
|
||||
return _struct_b
|
@ -1,120 +0,0 @@
|
||||
# This Python file uses the following encoding: utf-8
|
||||
"""autogenerated by genpy from unitree_legged_msgs/LED.msg. Do not edit."""
|
||||
import codecs
|
||||
import sys
|
||||
python3 = True if sys.hexversion > 0x03000000 else False
|
||||
import genpy
|
||||
import struct
|
||||
|
||||
|
||||
class LED(genpy.Message):
|
||||
_md5sum = "353891e354491c51aabe32df673fb446"
|
||||
_type = "unitree_legged_msgs/LED"
|
||||
_has_header = False # flag to mark the presence of a Header object
|
||||
_full_text = """uint8 r
|
||||
uint8 g
|
||||
uint8 b"""
|
||||
__slots__ = ['r','g','b']
|
||||
_slot_types = ['uint8','uint8','uint8']
|
||||
|
||||
def __init__(self, *args, **kwds):
|
||||
"""
|
||||
Constructor. Any message fields that are implicitly/explicitly
|
||||
set to None will be assigned a default value. The recommend
|
||||
use is keyword arguments as this is more robust to future message
|
||||
changes. You cannot mix in-order arguments and keyword arguments.
|
||||
|
||||
The available fields are:
|
||||
r,g,b
|
||||
|
||||
:param args: complete set of field values, in .msg order
|
||||
:param kwds: use keyword arguments corresponding to message field names
|
||||
to set specific fields.
|
||||
"""
|
||||
if args or kwds:
|
||||
super(LED, self).__init__(*args, **kwds)
|
||||
# message fields cannot be None, assign default values for those that are
|
||||
if self.r is None:
|
||||
self.r = 0
|
||||
if self.g is None:
|
||||
self.g = 0
|
||||
if self.b is None:
|
||||
self.b = 0
|
||||
else:
|
||||
self.r = 0
|
||||
self.g = 0
|
||||
self.b = 0
|
||||
|
||||
def _get_types(self):
|
||||
"""
|
||||
internal API method
|
||||
"""
|
||||
return self._slot_types
|
||||
|
||||
def serialize(self, buff):
|
||||
"""
|
||||
serialize message into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_3B().pack(_x.r, _x.g, _x.b))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize(self, str):
|
||||
"""
|
||||
unpack serialized message in str into this message instance
|
||||
:param str: byte array of serialized message, ``str``
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 3
|
||||
(_x.r, _x.g, _x.b,) = _get_struct_3B().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
|
||||
def serialize_numpy(self, buff, numpy):
|
||||
"""
|
||||
serialize message with numpy array types into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_3B().pack(_x.r, _x.g, _x.b))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize_numpy(self, str, numpy):
|
||||
"""
|
||||
unpack serialized message in str into this message instance using numpy for array types
|
||||
:param str: byte array of serialized message, ``str``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 3
|
||||
(_x.r, _x.g, _x.b,) = _get_struct_3B().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
_struct_I = genpy.struct_I
|
||||
def _get_struct_I():
|
||||
global _struct_I
|
||||
return _struct_I
|
||||
_struct_3B = None
|
||||
def _get_struct_3B():
|
||||
global _struct_3B
|
||||
if _struct_3B is None:
|
||||
_struct_3B = struct.Struct("<3B")
|
||||
return _struct_3B
|
@ -1,343 +0,0 @@
|
||||
# This Python file uses the following encoding: utf-8
|
||||
"""autogenerated by genpy from unitree_legged_msgs/LowCmd.msg. Do not edit."""
|
||||
import codecs
|
||||
import sys
|
||||
python3 = True if sys.hexversion > 0x03000000 else False
|
||||
import genpy
|
||||
import struct
|
||||
|
||||
import unitree_legged_msgs.msg
|
||||
|
||||
class LowCmd(genpy.Message):
|
||||
_md5sum = "357432b2562edd0a8e89b9c9f5fc4821"
|
||||
_type = "unitree_legged_msgs/LowCmd"
|
||||
_has_header = False # flag to mark the presence of a Header object
|
||||
_full_text = """uint8 levelFlag
|
||||
uint16 commVersion # Old version Aliengo does not have
|
||||
uint16 robotID # Old version Aliengo does not have
|
||||
uint32 SN # Old version Aliengo does not have
|
||||
uint8 bandWidth # Old version Aliengo does not have
|
||||
MotorCmd[20] motorCmd
|
||||
LED[4] led
|
||||
uint8[40] wirelessRemote
|
||||
uint32 reserve # Old version Aliengo does not have
|
||||
uint32 crc
|
||||
|
||||
Cartesian[4] ff # will delete # Old version Aliengo does not have
|
||||
================================================================================
|
||||
MSG: unitree_legged_msgs/MotorCmd
|
||||
uint8 mode # motor target mode
|
||||
float32 q # motor target position
|
||||
float32 dq # motor target velocity
|
||||
float32 tau # motor target torque
|
||||
float32 Kp # motor spring stiffness coefficient
|
||||
float32 Kd # motor damper coefficient
|
||||
uint32[3] reserve # motor target torque
|
||||
================================================================================
|
||||
MSG: unitree_legged_msgs/LED
|
||||
uint8 r
|
||||
uint8 g
|
||||
uint8 b
|
||||
================================================================================
|
||||
MSG: unitree_legged_msgs/Cartesian
|
||||
float32 x
|
||||
float32 y
|
||||
float32 z"""
|
||||
__slots__ = ['levelFlag','commVersion','robotID','SN','bandWidth','motorCmd','led','wirelessRemote','reserve','crc','ff']
|
||||
_slot_types = ['uint8','uint16','uint16','uint32','uint8','unitree_legged_msgs/MotorCmd[20]','unitree_legged_msgs/LED[4]','uint8[40]','uint32','uint32','unitree_legged_msgs/Cartesian[4]']
|
||||
|
||||
def __init__(self, *args, **kwds):
|
||||
"""
|
||||
Constructor. Any message fields that are implicitly/explicitly
|
||||
set to None will be assigned a default value. The recommend
|
||||
use is keyword arguments as this is more robust to future message
|
||||
changes. You cannot mix in-order arguments and keyword arguments.
|
||||
|
||||
The available fields are:
|
||||
levelFlag,commVersion,robotID,SN,bandWidth,motorCmd,led,wirelessRemote,reserve,crc,ff
|
||||
|
||||
:param args: complete set of field values, in .msg order
|
||||
:param kwds: use keyword arguments corresponding to message field names
|
||||
to set specific fields.
|
||||
"""
|
||||
if args or kwds:
|
||||
super(LowCmd, self).__init__(*args, **kwds)
|
||||
# message fields cannot be None, assign default values for those that are
|
||||
if self.levelFlag is None:
|
||||
self.levelFlag = 0
|
||||
if self.commVersion is None:
|
||||
self.commVersion = 0
|
||||
if self.robotID is None:
|
||||
self.robotID = 0
|
||||
if self.SN is None:
|
||||
self.SN = 0
|
||||
if self.bandWidth is None:
|
||||
self.bandWidth = 0
|
||||
if self.motorCmd is None:
|
||||
self.motorCmd = [unitree_legged_msgs.msg.MotorCmd() for _ in range(20)]
|
||||
if self.led is None:
|
||||
self.led = [unitree_legged_msgs.msg.LED() for _ in range(4)]
|
||||
if self.wirelessRemote is None:
|
||||
self.wirelessRemote = b'\0'*40
|
||||
if self.reserve is None:
|
||||
self.reserve = 0
|
||||
if self.crc is None:
|
||||
self.crc = 0
|
||||
if self.ff is None:
|
||||
self.ff = [unitree_legged_msgs.msg.Cartesian() for _ in range(4)]
|
||||
else:
|
||||
self.levelFlag = 0
|
||||
self.commVersion = 0
|
||||
self.robotID = 0
|
||||
self.SN = 0
|
||||
self.bandWidth = 0
|
||||
self.motorCmd = [unitree_legged_msgs.msg.MotorCmd() for _ in range(20)]
|
||||
self.led = [unitree_legged_msgs.msg.LED() for _ in range(4)]
|
||||
self.wirelessRemote = b'\0'*40
|
||||
self.reserve = 0
|
||||
self.crc = 0
|
||||
self.ff = [unitree_legged_msgs.msg.Cartesian() for _ in range(4)]
|
||||
|
||||
def _get_types(self):
|
||||
"""
|
||||
internal API method
|
||||
"""
|
||||
return self._slot_types
|
||||
|
||||
def serialize(self, buff):
|
||||
"""
|
||||
serialize message into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_B2HIB().pack(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth))
|
||||
if len(self.motorCmd) != 20:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (20, len(self.motorCmd), 'self.motorCmd')))
|
||||
for val1 in self.motorCmd:
|
||||
_x = val1
|
||||
buff.write(_get_struct_B5f().pack(_x.mode, _x.q, _x.dq, _x.tau, _x.Kp, _x.Kd))
|
||||
buff.write(_get_struct_3I().pack(*val1.reserve))
|
||||
if len(self.led) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.led), 'self.led')))
|
||||
for val1 in self.led:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3B().pack(_x.r, _x.g, _x.b))
|
||||
_x = self.wirelessRemote
|
||||
# - if encoded as a list instead, serialize as bytes instead of string
|
||||
if type(_x) in [list, tuple]:
|
||||
buff.write(_get_struct_40B().pack(*_x))
|
||||
else:
|
||||
buff.write(_get_struct_40s().pack(_x))
|
||||
_x = self
|
||||
buff.write(_get_struct_2I().pack(_x.reserve, _x.crc))
|
||||
if len(self.ff) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.ff), 'self.ff')))
|
||||
for val1 in self.ff:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize(self, str):
|
||||
"""
|
||||
unpack serialized message in str into this message instance
|
||||
:param str: byte array of serialized message, ``str``
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
if self.motorCmd is None:
|
||||
self.motorCmd = None
|
||||
if self.led is None:
|
||||
self.led = None
|
||||
if self.ff is None:
|
||||
self.ff = None
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 10
|
||||
(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth,) = _get_struct_B2HIB().unpack(str[start:end])
|
||||
self.motorCmd = []
|
||||
for i in range(0, 20):
|
||||
val1 = unitree_legged_msgs.msg.MotorCmd()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 21
|
||||
(_x.mode, _x.q, _x.dq, _x.tau, _x.Kp, _x.Kd,) = _get_struct_B5f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 12
|
||||
val1.reserve = _get_struct_3I().unpack(str[start:end])
|
||||
self.motorCmd.append(val1)
|
||||
self.led = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.LED()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 3
|
||||
(_x.r, _x.g, _x.b,) = _get_struct_3B().unpack(str[start:end])
|
||||
self.led.append(val1)
|
||||
start = end
|
||||
end += 40
|
||||
self.wirelessRemote = str[start:end]
|
||||
_x = self
|
||||
start = end
|
||||
end += 8
|
||||
(_x.reserve, _x.crc,) = _get_struct_2I().unpack(str[start:end])
|
||||
self.ff = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.Cartesian()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
self.ff.append(val1)
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
|
||||
def serialize_numpy(self, buff, numpy):
|
||||
"""
|
||||
serialize message with numpy array types into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_B2HIB().pack(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth))
|
||||
if len(self.motorCmd) != 20:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (20, len(self.motorCmd), 'self.motorCmd')))
|
||||
for val1 in self.motorCmd:
|
||||
_x = val1
|
||||
buff.write(_get_struct_B5f().pack(_x.mode, _x.q, _x.dq, _x.tau, _x.Kp, _x.Kd))
|
||||
buff.write(val1.reserve.tostring())
|
||||
if len(self.led) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.led), 'self.led')))
|
||||
for val1 in self.led:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3B().pack(_x.r, _x.g, _x.b))
|
||||
_x = self.wirelessRemote
|
||||
# - if encoded as a list instead, serialize as bytes instead of string
|
||||
if type(_x) in [list, tuple]:
|
||||
buff.write(_get_struct_40B().pack(*_x))
|
||||
else:
|
||||
buff.write(_get_struct_40s().pack(_x))
|
||||
_x = self
|
||||
buff.write(_get_struct_2I().pack(_x.reserve, _x.crc))
|
||||
if len(self.ff) != 4:
|
||||
self._check_types(ValueError("Expecting %s items but found %s when writing '%s'" % (4, len(self.ff), 'self.ff')))
|
||||
for val1 in self.ff:
|
||||
_x = val1
|
||||
buff.write(_get_struct_3f().pack(_x.x, _x.y, _x.z))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize_numpy(self, str, numpy):
|
||||
"""
|
||||
unpack serialized message in str into this message instance using numpy for array types
|
||||
:param str: byte array of serialized message, ``str``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
if self.motorCmd is None:
|
||||
self.motorCmd = None
|
||||
if self.led is None:
|
||||
self.led = None
|
||||
if self.ff is None:
|
||||
self.ff = None
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 10
|
||||
(_x.levelFlag, _x.commVersion, _x.robotID, _x.SN, _x.bandWidth,) = _get_struct_B2HIB().unpack(str[start:end])
|
||||
self.motorCmd = []
|
||||
for i in range(0, 20):
|
||||
val1 = unitree_legged_msgs.msg.MotorCmd()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 21
|
||||
(_x.mode, _x.q, _x.dq, _x.tau, _x.Kp, _x.Kd,) = _get_struct_B5f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 12
|
||||
val1.reserve = numpy.frombuffer(str[start:end], dtype=numpy.uint32, count=3)
|
||||
self.motorCmd.append(val1)
|
||||
self.led = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.LED()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 3
|
||||
(_x.r, _x.g, _x.b,) = _get_struct_3B().unpack(str[start:end])
|
||||
self.led.append(val1)
|
||||
start = end
|
||||
end += 40
|
||||
self.wirelessRemote = str[start:end]
|
||||
_x = self
|
||||
start = end
|
||||
end += 8
|
||||
(_x.reserve, _x.crc,) = _get_struct_2I().unpack(str[start:end])
|
||||
self.ff = []
|
||||
for i in range(0, 4):
|
||||
val1 = unitree_legged_msgs.msg.Cartesian()
|
||||
_x = val1
|
||||
start = end
|
||||
end += 12
|
||||
(_x.x, _x.y, _x.z,) = _get_struct_3f().unpack(str[start:end])
|
||||
self.ff.append(val1)
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
_struct_I = genpy.struct_I
|
||||
def _get_struct_I():
|
||||
global _struct_I
|
||||
return _struct_I
|
||||
_struct_2I = None
|
||||
def _get_struct_2I():
|
||||
global _struct_2I
|
||||
if _struct_2I is None:
|
||||
_struct_2I = struct.Struct("<2I")
|
||||
return _struct_2I
|
||||
_struct_3B = None
|
||||
def _get_struct_3B():
|
||||
global _struct_3B
|
||||
if _struct_3B is None:
|
||||
_struct_3B = struct.Struct("<3B")
|
||||
return _struct_3B
|
||||
_struct_3I = None
|
||||
def _get_struct_3I():
|
||||
global _struct_3I
|
||||
if _struct_3I is None:
|
||||
_struct_3I = struct.Struct("<3I")
|
||||
return _struct_3I
|
||||
_struct_3f = None
|
||||
def _get_struct_3f():
|
||||
global _struct_3f
|
||||
if _struct_3f is None:
|
||||
_struct_3f = struct.Struct("<3f")
|
||||
return _struct_3f
|
||||
_struct_40B = None
|
||||
def _get_struct_40B():
|
||||
global _struct_40B
|
||||
if _struct_40B is None:
|
||||
_struct_40B = struct.Struct("<40B")
|
||||
return _struct_40B
|
||||
_struct_40s = None
|
||||
def _get_struct_40s():
|
||||
global _struct_40s
|
||||
if _struct_40s is None:
|
||||
_struct_40s = struct.Struct("<40s")
|
||||
return _struct_40s
|
||||
_struct_B2HIB = None
|
||||
def _get_struct_B2HIB():
|
||||
global _struct_B2HIB
|
||||
if _struct_B2HIB is None:
|
||||
_struct_B2HIB = struct.Struct("<B2HIB")
|
||||
return _struct_B2HIB
|
||||
_struct_B5f = None
|
||||
def _get_struct_B5f():
|
||||
global _struct_B5f
|
||||
if _struct_B5f is None:
|
||||
_struct_B5f = struct.Struct("<B5f")
|
||||
return _struct_B5f
|
@ -1,150 +0,0 @@
|
||||
# This Python file uses the following encoding: utf-8
|
||||
"""autogenerated by genpy from unitree_legged_msgs/MotorCmd.msg. Do not edit."""
|
||||
import codecs
|
||||
import sys
|
||||
python3 = True if sys.hexversion > 0x03000000 else False
|
||||
import genpy
|
||||
import struct
|
||||
|
||||
|
||||
class MotorCmd(genpy.Message):
|
||||
_md5sum = "bbb3b7d91319c3a1b99055f0149ba221"
|
||||
_type = "unitree_legged_msgs/MotorCmd"
|
||||
_has_header = False # flag to mark the presence of a Header object
|
||||
_full_text = """uint8 mode # motor target mode
|
||||
float32 q # motor target position
|
||||
float32 dq # motor target velocity
|
||||
float32 tau # motor target torque
|
||||
float32 Kp # motor spring stiffness coefficient
|
||||
float32 Kd # motor damper coefficient
|
||||
uint32[3] reserve # motor target torque"""
|
||||
__slots__ = ['mode','q','dq','tau','Kp','Kd','reserve']
|
||||
_slot_types = ['uint8','float32','float32','float32','float32','float32','uint32[3]']
|
||||
|
||||
def __init__(self, *args, **kwds):
|
||||
"""
|
||||
Constructor. Any message fields that are implicitly/explicitly
|
||||
set to None will be assigned a default value. The recommend
|
||||
use is keyword arguments as this is more robust to future message
|
||||
changes. You cannot mix in-order arguments and keyword arguments.
|
||||
|
||||
The available fields are:
|
||||
mode,q,dq,tau,Kp,Kd,reserve
|
||||
|
||||
:param args: complete set of field values, in .msg order
|
||||
:param kwds: use keyword arguments corresponding to message field names
|
||||
to set specific fields.
|
||||
"""
|
||||
if args or kwds:
|
||||
super(MotorCmd, self).__init__(*args, **kwds)
|
||||
# message fields cannot be None, assign default values for those that are
|
||||
if self.mode is None:
|
||||
self.mode = 0
|
||||
if self.q is None:
|
||||
self.q = 0.
|
||||
if self.dq is None:
|
||||
self.dq = 0.
|
||||
if self.tau is None:
|
||||
self.tau = 0.
|
||||
if self.Kp is None:
|
||||
self.Kp = 0.
|
||||
if self.Kd is None:
|
||||
self.Kd = 0.
|
||||
if self.reserve is None:
|
||||
self.reserve = [0] * 3
|
||||
else:
|
||||
self.mode = 0
|
||||
self.q = 0.
|
||||
self.dq = 0.
|
||||
self.tau = 0.
|
||||
self.Kp = 0.
|
||||
self.Kd = 0.
|
||||
self.reserve = [0] * 3
|
||||
|
||||
def _get_types(self):
|
||||
"""
|
||||
internal API method
|
||||
"""
|
||||
return self._slot_types
|
||||
|
||||
def serialize(self, buff):
|
||||
"""
|
||||
serialize message into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_B5f().pack(_x.mode, _x.q, _x.dq, _x.tau, _x.Kp, _x.Kd))
|
||||
buff.write(_get_struct_3I().pack(*self.reserve))
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize(self, str):
|
||||
"""
|
||||
unpack serialized message in str into this message instance
|
||||
:param str: byte array of serialized message, ``str``
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 21
|
||||
(_x.mode, _x.q, _x.dq, _x.tau, _x.Kp, _x.Kd,) = _get_struct_B5f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 12
|
||||
self.reserve = _get_struct_3I().unpack(str[start:end])
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
|
||||
def serialize_numpy(self, buff, numpy):
|
||||
"""
|
||||
serialize message with numpy array types into buffer
|
||||
:param buff: buffer, ``StringIO``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
try:
|
||||
_x = self
|
||||
buff.write(_get_struct_B5f().pack(_x.mode, _x.q, _x.dq, _x.tau, _x.Kp, _x.Kd))
|
||||
buff.write(self.reserve.tostring())
|
||||
except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
|
||||
except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
|
||||
|
||||
def deserialize_numpy(self, str, numpy):
|
||||
"""
|
||||
unpack serialized message in str into this message instance using numpy for array types
|
||||
:param str: byte array of serialized message, ``str``
|
||||
:param numpy: numpy python module
|
||||
"""
|
||||
codecs.lookup_error("rosmsg").msg_type = self._type
|
||||
try:
|
||||
end = 0
|
||||
_x = self
|
||||
start = end
|
||||
end += 21
|
||||
(_x.mode, _x.q, _x.dq, _x.tau, _x.Kp, _x.Kd,) = _get_struct_B5f().unpack(str[start:end])
|
||||
start = end
|
||||
end += 12
|
||||
self.reserve = numpy.frombuffer(str[start:end], dtype=numpy.uint32, count=3)
|
||||
return self
|
||||
except struct.error as e:
|
||||
raise genpy.DeserializationError(e) # most likely buffer underfill
|
||||
|
||||
_struct_I = genpy.struct_I
|
||||
def _get_struct_I():
|
||||
global _struct_I
|
||||
return _struct_I
|
||||
_struct_3I = None
|
||||
def _get_struct_3I():
|
||||
global _struct_3I
|
||||
if _struct_3I is None:
|
||||
_struct_3I = struct.Struct("<3I")
|
||||
return _struct_3I
|
||||
_struct_B5f = None
|
||||
def _get_struct_B5f():
|
||||
global _struct_B5f
|
||||
if _struct_B5f is None:
|
||||
_struct_B5f = struct.Struct("<B5f")
|
||||
return _struct_B5f
|
@ -1,9 +0,0 @@
|
||||
from ._Cartesian import *
|
||||
from ._HighCmd import *
|
||||
from ._HighState import *
|
||||
from ._IMU import *
|
||||
from ._LED import *
|
||||
from ._LowCmd import *
|
||||
from ._LowState import *
|
||||
from ._MotorCmd import *
|
||||
from ._MotorState import *
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue