• Home
    • Copter
    • Plane
    • Rover
    • Blimp
    • Sub
    • AntennaTracker
    • Mission Planner
    • APM Planner 2
    • MAVProxy
    • Companion Computers
    • Developer
  • Downloads
    • Mission Planner
    • APM Planner 2
    • Advanced User Tools
    • Developer Tools
    • Firmware
  • Community
    • Support Forums
    • Facebook
    • Developer Chat (Discord)
    • Developer Voice (Discord)
    • Contact us
    • Getting involved
    • Commercial Support
    • Development Team
    • UAS Training Centers
  • Stores
  • About
    • History
    • License
    • Trademark
    • Acknowledgments
    • Wiki Editing Guide
    • Partners Program
Dev Logo

Getting Started

  • Downloading the code / Using Git
  • Building the code
  • Editors & IDEs
  • Learning the code
  • Simulation & Testing
    • SITL Simulator
    • Mission Planner Simulation
    • Gazebo
    • XPlane-10
    • XPlane-10 Soaring
    • RealFlight
    • Morse
    • Replay
    • JSBSim
    • AirSim
    • Silent Wings Soaring
    • Last Letter
    • CRRCSim
    • HITL Simulators
    • Autotest Framework
    • Autotest Tests
    • Unit Tests
    • SCRIMMAGE
    • Webots
    • MATLAB and Simulink
      • MATLAB Simulation
      • Simulink Simulation
      • Plotting in real time
      • MATLAB serial driver testing
    • JSON interface
  • Debugging
  • License (GPLv3)

Contributing

  • Contributing Code
  • How The Team Works
  • Wiki Editing Guide
  • GSoC

Hardware & Peripherals

  • Porting to a new Flight Controller
  • Advanced Hardware Info
  • AP_Peripheral Devices
  • Companion Computers
  • Linux Support
  • OEM Customization
  • RTF Vehicle Developer Information
  • USB IDs

Protocols & Interfaces

  • MAVLink Interface
  • MAVProxy Developer GCS
  • GCS Developer Resources
  • CAN and DroneCAN/UAVCAN
  • Lua Scripts
  • ROS1
  • ROS2
  • RemoteID

Security & Reference

  • Security
  • Support Proxy
  • User Alerts
  • Appendix

Community & Events

  • Developers Conference
  • Events
  • Training Centers
  • Academic Works Involving ArduPilot


Individual Partners SWAG Shop
Dev
  • Simulation
  • MATLAB and Simulink
  • Edit on GitHub

MATLAB and SimulinkΒΆ

All Matlab and Simulink functions rely on the TCP/UDP/IP Toolbox 2.0.6. A modified version of the toolbox is provided in the ArduPilot repository. The toolbox is compiled into a MEX file allowing for fast connection speeds, also removing the need for a licence for the official TCP/UDP tools. Pre-built MEX files are provided for Windows and Linux however it may be necessary to compile locally. The basic MATLAB Simulation copter example will try to do this if no MEX file is found. This should be run before trying the other examples.

  • MATLAB Simulation
  • Simulink Simulation
  • Plotting in real time
  • MATLAB serial driver testing

Tip

For advice using MATLAB and Simulink with ArduPilot please join the simulation channel on Discord.

Previous Next

Questions, issues, and suggestions about this page can be raised on the forums. Issues and suggestions may be posted on the forums or the Github Issue Tracker.

Creative Commons License© Copyright 2024, ArduPilot Dev Team.