Close critical engineering gaps before year-end. Get expert support in hardware, FPGA or embedded software. Talk to our engineers ▶✕

6x Less RAM on an Edge Device, Without a Board Redesign

Project in a Nutshell: A product company needed to scale deployments of a Raspberry Pi Compute Module 4-based edge device that collects multichannel sensor data and video. At 20 to 50 units per site, raw streams saturated networks already crowded with Wi-Fi: connections dropped and data stopped arriving in real time. The client set two requirements, stable operation first and a lower device cost second.

Promwad rebuilt the embedded Linux environment, the memory handling, and the data processing pipeline, cutting RAM consumption from over 4 GB to approximately 700 MB and moving the analysis onto the device. The product now runs on a 1 GB RAM / 8 GB eMMC Compute Module 4 configuration without redesigning the carrier board, and it holds its connections on busy sites while sending 50 to 100 times less traffic.

 

quick facts

Challenge

Our client developed an edge device combining a multichannel sensor and camera for installations of 20–50 units per site. Each unit acquired approximately 24 Mbit/s of raw sensor data, alongside a video stream, and relied on a server for part of the analysis.

The prototype used a general-purpose Linux distribution, Python applications, several Docker containers, and the sensor manufacturer's SDK. It ran on a Raspberry Pi Compute Module 4 with 8 GB RAM and 32 GB eMMC.

The software consumed more than 4 GB of RAM, and the device experienced high operating temperatures and data errors under load. Installation sites were often crowded with Wi-Fi networks, and raw streams from a full deployment competed for the same bandwidth. Connections dropped repeatedly and the system could not deliver data in real time. The devices also disturbed other networks and other sensors sharing the same site.

 The customer set forth two requirements:

  • the system had to operate reliably at maximum deployment density;
  • the device’s manufacturing cost had to be lower.

Both requirements had to be met using the existing hardware design, sensor, and camera.

 

Where the Prototype Hit Its Limits
Need an edge device to run on less RAM without a board redesign?

 

Solution

Promwad audited the existing software architecture and focused on three areas: embedded Linux, memory management, and on-device processing.

 

Engineering Solution at a Glance

Creating a more compact embedded Linux system. The team replaced the generic Linux distribution with a minimal Yocto-based image, configuring the kernel, drivers, and system components to meet the device’s actual requirements.

Several Docker containers were replaced with native system services. This reduced the number of unnecessary runtime components and provided tighter control over the size of the software and its dependencies.

The optimized system preserved the required functionality with a smaller software footprint.

Reducing memory copies and buffer overhead. The original sensor data pipeline included numerous intermediate buffers and unnecessary data copying, including overhead associated with the integration of a third-party SDK.

The Promwad team analyzed how software components exchanged data and reduced redundant copying by using shared buffers and reference-based data processing wherever possible.

The team also made a number of changes:

  • Static buffer allocation to ensure more predictable memory usage in continuous operation mode.
  • Use of appropriate numeric data types, replacing unnecessary 64-bit representations with 32-bit or 16-bit types where the required signal precision allowed.
  • Reducing the number of data transfer operations to lessen the load on memory bandwidth and reduce unnecessary CPU load.

The footprint came down on both sides of the module. The processing pipeline holds less RAM, and the system image and the data kept on the device need less eMMC.

Computational optimization and edge computing. The optimized pipeline enabled more on-device processing, reducing the amount of data transmitted to the server. On-device processing also changed what the product has to store. The prototype carried a 256 GB SD card. Once the device keeps results rather than raw captures, the client can remove the card and take about $50 off each unit, or keep one of up to 16 GB as an intermediate backup buffer.

Performance-critical code was rewritten from Python to C. Mathematical operations, including processing using the Fast Fourier Transform (FFT), were optimized using Arm NEON vector instructions, and computational workloads were distributed across the processor cores.

The team also reorganized the data prior to compression to improve compression efficiency.

These improvements made it possible to perform a greater volume of processing directly on the device. Instead of relying on a server to analyze the same volume of data, the system could process the data locally and transmit a significantly smaller amount of information.

The existing carrier board, sensor, and camera were retained.

Key Benefits and Results

Before-After

The main gain was reliability. Sending results instead of raw data cut traffic per device by 50 to 100 times, which took the pressure off networks that were already busy. The devices now keep their connections at full deployment density, and they no longer crowd out other networks and sensors sharing the site.

Cost was the second requirement, and the optimized software met it without touching the carrier board. The device moves to a lower-cost Compute Module 4 configuration, with both RAM and eMMC requirements down. Removing the 256 GB SD card takes about another $50 off each unit. In volume production, those savings repeat on every device built.

Moving processing to the edge also lightened the server. At the time of the project, a server costing approximately $3,000 could be replaced with a mini-PC costing around $700.

More of What We Do for Memory-Constrained Devices

FAQ

Our device already works. What would an audit of its Linux system look at?

 

A technical audit of a Linux-based system follows the resources. It covers security exposure, start-up time and energy use, processor efficiency, and how RAM, ROM, and flash are actually used. In this project the prototype ran, but it ran on the largest module configuration in the family and the processor heated up under load. The audit answers one question before any rework begins: how much of the memory and the processor time does useful work.

 

 

Which processors and Linux environments do you work with?

 

Driver and kernel work covers x86, Arm, RISC-V, PowerPC, SPARC, and other processor architectures. We start by analyzing the hardware specification and what the solution as a whole has to do, then tailor the kernel to that platform and adjust its features to the application. This project ran on an Arm application processor in a Compute Module 4, and the same approach applies to an industrial PC or an x86 system.

 

 

How deep into the system does this work go?

 

It starts at the boot loader. A board support package can include boot loaders such as U-Boot or a custom one, drivers, protocol stacks and system interfaces, a power-on self-test sequence, and profiling and code optimization. Above that sit the kernel-level pieces: file systems, task scheduling, networking stack, device tree configuration, and memory management. In this project the memory management and the data path between software components were where the savings came from.

 

 

Can you work on a Linux system that we or another vendor already built?

 

That is the usual starting point. Customizing an existing Linux distribution, migrating a system to another OS, and porting middleware between solutions are all part of the service. Here the prototype used a general-purpose distribution with Python applications, several Docker containers, and the sensor manufacturer’s SDK, none of which Promwad wrote. The SDK turned out to be the largest single source of redundant data copying.

 

 

How does kernel-level work actually bring memory use down?

 

By optimizing the kernel configuration and tuning the parameters around it, so the system makes better use of the resources it has instead of asking for more. The core-level work sits in memory management and I/O scheduling, and profiling shows where the time and the bytes go. In this project that meant a minimal image carrying only the components the device uses, native system services in place of containers, shared buffers and reference-based processing instead of copies, and numeric types matched to the real precision of the signal.

 

 

Tell us about your project

We’ll review it carefully and get back to you with the best technical approach.

All information you share stays private and secure — NDA available upon request.

Prefer direct email?
Write to info@promwad.com

Secured call with our expert in 24h
Secured call with our expert in 24h
Embedded in your team, end-to-end engineering
Embedded in your team, end-to-end engineering
22 years of engineering expertise
500+ projects for OEMs in EU & US
500+ projects for OEMs in EU and US
22 years of engineering expertise
MVP in 8–10 weeks
MVP in 8–10 weeks — predictable delivery
Featured at IBC, Embedded World, MWC
Featured at IBC, Embedded World, MWC

Other Case Studies