mit-biomimetics / Cheetah-Software

MIT License
2.53k stars 911 forks source link

Compilation terminated ? #1

Closed DeepDuke closed 5 years ago

DeepDuke commented 5 years ago

Hi , I try to compile these code. But I met

/Cheetah-Software/common/../lcm-types/cpp: No such file or directory [-Werror=missing-include-dirs] cc1plus: all warnings being treated as errors

I made a directory named cpp under ../lcm-types and it works. When it went on compiling, I met another error:

/Cheetah-Software/common/include/SimUtilities/GamepadCommand.h:10:28: fatal error: gamepad_lcmt.hpp: No such file or directory compilation terminated.

It seems that a file named gamepad_lcmt.hpp is lost. I didn't find it. Could you please tell me how to solve this problem? Thanks !

dhkim0821 commented 5 years ago

Can you try running ./script/make_types.sh?

DeepDuke commented 5 years ago

I ran make_types.sh and got this :

Starting LCM type generation... rm: cannot remove '*/*.jar': No such file or directory rm: cannot remove '*/*.class': No such file or directory rm: cannot remove '*/*.pyc': No such file or directory Notice: enclosing LCM types without package into java namespace 'lcmtypes'. cp: cannot stat '/usr/local/share/java/lcm.jar': No such file or directory lcmtypes/cheetah_visualization_lcmt.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/cheetah_visualization_lcmt.java:12: error: package lcm.lcm does not exist public final class cheetah_visualization_lcmt implements lcm.lcm.LCMEncodable ^ lcmtypes/control_parameter_request_lcmt.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/control_parameter_request_lcmt.java:12: error: package lcm.lcm does not exist public final class control_parameter_request_lcmt implements lcm.lcm.LCMEncodable ^ lcmtypes/control_parameter_respones_lcmt.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/control_parameter_respones_lcmt.java:12: error: package lcm.lcm does not exist public final class control_parameter_respones_lcmt implements lcm.lcm.LCMEncodable ^ lcmtypes/gamepad_lcmt.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/gamepad_lcmt.java:12: error: package lcm.lcm does not exist public final class gamepad_lcmt implements lcm.lcm.LCMEncodable ^ lcmtypes/gui_main_control_settings_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/gui_main_control_settings_t.java:12: error: package lcm.lcm does not exist public final class gui_main_control_settings_t implements lcm.lcm.LCMEncodable ^ lcmtypes/qp_controller_data_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/qp_controller_data_t.java:12: error: package lcm.lcm does not exist public final class qp_controller_data_t implements lcm.lcm.LCMEncodable ^ lcmtypes/rc_channels_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/rc_channels_t.java:12: error: package lcm.lcm does not exist public final class rc_channels_t implements lcm.lcm.LCMEncodable ^ lcmtypes/sim_command_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/sim_command_t.java:12: error: package lcm.lcm does not exist public final class sim_command_t implements lcm.lcm.LCMEncodable ^ lcmtypes/simulator_lcmt.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/simulator_lcmt.java:12: error: package lcm.lcm does not exist public final class simulator_lcmt implements lcm.lcm.LCMEncodable ^ lcmtypes/spi_command_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/spi_command_t.java:12: error: package lcm.lcm does not exist public final class spi_command_t implements lcm.lcm.LCMEncodable ^ lcmtypes/spi_data_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/spi_data_t.java:12: error: package lcm.lcm does not exist public final class spi_data_t implements lcm.lcm.LCMEncodable ^ lcmtypes/spi_torque_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/spi_torque_t.java:12: error: package lcm.lcm does not exist public final class spi_torque_t implements lcm.lcm.LCMEncodable ^ lcmtypes/vectornav_lcmt.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/vectornav_lcmt.java:12: error: package lcm.lcm does not exist public final class vectornav_lcmt implements lcm.lcm.LCMEncodable ^ lcmtypes/vision_data_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/vision_data_t.java:12: error: package lcm.lcm does not exist public final class vision_data_t implements lcm.lcm.LCMEncodable ^ lcmtypes/wbc_test_data_t.java:10: error: package lcm.lcm does not exist import lcm.lcm.*; ^ lcmtypes/wbc_test_data_t.java:12: error: package lcm.lcm does not exist public final class wbc_test_data_t implements lcm.lcm.LCMEncodable ^ lcmtypes/cheetah_visualization_lcmt.java:74: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class cheetah_visualization_lcmt lcmtypes/cheetah_visualization_lcmt.java:72: error: recursive constructor invocation public cheetah_visualization_lcmt(byte[] data) throws IOException ^ lcmtypes/control_parameter_request_lcmt.java:67: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class control_parameter_request_lcmt lcmtypes/control_parameter_request_lcmt.java:65: error: recursive constructor invocation public control_parameter_request_lcmt(byte[] data) throws IOException ^ lcmtypes/control_parameter_respones_lcmt.java:67: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class control_parameter_respones_lcmt lcmtypes/control_parameter_respones_lcmt.java:65: error: recursive constructor invocation public control_parameter_respones_lcmt(byte[] data) throws IOException ^ lcmtypes/gamepad_lcmt.java:104: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class gamepad_lcmt lcmtypes/gamepad_lcmt.java:102: error: recursive constructor invocation public gamepad_lcmt(byte[] data) throws IOException ^ lcmtypes/gui_main_control_settings_t.java:149: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class gui_main_control_settings_t lcmtypes/gui_main_control_settings_t.java:147: error: recursive constructor invocation public gui_main_control_settings_t(byte[] data) throws IOException ^ lcmtypes/qp_controller_data_t.java:152: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class qp_controller_data_t lcmtypes/qp_controller_data_t.java:150: error: recursive constructor invocation public qp_controller_data_t(byte[] data) throws IOException ^ lcmtypes/rc_channels_t.java:98: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class rc_channels_t lcmtypes/rc_channels_t.java:96: error: recursive constructor invocation public rc_channels_t(byte[] data) throws IOException ^ lcmtypes/sim_command_t.java:61: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class sim_command_t lcmtypes/sim_command_t.java:59: error: recursive constructor invocation public sim_command_t(byte[] data) throws IOException ^ lcmtypes/simulator_lcmt.java:160: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class simulator_lcmt lcmtypes/simulator_lcmt.java:158: error: recursive constructor invocation public simulator_lcmt(byte[] data) throws IOException ^ lcmtypes/spi_command_t.java:146: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class spi_command_t lcmtypes/spi_command_t.java:144: error: recursive constructor invocation public spi_command_t(byte[] data) throws IOException ^ lcmtypes/spi_data_t.java:95: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class spi_data_t lcmtypes/spi_data_t.java:93: error: recursive constructor invocation public spi_data_t(byte[] data) throws IOException ^ lcmtypes/spi_torque_t.java:68: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class spi_torque_t lcmtypes/spi_torque_t.java:66: error: recursive constructor invocation public spi_torque_t(byte[] data) throws IOException ^ lcmtypes/vectornav_lcmt.java:68: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class vectornav_lcmt lcmtypes/vectornav_lcmt.java:66: error: recursive constructor invocation public vectornav_lcmt(byte[] data) throws IOException ^ lcmtypes/vision_data_t.java:62: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class vision_data_t lcmtypes/vision_data_t.java:60: error: recursive constructor invocation public vision_data_t(byte[] data) throws IOException ^ lcmtypes/wbc_test_data_t.java:236: error: cannot find symbol this(new LCMDataInputStream(data)); ^ symbol: class LCMDataInputStream location: class wbc_test_data_t lcmtypes/wbc_test_data_t.java:234: error: recursive constructor invocation public wbc_test_data_t(byte[] data) throws IOException ^ 60 errors */*.class : no such file or directory mv: cannot stat 'lcm.jar': No such file or directory ls: cannot access '*/*.class': No such file or directory Done with LCM type generation It seems something wrong with lcm?

dhkim0821 commented 5 years ago

It looks like that you do not have lcm-java extension on your computer. Did you install lcm after java installation? Please, make it sure that lcm recognizes java and let lcm compile its java extension.

DeepDuke commented 5 years ago

Oh, I forgot to install java extension. I reinstalled LCM . But when I compile again, I met

[ 72%] Linking CXX executable sim /home/zmchen/Qt5.10.1/5.10.1/android_x86/lib/libQt5Gamepad.so: error adding symbols: File in wrong format collect2: error: ld returned 1 exit status sim/CMakeFiles/sim.dir/build.make:454: recipe for target 'sim/sim' failed make[2]: *** [sim/sim] Error 1 CMakeFiles/Makefile2:4417: recipe for target 'sim/CMakeFiles/sim.dir/all' failed make[1]: *** [sim/CMakeFiles/sim.dir/all] Error 2 make[1]: *** Waiting for unfinished jobs....

And when I ran make_types.sh, I got:

Starting LCM type generation... rm: cannot remove '*/*.class': No such file or directory rm: cannot remove '*/*.pyc': No such file or directory Notice: enclosing LCM types without package into java namespace 'lcmtypes'. Done with LCM type generation

dhkim0821 commented 5 years ago

One weird thing is that your compiler points Qt library in '5.10.1/android_x86/lib' rather than one in '5.10.1/gcc_64/lib'. You might want to check the path for Qt library.

For the lcm build, you need to be in build folder and execute command './../scripts/make_types.sh', which may be already done by you. As long as you have folders with lcm types under the lcm-types folder, it's fine. If you run the command first time, it can show error messages because there is no folder to remove. If you run the commands after generating the folders and files, you could see the following message or something similar:

 Starting LCM type generation...
rm: cannot remove '*/*.pyc': No such file or directory
Notice: enclosing LCM types without package into java namespace 'lcmtypes'.
 Done with LCM type generation
DeepDuke commented 5 years ago

I reset my compiler path. Now I can pass through the compilation process. But when I run./robot/robot 3 s, I got:

Quadruped] Cheetah Software Quadruped: Cheetah 3 Driver: Development Simulation Driver [Shared Memory] open existing development-simulator size 266176 bytes [ERROR] SharedMemoryObject::attach shm_open(development-simulator) failed: No such file or directory terminate called after throwing an instance of 'std::runtime_error' what(): Failed to create shared memory! Aborted (core dumped)

dicarlo236 commented 5 years ago

If you are running the robot code in simulation mode, you need to have the simulator running first. You should launch the simulator with sim/sim, then select "Cheetah", and "Simulator", then click "Start". Then try running robot again.

If you are still having issues, can you share what shared-memory related messages appear in the simulator window? And what OS you are using? We've only tested on recent Ubuntus (16.04 - 19.04)

DeepDuke commented 5 years ago

I'm using ubuntu 16.04. As soon as I click "Start", the simulator panel closed immediately. And I got the following message: `[SimControlPanel] Init simulator parameters...

sim parameters are all good

[SimControlPanel] Initialize Graphics...

[DrawList] Load object files...

ERROR bad obj line s off

ERROR bad obj line

ERROR bad obj line s off

ERROR bad obj line

ERROR bad obj line mtllib u_link_c3.mtl

ERROR bad obj line usemtl None

ERROR bad obj line s off

ERROR bad obj line

ERROR bad obj line mtllib l_link_c3.mtl

ERROR bad obj line usemtl None

ERROR bad obj line s off

ERROR bad obj line

ERROR bad obj line s off

ERROR bad obj line

ERROR bad obj line s off

ERROR bad obj line

ERROR bad obj line s off

ERROR bad obj line

ERROR bad obj line mtllib l_link_mini.mtl

ERROR bad obj line usemtl None

ERROR bad obj line s off

ERROR bad obj line

ERROR bad obj line mtllib sphere.mtl

ERROR bad obj line g sphere1_default

ERROR bad obj line usemtl default

ERROR bad obj line s 1

ERROR bad obj line

ERROR bad obj line

ERROR bad obj line

ERROR bad obj line

ERROR bad obj line

Device discovery cannot open device "/dev/input/event0"

Device discovery cannot open device "/dev/input/event1"

Device discovery cannot open device "/dev/input/event10"

Device discovery cannot open device "/dev/input/event11"

Device discovery cannot open device "/dev/input/event12"

Device discovery cannot open device "/dev/input/event13"

Device discovery cannot open device "/dev/input/event14"

Device discovery cannot open device "/dev/input/event15"

Device discovery cannot open device "/dev/input/event16"

Device discovery cannot open device "/dev/input/event17"

Device discovery cannot open device "/dev/input/event18"

Device discovery cannot open device "/dev/input/event2"

Device discovery cannot open device "/dev/input/event3"

Device discovery cannot open device "/dev/input/event4"

Device discovery cannot open device "/dev/input/event5"

Device discovery cannot open device "/dev/input/event6"

Device discovery cannot open device "/dev/input/event7"

Device discovery cannot open device "/dev/input/event8"

Device discovery cannot open device "/dev/input/event9"

Device discovery cannot open device "/dev/input/mice"

Device discovery cannot open device "/dev/input/mouse0"

Device discovery cannot open device "/dev/input/mouse1"

Device discovery cannot open device "/dev/input/mouse2"

[ERROR: GameController] No controller was connected! All joystick commands will be zero!

[SIM GRAPHICS] New graphics window.

[Graphics3D] Initialize OpenGL...

[SimControlPanel] Initialize simulator...

[Simulation] Load parameters...

[Simulation] Setup LCM...

[Simulation] Build quadruped...

[Simulation] Build actuator model...

[Simulation] Setup Cheetah graphics...

size of kinematicXform: 13, j0: 0

size of kinematicXform: 26, j0: 13

[Simulation] Build rigid body model...

Segmentation fault (core dumped) `

DeepDuke commented 5 years ago

If I ran ./robot/robot, I would got: ` [Quadruped] Cheetah Software

    Quadruped:  Cheetah 3

    Driver: Development Simulation Driver

[Shared Memory] open existing development-simulator size 266176 bytes

[ERROR] SharedMemoryObject::attach shm_open(development-simulator) failed: No such file or directory

terminate called after throwing an instance of 'std::runtime_error'

what(): Failed to create shared memory!

Aborted (core dumped)

`

dhkim0821 commented 5 years ago

The error messages during simulation runs is not a big issue. However, you got segmentation fault during dynamic model or simulation model building. Please check your glibc version is higher than 2.2, and try to run it with sudo mode (just in case). It looks like that you have some issues with shared memory although it is unclear...

zapplelove commented 5 years ago

When I run make -j4, I would get: /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQByteArray::append(char)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to qt_version_tag@Qt_5.10' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQMetaType::typeName(int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMetaType::unregisterConverterFunction(int, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQString::operator=(QString const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QVariant::~QVariant()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQLoggingCategory::~QLoggingCategory()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QListData::append(QListData const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObject::childEvent(QChildEvent)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMetaObject::Connection::~Connection()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObject::staticMetaObject@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QListData::shared_null@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQMapDataBase::freeData(QMapDataBase)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMapDataBase::createNode(int, int, QMapNodeBase*, bool)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQFactoryLoader::instance(int) const@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QByteArray::isNull() const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQMetaObject::normalizedType(char const)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QArrayData::shared_null@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObject::~QObject()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to `QString::fromUtf8_helper(char const, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObject::timerEvent(QTimerEvent*)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQCoreApplication::addLibraryPath(QString const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QVariant::isNull() const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQListData::append()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMetaType::registerConverterFunction(QtPrivate::AbstractConverterFunction const*, int, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQDebug::putString(QChar const, unsigned long)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMapDataBase::createData()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQByteArray::endsWith(char) const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMapDataBase::recalcMostLeftNode()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQListData::dispose(QListData::Data)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QSettings::beginGroup(QString const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQKeyEvent::QKeyEvent(QEvent::Type, int, QFlags, QString const&, bool, unsigned short)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QtPrivate::QStringList_contains(QStringList const*, QString const&, Qt::CaseSensitivity)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObject::eventFilter(QObject, QEvent)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QTextStream::operator<<(QString const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQCoreApplication::self@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QSettings::QSettings(QObject*)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQFactoryLoader::indexOf(QString const&) const@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMessageLogger::debug() const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQMetaType::registerNormalizedTypedef(QByteArray const&, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObject::disconnectNotify(QMetaMethod const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObject::connect(QObject const, char const, QObject const, char const, Qt::ConnectionType)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObject::qt_metacall(QMetaObject::Call, int, void**)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQGuiApplication::focusWindow()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObjectData::dynamicMetaObject() const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQString::fromLatin1_helper(char const, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to `QMetaType::registerNormalizedType(QByteArray const&, void ()(void), void ()(void, void const), int, QFlags, QMetaObject const)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QSettings::setValue(QString const&, QVariant const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQCoreApplication::notifyInternal2(QObject, QEvent)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QDir::toNativeSeparators(QString const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQDebug::~QDebug()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QHashData::shared_null@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQFactoryLoader::keyMap() const@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QString::arg(long long, int, int, QChar) const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQHashData::rehash(int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObject::qt_metacast(char const*)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQLoggingCategory::QLoggingCategory(char const)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to `QByteArray::append(char const, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QString::QString(int, Qt::Initialization)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQHashData::detach_helper(void ()(QHashData::Node, void), void ()(QHashData::Node), int, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QTextStream::operator<<(char)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQListData::detach(int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QSettings::value(QString const&, QVariant const&) const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQListData::detach_grow(int, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObject::event(QEvent*)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQSettings::remove(QString const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMapDataBase::shared_null@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toqgetenv(char const)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QMetaType::hasRegisteredConverterFunction(int, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObject::connectImpl(QObject const, void, QObject const*, void*, QtPrivate::QSlotObjectBase, Qt::ConnectionType, int const, QMetaObject const)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QHashData::free_helper(void (*)(QHashData::Node*))@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQHashData::nextNode(QHashData::Node)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QByteArray::reallocData(unsigned int, QFlags<QArrayData::AllocationOption>)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQMetaObject::cast(QObject) const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObject::deleteLater()@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQFactoryLoader::~QFactoryLoader()@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to `QMetaObject::activate(QObject, QMetaObject const, int, void)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QArrayData::deallocate(QArrayData*, unsigned long, unsigned long)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQMapNodeBase::nextNode() const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QSettings::QSettings(QString const&, QString const&, QObject*)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQFactoryLoader::QFactoryLoader(char const, QString const&, Qt::CaseSensitivity)@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to `QMapDataBase::freeTree(QMapNodeBase, int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to typeinfo for QObjectPrivate@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQString::append(QString const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QHashData::freeNode(void*)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQMessageLogger::warning() const@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObjectPrivate::~QObjectPrivate()@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObject::QObject(QObjectPrivate&, QObject)@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QHashData::allocateNode(int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference tooperator delete(void, unsigned long)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QObject::connectNotify(QMetaMethod const&)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObjectPrivate::QObjectPrivate(int)@Qt_5_PRIVATE_API' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to QListData::realloc(int)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference toQObject::customEvent(QEvent)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to `QObject::QObject(QObject)@Qt_5' /opt/Qt5/5.10.0/gcc_64/lib/libQt5Gamepad.so.5.10.0: undefined reference to typeinfo for QObject@Qt_5' collect2: error: ld returned 1 exit status sim/CMakeFiles/sim.dir/build.make:454: recipe for target 'sim/sim' failed make[2]: *** [sim/sim] Error 1 CMakeFiles/Makefile2:4417: recipe for target 'sim/CMakeFiles/sim.dir/all' failed make[1]: *** [sim/CMakeFiles/sim.dir/all] Error 2 Makefile:149: recipe for target 'all' failed make: *** [all] Error 2 How can I solve this? Thanks

dicarlo236 commented 5 years ago

It seems like there is an error with linking libQt5Gamepad. What version of linux are you running, and how did you install qt5 / qt5gamepad?

zapplelove commented 5 years ago

It seems like there is an error with linking libQt5Gamepad. What version of linux are you running, and how did you install qt5 / qt5gamepad?

My linux version is Ubuntu 16.04, and I install the qt5 using "https://download.qt.io/archive/qt/5.10/5.10.0/qt-opensource-linux-x64-5.10.0.run", and just install Desktop gcc 64-bit and Tools components. Then I set export CMAKE_PREFIX_PATH="$CMAKE_PREFIX_PATH:/opt/Qt5/5.10.0/gcc_64" to my .bashrc

dicarlo236 commented 5 years ago

It's weird that it installed to /opt, but try running

export PATH=/opt/qt5/bin:$PATH
export LD_LIBRARY_PATH=/opt/qt5/lib:$LD_LIBRARY_PATH
sudo ldconfig
zapplelove commented 5 years ago

It's weird that it installed to /opt, but try running

export PATH=/opt/qt5/bin:$PATH
export LD_LIBRARY_PATH=/opt/qt5/lib:$LD_LIBRARY_PATH
sudo ldconfig

Just has the same error

zapplelove commented 5 years ago

It's weird that I just successfully build MINI_CHEETAH_BUILD using the command cmake -DMINI_CHEETAH_BUILD=TRUE ..; make -j4. But I still get errors using the command cmake ..; make -j4

dicarlo236 commented 5 years ago

Yeah, that is a bit weird. If you can still run sim/sim produced from a MINI_CHEETAH_BUILD, it's fine to use that instead. The only thing that MINI_CHEETAH_BUILD does is adjust the compiler optimization flags to make sure it is compatible with the mini cheetah's computer. It should still run on a normal PC too.

zapplelove commented 5 years ago

Is this correct? mini cheetah

dicarlo236 commented 5 years ago

Yes, that is the default pose before the simulation connects to the robot code. The version currently on GitHub does not have any controllers for locomotion, but they will be added soon.

iceberg2016 commented 5 years ago

When I run './common/test-common, the result is [----------] Global test environment tear-down [==========] 104 tests from 22 test suites ran. (3275 ms total) [ PASSED ] 104 tests. I run './sim/sim', select "Mini Cheetah" and "Simulator", then click "Start". The interface is normal. But when I run './user/MIT_Controller/mit_ctrl m s`, the interface crashed.

[Simulation] Waiting for robot... [Graphics 3D] Uploaded data (14.800850 MB) Success! the robot is alive [Simulation] Send robot control parameters to robot... Request(1) set robot s64 cheater_mode robot to: 1 Request(2) set robot double control_mode robot to: 1 Request(3) set robot double controller_dt robot to: 0.001 Request(4) set robot double foot_height_sensor_noise robot to: 0 Request(5) set robot double foot_process_noise_position robot to: 0 Request(6) set robot double foot_sensor_noise_position robot to: 0 Request(7) set robot double foot_sensor_noise_velocity robot to: 0 Request(8) set robot double imu_process_noise_position robot to: 0 Request(9) set robot double imu_process_noise_velocity robot to: 0 Request(10) set robot vec3d kdBase robot to: [20, 10, 10] Request(11) set robot vec3d kdCOM robot to: [10, 10, 10] Request(12) set robot vec3d kpBase robot to: [300, 200, 100] Request(13) set robot vec3d kpCOM robot to: [50, 50, 50] Request(14) set robot double myValue robot to: 12 Request(15) set robot vec3d stand_kd_cartesian robot to: [60, 60, 60] Request(16) set robot vec3d stand_kp_cartesian robot to: [1000, 1000, 1000] Request(17) set robot double testValue robot to: 456 Request(18) set user double cmpc_gait user to: 9 Request(19) set user double test_param user to: 100 [Simulator] Starting run loop (dt 0.001000, dt-low-level 0.000200, dt-high-level 0.001000 speed 1.000000 graphics 1)... sim: /usr/local/include/eigen3/Eigen/src/Core/util/XprHelper.h:110:Eigen::internal::variable_if_dynamic<T, Value>::variable_if_dynamic(T) [with T = long int; int Value = 6]: Assertion `v == T(Value)' failed. Aborted (core dumped)

billchent commented 5 years ago

very weird, I run the simulation successfully yesterday, but now it shows [ERROR] Timed out waiting for message from robot! Did it crash?. the simulation window stopped after starting about 1 s Is there something wrong about it? thank u.

WingBot commented 5 years ago

When I run './common/test-common, the result is [----------] Global test environment tear-down [==========] 104 tests from 22 test suites ran. (2961 ms total) [ PASSED ] 104 tests. When I run './sim/sim', select "Cheetah 3 " and "Simulator", then click "Start". I got the following message: [SimControlPanel] Init simulator parameters... sim parameters are all good [SimControlPanel] Initialize Graphics... [DrawList] Load object files... ERROR bad obj line ERROR bad obj line ERROR bad obj line ERROR bad obj line ERROR bad obj line ERROR bad obj line ERROR bad obj line ......

The interface is stuck.Did it crash? when I run './user/JPos_Controller/jpos_ctrl 3 s`, I got the following message:

[Quadruped] Cheetah Software Quadruped: Cheetah 3 Driver: Development Simulation Driver [Shared Memory] open existing development-simulator size 266144 bytes [ERROR] SharedMemoryObject::attach shm_open(development-simulator) failed: No such file or directory terminate called after throwing an instance of 'std::runtime_error' what(): Failed to create shared memory! Aborted (core dumped)

Is there a solution? Thank you.

dicarlo236 commented 5 years ago

@WingBot Can you try running the controller with sudo? If this does not work, can you post the full output of the simulator after the ERROR bad obj line? Also, what OS are you using? We only have tested on Ubuntu 16.04 and 18.04.

@billchent Maybe you have a second controller running in the background? Can you post the full output of the control code? Make sure you run the control code after clicking "start" in the simulator window.

@iceberg2016 What version of Eigen/Linux are you using? We recommend using the latest version. If this does not solve your problem, can you use gdb to get a backtrace of where the assertion is being triggered from?

billchent commented 5 years ago

After a night, the same project that not work yesterday, it is work again. The console shows the info same as those yesterday before the controller mit_ctrl begin. After running the controller it stops and shows the Error yesterday, image however it not show that now. I dont know what problem is, but now it work again,so weird.

iceberg2016 commented 5 years ago

@dicarlo236 I download the code again and repeat the steps, the problem is solved.

WingBot commented 5 years ago

@dicarlo236 I am using Ubuntu 16.04 and I run the controller with sudo. It still doesn't work ,and the full output of the simulator is always repeated ERROR bad obj line. Also, I download the code again and repeat the steps,the problem is still not solved.

dicarlo236 commented 5 years ago

@WingBot. Can you please post the full output of the simulator? (Copy and paste the whole thing here). Also, please use Mini Cheetah instead of Cheetah 3 for now.

Edit: Can you also show the output of ls /dev/shm* after starting the simulator?

Dv-dev-cloud commented 2 months ago

Have you solved this problem now? When I try to use the robot option in. /bin/sim, it appears:hz110@raspberrypi:/media/hz110/ls/Cheetah-Software-master/build $ ./bin/sim [SimControlPanel] Init simulator parameters... sim parameters are all good [SimControlPanel] Initialize Graphics... [DrawList] Load object files... ERROR bad obj line s off ERROR bad obj line ERROR bad obj line s off ERROR bad obj line ERROR bad obj line mtllib u_link_c3.mtl ERROR bad obj line usemtl None ERROR bad obj line s off ERROR bad obj line ERROR bad obj line mtllib l_link_c3.mtl ERROR bad obj line usemtl None ERROR bad obj line s off ERROR bad obj line ERROR bad obj line s off ERROR bad obj line ERROR bad obj line s off ERROR bad obj line ERROR bad obj line s off ERROR bad obj line ERROR bad obj line mtllib l_link_mini.mtl ERROR bad obj line usemtl None ERROR bad obj line s off ERROR bad obj line ERROR bad obj line mtllib sphere.mtl ERROR bad obj line g sphere1_default ERROR bad obj line usemtl default ERROR bad obj line s 1 ERROR bad obj line ERROR bad obj line ERROR bad obj line ERROR bad obj line ERROR bad obj line [GameController] Found 1 joystick [SIM GRAPHICS] New graphics window. [Graphics3D] Initialize OpenGL... [SimControlPanel] Init Robot Interface... [RobotInterface] Load parameters... [RobotInterface] Init LCM [RobotInterface] Init graphics draw list has 13 items [RobotInterface] Init dynamics [RobotInterface] Send parameters to robot... [PeriodicTask] Start robot-interface (0 s, 16666667 ns) set cheater_mode to 0 (0) [RobotInterface] Failed to send parameter cheater_mode (iter 0 timed out), trying again... set cheater_mode to 0 (0) [RobotInterface] Failed to send parameter cheater_mode (iter 0 timed out), trying again...

I don't know how to use robot through mit code. I look forward to your help. Thank you.

Dv-dev-cloud commented 2 months ago

@dhkim0821 @DeepDuke