Accelerometer measuremet of pixhawk 6X using UWAV Toolbox Support Package for PX4 Autopilots, MATLAB 2024a
Mostra commenti meno recenti
I'm now trying to setup the pixhawk 6X using UAV Toolbox Support Package for PX4 Autopilots (ver. 24.12).
I successfully finished the hardware setup.
Next, I created a simple simulink file as below.
I connected the hardware and tried to see the measurement values, but I could not find the values.
(The displayed values are zero.)
Please tell me how to solve this problem.

Risposte (2)
Jatin
il 9 Ago 2024
0 voti
To help you solve the issue, I would recommend you go through the documentation for deployment on unsupported PX4 Autopilots from Simulink:
You might also want to have a look at this MATLAB Answer:
If the issue persists, there can be various reasons of encountering zero value while monitoring accelerometer, few things you might want to check includes:
- Ensure that the accelerometer sensor on the Pixhawk is calibrated correctly.
- Use “QGroundControl” to verify that the accelerometer data is being published correctly by the Pixhawk.
- Ensure that the sample time of the PX4 accelerometer block is set correctly.
Hope this helps.
1 Commento
Sakahisa Nagai
il 9 Ago 2024
Ankur Bose
il 14 Ago 2024
0 voti
When the hardware setup process using the hardware setup screens is almost finished, there is a screen at the end called "Test Connection" where you upload the PX4 Firmware to autopilot and fetch accelerometer data. Can you confirm if you could see the accelerometer data during Test Connection? Also, how are you running the Simulink Model? Is it deployed via Monitor & Tune OR it is running over Connected IO?
19 Commenti
Sakahisa Nagai
il 15 Ago 2024
Ankur Bose
il 16 Ago 2024
Your board has been configured in HITL mode from QGroundControl previously. in HITL mode, all onboard sensors are disabled, hence you are not getting any values when you run Connected IO simulation in Simulink. To remove the HITL mode,
- Connect the Pixhawk 6x board to QGC.
- Once the QGC is conneted, navigate to the parameters, search for SYS_HITL and set 0 as parameter value or HITL disabled.
- Restart the board
- Alternatively, you can select any non-HITL airframe in QGC and appy to the board
Sakahisa Nagai
il 19 Ago 2024
Ankur Bose
il 19 Ago 2024
Can you select any non-HITL airframe in QGC and then try?
Sakahisa Nagai
il 19 Ago 2024
Ankur Bose
il 19 Ago 2024
What is the aiframe selected in QGC?
Sakahisa Nagai
il 19 Ago 2024
Ankur Bose
il 22 Ago 2024
okay. navigate to the MAVLink Inspector tab in QGC. Can you see if there is a MAVLink message called HIGHRES_IMU? If yes, what are the values in the x,y, and z field of the message. You can attach a screenshot of the MAVLink inspector tab here
Sakahisa Nagai
il 22 Ago 2024
Ankur Bose
il 22 Ago 2024
okay. seems like the board is not in HITL mode then. Can you try running the Connected IO simulation in Simulink now?
Sakahisa Nagai
il 22 Ago 2024
Modificato: Sakahisa Nagai
il 22 Ago 2024
Ankur Bose
il 22 Ago 2024
The problem syndrome you are mentioning seems similar to the PX4 bug discussed here, but since we dont see the issue with the Pixhawk 6x board we have, we are unable to verify this. Can you make the PX4 Firmware change for the above issue as mentioned here in your clone of PX4 Firmware? Basically, you need to increase the timeout to 1000ms from the current 500 ms. Once you do that, run the PX4 hardware setup screens again for your board and try Test Connection in setup screens or Connected IO simulation.
Sakahisa Nagai
il 23 Ago 2024
Sakahisa Nagai
il 23 Ago 2024
Ankur Bose
il 23 Ago 2024
Thanks for running the experiment. Can you reach out to MathWorks Technical Support with your issue?
Sakahisa Nagai
il 23 Ago 2024
Tharani
il 28 Nov 2024
Were you able to solve this issue? I'm trying to resolve the same error.
Sakahisa Nagai
il 28 Nov 2024
Categorie
Scopri di più su Simulink 3D Animation in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!





