The objective of this thesis is to develop a quadcopter Higher Order Sliding Mode (HOSM) trajectory tracker controller, and to integrate it in the PX4 open source autopilot software. The first part is dedicated to the analysis of the PX4 firmware with a focus on its key elements that we exploited in the pursuit of the aforementioned aim. In particular, PX4 offers a sophisticated simulation environment powered by the Gazebo simulator; furthermore, its middleware, based on a publish/subscribe paradigm, facilitates the integration and the interaction of the developed modules with the pre-existing architecture. The design of the HOSM controller is simplified if the system can be expressed in one of the canonical forms. Thus, in the second part, we exploit the flatness theory to transform the nonlinear coupled quadrotor model into four single-input independent subsystems in Brunovski canonical form. In particular, we propose both a feedback and a feedforward linearization approaches. Having linearized the quadcopter systems, allowed us also to employ a pole placement controller to perform the trajectory tracking task. The three main PX4 modules developed during the thesis are: a Levant differentiator used to estimate the vehicle jerk from the accelerometer noisy signals, a module implementing the quadcopter linearization, and, finally, the trajectory tracking controller based on the pole placement or the HOSM approaches. Moreover, we developed a custom ground station application to remotely command and communicate with the vehicle during the flight. Lastly, we compared the two novel control approaches with the default cascaded PID control architecture used by PX4. The results achieved by the pole placement controller are superior with respect to the cascaded PID, thus proving the effectiveness of the linearization and the differentiator. On the other hand, the PX4 firmware characteristics hindered the HOSM controller: in fact, the PX4 state estimator runs at 250Hz, while the HOSM controller requires a frequency of at least 1kHz to be effective.
L'obbiettivo della presente tesi è lo sviluppo di un controllore Higher Order Sliding Mode (HOSM) per l'inseguimento di traiettoria su quadricottero, e la sua integrazione con il software di autopilota PX4. La prima parte è dedicata all'analisi del firmware PX4, con particolare attenzione agli elementi chiave per il lavoro svolto. In particolare, PX4 offre un ambiente di simulazione molto realistico grazie al simulatore Gazebo; inoltre, il suo middleware, basato sul paradigma publish/subscribe, facilita l'integrazione e l'interazione dei nuovi componenti con l'architettura pre-esistente. Il design di un controllore HOSM è agevolato se il sistema in analisi può essere espresso in una delle forme canoniche. Perciò, nella seconda parte, abbiamo sfruttato la teoria del controllo flatness per trasformare il modello non lineare del quadricottero in quattro sottosistemi lineri ed indipendenti espressi in forma canonica di Brunovski. In particolare abbiamo proposto sia una linearizzazione con feedback che una con feedforward. Avendo linearizzato il modello del quadricottero, abbiamo anche potuto implementare un controllore basato sul piazzamento dei poli del sistema in anello chiuso. I tre principali moduli di PX4 che abbiamo sviluppato sono: un differenziatore di Levant usato per stimare lo strappo del veicolo dai dati dell'accelerometro, un modulo dedicato alla linearizzazione del modello, ed infine, il controllore di traiettoria basato sul piazzamento dei poli o su HOSM. Inolre, abbiamo sviluppato una stazione di controllo di terra per comandare e comunicare con il drone durante il volo. Infine, abbiamo confrontato i nuovi controllori con l'architettura di controllo proposta da PX4 basata su PID in csacata. I risultati ottenuti dal controllore con piazzamento dei poli sono migliori rispetto alla soluzione proposta da PX4, validando di conseguenza il lnearizzatore ed il differenziatore. Tuttavia, le caratteristiche di PX4 hanno ostacolato il funzionamento del controllore HOSM: infatti, lo stimatore degli stati di PX4 ha una frequenza di 250Hz, mentre il controllore HOSM richiede una frequenza di almeno 1kHz per essere effettivo.
Quadrotor HOSM controller implementation on PX4 autopilot
Colli, Stefano
2022/2023
Abstract
The objective of this thesis is to develop a quadcopter Higher Order Sliding Mode (HOSM) trajectory tracker controller, and to integrate it in the PX4 open source autopilot software. The first part is dedicated to the analysis of the PX4 firmware with a focus on its key elements that we exploited in the pursuit of the aforementioned aim. In particular, PX4 offers a sophisticated simulation environment powered by the Gazebo simulator; furthermore, its middleware, based on a publish/subscribe paradigm, facilitates the integration and the interaction of the developed modules with the pre-existing architecture. The design of the HOSM controller is simplified if the system can be expressed in one of the canonical forms. Thus, in the second part, we exploit the flatness theory to transform the nonlinear coupled quadrotor model into four single-input independent subsystems in Brunovski canonical form. In particular, we propose both a feedback and a feedforward linearization approaches. Having linearized the quadcopter systems, allowed us also to employ a pole placement controller to perform the trajectory tracking task. The three main PX4 modules developed during the thesis are: a Levant differentiator used to estimate the vehicle jerk from the accelerometer noisy signals, a module implementing the quadcopter linearization, and, finally, the trajectory tracking controller based on the pole placement or the HOSM approaches. Moreover, we developed a custom ground station application to remotely command and communicate with the vehicle during the flight. Lastly, we compared the two novel control approaches with the default cascaded PID control architecture used by PX4. The results achieved by the pole placement controller are superior with respect to the cascaded PID, thus proving the effectiveness of the linearization and the differentiator. On the other hand, the PX4 firmware characteristics hindered the HOSM controller: in fact, the PX4 state estimator runs at 250Hz, while the HOSM controller requires a frequency of at least 1kHz to be effective.File | Dimensione | Formato | |
---|---|---|---|
2024_04_Colli_Tesi_01.pdf
accessibile in internet solo dagli utenti autorizzati
Descrizione: Testo tesi
Dimensione
5.9 MB
Formato
Adobe PDF
|
5.9 MB | Adobe PDF | Visualizza/Apri |
2024_04_Colli_Executive_Summary_02.pdf
accessibile in internet solo dagli utenti autorizzati
Descrizione: Executive summary
Dimensione
1.05 MB
Formato
Adobe PDF
|
1.05 MB | Adobe PDF | Visualizza/Apri |
I documenti in POLITesi sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.
https://hdl.handle.net/10589/219849