From 746cea809e0660a414fc81e8a65b740030ffafb9 Mon Sep 17 00:00:00 2001 From: Johannes Paehr Date: Wed, 24 Dec 2025 10:53:38 +0100 Subject: [PATCH] made analyzer more robust --- src/TLC59731Analyzer.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/TLC59731Analyzer.cpp b/src/TLC59731Analyzer.cpp index 8a52135..102be19 100644 --- a/src/TLC59731Analyzer.cpp +++ b/src/TLC59731Analyzer.cpp @@ -26,6 +26,7 @@ void TLC59731Analyzer::SetupResults() void TLC59731Analyzer::WorkerThread() { mSampleRateHz = GetSampleRate(); + bool foundLegitStart = false; mSerial = GetAnalyzerChannelData( mSettings.mInputChannel ); bool run = 1; @@ -41,6 +42,14 @@ void TLC59731Analyzer::WorkerThread() mSerial->AdvanceToNextEdge(); // wait for rising } + if( !mSerial->WouldAdvancingCauseTransition( NSToSamples( 8 * 50000 ) ) && mSerial->GetBitState() == BIT_HIGH && !foundLegitStart ) + { + // found something, but nothing from frame + mSerial->AdvanceToNextEdge(); + foundLegitStart = true; + continue; + } + U32 data = 0; U32 bitCtr = 1; // measure cycletime