Return to search

Exploration of AirSim using C and Rust in the Context of SafetyCritical Systems / Utforskning av AirSim med hjälp av C och Rust inom ramen för Säkerhetskritiska System

AirSim is a new simulator developed as a plugin for the Unreal Engine, aiming to be a useful tool aiding the development and testing of algorithms for autonomous vehicles. Due to AirSim still being in its infancy there is little to none research available of its possibilities or detailed guidelines and tutorials on how to use its APIs.Rust is a new systems programming language with the purpose of being safe, practical and concurrent which through design choices can solve some of the major drawbacks of the C programming language such as memory leaks, thread management, and segmentation faults.Researching the features of AirSim and its different ways of communicating, we determine the possibility of implementing a custom flight controller in Rust and C able to control a drone in the simulator and evaluate the capabilities of Rust compared to C. This is conducted by reading available documentation for AirSim, studying the source code and learning about the communication protocols used by AirSim.This thesis results in an implementation of a custom flight controller in Rust and C that controls a drone in AirSim using a communication protocol named MAVLink which enables fine-grained control of the motors. The conclusion made about the comparison of Rust and C is that both languages were able to implement the safety-critical functionality of the flight controller and that Rust provided capabilities which could be useful when developing safety-critical systems. / AirSim är en ny simulator utvecklad som ett plugin för Unreal Engine, med målet att fungera som ett hjälpmedel inom utveckling och testning av algoritmer för autonoma fordon. På grund av att AirSim fortfarande är väldigt ungt finns väldigt lite forskning tillgänglig om dess möjligheter eller detaljerade riktlinjer och beskrivningar för användningen av dess APIer.Rust är ett nytt programmeringsspråk med målet att vara säkert, praktiskt och parallellt vilket genom designval kan lösa några av de största problemen med programmeringsspråket C som till exempel minnessläckor, trådhantering och segmenteringsfel.Genom att undersöka funktionerna i AirSim och dess olika sätt att kommunicera, utforskar vi möjligheten av att utveckla en egen flygkontroller i Rust och C som kan styra en drönare i simulatorn och utvärdera Rust i förhållande till C. Detta genomförs genom att läsa tillgänglig dokumentation för AirSim, studera källkoden och lära oss de kommunikationsprotokoll som används av AirSim.Denna avhandling resulterar i implementationen av en egen flygkontroller i Rust och C som styr en drönare i AirSim med kommunikationsprotokollet MAVLink, vilket möjliggör en noggrann kontroll av motorerna. Slutsatsen gällande Rust och C är att båda språken fungerade väl för implementationen av säkerhetsritiska funktioner i flygkontrollern samt att Rust erbjöd förmågor som kan visa sig vara användbara vid utveckling av säkerhetskritiska system.

Identiferoai:union.ndltd.org:UPSALLA1/oai:DiVA.org:kth-235488
Date January 2018
CreatorsAros Banda, Daniel, Wachsler, Joel
PublisherKTH, Skolan för elektroteknik och datavetenskap (EECS)
Source SetsDiVA Archive at Upsalla University
LanguageEnglish
Detected LanguageSwedish
TypeStudent thesis, info:eu-repo/semantics/bachelorThesis, text
Formatapplication/pdf
Rightsinfo:eu-repo/semantics/openAccess
RelationTRITA-EECS-EX ; 2018:180

Page generated in 0.0028 seconds