What is the Current State of Connected I/O for PX4

8 visualizzazioni (ultimi 30 giorni)
riley
riley il 28 Mar 2025
Commentato: riley il 3 Apr 2025
What is the current status for whether or not Connected I/O has some avenue for working in MATLAB SImulink 24a/b? I havent seen any updates of late and have not been able to get my models to work with connected I/O.
I was able to actually get Connected I/O (no ULog present) to work in my 23b models but I know theres been big leaps since then.
Typical Error:
Error:MATLAB System block 'my_model/Read Parameter17' error occurred when invoking 'setupImpl' method of 'px4.internal.block.ParameterUpdate'. The error was thrown from '
'C:\Program Files\MATLAB\R2024b\toolbox\target\shared\ioserver\+matlabshared\+ioclient\DeployAndConnectHandle.p' at line 0
'C:\Program Files\MATLAB\R2024b\toolbox\target\shared\ioserver\+matlabshared\+ioclient\DeployAndConnectHandle.p' at line 0
'C:\Program Files\MATLAB\R2024b\toolbox\target\shared\ioserver\+matlabshared\+ioclient\DeployAndConnectHandle.p' at line 0
'C:\ProgramData\MATLAB\SupportPackages\R2024b\toolbox\target\supportpackages\px4\core\+px4\+internal\+block\ParameterUpdate.p' at line 91
'C:\Program Files\MATLAB\R2024b\toolbox\target\codertarget\sltoolstrip\m\+codertarget\+internal\+sltoolstrip\ConnectedIOHandler.m' at line 106
'C:\Program Files\MATLAB\R2024b\toolbox\target\codertarget\sltoolstrip\m\+codertarget\+sltoolstrip\EmbeddedHardwareBoardContext.m' at line 548'.
Caused by:
Simulink Connected IO: Error: IO server is not flashed properly. Reconnect the board and try again.

Risposte (2)

Ankur Bose
Ankur Bose il 1 Apr 2025
Hi @riley,
Connected IO is supported in R2024a and R2024b. Can you give us some more details on the issue here
  • What is the Hardware board here? Is it PX4 Host Target or some physical hardware?
  • When you click on Run button in Simulink Toolstrip to run COnnected IO, do you see the firmware getting flashed? Does the error happen after the firmware is flashed?
You can also reach out to MathWorks Tech support about this issue and we will look into it
  1 Commento
riley
riley il 1 Apr 2025
Hello,
I got it working, but I do not know why it experienced the initial error.
I am using a Pixhawk 6x, 2024b, and when I click run for connected I/O it goes through the normal process and the diaglog box for reconnect. It appears to move through the flash process then hits the same error that I mentioned in the original posting.
I took a blank model and simply ran connected I/O with no blocks in the model which worked immediately, all subsequent attempts for connected I/O on my full models now work perfectly. Perhaps some form of initialization was required via the blank model. Very strange.

Accedi per commentare.


w
w il 2 Apr 2025
Uploading Connected I/O Firmware to PX4 Pixhawk 4 Hardware ... Using COM5 for upload. Loaded firmware for board id: 50,0 size: 1756493 bytes (85.09%), waiting for the bootloader... Found board id: 50,0 bootloader version: 5 on COM5 sn: 003f00313033510b36323635 chip: 10016451 family: STM32F7[6|7]x revision: Z flash: 2064384 bytes Windowed mode: False Erase : [ ] 0.0% Erase : [= ] 5.7% Erase : [== ] 11.4% Erase : [=== ] 17.0% Erase : [==== ] 22.7% Erase : [===== ] 28.4% Erase : [====== ] 34.1% Erase : [======= ] 39.8% Erase : [========= ] 45.5% Erase : [========== ] 51.2% Erase : [=========== ] 56.8% Erase : [============ ] 62.5% Erase : [============= ] 68.2% Erase : [====================] 100.0% Program: [ ] 0.0% Program: [ ] 3.7% Program: [= ] 7.3% Program: [== ] 11.0% Program: [== ] 14.7% Program: [=== ] 18.4% Program: [==== ] 22.0% Program: [===== ] 25.7% Program: [===== ] 29.4% Program: [====== ] 33.1% Program: [======= ] 36.7% Program: [======== ] 40.4% Program: [======== ] 44.1% Program: [========= ] 47.7% Program: [========== ] 51.4% Program: [=========== ] 55.1% Program: [=========== ] 58.8% Program: [============ ] 62.4% Program: [============= ] 66.1% Program: [============= ] 69.8% Program: [============== ] 73.4% Program: [=============== ] 77.1% Program: [================ ] 80.8% Program: [================ ] 84.5% Program: [================= ] 88.1% Program: [================== ] 91.8% Program: [=================== ] 95.5% Program: [=================== ] 99.2% Program: [====================] 100.0% Verify : [ ] 1.0% Verify : [====================] 100.0% Rebooting. Elapsed Time 25.276
: Simulink IO:Error: IO server is not flashed properly. Reconnect the board and try again
I also encountered the same problem. My MATLAB version is 2022a and the flight control version is pixhawk4. In simulink, in connected IO mode, run with io, the above error occurred. How should it be solved?
  1 Commento
riley
riley il 3 Apr 2025
Upgrading to a newer verison of matlab might be helpful. But I noticed running my model with no PX4 blocks and only a display block would allow the Connected I/O to intialize, then subsequent attempts to run Connected I/O with the Px4 sensor blocks should work.

Accedi per commentare.

Prodotti


Release

R2024b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by