Cause:
- FlyingStart Single lacked a procedure-level calculation of a corrected pulse constant from measured volume errors at different flow rates.
- Correction results needed to be available for configurable export without changing original measurements or the internal TBF results database.
Solution:
1. Added procedure-level PPU correction
- Added the “Calculate PPU correction” Yes/No setting, disabled by default.
- Execute PulseCorrectionOp after all regular procedure tests and repetitions are complete, before saving and exporting results.
- Calculate a common corrected PPU for each active meter using the original measured PPU, volume errors and configured error limits.
- Preserve the original KorrRechnen acceptance rules, including the strict 8% input-error limit.
- Invalidate previous corrections when starting a new measurement and reject incomplete or invalid inputs.
2. Added correction results and configurable export
- Expose corrected PPU, predicted volume error, per-test correction acceptance and overall correction status.
- Export only selected variables through configured ResultsWriter and UniDataStorageWriter components.
- Keep correction fields outside the internal TBF results database mapping; require no additional database columns.
- Preserve original PPU, pulse counts, measured errors and test evaluation.
- Retain correction values in temporary batch recovery data and support older recovery records.
- Update FlyingStart simulation to support correction tests and repetitions.
3. Added regression coverage
- Not filled in.
4. Increased revision
- Updated TBF AssemblyVersion and AssemblyFileVersion from 3.9.3147.119 to 3.9.3147.120.
- Added `HasOwnedManualOpticalStream` method to ensure manual stream state remains valid regardless of port identity delays.
- Refactored `EnterManual` calls to use the new ownership check.
- Updated tests to verify manual stream ownership handling during transient states.
- Incremented assembly version to 3.9.3178.1.
- Introduced `AsicHeadProfile` to support old, new, and custom ASIC head configurations.
- Added custom baud rate fields for direct radio, RFID service, and optical communication.
- Enhanced `AsicReaderCfg` with profile-based baud rate management via `ApplyHeadProfile`.
- Updated UI with head profile editor, dynamic baud rate configuration, and validation logic.
- Adjusted reader initialization and tests to incorporate profile-based baud rate settings.
- Added `SetStandingOpticalMode` to manage optical test mode transitions for Poseidon readers.
- Enhanced `SmartReader` to toggle test mode before and after optical data capture, ensuring proper mode cleanup.
- Introduced helper method `IsSuccessfulStandingModeResult` to validate optical mode transition responses.
- Updated `TestStartEndForm` to use a new `CreateRegisterReadWatchdog` method for non-designer timer instantiation.
- Expanded unit tests to validate optical mode transitions and standing mode result behaviors.
- Bumped assembly version to 3.9.3177.4.
- Introduced `BeginOpenDialog` for asynchronous WinForms dialog initialization, improving UI responsiveness in `EntryFormNoStartEnd`.
- Added `SanitizeNonFiniteMeterResults` in `DB` to replace NaN/Infinity values before batch persistence, ensuring database compatibility.
- Enhanced `SmartReader` with semaphore-based synchronization for data entry snapshots and direct serial number extraction logic.
- Applied refined error handling for Poseidon optical measurements in `StandingStartMassCollectionSeq`.
- Expanded test coverage with `ResultsDbNonFiniteValueTests` to validate non-finite value sanitization.
Cause:
- The previous fix protected the main Q3 result, but invalid numeric values could still reach calibration details and prevent the batch from being saved.
- Channel records could inherit an uninitialized nominal calibration factor when Prepare Q3 Calibration had not been executed.
- Missing Q3 deviations were stored as zero in calibration details, incorrectly suggesting a valid zero deviation.
Solution:
1. Protect calibration detail persistence
- Store NaN and infinity as NULL in calibration error, timing, raw reading and volume fields.
- Update MySQL and SQLite schemas to allow missing values while preserving existing records and valid numeric values.
2. Validate Q3 calibration factors and deviations
- Use configured channel factors when the reader's nominal factors are unavailable.
- Keep the default factor of 15625 when all three configuration fields are empty.
- Preserve existing snapshots when configuration is invalid.
- Reject invalid nominal and applied factors before updating meter records.
- Preserve missing deviations instead of replacing them with zero, and mark invalid calibration details accordingly.
3. Increased revision
- Updated AssemblyVersion and AssemblyFileVersion from 3.9.3147.119 to 3.9.3147.121.
- Introduced support for V1 optical diagnostic frames (C3/C4) with separate processing to prevent interference with metrology data.
- Added `DiagnosticTelegramReceived` callback in `OptoHeadService` for detailed logging of V1 frames.
- Enhanced `PoseidonOpticalLineParser` to parse and handle C3 calibration factors and C4 auxiliary ADC values.
- Implemented a new diagnostic logging method in `SmartReader` for V1 telegrams.
- Extended test coverage with new cases to validate C3/C4 frame parsing and diagnostic handling.
- Bumped assembly version to 3.9.3176.0.
- Introduced `WaterMetrologyData.FromC2` to support legacy C2 metrology payloads.
- Updated protocol profiles to handle C2 message types (`0xC1`) in optical communication.
- Refactored `OptoHeadService` and `SmartReader` to process both C2 and C7 datasets.
- Streamlined optical telegram buffering and applied enhanced metrology data selection logic.
- Improved flow rate and metrology time calculations for C2 compatibility.
- Bumped assembly version to 3.9.3175.0.
- Added `ExtractSerialNumber` helper to remove diagnostic information from serial numbers appended by the direct protocol formatter.
- Updated serial number handling to ensure persistent fields and exported results remain clean.
- Replaced legacy worker-thread structure with a single-threaded command scheduler for improved resource handling.
- Added support for retries and delays between direct NA2W commands with enhanced error logging.
- Enabled integration of shared SmartCommunicationForm for better operator visibility and control over direct communication tasks.
- Consolidated redundant logic for optical capture and data stream operations into reusable components.
- Published new Poseidon activities with public identifiers to streamline task configuration.
- Introduced new helper methods and synchronization mechanisms to simplify water meter data mapping and result updates.
- Optimized workflow by embedding inline progress updates for real-time feedback during execution.
- Version bumped to 3.9.3174.0.
- Introduced `PoseidonNa2wSerialTransport` for raw NA2W command handling without CLI or vendor dependencies.
- Added `PoseidonCommunicationCfg` for direct communication settings, including retries, timeouts, and serial parameters.
- Implemented unit tests to validate configuration and parameter exposure in `PoseidonCommunicationConfigTests`.
- Updated project files to include new Poseidon communication classes and tests.
- Bumped version to 3.9.3173.0.
- Replaced legacy `SerialPortData` and `NfcHeadServiceOld` with `PoseidonCommandAccessFactory` for improved direct communication.
- Added new configurable parameters for direct raw capture, baud rate, timeout, and retries in `PoseidonCfgCtrl`.
- Introduced measurement configuration support in the UI with a dedicated tab.
- Expanded localized resource strings for multiple languages to include direct communication labels and tooltips.
- Updated logging configuration to include a new appender for `PoseidonDirect` communication.
- Refactored code to remove obsolete elements and improve UI consistency.
- Introduced configurable CLI logging path for better debugging (`PoseidonReader` and `CliRunner`).
- Implemented legacy CLI fallback mechanism in `SerialPortData` with compatibility validation.
- Enhanced logging granularity for CLI operations including outputs, errors, and task details.
- Added new test cases to validate default CLI configuration and fallback logic.
- Updated assembly version to 3.9.3170.0.
- Added new localized resource strings for optical and group-related configurations.
- Refactored `AsicReaderLogsCfgCtrl` and `AsicReaderCfgCtrl` to utilize shared components for consistency.
- Simplified UI initialization with dock-based controls for better layout management.
- Removed legacy code and unused designer elements to improve maintainability.
- Added `GroupPresetConcurrency` to `AsicReaderCfg` for explicit group-based execution.
- Updated `RegisterReaderGroupScheduler` to support parallel and serial processing based on approved presets.
- Expanded resource strings with localization for group-related features and tooltips.
- Enhanced UI components in `AsicReader` for improved user configuration and diagnostics.
- Refactored designer code to improve readability and ensure compatibility with runtime setup.
Cause:
- The procedure editor always displayed the "Water meters" tab caption.
- Selecting "Heat meter" left a misleading caption.
Solution:
1. Display the caption according to the selected meter kind
- Show "Heat meters" for heat meter procedures.
- Update the caption immediately when the selection changes.
2. Add localized captions
- Added translations for all supported UI languages.
- Preserved "Water meters" for Single and Compound selections.
- Measurement behavior remains unchanged.
3. Added regression coverage
- Not filled in.
4. Revision increase — pending
- Update AssemblyVersion and AssemblyFileVersion from 3.9.3147.119 to 3.9.3147.120 before committing.
- Added group-based scheduling to RegisterReaderGroupScheduler to optimize calibration and batch processing.
- Introduced `Group1` and `Group2` configuration for logical lanes and batches in `AllyReaderCfg` and related classes.
- Enhanced `AllyReaderCfgCtrl` with UI changes for group settings and optical head presets.
- Updated `AllyMeterReader` and other components to utilize group settings and locking for shared resources.
- Revised test cases to cover group-based parallelism and new execution logic.
- Bumped version to 3.9.3169.0.
Cause:
- Commit 3a5950319 introduced the missing Q3 result persistence fix without incrementing the TBF revision.
- Both the XLSX export fix and the subsequent UnionTown persistence fix therefore reported 3.9.3147.118.
Solution:
1. Give the combined fixes a distinct revision
- Assign 3.9.3147.119 to the current code containing both fixes.
- Preserve the already published commit history.
2. Validation
- Verified both assembly version attributes and checked the diff.
- No application logic changed; existing build and test results are not a rebuild of revision 119.
3. Increased revision
- Updated TBF AssemblyVersion and AssemblyFileVersion from 3.9.3147.118 to 3.9.3147.119.
Cause:
- Commit 3a5950319 introduced the missing Q3 result persistence fix without incrementing the TBF revision.
- Both the XLSX export fix and the subsequent UnionTown persistence fix therefore reported 3.9.3147.118.
Solution:
1. Give the combined fixes a distinct revision
- Assign 3.9.3147.119 to the current code containing both fixes.
- Preserve the already published commit history.
2. Validation
- Verified both assembly version attributes and checked the diff.
- No application logic changed; existing build and test results are not a rebuild of revision 119.
3. Increased revision
- Updated TBF AssemblyVersion and AssemblyFileVersion from 3.9.3147.118 to 3.9.3147.119.
Cause:
- Commit 3a5950319 introduced the missing Q3 result persistence fix without incrementing the TBF revision.
- Both the XLSX export fix and the subsequent UnionTown persistence fix therefore reported 3.9.3147.118.
Solution:
1. Give the combined fixes a distinct revision
- Assign 3.9.3147.119 to the current code containing both fixes.
- Preserve the already published commit history.
2. Validation
- Verified both assembly version attributes and checked the diff.
- No application logic changed; existing build and test results are not a rebuild of revision 119.
3. Increased revision
- Updated TBF AssemblyVersion and AssemblyFileVersion from 3.9.3147.118 to 3.9.3147.119.
Cause:
- Q3 results can contain NaN, which cannot be stored as a regular MySQL numeric value.
- MainSeq ignored SaveNewBatch failure and continued processing, potentially reporting a misleading RsltsSent update error.
Solution:
1. Persist unavailable result errors safely
- Store non-finite MeterTestRslt.Error values as database NULL.
- Restore NULL as NaN when loading, preserving finite values and test pass/fail status.
- Allow NULL in older MySQL Error columns while retaining their numeric type and finite default.
2. Stop processing after database save failures
- Return the underlying error from SaveNewBatch.
- Stop before export, printing and RsltsSent updates when saving fails.
- Dispose database resources and preserve the original exception if rollback also fails.
3. Added regression coverage
- Verify NULL/NaN round trips through production NHibernate mappings using in-memory SQLite.
- Verify finite values, non-finite parameter conversion and save-failure reporting.
- All 4 targeted tests passed; Results and TBF Release builds passed.
4. Revision
- AssemblyVersion and AssemblyFileVersion remain at 3.9.3147.118.
- Load the workbook once and save once per batch
- Publish through a temporary file to protect existing output
- Discard buffered changes on failure or cancellation
- Preserve standalone writes, CSV exports and result row views
- Add regression tests for batch exports and failure scenarios
- Keep the current application version and ALLY/ASIC behavior unchanged
Source: 3e1240c0ea
add recoverable optical start handling with lifecycle logging and test coverage
- Introduced `RecoverableAllyStartOp` adapter to handle recoverable errors during optical measurement start.
- Enhanced `FlyingStartMassCollectionSeq` with improved error recovery and control transfer logic.
- Updated `AllyMeterReader` to expose `MeasurementStartFailed` for error evaluation.
- Added comprehensive test cases for recoverable and successful optical starts.
Cause:
- ResultsWriter exported each meter/test result as a separate write operation, repeatedly loading and saving the entire XLSX workbook.
- Exporting 20 meters with 12 tests took approximately 9 minutes in the supplied production log.
Solution:
1. Added an explicit batch write scope
- Load the XLSX workbook once, buffer rows and save once after successful completion.
- Preserve standalone SetData behavior, existing CSV exports and both result row views.
2. Handle unsuccessful exports safely
- Discard buffered XLSX changes on failure or cancellation.
- Publish through a temporary file to protect the existing workbook.
- Report export success only after saving completes; preserve the existing RsltsSent behavior.
3. Added regression coverage
- Verify 240-row export, subsequent appends, standalone writes, cancellation, invalid rows, locked destinations and empty exports.
- All 16 targeted tests passed. A small test workbook export of 20 meters x 12 tests took 446 ms.
4. Increased revision
- Updated TBF AssemblyVersion and AssemblyFileVersion from 3.9.3147.117 to 3.9.3147.118.
- Introduced `ResultOutputJob` class to handle result delivery with enhanced thread safety and logging.
- Updated `MainSeq` to manage output jobs independently and ensure fault tolerance for multiple outputs.
- Added cancellation and timeout handling for result outputs with detailed status reporting.
- Improved user interaction for stopping output processing during runtime.
- Added tooltip and double-click functionality to copy file paths to the clipboard.
- Implemented "Copy backup file" button with custom drawing and clipboard integration.
- Improved status updates and error handling for clipboard operations.
Cause:
- Incomplete runtime copying mixed outdated and current Laatzen assemblies, causing missing-library and assembly-version errors.
- An explicitly configured local output path was incorrectly treated as an external binary package, skipping local dependency preparation.
Solution:
1. Make GCI build update the Laatzen runtime
- Prepare local GenesisToolBox dependencies before resolving GCI references.
- Validate and synchronize the runtime into packages/Common, GCI output and the runtime package.
- Reject missing or incompatible assemblies before copying.
2. Preserve external binary package support
- Normalize source paths to correctly recognize local output.
- Consume packages from other directories without building external projects and preserve the BuildLocalLaatzenRuntime override.
- Copy runtime subdirectories into TBF output, remove obsolete binding redirects and track synchronized files while preserving unrelated destination files.
- Include the refreshed Common runtime distribution, documentation and the patch required for the ignored external GenesisToolBox project.
3. Added regression coverage
- Added checks for missing assemblies, incompatible versions, recursive copying, stale-file cleanup and manifest path containment; synchronization checks passed.
- GCI rebuild passed with the explicit local source path from the failing Visual Studio log; external-package mode and explicit preparation disablement also passed.
- Verified identical copies of three affected DLLs across all five pipeline locations.
- TBF copying passed; full TBF compilation remained unverified because other project outputs were missing. The subsequent revision-only change was verified in source.
4. Increased revision
- Updated TBF AssemblyVersion and AssemblyFileVersion from 3.9.3147.116 to 3.9.3147.117.
- Introduced `DataBackupForm` UI for streamlined data backup functionality with language localization and preferences support.
- Added detailed tests for optical volume handling: FlyingVolume with signed modulo handling, reverse boundaries, and unwrapping.
- Enhanced batch processing with robust error handling for ASIC optical measurements.
- Updated `MainWnd` with menu integration for data backup access.
Cause:
- Cordonel calibration percentages could use the legacy iPerl nominal factor of 4096.
- This produced misleading corrections such as 265.5762 %.
Solution:
1. Use channel-specific nominal factors
- Calculate percentages against the initial factor configured for each Cordonel channel.
- Preserve the existing parent-meter mapping to CH3.
- Populate channel meters with their own applied and nominal factors.
2. Keep factor values synchronized
- Update results after successful factor register writes and during calibration preparation.
- Apply the same mapping when creating channel meters and in simulation.
- Preserve existing variable names and iPerl percentage behavior.
3. Added regression coverage
- Added tests for channel-specific bases, parent CH3 mapping, newly created channels, preparation reset and meter isolation.
- Added coverage for the unchanged iPerl default of 4096.
- Isolated checks using production helper code and percentage getters passed.
4. Increased revision
- Updated AssemblyVersion and AssemblyFileVersion from 3.9.3147.115 to 3.9.3147.116.
Cause:
- Write Q3 Calibration results were only recorded for the parent meter.
- Channel tables did not show individual factor deviations or the calibration write outcome.
Solution:
1. Add channel result rows
- Add Write Q3 Calibration to CH1, CH2 and CH3.
- Display each channel's signed factor deviation in E rel.
- Preserve the maximum deviation displayed for the parent meter.
2. Record the calibration write outcome
- Populate Test passed() from the actual write operation outcome.
- Mark all three channel rows as failed when the write is rejected.
- Update existing rows on repeated execution without creating duplicates.
- Keep other auxiliary Q3 communication steps out of channel tables.
3. Added regression coverage
- Added coverage for signed deviations, rejected writes, successful retries, missing data, duplicate prevention and meter isolation.
- Isolated checks of the row-update helper passed using minimal model stubs.
4. Increased revision
- Updated AssemblyVersion and AssemblyFileVersion from 3.9.3147.114 to 3.9.3147.115.
Cause:
- E rel. in the Write Q3 Calibration row did not display the calculated factor deviation.
- Users could not see the largest factor change when calibration passed or was rejected.
Solution:
1. Display the maximum signed deviation
- Select the channel with the largest absolute percentage change from its original calibration factor.
- Preserve the sign and store the value in E rel. for the Write Q3 Calibration activity.
2. Record deviations regardless of validation outcome
- Store the deviation before rejecting factors outside the configured limits.
- Display the value when all channels are within limits.
- Preserve existing factor validation and write behavior.
- Clear the previous value before each attempt and use NaN for unavailable data.
3. Added regression coverage
- Added tests for positive and negative deviations within and outside limits, and missing channel data.
- Standalone calculation checks passed for five signed-deviation cases and three invalid-data cases.
4. Increased revision
- Updated AssemblyVersion and AssemblyFileVersion from 3.9.3147.113 to 3.9.3147.114.
Cause:
- Login results were evaluated using shared communication-head flags instead of the outcome of the individual login operation.
- Failed login attempts could appear as passed in Test passed().
Solution:
1. Store individual login outcomes
- Capture Login and Login (Combined workflow) results separately for each test and meter.
- Populate Test passed() from the captured outcome.
2. Preserve results across subsequent activities
- Prevent later communication-head state changes from overwriting the login outcome.
- Treat missing login outcomes as not passed.
- Preserve result evaluation for other communication activities.
3. Verification
- git diff --check passed.
- No automated regression tests added.
4. Increased revision
- Updated AssemblyVersion and AssemblyFileVersion from 3.9.3147.112 to 3.9.3147.113.