QT Creator no rule to make target 'upload' error

Hi guys.

First of all I’m very new to Linux and Qt Creator environment. My purpose is building and uploading my edited code on Pixhawk. But when i press run button, it gives following error.

  • make: *** No rule to make target ‘upload’. Stop.
  • /usr/bin/make exited with code 2

I’ve searched forum and tried different approaches for similar problems but i couldnt make it.

That’s what i did.

  1. Downloaded with this commands

2)Downloaded QT Creator 3.5.1
3) Applied this commands from https://dev.px4.io/en/setup/building_px4.html

  • cd ~/src/Firmware
  • mkdir …/Firmware-build
  • cd …/Firmware-build
  • cmake …/Firmware -G “CodeBlocks - Unix Makefiles”
  1. Loaded the CMakeLists.txt in the root firmware folder via File -> Open File or Project -> Select the CMakeLists.txt file,

  2. I clicked on the Projects tab to apply the settings. For build directory: /home/berkay/src/Firmware/build_px4fmu-v2_default for run section, i added custom executable entering make as executable and upload as argument.

These 5 steps give me this error. With the approaches on forum I’ve changed working directory as home/berkay/src/Firmware/build_px4fmu-v2_default. It didnt worked. I also changed build directory as /home/berkay/src/Firmware in order to make it. I even tried to do make px4fmu-v2_default in the folder Firmware just after download.But all of these didnt work. I can’t even upload code with terminal because it gives same error. But i am able to upload original firmwares from Qgroundcontrol application.

I’m open for any approaches. Thank you so much for your help.

1 Like


I had the same problem for a long time.
Finallly, we solved the problem:

Let me know whether this works.

Thank you so much your reply. But it did not work. I’ve tried to do changes as indicated topic, but I am using Linux and this settings are not one to one match.

Hello! I found solution for me. I use Ubuntu 16.04 and upload firmware to Pixhawk 2.1

I make same 1-4 steps, but 5 is different.

BUILD section
Build directory: /home/stepan/src/Firmware-build

RUN section
Make custom executable.
Executable: make
Command line arguments: px4_fmu-3v_default upload
Working directory: /home/stepan/src/Firmware

Then click run.

1 Like