Airnamics Develops Unmanned Aerial System for Close-Range Filming with Model-Based Design
- Time-to-market shortened by up to an order of magnitude
- Test flight anomalies quickly resolved
- Debugging time reduced from weeks to hours
“With Model-Based Design our three-engineer team found more than 95% of control software bugs before the first flight. We used the test flights to increase our Simulink models’ fidelity and isolate remaining bugs with high precision. The result is a safer, more reliable, and higher-quality product.”Marko Thaler, Airnamics
The Airnamics R5 unmanned aerial system (UAS) provides cinematographers with a camera motion system for close-range aerial filming. With a top speed of 130 kph (80 mph), a camera payload of 8 kg (18 lbs), and a GPS system accurate to within 25 millimeters (1 inch), the R5 is designed to deliver unprecedented levels of performance, safety, and ease of use.
Airnamics accelerated development of the R5’s fly-by-wire (FBW) controller and flight management system (FMS) by using Model-Based Design with MATLAB® and Simulink®.
“In flight control system performance, reliability and safety are primary concerns,” says Dr. Marko Thaler, CEO and CTO at Airnamics. “You cannot take shortcuts, because if you do, you’ll eventually crash. With Model-Based Design we were able to test the entire system via simulation. As a result, we not only sped the development and debugging of control algorithms, we also produced higher-quality code without expensive prototyping or long development cycles.”
The Airnamics development team consisted of just three engineers. Initially the team relied on handwritten C code. After several months of development, they concluded that this approach was slow and inefficient. They lacked an easy way to run high-fidelity simulations using the handwritten code, which made debugging and quality assurance activities difficult. As reliability and safety concerns mounted, the company looked for a new approach.
The engineers wanted to model the R5 aircraft and its control systems and run simulations to verify and optimize the control algorithms. They also wanted to rapidly prototype the controller by generating code from the model and running the code on a real-time machine on the vehicle. Ultimately, their goal was to complete production versions of the software that could be certified by aviation authorities for real-world operation.
Airnamics adopted Model-Based Design with MATLAB and Simulink to accelerate development of FBW and FMS software for the R5 UAS.
While Thaler already had substantial experience with MATLAB and Simulink, his two colleagues had only limited experience. They quickly came up to speed by using webinars and examples on mathworks.com and consulting MathWorks application engineers.
Working with Simulink and basic components in Aerospace Blockset™, the team created a plant model of the R5 aircraft, including the airframe, eight motors and propellers, three inertial measurement units (for redundancy and better gyro head stabilization performance), a laser range finder, and other sensors.
Using Simulink and Control System Toolbox™ they created a control model that included an attitude and motion control algorithm and an extended Kalman filter for state estimation.
They ran closed-loop simulations of the control model and plant model to verify controller functionality. As the design progressed, they simulated sensor failures, motor failures, wind gusts, and other scenarios.
During the simulations, the team used Simulink 3D Animation™ to visualize the dynamic system behavior of the R5 aircraft.
In preparation for flight tests, they used Simulink Coder™ to generate code from the controller model, which they compiled and deployed to a custom-developed onboard PC with an Intel® Atom™ processor running Simulink Real-Time™.
Following flight tests, the team analyzed flight recorder data in MATLAB, and used the results to refine the plant model and optimize the controller. In some cases, the team accelerated development iterations by updating the model and generating new code in the field between flights.
Airnamics is currently finalizing the R5 design and preparing it for certification. The company now offers a UAS development service to clients that covers everything from conceptual design to serial production of custom-made UAS systems.
Time-to-market shortened by up to an order of magnitude. “When developing a new UAS system from scratch, we’ve found that, for a small team like ours, Model-Based Design can reduce the time-to-market and development cost by up to an order of magnitude compared with a traditional development approach with hand-coding,” says Thaler.
Test flight anomalies quickly resolved. “A strong wind gust during flight testing resulted in unexpected behavior of the R5 control system,” says Thaler. “We used the flight recorder data and Simulink to determine the direction and intensity of the gust, analyze the control algorithm’s response, and quickly pinpoint the part of algorithm that was not performing optimally.”
Debugging time reduced from weeks to hours. “With Model-Based Design we have the ability to understand and reproduce errors in simulation instead of relying on flight tests alone,” notes Thaler. “As a result, in a matter of hours we can find and fix bugs that would previously have taken weeks to resolve.”