Submitted:
24 July 2023
Posted:
24 July 2023
You are already at the latest version
Abstract
Keywords:
1. Introduction
2. Related Work
3. Materials and Methods
3.1. Tower System Architecture
3.2. Tower System Software Infrustructure
3.3. Methodology
3.3.1. Multithreaded Application
3.3.2. Multiple Processes and Threads Generation
| Algorithm 1 Iterative multiple processes and threads creation |
| Inputs: number of processes p [2:np], number of threads th [2:32] |
| create_processes(p) { |
| for number of processes np { |
| set_process_attributes(); |
| set_process_policy(RoundRobin, 99); |
| create_threads(th); { |
| for number of threads nth { |
| pthread_create(&threads[nth--], NULL, threads_functions[nth--], NULL); |
| pthread_join(threads[nth--], NULL); }}} |
| threads_functions(nth); { set_threads_attributes(); if (th%2<>0) sort_ops(); } //sorting operations else matrix_ops(); } //matrix operations perform_measurements(); Outputs: measurements [execution time, threads waiting time, response latency] |
3.4. Performance Metrics
3.4.1. Execution time
3.4.2. Threads waiting time
3.4.3. Response time
4. Results
4.1. The Experimental Framework
4.2. Performance Measurements on TWR-K70F120M Platform
4.3. Comparative Performance Measurements
4.4. Benchmarking
5. Discussion
6. Conclusions
Funding
Data Availability Statement
Acknowledgments
Conflicts of Interest
References
- Fernández-Cerero, D.; Fernández-Rodríguez, J.Y.; Álvarez-García, J.A.; Soria-Morillo, L.M.; Fernández-Montes, A. Single-Board-Computer Clusters for Cloudlet Computing in Internet of Things. Sensors 2019, 19, 3026. [Google Scholar] [CrossRef] [PubMed]
- Adam, G.K. Real-time performance analysis of distributed multithreaded applications in a cluster of ARM-based embedded devices. International Journal of High Performance Systems Architecture 2022, 11, 105–116. [Google Scholar] [CrossRef]
- Coelho, P.; Bessa, C.; Landeck, J.; Silva, C. The Potential of Low-Power, Cost-Effective Single Board Computers for Manufacturing Scheduling. Procedia Computer Science 2023, 217, 904–911. [Google Scholar] [CrossRef]
- Galkin, P.; Golovkina, L.; Klyuchnyk, I. Analysis of Single-Board Computers for IoT and IIoT Solutions in Embedded Control Systems. In Proceedings of the International Scientific-Practical Conference Problems of Infocommunications, Kharkiv, Ukraine, 9-12 October 2018; pp. 297–302. [Google Scholar] [CrossRef]
- Prashanth, K.V.; Akram, P.S.; Reddy, T.A. Real-time issues in embedded system design. In Proceedings of the International Conference on Signal Processing and Communication Engineering Systems, Guntur, India, 2-3 January 2015; pp. 167–171. [Google Scholar] [CrossRef]
- Hee, Y.H.; Ishak, M.K.; Asaari, M.S.M.; Seman, M.T.A. Embedded operating system and industrial applications: a review. Bulletin of Electrical Engineering and Informatics 2021, 10, 1687–1700. [Google Scholar] [CrossRef]
- Ungurean, I. Timing Comparison of the Real-Time Operating Systems for Small Microcontrollers. Symmetry 2020, 12, 592. [Google Scholar] [CrossRef]
- Costa, D.G.; Duran-Faundez, C. Open-Source Electronics Platforms as Enabling Technologies for Smart Cities: Recent Developments and Perspectives. Electronics 2018, 7, 404. [Google Scholar] [CrossRef]
- Rodrigues, J.M.F.; Cardoso, P.J.S.; Monteiro, J. Smart Systems Design, Applications, and Challenges. IGI Global: Hershey, USA, 2020.
- KBV Research: Single Board Computer Market Size. Available online: www.kbvresearch.com/single-board-computer-market/ (accessed on 5 July 2023).
- NXP Semiconductors: Kinetis K70 120 MHz Tower System Module. Available online: www.nxp.com/design/development-boards/tower-development-boards/mcu-and-processor-modules/kinetis-modules/kinetis-k70-120-mhz-tower-system-module:TWR-K70F120M (accessed on 4 February 2023).
- Adam Co.: Automatic Press Machines. Available online: https://www.adam.com.gr/ (accessed on 15 March 2023).
- µClinux. Available online: https://en.wikipedia.org/wiki/%CE%9CClinux (accessed on 11 April 2023).
- ModBerry: Industrial Raspberry Pi with Compute Module 4. Available online: https://modberry.techbase.eu/tag/compute-module-4/ (accessed on 25 April 2023).
- NXP Semiconductors: S32V2 Vision and Sensor Fusion low-cost Evaluation Board. Available online: www.nxp.com/design/development-boards/automotive-development-platforms/s32v-mpu-platforms/s32v2-vision-and-sensor-fusion-low-cost-evaluation-board:SBC-S32V234 (accessed on 16 January 2023).
- RevPi: Open Source IPC based on Raspberry Pi. Available online: https://revolutionpi.com/ (accessed on 5 December 2022).
- Wang, K.C. Embedded and Real-Time Operating Systems. Springer: Cham, Switzerland, 2017.
- Seo, S.; Kim, J.; Kim, S.M. An Analysis of Embedded Operating Systems: Windows CE Linux VxWorks uC/OS-II and OSEK/VDX. Int. J. Appl. Eng. Res. 2017, 12, 7976–7981. [Google Scholar]
- Adam, G.K. Co-Design of Multicore Hardware and Multithreaded Software for Thread Performance Assessment on an FPGA. Computers 2022, 11, 76. [Google Scholar] [CrossRef]
- MicroC/OS: Micro-Controller Operating Systems. Available online: https://en.wikipedia.org/wiki/Micro-Controller_Operating_Systems (accessed on 7 March 2023).
- Aysu, A.; Gaddam, S.; Mandadi, H.; Pinto, C.; Wegryn, L.; Schaumont, P. A design method for remote integrity checking of complex PCBs. In Proceedings of the Design, Automation & Test in Europe Conference & Exhibition, Dresden, Germany, 14-18 March 2016; pp. 1517–1522. [Google Scholar]
- Musaddiq, A.; Zikria, Y.B.; Hahm, O.; Yu, H.; Bashir, A.K.; Kim, S.W. A Survey on Resource Management in IoT Operating Systems. IEEE Access 2018, 6, 8459–8482. [Google Scholar] [CrossRef]
- Belleza, R.R.; Freitas, E.P. Performance study of real-time operating systems for internet of things devices. IET Softw. 2018, 12, 176–182. [Google Scholar] [CrossRef]
- Petrellis, N. A Scalar Interpolator for the Improvement of an ADC Output Linearity. International. Journal of Engineering Science and Innovative Technology 2014, 3, 591–600. [Google Scholar]
- Arrobo, G.E.; Perumalla, C.A.; Hanke, S.B.; Ketterl, T.P.; Fabn, P.J.; Gitin, R.D. An innovative wireless Cardiac Rhythm Management (iCRM) system. In Proceedings of the Wireless Telecommunications Symposium, Washington, DC, USA, 9-11 April 2014; pp. 1–5. [Google Scholar] [CrossRef]
- Deschambault, O.; Gherbi, A.; Legare, C. Efficient Implementation of the MQTT Protocol for Embedded Systems. J Inf Process Syst 2017, 13, 26–39. [Google Scholar] [CrossRef]
- Vicari, L. Performance analysis of an embedded system. MSc Thesis, Politecnico Di Torino, Torino, Italy, 2018. [Google Scholar]
- wolfSSL Inc.: Benchmarking wolfSSL and wolfCrypt. Available online: www.wolfssl.com/docs/benchmarks/ (accessed on 5 June 2023).
- NXP Semiconductors: CodeWarrior Embedded Software Development Tools. Available online: www.nxp.com/design/software/development-software/codewarrior-development-tools:CW_HOME (accessed on 8 December 2022).
- NXP-TWR. Available online: https://github.com/gadam2018/NXP-TWR (accessed on 20 July 2023).













| Threads | Sort Alg | Datasets (of 32-bit integers) | |||||||
|---|---|---|---|---|---|---|---|---|---|
| 102 | 103 | 104 | 105 | 106 | |||||
| Execution Time (ms) | avg | mean | ratio | ||||||
| 2 | Selection | 0.25 | 0.45 | 1.52 | 2.56 | 5.90 | 2.136 | 1.83 | - |
| Quick | 0.18 | 0.30 | 1.09 | 1.79 | 4.30 | 1.532 | |||
| 4 | Selection | 0.22 | 0.37 | 1.27 | 2.12 | 5.25 | 1.846 | 1.67 | -9% |
| Quick | 0.17 | 0.31 | 1.10 | 1.67 | 4.20 | 1.490 | |||
| 8 | Selection | 0.20 | 0.29 | 1.10 | 1.98 | 4.97 | 1.708 | 1.58 | -14% |
| Quick | 0.18 | 0.32 | 1.12 | 1.56 | 4.11 | 1.458 | |||
| 16 | Selection | 0.17 | 0.25 | 1.02 | 1.88 | 4.56 | 1.576 | 1.48 | -19% |
| Quick | 0.17 | 0.29 | 1.01 | 1.45 | 3.97 | 1.378 | |||
| 32 | Selection | 0.16 | 0.23 | 0.97 | 1.82 | 4.48 | 1.532 | 1.44 | -22% |
| Quick | 0.15 | 0.25 | 1.00 | 1.43 | 3.87 | 1.340 | |||
| Threads | Matrix | Matrices (size of short integers) | |||||||
|---|---|---|---|---|---|---|---|---|---|
| 512 | 1024 | 2048 | 4096 | 8192 | |||||
| Execution Time (ms) | avg | mean | ratio | ||||||
| 2 | Addition | 0.02 | 0.04 | 0.09 | 0.20 | 0.32 | 0.134 | 0.20 | - |
| Multiplication | 0.05 | 0.09 | 0.21 | 0.29 | 0.67 | 0.262 | |||
| 4 | Addition | 0.02 | 0.03 | 0.07 | 0.20 | 0.31 | 0.126 | 0.19 | -2% |
| Multiplication | 0.04 | 0.11 | 0.22 | 0.29 | 0.65 | 0.262 | |||
| 8 | Addition | 0.04 | 0.05 | 0.06 | 0.21 | 0.34 | 0.140 | 0.21 | 7% |
| Multiplication | 0.06 | 0.13 | 0.24 | 0.32 | 0.66 | 0.282 | |||
| 16 | Addition | 0.05 | 0.07 | 0.09 | 0.25 | 0.38 | 0.168 | 0.24 | 20% |
| Multiplication | 0.08 | 0.15 | 0.26 | 0.35 | 0.69 | 0.306 | |||
| 32 | Addition | 0.07 | 0.10 | 0.11 | 0.29 | 0.44 | 0.202 | 0.28 | 41% |
| Multiplication | 0.12 | 0.20 | 0.31 | 0.40 | 0.75 | 0.356 | |||
| Threads | Average execution time (ms) | Average threads waiting time (ms) | Average response time (ms) | |||||||||
| Sorting ops | Matrix ops | mean | ratio | Sorting ops | Matrix ops | mean | ratio | Sorting ops | Matrix ops | mean | ratio | |
| 2 | 1.834 | 0.198 | 1.016 | - | 0.877 | 0.041 | 0.459 | - | 0.454 | 0.024 | 0.239 | - |
| 4 | 1.668 | 0.194 | 0.931 | -8% | 0.686 | 0.052 | 0.369 | -20% | 0.470 | 0.015 | 0.243 | 1% |
| 8 | 1.583 | 0.211 | 0.897 | -12% | 0.824 | 0.046 | 0.435 | -5% | 0.512 | 0.023 | 0.268 | 12% |
| 16 | 1.477 | 0.237 | 0.857 | -16% | 0.765 | 0.060 | 0.413 | -10% | 0.531 | 0.010 | 0.271 | 13% |
| 32 | 1.436 | 0.279 | 0.858 | -16% | 0.785 | 0.072 | 0.429 | -7% | 0.560 | 0.022 | 0.291 | 22% |
| Platform | Linux Kernel | Threads | Average execution time (ms) |
Average threads waiting time (ms) | Average response time (ms) |
|||
| Sorting ops | Matrix ops | Sorting ops | Matrix ops | Sorting ops | Matrix ops | |||
| TWR | 2.6 | 2 | 1.834 | 0.198 | 0.877 | 0.041 | 0.454 | 0.024 |
| RPi4 | 4.14 | 3.12 | 0.23 | 1.3 | 0.8 | 0.9 | 0.008 | |
| BBAI | 4.14 | 2.79 | 0.2 | 0.9 | 0.7 | 0.5 | 0.007 | |
| TWR | 2.6 | 4 | 1.668 | 0.194 | 0.686 | 0.052 | 0.470 | 0.015 |
| RPi4 | 4.14 | 2.89 | 0.17 | 1.2 | 0.6 | 0.8 | 0.006 | |
| BBAI | 4.14 | 2.36 | 0.19 | 0.6 | 0.5 | 0.5 | 0.007 | |
| TWR | 2.6 | 8 | 1.583 | 0.237 | 0.824 | 0.046 | 0.512 | 0.023 |
| RPi4 | 4.14 | 2.5 | 0.14 | 1.2 | 0.7 | 0.7 | 0.005 | |
| BBAI | 4.14 | 2.08 | 0.18 | 0.5 | 0.5 | 0.4 | 0.006 | |
| TWR | 2.6 | 16 | 1.477 | 0.237 | 0.765 | 0.060 | 0.531 | 0.010 |
| RPi4 | 4.14 | 2.39 | 0.12 | 1.1 | 0.6 | 0.6 | 0.004 | |
| BBAI | 4.14 | 1.98 | 0.16 | 0.3 | 0,4 | 0.5 | 0.006 | |
| TWR | 2.6 | 32 | 1.436 | 0.279 | 0.785 | 0.072 | 0.560 | 0.022 |
| RPi4 | 4.14 | 2.3 | 0.11 | 1.1 | 0.7 | 0.7 | 0.005 | |
| BBAI | 4.14 | 1.87 | 0.15 | 0.3 | 0.5 | 0.6 | 0.006 | |
| Platform | Threads | Average execution time (ms) | Average threads waiting time (ms) | Average response time (ms) |
| TWR | 2 | 1.016 | 0.459 | 0.239 |
| RPi4 | 1.675 | 1.050 | 0.454 | |
| BBAI | 1.495 | 0.800 | 0.254 | |
| TWR | 4 | 0.931 | 0.369 | 0.243 |
| RPi4 | 1.530 | 0.900 | 0.403 | |
| BBAI | 1.275 | 0.550 | 0.254 | |
| TWR | 8 | 0.897 | 0.435 | 0.268 |
| RPi4 | 1.320 | 0.950 | 0.353 | |
| BBAI | 1.130 | 0.500 | 0.203 | |
| TWR | 16 | 0.857 | 0.413 | 0.271 |
| RPi4 | 1.255 | 0.850 | 0.302 | |
| BBAI | 1.070 | 0.350 | 0.253 | |
| TWR | 32 | 0.858 | 0.429 | 0.291 |
| RPi4 | 1.205 | 0.900 | 0.353 | |
| BBAI | 1.010 | 0.400 | 0.303 |
| wolfCrypt Benchmark |
OS | Duration (sec) | Throughput (MB/s) |
| AES 5120 kB | MQX | 9.059 | 0.55 |
| μClinux | 10.120 | 0.49 | |
| ARC4 5120 kB | MQX | 2.190 | 2.28 |
| μClinux | 2.201 | 2.27 | |
| DES 5120 kB | MQX | 18.453 | 0.27 |
| μClinux | 19.897 | 0.25 | |
| MD5 5120 kB | MQX | 1.396 | 3.58 |
| μClinux | 1.411 | 3.54 | |
| SHA 5120 kB | MQX | 3.635 | 1.38 |
| μClinux | 3.712 | 1.35 | |
| SHA-256 5120 kB | MQX | 9.145 | 0.55 |
| μClinux | 9.356 | 0.53 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).