Embedded Controller for Atomic Absorption Spectrophotometer with Sparklet GUI

CASE STUDY SNAPSHOT

Customer : A leading Indian manufacturer of analytical and scientific instruments serving medical, clinical, and research laboratories
Size : 200–1000
Project vertical :  Medical and Scientific Instrumentation, Embedded Electronics
Challenge :  Develop production embedded firmware for an atomic absorption spectrophotometer, covering precision analog front-end data acquisition, RTOS-based instrument control, Sparklet GUI-based operator interface, and Windows PC simulator support, on a Freescale Kinetis K70 ARM Cortex-M4 MCU
Solution :  Production RTOS-based embedded firmware on Freescale Kinetis K70 for an atomic absorption spectrophotometer with precision analog front-end integration, Sparklet GUI library-based TFT operator interface developed using Flint IDE, data processing algorithms per clinical standards, and Windows simulator for accelerated HMI development
Services & Products Availed :  Turnkey Product Engineering, Embedded Firmware Development, Embedded Hardware Design, Sparklet GUI Library, Flint IDE
Tools and Technologies:
  • Target MCU:  Freescale Kinetis K70 (ARM Cortex-M4)
  • OS:  RTOS
  • GUI:  Embien Sparklet GUI Library
  • IDE:  Flint IDE (HMI development), Windows Simulator
  • Display:  TFT LCD with capacitive touch
  • Analog Front End:  Precision ADC, signal conditioning
  • Languages:  C
  • Tools:  Kinetis Design Studio

Introduction

Atomic Absorption Spectrophotometry is one of the most widely used analytical techniques in clinical, medical, and research laboratories, providing precise quantitative measurement of metallic elements in biological samples such as blood, urine, and serum. Clinical applications include measurement of essential minerals, zinc, copper, iron, calcium, magnesium, and detection of toxic heavy metals such as lead, cadmium, and arsenic in patient samples. The accuracy and reliability of an atomic absorption spectrophotometer directly impacts the quality of clinical diagnoses and patient safety decisions made on the basis of its measurements.

A leading Indian manufacturer of analytical and scientific instruments, with a long-established product portfolio serving medical, clinical, and research laboratories across India and export markets, approached Embien to develop the complete embedded firmware for their next-generation atomic absorption spectrophotometer. The instrument required a precision analog front-end for detector signal acquisition, an RTOS-based control architecture for coordinating the instrument's measurement sequences, a TFT touch operator interface developed using Embien's Sparklet GUI library and Flint IDE, and a Windows PC simulator to accelerate HMI development and validation.

Challenge

Atomic absorption spectrophotometry places stringent demands on the embedded signal acquisition chain. The detector signal, representing the light absorption of the sample at the analytical wavelength, is a small, noise-sensitive analog voltage that must be acquired with high precision and low noise across a wide dynamic range. The analog front-end design and the firmware's data acquisition strategy had to achieve the signal-to-noise performance required for clinical-grade measurement accuracy, where errors in elemental concentration measurement could have direct patient safety implications.

The instrument's measurement sequence is inherently multi-step and time-critical. The light source must be stabilised, the sample introduced and atomised, the detector signal acquired over the correct time window, the background correction measurement performed, and the final concentration calculated, all in a precisely coordinated sequence whose timing directly affects measurement accuracy. Coordinating this sequence reliably while simultaneously managing the operator interface, responding to user inputs, and handling instrument status monitoring required a well-structured RTOS-based firmware architecture.

Developing a high-quality TFT operator interface for a scientific instrument, with the multiple screens, data visualisation widgets, graph displays, and configuration menus that clinical laboratory users expect, is a substantial software effort in its own right. Doing this efficiently within an embedded MCU context, without the UI development consuming a disproportionate share of the overall firmware development schedule, required a tool-assisted approach that could accelerate HMI development without sacrificing interface quality.

The Windows simulator requirement, enabling the HMI to be developed and tested on a PC before the target hardware was available, added a portability requirement to the Sparklet integration, as the GUI library had to run correctly on both the Kinetis K70 target and the Windows development environment.

Solution

TPMS Monitor App

Kinetis K70 Platform and RTOS Architecture

The instrument firmware was developed on the Freescale Kinetis K70, an ARM Cortex-M4 based MCU with a hardware floating-point unit, high-resolution ADC, and rich peripheral set well-suited to the precision data acquisition and instrument control requirements of the spectrophotometer. The firmware was architected around an RTOS with clearly defined tasks for each major functional domain, measurement sequence control, analog data acquisition, GUI rendering and input handling, data processing and algorithm execution, and instrument status monitoring. Task priorities were assigned to ensure that time-critical measurement sequence steps and analog acquisition operations were never preempted by lower-priority UI or communication tasks, preserving the timing precision required for accurate spectrophotometric measurements.

Precision Analog Front-End Integration

The detector signal acquisition chain was implemented with careful attention to the signal conditioning, sampling, and digital processing required for clinical-grade measurement performance. The analog front-end, interfacing the spectrophotometer's photodetector to the Kinetis K70's ADC, provided appropriate signal amplification, filtering, and level shifting to present the detector signal within the ADC's optimal input range across the full measurement dynamic range. The firmware's ADC acquisition task managed the sampling sequence, synchronising acquisition windows with the instrument's measurement timing, applying averaging and noise rejection processing to the raw ADC samples, and delivering processed detector readings to the measurement sequence controller for concentration calculation.

Data processing algorithms, implementing the concentration calculation, calibration curve fitting, background correction, and quality control checks required for the instrument's analytical performance, were developed in accordance with the clinical and analytical chemistry standards applicable to atomic absorption spectrophotometry. The Kinetis K70's hardware floating-point unit was leveraged for the computationally intensive calibration and concentration calculation algorithms, ensuring that processing time did not introduce delays into the measurement sequence.

Sparklet GUI Library and Flint IDE HMI Development

The operator interface was developed using Embien's Sparklet embedded GUI library, providing hardware-accelerated rendering of the instrument's TFT touch display with smooth, responsive UI performance on the Kinetis K70 platform. Sparklet's rendering engine was optimised for the K70's graphics capabilities, leveraging the MCU's DMA and display controller interfaces to deliver fluid screen transitions and real-time data updates without impacting the instrument's measurement and control tasks.

The HMI was designed and developed using Flint IDE, Embien's low-code development environment for Sparklet-based interfaces. The instrument's multiple screens, main measurement display, calibration setup, results table, trend graph, configuration menus, and diagnostic screens, were designed graphically in Flint and exported as Sparklet-compatible assets. Data variable bindings, linking the instrument's measurement results, status indicators, and configuration parameters to the corresponding UI widgets, were defined within Flint, enabling the HMI to update automatically in response to instrument state changes without manual UI update code. This tool-assisted development approach significantly compressed the HMI development timeline relative to manual embedded GUI programming.

The operator interface provided laboratory users with an intuitive workflow for instrument setup, measurement execution, calibration, results review, and data export, designed specifically for the clinical laboratory context where the instrument operators are analytical chemists and laboratory technicians rather than embedded systems engineers.

Windows PC Simulator

A Windows PC simulator was developed to enable HMI development and validation to proceed in parallel with the hardware bring-up of the Kinetis K70 target. The simulator ran the Sparklet GUI library and the Flint-generated HMI assets on a Windows PC, with simulated instrument data driving the UI widgets to demonstrate and validate the HMI behaviour before the actual instrument hardware was available. This parallel development approach, HMI design and validation on the simulator while hardware and firmware bring-up proceeded on the target, compressed the overall development timeline and allowed HMI issues to be identified and resolved before the integration phase, where they are more costly to fix.

The simulator was also used for ongoing HMI testing and demonstration, enabling the customer's product team and sales organisation to demonstrate the instrument's operator interface to laboratory customers and distributors without requiring the physical instrument hardware to be present.

Benefits

  • Clinical-grade analog acquisition Precision analog front-end with ADC synchronisation, noise rejection averaging, and hardware floating-point concentration calculation delivers the measurement accuracy required for clinical atomic absorption spectrophotometry
  • RTOS-based measurement coordination Priority-scheduled RTOS architecture ensures time-critical measurement sequence steps execute with the timing precision required for accurate spectrophotometric measurements, never preempted by UI or communication tasks
  • Sparklet and Flint HMI acceleration Tool-assisted HMI development using Sparklet GUI library and Flint IDE delivered a complete multi-screen clinical laboratory operator interface significantly faster than manual embedded GUI programming
  • Windows simulator for parallel development PC-based HMI simulator enabled interface design, validation, and customer demonstration to proceed in parallel with hardware bring-up, compressing the overall instrument development timeline
  • Production analytical instrument quality Complete firmware, analog acquisition, RTOS control, data processing algorithms, and operator interface, delivered to the quality and reliability standards required for a clinical laboratory analytical instrument

Conclusion

This atomic absorption spectrophotometer project demonstrates Embien's capability to deliver complete, production-grade embedded firmware for precision analytical instruments targeting clinical and medical laboratory applications. By combining a carefully designed analog acquisition chain, an RTOS-based measurement control architecture, Sparklet and Flint-accelerated HMI development, and a Windows PC simulator for parallel development, on the Freescale Kinetis K70 platform, Embien provided its analytical instrument customer with a robust, clinically appropriate firmware foundation for their spectrophotometer product. This project reflects Embien's experience at the intersection of precision analog signal acquisition, embedded instrument control, and clinical-grade software quality, a combination that is essential for analytical instruments where measurement accuracy has direct implications for patient care.

Looking to develop embedded firmware for a precision analytical instrument or scientific measurement device?

Partner with Embien for instrument firmware development covering precision analog acquisition, RTOS control, and Sparklet GUI-based operator interfaces.

For further information on how your personal data is processed, please refer to the Embien Privacy Policy.