+ Part II · Confidence from process
The software lifecycle.
IEC 62304, the international standard for the life cycle of medical device software, was published on 9 May 2006 and amended in June 2015. It prescribes activities and the records each one produces, but not an order in which to carry them out. Since January 2019 the FDA has recognized the amended edition in full, which means it accepts a maker's declaration of conformity to the standard, or to named clauses of it, in a premarket submission. A second edition would widen the standard's scope to health software in general. In August 2026 it reached its second committee draft, and it is not expected to be final before 2028. Because testing cannot be complete, the confidence a regulator accepts comes largely from how the software was made. The six chapters of this part follow that process: requirements derived from risk, an architecture that isolates what is dangerous, an account of the code taken from others, testing at several levels, and the ways agile teams and automated pipelines meet the same obligations.
What it must do, and must never do.
+ The questionWhat has to be written down before the code can be trusted, and why does risk decide how much?
A requirement is a promise that can be checked
A software requirement is a statement of what the software must do, or must never do, written so that a test, an inspection or an analysis can show whether it holds. "The display shall be easy to read" is not a requirement in this sense; "each dose value shall be shown with its unit, in characters at least 5 mm high, and shall remain on screen until the user confirms it" is. The difference is that the second statement can fail a test.
Requirements come from the intended use of Chapter 1. A claim to detect more than mild diabetic retinopathy from two photographs per eye implies requirements about which images are accepted, what happens when an image is too dark or blurred, what the three possible answers are and how each is shown, how results are tied to the right patient, and how long the analysis may take. Some requirements come from users and clinicians, some from standards, some from the hazards the software could cause, and some from the rest of the system the software is part of. Once written down and reviewed, the requirements become the reference for all later work: design is checked against them, tests are written from them, and a change is judged by which of them it touches.
Risk decides how much
Not every requirement carries the same weight. Risk management for medical devices follows ISO 14971. Its 2019 edition was reviewed in 2025 and confirmed without change. The standard describes a chain: a hazard, a potential source of harm; a sequence of events that leads to a hazardous situation, in which someone is exposed to the hazard; and the harm that may follow. The maker judges each chain by the severity of the harm and the probability that the harm occurs. Each unacceptable risk gets a risk control, a measure that reduces the probability or the severity of the harm. The immunoassay guide in this library follows the chain for an analyzer, from a fault to a wrong result to a harm. For software, one part of the judgment changes: the probability.
Chapter 2 showed that software failures are systematic, so there is no failure rate per hour to put into the chain. In a 2025 document on software-specific risk, the International Medical Device Regulators Forum suggests that it can help to start from a probability of software failure of one, as if the failure were certain, and, where possible, to estimate the probability of harm from other factors. In that approach, the risk is judged by its severity and by the controls that act if the failure happens. A risk control may itself be software, a check in another part of the program; or it may be hardware, procedure or labeling outside the software altogether.
Three classes of software
IEC 62304 builds on this risk analysis with three software safety classes. In the amended edition, software is class A if it cannot contribute to a hazardous situation, or if no hazardous situation it can contribute to leads to an unacceptable risk once risk controls outside the software are taken into account. It is class B if, after those external controls are taken into account, it could still contribute to a hazardous situation whose possible harm is a non-serious injury. It is class C if that harm could be death or serious injury. Until a team has classified its software, the standard treats it as class C.
The class sets how much process the standard demands. All three classes need a development plan, requirements, testing of the whole software against those requirements, risk management, configuration management, problem resolution and controlled release. In outline, class B adds a documented architecture and the verification of software units and of their integration; a software unit is the smallest part into which the software is divided. Class C adds a detailed design of each unit and more demanding criteria for verifying each unit. A class can also be set for each part of a program, and Chapter 5 shows how an architecture that separates dangerous functions can put most of the code in a lower class.
An infusion pump delivers fluid or a drug into a patient's body at a controlled rate, and its software computes that rate from a prescription. A wrong rate could kill, so before any controls the worst credible harm is death. Suppose the pump also has an independent hardware circuit, outside the software system, that stops the motor if the delivered volume exceeds a limit the clinician has set. Suppose too that the team's analysis shows that, with this circuit in place, the worst remaining harm from a software error is a non-serious injury. Under IEC 62304 as amended, the software may then be class B, because the external control counts. In its 2023 guidance on premarket software documentation, the FDA instead asks whether a failure "could present a hazardous situation with a probable risk of death or serious injury" before any risk controls are considered. The answer sets the documentation level, Basic or Enhanced, which decides how much software evidence a submission must contain. For the same pump software the answer is yes, so it would need the FDA's Enhanced documentation level. For the development practices in a submission, the guidance accepts a declaration of conformity to named clauses of IEC 62304, such as the development plan, maintenance and configuration management, and explains that a declaration to the whole standard is not needed, because the two schemes classify software differently.
A check that runs inside the same program, on the same processor and from the same code base, can fail together with the function it guards, as the redundant copies of Chapter 2 did. When a team sets the class under IEC 62304, the standard credits the risk controls that are external to the software system. A team that lowers a class by pointing to a software check inside the system has misread the standard and has also left the risk in place.
Tracing the threads
What makes requirements and risk controls auditable is a set of links between records. Each hazard links to the requirements that control it; each requirement links to the design elements that implement it and to the tests that verify it; each test links to its result. This linking is called traceability. With the links in place, a reviewer can start anywhere: from a hazard, find whether its control was implemented and tested; from a failed test, find which hazard is now uncontrolled; from a change, find every requirement and test it touches. Without the links, the same documents give a reviewer no path from a risk to its evidence.
The FDA made the top of such a chain public for IDx-DR in its decision summary: the three risks to health listed in Chapter 1, each linked to the mitigations that answer it. The FDA's reviewers also read the requirements and tests behind that summary, and those are not public. Chapter 7 describes the testing; Chapter 27 lists what the FDA, the EU and India ask to see of it.
Classify the software, and each software item, before the architecture is fixed. Write down the hazards, the external controls credited and the worst remaining harm behind each class. Record the FDA documentation level separately, assessed before risk controls. Revisit both whenever a requirement, a control or the intended use changes, because a class that rested on a hardware limit becomes wrong, without any warning, if that limit is removed.
- A software requirement states what the software must or must never do in a form that a test or inspection can check.
- ISO 14971 describes the chain from hazard to harm; because software failures are systematic, regulators suggest that it can help to assume a software failure will occur.
- Under IEC 62304, software is class A, B or C according to the worst harm after controls outside the software, and the class sets the process required.
- Traceability links hazards, requirements, design and tests, so a reviewer can follow any risk to its control and its evidence.
Let's Talk