メインコンテンツ

アルゴリズムの開発と PX4 Autopilot での展開

アルゴリズムを開発し、PX4 Autopilot に展開するモデルを準備する

アルゴリズムを開発し、PX4 Autopilot に展開するモデルを準備します。これらのトピックには、モデル コンフィギュレーション パラメーター、COM ポートの設定、および Simulink® からの PX4 Autopilot の展開に関する追加情報が記載されています。

ブロック

すべて展開する

I2C Controller ReadRead data from I2C peripheral device or I2C peripheral device register
I2C Controller WriteWrite data to I2C peripheral device or I2C peripheral device register
PX4 Analog InputMeasure analog voltage applied to an ADC channel
PX4 CAN ReceiveReceive message from CAN network (R2022b 以降)
PX4 CAN Transmit Transmit message to CAN network (R2022b 以降)
Serial ReceiveRead data from UART or USART port on PX4 flight controller
Serial TransmitSend serial data to UART or USART port
AccelerometerRead sensor_accel uORB topic and obtain three dimensional linear acceleration
BatteryRead battery_status uORB topic and obtain details about the battery's state
GPSRead vehicle_gps_position uORB topic and obtain GPS coordinates
GyroscopeRead sensor_gyro uORB topic and obtain three dimensional rate of rotation
MagnetometerRead sensor_mag uORB topic and obtain three dimensional magnetic field
Radio Control TransmitterRead input_rc uORB topic to obtain data from Radio Control Transmitter
Vehicle AttitudeRead vehicle_odometry uORB topic and obtain attitude measurements
PX4 uORB MessageCreate a blank message using specified uORB topic
PX4 uORB ReadRead uORB data for the specified uORB topic
PX4 uORB WriteWrite uORB data for the specified uORB topic
MAVLink Bridge SourceRead MAVLink data from the Pixhawk board (R2022a 以降)
MAVLink Bridge SinkWrite MAVLink data to the Pixhawk board (R2022a 以降)
PX4 Read Position SetpointRead the position setpoints published by the PX4 Navigator module in the uORB topic position_setpoint_triplet (R2021b 以降)
PX4 TimestampOutput absolute timestamp from the PX4 Autopilot to a Simulink model (R2023b 以降)
PX4 ULogLog Simulink signals to an SD card in ULog format (R2023b 以降)
PX4 Write ParameterWrite PX4 system parameters (R2025a 以降)
Read ParameterRead PX4 system parameters

関数

getMATFilesFromPixhawkRetrieve MAT files from SD card inserted on Pixhawk hardware board
px4MATFilestitcherCombine multiple MAT-files retrieved from SD card into a single MAT-file
createPX4uORBMessageSimulink モデルにおいて、ログ用のカスタム uORB トピックを作成する (R2023b 以降)
createCustomPX4ParameterCreate custom PX4 parameter for writing to the PX4 system parameter (R2025a 以降)

トピック

Simulink モデルの設定

PX4 Autopilot の周辺装置の情報

PX4 Autopilot との MAVLink 通信

追加情報

トラブルシューティング

Troubleshooting Deploy to Hardware Issues

Solve the problems when you try to deploy the Simulink model to Pixhawk Series flight controllers.

Troubleshooting PX4 Firmware Build Failure Due to Flash Memory Overflow on the Hardware

Solve the flash memory overflow on the hardware issues while using the default px4 board build target file.

Troubleshooting Running Out of File Descriptor Issues

Solve the running out of file descriptor issues.

Troubleshooting USB Issues with Cube Orange on Windows

Solve the USB issues with Cube Orange.

注目の例