Usage of virtual time in embedded Linux testing
Wuoti, Elias (2021)
Wuoti, Elias
2021
Informaatioteknologian ja viestinnän tiedekunta - Faculty of Information Technology and Communication Sciences
This publication is copyrighted. Only for Your own personal use. Commercial use is prohibited.
Hyväksymispäivämäärä
2021-05-05
Julkaisun pysyvä osoite on
https://urn.fi/URN:NBN:fi:tuni-202104273780
https://urn.fi/URN:NBN:fi:tuni-202104273780
Tiivistelmä
Modern software engineering is based on fast release and delivery schedules. To enable fast releases, software testing must also support the rapid development cycles. Fast release schedules affect embedded device development as well.
One method of increasing the speed of testing in embedded systems development is with the use of virtual time. Virtual time is a concept in computing where the time inside a device progresses at a different rate compared to inside the device. Using virtual time, the speed at which a device runs can be altered. The rate is referred to as time dilation factor (TDF). This thesis describes different virtual time methods and categorizes them based on the level virtual time is implemented on.
In this thesis virtual time is implemented on an embedded Linux device used for protection in electrical substations. The protection functionality of the device is tested with a series of system tests, one of which is examined in this thesis. The system test examined in this thesis verifies that the overcurrent detection on the device works correctly. In this thesis, a component on the device is implemented to record the system test for later replay. The replay functionality works with the device feeding the frames from the file to itself.
The virtual time implementation on the device is based on fast-forwarding time between frames in the system test recording. The virtual time implementation works using a centralized virtual time manager and individual virtual time gatekeepers. The virtual time gatekeepers request fast-forwarding from the virtual time manager, which handles the requests for fast-forwarding: once every gatekeeper has requested fast-forward, time is skipped to the earliest requested timestamp.
The performance of the virtual time implementation in this thesis is evaluated by running the overcurrent detection system test in virtual time. Verification of the system test results is done using network traffic capture, which contained both the timestamps inside and outside of the device. Based on the relation of the timestamps, the TDF of the virtual time is calculated. With the calculations, the system is determined to have a TDF of 2, meaning that the system runs twice as fast in virtual time compared to real time.
One method of increasing the speed of testing in embedded systems development is with the use of virtual time. Virtual time is a concept in computing where the time inside a device progresses at a different rate compared to inside the device. Using virtual time, the speed at which a device runs can be altered. The rate is referred to as time dilation factor (TDF). This thesis describes different virtual time methods and categorizes them based on the level virtual time is implemented on.
In this thesis virtual time is implemented on an embedded Linux device used for protection in electrical substations. The protection functionality of the device is tested with a series of system tests, one of which is examined in this thesis. The system test examined in this thesis verifies that the overcurrent detection on the device works correctly. In this thesis, a component on the device is implemented to record the system test for later replay. The replay functionality works with the device feeding the frames from the file to itself.
The virtual time implementation on the device is based on fast-forwarding time between frames in the system test recording. The virtual time implementation works using a centralized virtual time manager and individual virtual time gatekeepers. The virtual time gatekeepers request fast-forwarding from the virtual time manager, which handles the requests for fast-forwarding: once every gatekeeper has requested fast-forward, time is skipped to the earliest requested timestamp.
The performance of the virtual time implementation in this thesis is evaluated by running the overcurrent detection system test in virtual time. Verification of the system test results is done using network traffic capture, which contained both the timestamps inside and outside of the device. Based on the relation of the timestamps, the TDF of the virtual time is calculated. With the calculations, the system is determined to have a TDF of 2, meaning that the system runs twice as fast in virtual time compared to real time.