Marvee Amasi
DIIDevHeads IoT Integration Server
•Created by Marvee Amasi on 6/7/2024 in #middleware-and-os
How to Efficiently Sort 10,000 16-bit Integers on an Embedded Device with 512 KB RAM?
I am working on a project that involves a small, embedded device with only
512 KB
of RAM. This device needs to accept a list of 10,000
random numbers prolly 16-bit
integers over a serial connection and then send them back sorted in ascending order. The catch is that the device has no additional storage beyond the RAM.
I can't discard any data during the sorting process.
Also the code itself will be stored in ROM.
My question is that , is it possible to sort this list of numbers efficiently within the limited RAM of the device? If so, what are some creative ways we can approach this problem, considering the constraints?
@Middleware & OS3 replies