Files
essim/src/system/bsdl_check.hpp
François 952afe3979 verify: JTAG boundary-scan chain integrity (flagship)
New check_jtag_chain(System*): collects TAP pins by PinSpec.function, resolves
each to its net, and flags JtagTapIncomplete (a device missing TDI/TDO/TMS/
TCK), JtagBusUnbridged (TMS or TCK not common to every TAP device), and
JtagChainBreak (dangling TDO/TDI, chain fan-out, or not a single head->tail
daisy chain). Surfaced as a pass in `verify`; AnomalyKind extended. Covered by
test_bsdl_check (healthy chain, broken chain + split bus, incomplete TAP).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-03 15:24:00 +02:00

29 lines
1.2 KiB
C++

#ifndef _BSDL_CHECK_HPP_
#define _BSDL_CHECK_HPP_
#include "analysis.hpp" // Anomaly, AnomalyKind
#include <vector>
class System;
// Model-driven pin checks over the system's nets, using the PinSpec
// direction/function populated by connector or BSDL models. Emits:
// - DriveContention : a net with ≥2 push-pull output drivers;
// - UndrivenNet : a multi-pin net with input(s) but no driver;
// - NcWired : a no-connect pin wired onto a multi-pin net.
// Read-only; nets with no direction data are skipped (no false positives on
// un-modelled parts).
std::vector<Anomaly> check_pin_specs(System *sys);
// JTAG boundary-scan chain integrity, using pins whose PinSpec.function is a TAP
// role (JtagTdi/Tdo/Tms/Tck/Trst). Resolves each TAP pin to its net and checks:
// - JtagTapIncomplete : a TAP device missing TDI/TDO/TMS/TCK;
// - JtagBusUnbridged : TMS or TCK not common to every TAP device;
// - JtagChainBreak : the TDO→TDI daisy chain dangles, fans out, or is not a
// single path (≠1 head / ≠1 tail).
// Empty when the system has no TAP pins.
std::vector<Anomaly> check_jtag_chain(System *sys);
#endif // _BSDL_CHECK_HPP_