Related Experiment Video
Updated: Jan 13, 2026

10:31
A Visual Guide to Sorting Electrophysiological Recordings Using 'SpikeSorter'
Published on: February 10, 2017
11.5K
Empirical Evaluation of Unoptimized Sorting Algorithms on 8-Bit AVR Arduino Microcontrollers
1Faculty of Computer Science and Mathematics, Cracow University of Technology, 31-155 Kraków, Poland.
Sensors (Basel, Switzerland)
|January 10, 2026
Summary
Heap Sort offers the best performance for resource-constrained microcontrollers, balancing speed and memory usage. This study evaluated six sorting algorithms on Arduino boards, finding Heap Sort optimal for embedded sensing applications.
Area of Science:
- Embedded Systems Engineering
- Computer Science
- Algorithm Analysis
Background:
- Resource-constrained microcontrollers in Internet-of-Things (IoT) and embedded sensing demand efficient algorithms.
- Algorithmic choices significantly impact latency, energy consumption, and memory footprint on low-cost devices.
- Existing research often overlooks the specific limitations of microcontrollers like Arduino boards.
Purpose of the Study:
- To evaluate the performance of six common sorting algorithms (Bubble, Insertion, Selection, Merge, Quick, Heap Sort) on microcontrollers.
- To analyze execution time, write operations, and memory usage under realistic embedded sensing conditions.
- To provide practical guidelines for algorithm selection in resource-limited environments.
Main Methods:
- Implemented six unoptimized sorting algorithms on Arduino Uno, Leonardo, and Mega 2560 boards.
- Tested algorithms with datasets of increasing size, simulating buffered time-series sensor data (random, ascending, descending).
- Measured execution time, write operations, and static random-access memory (SRAM) usage.
Main Results:
- O(n log n) algorithms (Quick Sort, Heap Sort) significantly outperformed O(n^2) algorithms (Bubble, Insertion, Selection Sort).
- Quick Sort and Merge Sort showed high speed but excessive SRAM usage (2023 bytes for Merge Sort) or recursion issues.
- Heap Sort demonstrated the best trade-off, executing all tested sizes within SRAM limits (approx. 12-13 bytes extra SRAM) and achieving fast runtimes (<100,000 μs for n=1000).
Conclusions:
- Heap Sort is the recommended algorithm for resource-constrained 8-bit AVR microcontrollers in sensing applications.
- Algorithm selection must consider the specific constraints of RAM, program memory, and energy.
- This study provides empirical data to guide practical implementation choices for embedded systems.
Related Concept Videos
Multiple Comparison Tests
4.4K
Multiple comparison test, abbreviated as MCT, is a post hoc analysis generally performed after comparing multiple samples with one or more tests. An MCT will help identify a significantly different sample among multiple samples or a factor among multiple factors.
It would be easy to compare two samples using a significance alpha level of 0.05. In other words, there is only one sample pair to be compared. However, it would be difficult to identify a significantly different sample if the number...
It would be easy to compare two samples using a significance alpha level of 0.05. In other words, there is only one sample pair to be compared. However, it would be difficult to identify a significantly different sample if the number...
4.4K
Optimization Problems
8
Optimization problems often involve identifying maximum or minimum values under specific constraints. A well-known example is determining the longest horizontal pipe that can be moved around a right-angled corner, where a 3-meter-wide hallway meets a 2-meter-wide hallway. This scenario, common in architectural design and industrial transport, can be understood conceptually through geometric and trigonometric reasoning.To visualize the problem, consider the pipe as a straight line that touches...
8
Serial Position Effect
501
The serial position effect is a cognitive phenomenon where individuals are more likely to recall the first and last items in a list compared to those in the middle. This effect is divided into the primacy effect and the recency effect. The primacy effect is observed when the initial items in a list are remembered better. This occurs because these items are rehearsed more frequently or receive more elaborative processing, allowing them to be encoded into long-term memory more effectively. For...
501
Voltage Dividers
1.2K
In electrical circuits, resistors can be connected in series, sequentially linked one after the other. In a series configuration, the same current flows through each resistor. Ohm's law is a fundamental principle to understand the behavior of resistors in series. It expresses the voltage across these resistors in terms of the current and resistance.
Kirchhoff's voltage law implies that the sum of the voltages across the resistors in series equals the source voltage. This means that the current...
Kirchhoff's voltage law implies that the sum of the voltages across the resistors in series equals the source voltage. This means that the current...
1.2K
Non-ohmic Devices
1.5K
In most substances, the current flow is proportional to the voltage applied to it. A simple relationship between the values of current, voltage, and resistance is known as Ohm's law. Nonohmic devices do not exhibit a linear relationship between voltage and current. One such device is the semiconducting circuit element known as a diode. A diode is a circuit device that allows current flow in only one direction.
Consider a simple circuit consisting of a battery, a diode, and a resistor. A...
Consider a simple circuit consisting of a battery, a diode, and a resistor. A...
1.5K
Sieve Analysis and Grading Curves
909
Sieve analysis is a method used to determine the particle size distribution of aggregate materials. This process involves the following steps:
909

