Files
LLA_TLC59731/src/TLC59731Analyzer.h
JPaehr 866e5e9a7d
Some checks failed
Build / windows (push) Has been cancelled
Build / macos (push) Has been cancelled
Build / linux (push) Has been cancelled
Build / publish (push) Has been cancelled
init
2025-12-21 21:43:47 +01:00

52 lines
1.4 KiB
C++

#ifndef TLC59731_ANALYZER_H
#define TLC59731_ANALYZER_H
#include <Analyzer.h>
#include "TLC59731AnalyzerSettings.h"
#include "TLC59731AnalyzerResults.h"
#include "TLC59731SimulationDataGenerator.h"
#include <LogicPublicTypes.h>
#include <memory>
#define TLL_MIN 500000
#define MAX_CYCLETIME 50000 // in ns
class ANALYZER_EXPORT TLC59731Analyzer : public Analyzer2
{
public:
TLC59731Analyzer();
virtual ~TLC59731Analyzer();
virtual void SetupResults();
virtual void WorkerThread();
virtual U32 GenerateSimulationData( U64 newest_sample_requested, U32 sample_rate, SimulationChannelDescriptor** simulation_channels );
virtual U32 GetMinimumSampleRateHz();
virtual const char* GetAnalyzerName() const;
virtual bool NeedsRerun();
U64 SamplesToNS(U64 samples) { return (samples * 1000000000) / mSampleRateHz; }
protected: //vars
TLC59731AnalyzerSettings mSettings;
std::unique_ptr<TLC59731AnalyzerResults> mResults;
AnalyzerChannelData* mSerial;
TLC59731SimulationDataGenerator mSimulationDataGenerator;
bool mSimulationInitilized;
//Serial analysis vars:
U32 mSampleRateHz;
U64 cycleTime;
U32 mStartOfStopBitOffset;
U32 mEndOfStopBitOffset;
};
extern "C" ANALYZER_EXPORT const char* __cdecl GetAnalyzerName();
extern "C" ANALYZER_EXPORT Analyzer* __cdecl CreateAnalyzer( );
extern "C" ANALYZER_EXPORT void __cdecl DestroyAnalyzer( Analyzer* analyzer );
#endif //TLC59731_ANALYZER_H