StimBuff: make start/stop virtual;
We can now have the derived StimBuff class implement its own start()/stop() preamble and epilogue.
This commit is contained in:
@@ -67,7 +67,7 @@ public:
|
||||
StimulusBuffer& operator=(StimulusBuffer&&) = default;
|
||||
|
||||
// Control methods
|
||||
void start()
|
||||
virtual void start()
|
||||
{
|
||||
std::cout << __func__ << ": Starting stimulus buffer for device "
|
||||
<< deviceAttachmentSpec.deviceSelector << std::endl;
|
||||
@@ -76,7 +76,7 @@ public:
|
||||
scheduleNextTimeout();
|
||||
}
|
||||
|
||||
void stop();
|
||||
virtual void stop();
|
||||
|
||||
protected:
|
||||
// Virtual functions for derived classes to override
|
||||
|
||||
@@ -32,6 +32,22 @@ ioUringAssemblyEngine(*this)
|
||||
{
|
||||
}
|
||||
|
||||
void PcloudStimulusBuffer::start()
|
||||
{
|
||||
// Call ioUringAssemblyEngine setup() as the final step
|
||||
// ioUringAssemblyEngine.setup();
|
||||
// Call base class start() as the final step
|
||||
StimulusBuffer::start();
|
||||
}
|
||||
|
||||
void PcloudStimulusBuffer::stop()
|
||||
{
|
||||
// Call base class stop() as the first step
|
||||
StimulusBuffer::stop();
|
||||
// Call ioUringAssemblyEngine stop() as the final step
|
||||
// ioUringAssemblyEngine.finalize();
|
||||
}
|
||||
|
||||
void PcloudStimulusBuffer::stimFrameProductionTimesliceInd()
|
||||
{
|
||||
// Release the spinlock for now
|
||||
|
||||
@@ -40,6 +40,10 @@ public:
|
||||
PcloudStimulusBuffer(PcloudStimulusBuffer&&) = default;
|
||||
PcloudStimulusBuffer& operator=(PcloudStimulusBuffer&&) = default;
|
||||
|
||||
// Control methods
|
||||
void start() override;
|
||||
void stop() override;
|
||||
|
||||
protected:
|
||||
void stimFrameProductionTimesliceInd() override;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user