Firmware development

What Should a Firmware Test Plan Include?

Build a firmware test plan with a worked sensor example, measurable pass criteria, and an editable test matrix for vendor sign-off.

Download the editable test matrixSee the worked example

Engineer working with electronic components at a lab bench

A firmware test plan should identify what is being released, which requirements will be checked, where each test runs, what counts as a pass, where the evidence goes, and who signs off. Each test should identify the firmware build and hardware revision it applies to. A row marked “pass” is useful only if the next reviewer can tell what passed and on which configuration.

Download the editable test matrix and open it in Excel, Google Sheets, or a text editor. The starter rows correspond to the sensor example below. Results are left as Not run so you can replace the illustrative setup and record evidence from your project.

Define the release before listing tests

A test plan for a pilot should say what the pilot needs to demonstrate and which checks belong to a later release. For example, a pilot may need to recover readings after a gateway outage and document how the buyer programs a unit. Production may additionally require a factory fixture, release signing, or validation across hardware variants. Name those boundaries so that “pilot passed” has a precise meaning.

Build the plan from your requirements and give every case an ID. Use one or more cases for each requirement, and make it possible to find the requirement from the result. If a requirement reads “start quickly,” resolve the timing threshold and the conditions before running the test. The firmware requirements template shows how to specify a measurable threshold and assign responsibility before a vendor quotes.

Part of the plan What to record
Release scope Milestone, firmware tag or build, hardware revision, and in-scope behavior
Coverage Requirement ID, test case ID, test level, priority, and any known gaps
Setup Unit identifiers, instruments, simulator or fixture version, inputs, and operating conditions
Results Pass threshold, actual result, evidence location, and issue link where applicable
Ownership Executor, reviewer, buyer-supplied inputs, and sign-off authority
Release rules What blocks approval, how exceptions are recorded, and when tests must be repeated

NASA’s software engineering handbook includes requirements traceability, versioned test environments, test responsibilities, and schedules in its test planning guidance. Scale that structure to the decision your team is making. A pilot can keep these details in one small matrix if a reviewer can trace each result to the setup and requirement. NASA Software Test Plan

Choose where each test runs

Technician testing a circuit board with a multimeter

Choose the environment by the evidence you need. An inexpensive host test can cover many states in a buffer or parser. A bench test on the target board can show the hardware and firmware working together. For some behaviors you want both, with each test answering a different question.

Environment Good fit Evidence boundary
Host unit test Parsing, buffer operation, state transitions, edge cases Shows how the software behaves under the inputs supplied to the test
Simulation Repeatable interface sequences, gateway responses, and error cases Results depend on how closely the simulator represents the counterpart
Real-board bench test Cold start, sampling cadence, peripheral behavior, and current measurements Applies to the measured boards, build, and conditions
Hardware-in-the-loop Repeatable timing, stimuli, or faults while real hardware executes firmware Evidence depends on fixture repeatability and fidelity of the external model

For an outage feature, use host tests to exercise buffer bookkeeping and a simulator to vary disconnect and reconnect events. Use the target board to demonstrate that the firmware collects, retains, and sends data across the actual device interface. That final test needs both sides’ records if the requirement is to recover every buffered reading.

Schedule the scarce inputs early. A test engineer can develop parsers and scripts against known samples before boards are ready. An on-board timing run still needs the right PCB, a build, and a free bench. Use the firmware development timeline guide to see how those prerequisites affect the pilot date.

Record the setup and evidence

Technician probing an electronic circuit board

Before a run, write down the release tag or build identifier, board revision, unit IDs, test instrument or fixture settings, simulator version, and the relevant starting state. For a cold-start test, for example, define when the timer starts, how you recognize the first valid sample, and how you reset the board between trials. Record the conditions that matter rather than leaving them implicit in the log file name.

After the run, attach the evidence to the test case and store the actual result next to the threshold. If the setup could not be created, record the case as blocked and state what input is missing. If the test ran and the results missed the threshold, mark it failed and link the issue. Keep those states distinct because they send work to different owners. Preserve the original failure record when you add a retest.

Worked example: battery-powered temperature sensor

The fictional pilot uses three revision B boards and a buyer-supplied gateway simulator. The thresholds below match the sensor requirements example. The vendor runs the device checks and packages the evidence. The buyer’s firmware lead reviews those checks, and the buyer’s manufacturing engineer performs the clean-checkout handoff test.

Illustrative sensor pilot acceptance matrix. No tests have been run.
RequirementSetup and pass criterionEvidence and owner
FW-01 · StartupTen cold starts on each of three revision B boards at room temperature. Every first valid sample arrives within 3 seconds.Timestamped startup logs by board. Vendor runs, buyer firmware lead reviews.
FW-02 · Sampling cadenceOne hour of normal operation at room temperature on each pilot board. Every interval after the first sample is 58–62 seconds.Timestamped sample logs. Vendor runs, buyer firmware lead reviews.
FW-03 · Outage recoveryDisconnect the gateway simulator for 30 minutes while the device remains powered. Within 5 minutes of reconnection, every outage reading arrives with its sequence ID and original timestamp.Device and gateway logs plus reconciliation. Vendor runs, buyer firmware lead reviews.
FW-04 · Build and programmingStart from a clean checkout of the release tag. Follow the handoff procedure, program a revision B unit, and confirm the reported version.Build and programming transcript and version readout. Buyer manufacturing engineer runs.

For FW-03, capture the device log through the disconnect window and use it to create the set of readings expected at the gateway. After reconnection, compare that set with the received records by sequence ID and original timestamp. A live reading received after reconnection only proves live traffic resumed. It leaves open whether a buffered reading went missing or arrived without its original timestamp. Preserve both logs and the reconciliation result so the reviewer can confirm the pass decision.

For FW-04, ask the person who will operate the handoff to run it with the agreed tools and documentation. A successful build on the vendor’s workstation can rely on dependencies or settings absent elsewhere. Record any manual steps the buyer needed to take and update the handoff instructions before the final run.

When the acceptance matrix is ready, request a firmware consultation. Bring the unit count, fixture availability, test owners, and expected evidence to the follow-up conversation.

When choosing a team, use the firmware vendor scorecard to compare what each firm can demonstrate about testing and handoff.

To budget for these checks, use the firmware quote comparison worksheet to separate vendor validation fees from equipment and effort your team supplies.

Decide what blocks release and what to retest

Agree in advance which test cases block the milestone. A required outage test with missing records should remain open until the team fixes it and demonstrates the required behavior, or an authorized reviewer explicitly changes the release scope. A blocked check also needs a disposition before approval. Make the unresolved risk clear and record the reviewer and follow-up date if an exception is accepted.

When a fix changes buffer behavior, rerun the outage case on the new build. Review nearby cases that share the affected state or timing, such as sampling during an outage or how the application hands records to the communication layer. If a PCB revision changes the sensor or its power sequencing, decide which board-dependent results must be collected again before reusing evidence from the old board.

Finish with a release record identifying the approved build, boards and conditions covered, evidence locations, open exceptions, and sign-off owner. Keep it with the project handoff so the next engineer can identify which behavior was demonstrated and which checks belong to the next milestone.

Frequently asked questions

What is the difference between a firmware test plan and a test case?

The plan defines coverage, environments, owners, and release decisions. A test case specifies the setup, procedure, expected result, and evidence for one check.

What firmware tests can run before the target board arrives?

Run host tests for portable logic and use simulation for agreed interfaces and failure scenarios. Reserve checks dependent on electrical behavior, timing, peripherals, or power for the target board.

Does every firmware project need hardware-in-the-loop testing?

No. Choose it when real hardware needs repeatable stimuli, timing, or fault conditions that are difficult to reproduce consistently by hand. A documented bench test may be sufficient for a small pilot.

How many units and test repetitions are enough?

Choose based on failure consequences, hardware variation, and what the release decision requires. Three boards and ten cold starts each are explicit assumptions in the worked example, not a statistical qualification standard.

Who should own firmware test results and sign-off?

Name an executor for each test and a reviewer with authority to accept the evidence. On outsourced projects the vendor often runs bench tests while the buyer approves release and independently confirms the handoff.

Which tests should be repeated after a firmware fix or PCB revision?

Repeat the failed check on the new release candidate and rerun tests affected by the change or its shared dependencies. Record which evidence remains applicable and why.