PX4 / PX4-Autopilot

PX4 Autopilot Software
https://px4.io
BSD 3-Clause "New" or "Revised" License
8.2k stars 13.37k forks source link

Com port issue with Version 1.12.3[Bug] #22780

Open Waleed97 opened 6 months ago

Waleed97 commented 6 months ago

Describe the bug

An issue in px4 Holybro 6x (fmu-v6x) which causes the COM ports to disappear after successful flashing of the firmware. Hence not able to communicate with the drone after flashing the firmware.

No such problem in the px4 board if versions v1.13.0 and later are flashed.

I have tried updating the firmware in the Holybro px4 6x using these three methods but face the same issues:

1) QGC-> Vehicle setup -> Firmware -> Custom setup file -> selected the .px4 file 'px4_fmu-v6x_default.px4'.
Downloaded from https://github.com/PX4/PX4-Autopilot/releases. Detailed address:- [px4_fmu-v6x_default.px4](px4_fmu-v6x_default.px4 Uploaded by @LorenzMeier

Result: Framework successfully installed but it gets stuck here. Only this screen is visible. Problem: Doesnot go into Calibration page or setup page. Even plugout plugin doesn't work.

2) Through Cygwin 0.8 console, successfully built "px4_fmu-v6x_multicopter or px4_fmu-v6x_default".

3) Through the Matlab px4 toolbox GUI. Result: Successfully built and flashed. But then not able to talk to the board/firmware afterwards as COM ports disappear. See uploaded images.

Tried methods:

1) Different USB cables (good ones with data transfer capability) 2) Different laptops tried 3) Updated USB drivers

To Reproduce

  1. Connect px4 6x controller to PC using USB C.
  2. Open Device manager in your windows PC -> Note the COM PORTS
  3. Flash firmware stable v1.12.3 , maybe using QGC (will be successfull)
  4. Connect the drone again to QGC, no response as if there is no firmware
  5. Or connect the drone and try to communicate it through Matlab UAV toolbox (No response).
  6. Open device manager and see whether the related COM PORTS are present. For me this is absent

Expected behavior

After successful firmware flashing. Should be able to see the calibration and setup screen in QGC. COM Port should be visible in Device manager as communication happens through it

Screenshot / Media

successfull_flash_using_matlab_v1 12 3_px6_multicopter

Flight Log

Same/Related complaints raised by other users in other forums:

1) This user explains the problem with images -> Still unsolved https://de.mathworks.com/matlabcentral/answers/1992678-why-the-px4-firmware-version-supported-by-the-pixhawk-6x-minimum-version-1-13-1-and-the-firmware-v?s_tid=srchtitle

2) This user also facing the same issue but frames it little differently -> Still unsolved

https://de.mathworks.com/matlabcentral/answers/1957879-how-do-i-use-pixhawk-6x-with-uav-toolbox-support-package-for-px4-autopilots?s_tid=answers_rc1-3_p3_Topic

Software Version

Holybro PX4 6X px4_fmu-v6x

Flight controller

Holybro PX4 6X

Vehicle type

Multicopter

How are the different components wired up (including port information)

No response

Additional context

Although this problem is not there in new versions but this stable version is important as it is the only version for PX4 6X , which can be connected to MATLAB/SIMULINK TOOLBOX.

DronecodeBot commented 6 months ago

This issue has been mentioned on Discussion Forum for PX4, Pixhawk, QGroundControl, MAVSDK, MAVLink. There might be relevant details there:

https://discuss.px4.io/t/px4-community-q-a-march-06-2024/37071/3

DronecodeBot commented 6 months ago

This issue has been mentioned on Discussion Forum for PX4, Pixhawk, QGroundControl, MAVSDK, MAVLink. There might be relevant details there:

https://discuss.px4.io/t/px4-community-q-a-march-06-2024/37071/1

Daybreakerflint commented 5 months ago

I managed to brick my COM-port somehow.

I can't connect after boot to the device. I have tried different versions of PX4 and somehow it worked with the latest version 1.14.0. After I changed some settings on Telemetry port 2 (Setting it up to use with an gimbal) and did a restart of the device, I was no longer able to connect to the device. No matter what I do with PX4, I am no longer able to connect to it via QGC, the COM-port does not show up in the device manager.

Once I flash ArduPilot on it, the COM-port works as intended. I have no clue onto why this is the case.

I have a debugger but I would need detailed instructions on what to do.

Waleed97 commented 5 months ago

@Daybreakerflint The issue I was facing was i was already using arducopter in my board. Everything was working.

Then when I used to flash Px4 , the comport was not showing up.

It was due to the bootloader stuck in arducopter chibios for me. I was able to solve the issue by updating my bootloader using Qgc

Daybreakerflint commented 5 months ago

Hey @Waleed97 Thanks for getting back to me. How did you manage to update the bootloader via QGC? I have not found a way to update/change the bootloader in a way. PX4 does not open a COM-port for me no matter what I version I try.

Daybreakerflint commented 5 months ago

So, now I tried out to flash the bootloader via the debugger I got the binary from the git repo and flashed it to address 0x08000000

This seemed to work initially, but it returned back to the same behaviour. No serial-port visible. But what is interesting, I can flash the px4 bootloader, then upload the firmware but then it does not show a serial-port.

When flashed with the ardupilot Bootloader the serial-port does show up.

pulak-gautam commented 1 month ago

@Daybreakerflint Were you able to find a work around?

Daybreakerflint commented 4 weeks ago

Well yes, we found the defect. It was the gate which is tied directly to the 5V supply rail. No protection on the input of the 3.3V supplied logic IC.

U8 to be precise (MC74HC1G32DFT1G) image

After we switched the IC the comport works again with PX4. This is because the software is expecting a signal from this very IC. One only needs a small disturbance on the 5V-rail and the IC gets destroyed.