bitcraze / crazyflie-simulation

MIT License
64 stars 27 forks source link

ImportError: DLL load failed while importing _pid_controller: #31

Closed deduble closed 1 year ago

deduble commented 1 year ago
ERROR: Please adapt your project to R2023a following these instructions: https://github.com/cyberbotics/webots/wiki/How-to-adapt-your-world-or-PROTO-to-Webots-R2022b
ERROR: Missing declaration for 'TexturedBackground', add: 'EXTERNPROTO "https://raw.githubusercontent.com/cyberbotics/webots/R2023a/projects/objects/backgrounds/protos/TexturedBackground.proto"' to 'C:/Users/User/python_projects/karma-suru-yarisma/crazyflie-simulation/webots/worlds/crazyflie_world.wbt'.
ERROR: Missing declaration for 'TexturedBackgroundLight', add: 'EXTERNPROTO "https://raw.githubusercontent.com/cyberbotics/webots/R2023a/projects/objects/backgrounds/protos/TexturedBackgroundLight.proto"' to 'C:/Users/User/python_projects/karma-suru-yarisma/crazyflie-simulation/webots/worlds/crazyflie_world.wbt'.
ERROR: Missing declaration for 'Floor', add: 'EXTERNPROTO "https://raw.githubusercontent.com/cyberbotics/webots/R2023a/projects/objects/floors/protos/Floor.proto"' to 'C:/Users/User/python_projects/karma-suru-yarisma/crazyflie-simulation/webots/worlds/crazyflie_world.wbt'.
INFO: crazyflie_controller_py: Starting controller: python.exe -u crazyflie_controller_py.py
Traceback (most recent call last):
  File "C:\Users\User\python_projects\karma-suru-yarisma\crazyflie-simulation\webots\controllers\crazyflie_controller_py\crazyflie_controller_py.py", line 30, in <module>
    from  pid_controller import init_pid_attitude_fixed_height_controller, pid_velocity_fixed_height_controller
  File "../../../controllers\pid_controller.py", line 15, in <module>
    import _pid_controller
ImportError: DLL load failed while importing _pid_controller: The parameter is incorrect.

This is the output on the webots console.

I am doing:

swig -python pid_controller.i
python setup.py build_ext --inplace

Swig 4.0.1 Python 3.9.1 Windows 11 (developer build) and then running

webots webots/worlds/crazyflie_world.wbt

Added webots to PATH

knmcguire commented 1 year ago

Hi! We haven't tried this on 2023a.. so there are probably some difference. You can try it on 2022b perhaps? The crazyflie should be also part of the regular robots now in webots since 2022b https://www.cyberbotics.com/doc/guide/crazyflie

knmcguire commented 1 year ago

I'll close this due to inactivity