Control logic for a heart-lung machine's gas blender, written to IEC 62304 class C

We were part of the team that developed the electronic gas blender for the successor to the flagship heart-lung machine from LivaNova. We wrote the blender's control logic and its microcontroller drivers to IEC 62304, software safety class C.

Principle of an electronic gas blenderIllustration, not the client's design
CONTROL LOGICLOGICVALVEFLOW SENSORVALVEFLOW SENSORSET60 %4.0 L/minAIRO2MIXING POINTOXYGEN SENSOR60 %TO THE OXYGENATOR4.0 L/min2.03 L/min1.97 L/minCONTROLLOGICVALVESENSORVALVESENSORSET60 %4.0 L/minAIRO2MIXING POINTO2 SENSOR60 %TO OXYGENATOR4.0 L/minAIR 2.03 L/minOXYGEN 1.97 L/min
60 %
21 % · air only100 % · oxygen only
4.0 L/min
0.5 L/min10 L/min
Air valve
2.03L/min
Oxygen valve
1.97L/min
To the oxygenator
4.0L/min· 60 % oxygen

At 60 % oxygen and 4.0 L/min the air valve lets through 2.03 L/min and the oxygen valve 1.97 L/min.

From the project: an electronic gas blender for a heart-lung machine, with software in safety class C.
Illustration: the principle of such a device, with air taken as 21 % oxygen. The flow range is an example.
Client
LivaNova
Industry
Medical devices, cardiac surgery
Our scope
Control logic and microcontroller drivers of the electronic gas blender
Standard and stack
  • StandardIEC 62304
  • Safety classC
  • TargetMicrocontroller

Challenge

In class C, a failure of the software can lead to death or serious injury

During heart surgery a heart-lung machine does the work of the heart and the lungs. Its gas blender mixes air and oxygen for the oxygenator, the part of the machine where the blood takes up oxygen and gives off carbon dioxide.

IEC 62304 is the standard for medical device software. It sorts software into three safety classes, and the class decides how much of the standard's process applies. Class C is the highest, and all of it applies.

IEC 62304 · the three software safety classes

  1. A

    No injury or damage to health is possible.

  2. B

    Injury is possible, but not serious injury.

  3. C

    Death or serious injury is possible.

    The class of the gas blender's software

The worse the possible harm, the higher the class

From the project: the software of the gas blender is class C, the highest of the three.
Illustration: the three classes, shortened from the standard's wording.

What we did

We wrote the control logic and the drivers

The control logic decides what the blender does. The drivers connect it to the inputs and outputs of the microcontroller.

Under class C, each unit of code gets a written design before it is programmed and its own test afterwards. Every requirement has to be traceable to the test that proves it.

Where the two layers sitLayers 1 and 2: written by us
1 2 3
  1. Control logic

    Written by us

    Decides what the device does.

  2. Drivers

    Written by us

    Connect the logic to the inputs and outputs of the chip.

  3. Microcontroller

    Hardware, not ours

    The chip the software runs on.

Illustration: a general layering of such software, not the client's design.

Result

Software written to the highest safety class of IEC 62304

Validation and compliance

Oleksii Kvasnikov

Oleksii Kvasnikov · Founder and lead engineer

Medical device software to IEC 62304

Tell us the safety class and where the project stands.