Nous avons procédé ce jeudi matin 08 avril 2021 à une MAJ de sécurité urgente. Nous sommes passé de la version 13.9.3 à la version 13.9.5 les releases notes correspondantes sont ici:
https://about.gitlab.com/releases/2021/03/17/security-release-gitlab-13-9-4-released/
https://about.gitlab.com/releases/2021/03/31/security-release-gitlab-13-10-1-released/

Commit 697dc7b3 authored by Jussi Lindgren's avatar Jussi Lindgren

Merge branch 'wip-jole-core-1071-fix-mensia-library' of...

Merge branch 'wip-jole-core-1071-fix-mensia-library' of gitlab.inria.fr:openvibe/extras into wip-all-openvibe20-base
parents e0a732ce 258631ee
......@@ -123,6 +123,19 @@ namespace OpenViBEAcquisitionServer
virtual OpenViBE::boolean setImpedanceCheckRequested(const OpenViBE::boolean bImpedanceCheckRequested) = 0;
virtual OpenViBE::boolean isImpedanceCheckRequested(void) const = 0;
/**
* \brief Get impedance limit
* \return \e the chosen impedance limit.
*/
virtual OpenViBE::uint32 getImpedanceLimit(void) const = 0;
/**
* \brief Set impedance limit
* \param ui32ImpedanceLimit [in] : the new value for impedance limit
* \return \e true in case of success.
* \return \e false in case of error.
*/
virtual OpenViBE::boolean setImpedanceLimit(const OpenViBE::uint32 ui32ImpedanceLimit) = 0;
//@}
/** \name Chanel information */
//@{
......
......@@ -5,7 +5,8 @@
#include <toolkit/ovtk_all.h>
#include <windows.h>
//#include <Windows.h>
#include <system/WindowsUtilities.h>
#include <cmath>
#include <string>
......@@ -16,9 +17,74 @@ using namespace OpenViBEAcquisitionServer;
using namespace OpenViBE;
using namespace OpenViBE::Kernel;
static OpenViBE::CString s_sMensiaDLL = "openvibe-driver-mensia-acquisition.dll";
HINSTANCE m_oLibMensiaAcquisition; // Library Handle
namespace
{
enum EAcquisitionMode
{
AcquisitionMode_Undefined = 0,
AcquisitionMode_Data = 1,
AcquisitionMode_Impedance = 2,
};
OpenViBE::CString s_sMensiaDLL = "openvibe-driver-mensia-acquisition.dll";
HINSTANCE m_oLibMensiaAcquisition; // Library Handle
typedef int32 (* MACQ_InitializeAcquisitionDriver) (const char* sDeviceIdentifier, IDriverContext& rDriverContext);
typedef const char* (* MACQ_GetName) (size_t);
typedef const char* (* MACQ_GetDeviceURL) (size_t);
typedef bool (*MACQ_Preconfigure) (size_t, const char*);
typedef bool (*MACQ_Configure) (size_t, const char*);
typedef uint32 (*MACQ_GetSamplingRate) (size_t);
typedef uint32 (*MACQ_GetChannelCount) (size_t);
typedef const char* (*MACQ_GetChannelName) (size_t, size_t);
typedef bool (*MACQ_IsImpedanceCheckRequested) (size_t);
typedef void (*MACQ_SetImpedanceCheckRequested) (size_t, bool);
typedef float (*MACQ_GetChannelImpedance) (size_t, size_t);
typedef uint32 (*MACQ_GetImpedanceLimit) (size_t);
typedef void (*MACQ_SetImpedanceLimit) (size_t, uint32);
typedef uint32 (*MACQ_GetExperimentIdentifier) (size_t);
typedef uint32 (*MACQ_SetExperimentIdentifier) (size_t, uint32);
typedef uint32 (*MACQ_GetSubjectAge) (size_t);
typedef uint32 (*MACQ_SetSubjectAge) (size_t, uint32);
typedef uint32 (*MACQ_GetSubjectGender) (size_t);
typedef uint32 (*MACQ_SetSubjectGender) (size_t, uint32);
typedef uint32 (*MACQ_SetSampleCountPerBuffer) (size_t, uint32);
typedef bool (*MACQ_Initialize) (size_t, IDriverCallback*, uint32, const char*, EAcquisitionMode);
typedef bool (*MACQ_Start) (size_t);
typedef bool (*MACQ_Stop) (size_t);
typedef bool (*MACQ_Uninitialize) (size_t);
typedef bool (*MACQ_Loop) (size_t);
MACQ_InitializeAcquisitionDriver m_fpInitializeAcquisitionDriver;
MACQ_GetName m_fpGetName;
MACQ_GetDeviceURL m_fpGetDeviceURL;
MACQ_Preconfigure m_fpPreconfigure;
MACQ_Configure m_fpConfigure;
MACQ_GetSamplingRate m_fpGetSamplingRate;
MACQ_GetChannelCount m_fpGetChannelCount;
MACQ_GetChannelName m_fpGetChannelName;
MACQ_IsImpedanceCheckRequested m_fpIsImpedanceCheckRequested;
MACQ_SetImpedanceCheckRequested m_fpSetImpedanceCheckRequested;
MACQ_GetChannelImpedance m_fpGetChannelImpedance;
MACQ_GetImpedanceLimit m_fpGetImpedanceLimit;
MACQ_SetImpedanceLimit m_fpSetImpedanceLimit;
MACQ_GetExperimentIdentifier m_fpGetExperimentIdentifier;
MACQ_SetExperimentIdentifier m_fpSetExperimentIdentifier;
MACQ_GetSubjectAge m_fpGetSubjectAge;
MACQ_SetSubjectAge m_fpSetSubjectAge;
MACQ_GetSubjectGender m_fpGetSubjectGender;
MACQ_SetSubjectGender m_fpSetSubjectGender;
MACQ_SetSampleCountPerBuffer m_fpSetSampleCountPerBuffer;
MACQ_Initialize m_fpInitialize;
MACQ_Start m_fpStart;
MACQ_Stop m_fpStop;
MACQ_Uninitialize m_fpUninitialize;
MACQ_Loop m_fpLoop;
}
template<typename T>
void CDriverMensiaAcquisition::loadDLLfunct(T* functionPointer, const char* functionName)
......@@ -31,60 +97,16 @@ void CDriverMensiaAcquisition::loadDLLfunct(T* functionPointer, const char* func
}
}
typedef int32 (* MACQ_InitializeAcquisitionDriver) (const char* sDeviceIdentifier, IDriverContext& rDriverContexts);
typedef const char* (* MACQ_GetName) (size_t);
typedef const char* (* MACQ_GetDeviceURL) (size_t);
typedef boolean (* MACQ_Preconfigure) (size_t, const char*);
typedef boolean (* MACQ_Configure) (size_t, const char*);
typedef uint32 (* MACQ_GetSamplingRate) (size_t);
typedef uint32 (* MACQ_GetChannelCount) (size_t);
typedef const char* (* MACQ_GetChannelName) (size_t, size_t);
typedef uint32 (* MACQ_GetExperimentIdentifier) (size_t);
typedef uint32 (* MACQ_SetExperimentIdentifier) (size_t, uint32);
typedef uint32 (* MACQ_GetSubjectAge) (size_t);
typedef uint32 (* MACQ_SetSubjectAge) (size_t, uint32);
typedef uint32 (* MACQ_GetSubjectGender) (size_t);
typedef uint32 (* MACQ_SetSubjectGender) (size_t, uint32);
typedef boolean (* MACQ_Initialize) (size_t, IDriverCallback*, uint32, const char*);
typedef boolean (* MACQ_Start) (size_t);
typedef boolean (* MACQ_Stop) (size_t);
typedef boolean (* MACQ_Uninitialize) (size_t);
typedef boolean (* MACQ_Loop) (size_t);
MACQ_InitializeAcquisitionDriver m_fpInitializeAcquisitionDriver;
MACQ_GetName m_fpGetName;
MACQ_GetDeviceURL m_fpGetDeviceURL;
MACQ_Preconfigure m_fpPreconfigure;
MACQ_Configure m_fpConfigure;
MACQ_GetSamplingRate m_fpGetSamplingRate;
MACQ_GetChannelCount m_fpGetChannelCount;
MACQ_GetChannelName m_fpGetChannelName;
MACQ_GetExperimentIdentifier m_fpGetExperimentIdentifier;
MACQ_SetExperimentIdentifier m_fpSetExperimentIdentifier;
MACQ_GetSubjectAge m_fpGetSubjectAge;
MACQ_SetSubjectAge m_fpSetSubjectAge;
MACQ_GetSubjectGender m_fpGetSubjectGender;
MACQ_SetSubjectGender m_fpSetSubjectGender;
MACQ_Initialize m_fpInitialize;
MACQ_Start m_fpStart;
MACQ_Stop m_fpStop;
MACQ_Uninitialize m_fpUninitialize;
MACQ_Loop m_fpLoop;
CDriverMensiaAcquisition::CDriverMensiaAcquisition(IDriverContext& rDriverContext, const char* sDriverIdentifier)
:IDriver(rDriverContext)
:IDriver(rDriverContext)
// This hax only works because m_oSettings does creates a copy of the string
,m_oSettings(std::string( std::string("AcquisitionServer_Driver_MensiaAcquisition_") + sDriverIdentifier).c_str(), m_rDriverContext.getConfigurationManager())
,m_pCallback(NULL)
,m_ui32SampleCountPerSentBlock(0)
,m_pSample(NULL)
,m_ui32TotalSampleCount(0)
,m_ui64StartTime(0)
,m_pCallback(NULL)
,m_ui32SampleCountPerSentBlock(0)
,m_pSample(NULL)
,m_ui32TotalSampleCount(0)
,m_ui64StartTime(0)
{
m_rDriverContext.getLogManager() << LogLevel_Trace << "CDriverMensiaAcquisition::CDriverMensiaAcquisition\n";
m_bValid = true;
......@@ -94,16 +116,16 @@ CDriverMensiaAcquisition::CDriverMensiaAcquisition(IDriverContext& rDriverContex
if(!std::ifstream(l_sPath.toASCIIString()).is_open())
{
m_rDriverContext.getLogManager() << LogLevel_Trace << "CDriverMensiaAcquisition::CDriverMensiaAcquisition: " <<
" dll file [" << l_sPath.toASCIIString() <<"] not openable, perhaps it was not installed.\n";
" dll file [" << l_sPath.toASCIIString() <<"] not openable, perhaps it was not installed.\n";
m_bValid = false;
return;
}
m_oLibMensiaAcquisition = LoadLibrary(l_sPath);
m_oLibMensiaAcquisition = static_cast<HINSTANCE>(System::WindowsUtilities::utf16CompliantLoadLibrary(l_sPath.toASCIIString()));
if(!m_oLibMensiaAcquisition)
{
m_rDriverContext.getLogManager() << "CDriverMensiaAcquisition::CDriverMensiaAcquisition: LoadLibrary failed to load: [" <<
l_sPath.toASCIIString() <<"] with error [" << static_cast<uint64>(GetLastError()) << "]\n";
m_rDriverContext.getLogManager() << "CDriverMensiaAcquisition::CDriverMensiaAcquisition: utf16CompliantLoadLibrary failed to load: " <<
l_sPath.toASCIIString() <<" with error " << static_cast<uint64>(GetLastError()) << "\n";
}
loadDLLfunct<MACQ_InitializeAcquisitionDriver>(&m_fpInitializeAcquisitionDriver, "initializeAcquisitionDriver");
......@@ -114,12 +136,18 @@ CDriverMensiaAcquisition::CDriverMensiaAcquisition(IDriverContext& rDriverContex
loadDLLfunct<MACQ_GetSamplingRate>(&m_fpGetSamplingRate, "getSamplingRate");
loadDLLfunct<MACQ_GetChannelCount>(&m_fpGetChannelCount, "getChannelCount");
loadDLLfunct<MACQ_GetChannelName>(&m_fpGetChannelName, "getChannelName");
loadDLLfunct<MACQ_IsImpedanceCheckRequested>(&m_fpIsImpedanceCheckRequested, "isImpedanceCheckRequested");
loadDLLfunct<MACQ_SetImpedanceCheckRequested>(&m_fpSetImpedanceCheckRequested, "setImpedanceCheckRequested");
loadDLLfunct<MACQ_GetChannelImpedance>(&m_fpGetChannelImpedance, "getChannelImpedance");
loadDLLfunct<MACQ_GetImpedanceLimit>(&m_fpGetImpedanceLimit, "getImpedanceLimit");
loadDLLfunct<MACQ_SetImpedanceLimit>(&m_fpSetImpedanceLimit, "setImpedanceLimit");
loadDLLfunct<MACQ_GetExperimentIdentifier>(&m_fpGetExperimentIdentifier, "getExperimentIdentifier");
loadDLLfunct<MACQ_SetExperimentIdentifier>(&m_fpSetExperimentIdentifier, "setExperimentIdentifier");
loadDLLfunct<MACQ_GetSubjectAge>(&m_fpGetSubjectAge, "getSubjectAge");
loadDLLfunct<MACQ_SetSubjectAge>(&m_fpSetSubjectAge, "setSubjectAge");
loadDLLfunct<MACQ_GetSubjectGender>(&m_fpGetSubjectGender, "getSubjectGender");
loadDLLfunct<MACQ_SetSubjectGender>(&m_fpSetSubjectGender, "setSubjectGender");
loadDLLfunct<MACQ_SetSampleCountPerBuffer>(&m_fpSetSampleCountPerBuffer, "setSampleCountPerBuffer");
loadDLLfunct<MACQ_Initialize>(&m_fpInitialize, "initialize");
loadDLLfunct<MACQ_Start>(&m_fpStart, "start");
loadDLLfunct<MACQ_Stop>(&m_fpStop, "stop");
......@@ -128,7 +156,7 @@ CDriverMensiaAcquisition::CDriverMensiaAcquisition(IDriverContext& rDriverContex
if (!m_bValid)
{
m_rDriverContext.getLogManager() << LogLevel_Warning << "Could not initialize Mensia Acqsuisition Driver driver\n";
m_rDriverContext.getLogManager() << LogLevel_Warning << "Could not initialize Mensia Acquisition Driver driver\n";
return;
}
......@@ -139,7 +167,7 @@ CDriverMensiaAcquisition::CDriverMensiaAcquisition(IDriverContext& rDriverContex
// Negative value is considered an error
if (l_i32DriverId < 0)
{
m_rDriverContext.getLogManager() << LogLevel_Warning << "Could not initialize Mensia Acqsuisition Driver driver\n";
m_rDriverContext.getLogManager() << LogLevel_Warning << "Could not initialize Mensia Acquisition Driver driver\n";
return;
}
m_ui32DriverId = static_cast<uint32>(l_i32DriverId);
......@@ -162,6 +190,9 @@ CDriverMensiaAcquisition::CDriverMensiaAcquisition(IDriverContext& rDriverContex
m_fpSetSubjectAge(m_ui32DriverId, m_oHeader.getSubjectAge());
m_fpSetSubjectGender(m_ui32DriverId, m_oHeader.getSubjectGender());
m_fpSetImpedanceCheckRequested(m_ui32DriverId, m_oHeader.isImpedanceCheckRequested());
m_fpSetImpedanceLimit(m_ui32DriverId, m_oHeader.getImpedanceLimit());
m_fpPreconfigure(m_ui32DriverId, m_sDeviceURL.toASCIIString());
m_oHeader.setChannelCount(m_fpGetChannelCount(m_ui32DriverId));
......@@ -189,17 +220,23 @@ const char* CDriverMensiaAcquisition::getName(void)
// //
boolean CDriverMensiaAcquisition::initialize(
const uint32 ui32SampleCountPerSentBlock,
IDriverCallback& rCallback)
const uint32 ui32SampleCountPerSentBlock,
IDriverCallback& rCallback)
{
m_rDriverContext.getLogManager() << LogLevel_Trace << "CDriverMensiaAcquisition::initialize\n";
if(m_rDriverContext.isConnected()) { return false; }
m_ui32SampleCountPerSentBlock=ui32SampleCountPerSentBlock;
m_ui32SampleCountPerSentBlock = ui32SampleCountPerSentBlock;
m_fpSetSampleCountPerBuffer(m_ui32DriverId, m_ui32SampleCountPerSentBlock);
m_sDeviceURL = CString(m_fpGetDeviceURL(m_ui32DriverId));
m_pCallback=&rCallback;
if (!m_fpInitialize(m_ui32DriverId, m_pCallback, m_ui32SampleCountPerSentBlock, m_sDeviceURL.toASCIIString()))
m_oHeader.setImpedanceCheckRequested(m_fpIsImpedanceCheckRequested(m_ui32DriverId));
EAcquisitionMode l_eAcquisitionMode = m_oHeader.isImpedanceCheckRequested() ?
EAcquisitionMode::AcquisitionMode_Impedance : EAcquisitionMode::AcquisitionMode_Data;
if (!m_fpInitialize(m_ui32DriverId, m_pCallback, m_ui32SampleCountPerSentBlock, m_sDeviceURL.toASCIIString(), l_eAcquisitionMode))
{
return false;
}
......@@ -213,7 +250,9 @@ boolean CDriverMensiaAcquisition::initialize(
m_oHeader.setExperimentIdentifier(m_fpGetExperimentIdentifier(m_ui32DriverId));
m_oHeader.setSubjectAge(m_fpGetSubjectAge(m_ui32DriverId));
m_oHeader.setSubjectGender(m_fpGetSubjectGender(m_ui32DriverId));
m_oHeader.setImpedanceLimit(m_fpGetImpedanceLimit(m_ui32DriverId));
m_oHeader.setImpedanceCheckRequested(m_fpIsImpedanceCheckRequested(m_ui32DriverId));
for (size_t uiChannelIndex = 0; uiChannelIndex < m_oHeader.getChannelCount(); uiChannelIndex++)
{
......@@ -258,15 +297,15 @@ boolean CDriverMensiaAcquisition::loop(void)
{
return false;
}
// TODO_JL impedance check here
/* if(m_rDriverContext.isImpedanceCheckRequested())
// impedance check here
if(m_rDriverContext.isImpedanceCheckRequested())
{
for(uint32 j=0; j<m_oHeader.getChannelCount(); j++)
{
m_rDriverContext.updateImpedance(j, 1);
m_rDriverContext.updateImpedance(j, m_fpGetChannelImpedance(m_ui32DriverId, j));
}
}
*/
}
return true;
......@@ -356,6 +395,8 @@ boolean CDriverMensiaAcquisition::configure(void)
m_oHeader.setExperimentIdentifier(m_fpGetExperimentIdentifier(m_ui32DriverId));
m_oHeader.setSubjectAge(m_fpGetSubjectAge(m_ui32DriverId));
m_oHeader.setSubjectGender(m_fpGetSubjectGender(m_ui32DriverId));
m_oHeader.setImpedanceLimit(m_fpGetImpedanceLimit(m_ui32DriverId));
m_oHeader.setImpedanceCheckRequested(m_fpIsImpedanceCheckRequested(m_ui32DriverId));
/*
m_fpSetExperimentIdentifier(m_ui32DriverId, m_oHeader.getExperimentIdentifier());
m_fpSetSubjectAge(m_ui32DriverId, m_oHeader.getSubjectAge());
......
......@@ -47,6 +47,8 @@ namespace OpenViBEAcquisitionServer
OpenViBE::uint32 m_ui32TotalSampleCount;
OpenViBE::uint64 m_ui64StartTime;
OpenViBE::uint32* m_pSampleCountPerBuffer;
private:
// Settings
OpenViBE::CString m_sDeviceURL;
......
......@@ -55,6 +55,7 @@
#include <cstring>
#include <cassert>
#include <system/WindowsUtilities.h>
//
#define boolean OpenViBE::boolean
......@@ -203,10 +204,10 @@ CAcquisitionServerGUI::CAcquisitionServerGUI(const IKernelContext& rKernelContex
#endif
// BEGIN MENSIA ACQUISITION DRIVERS
// @FIXME CERT Mensia Acquisition Driver crashes, disabled
#if defined TARGET_OS_Windows && defined TARGET_HasMensiaAcquisitionDriver && defined(false)
#if defined TARGET_OS_Windows && defined TARGET_HasMensiaAcquisitionDriver
m_pAcquisitionServer->getDriverContext().getLogManager() << LogLevel_Trace << "Loading Mensia Driver Collection\n";
m_pLibMensiaAcquisition = nullptr;
CString l_sMensiaDLLPath = m_pAcquisitionServer->getDriverContext().getConfigurationManager().expand("${Path_Bin}/openvibe-driver-mensia-acquisition.dll");
if(!std::ifstream(l_sMensiaDLLPath.toASCIIString()).is_open())
{
......@@ -215,8 +216,8 @@ CAcquisitionServerGUI::CAcquisitionServerGUI(const IKernelContext& rKernelContex
}
else
{
HINSTANCE l_oLibMensiaAcquisition; // Library Handle
l_oLibMensiaAcquisition = ::LoadLibrary(l_sMensiaDLLPath.toASCIIString());
m_pLibMensiaAcquisition = System::WindowsUtilities::utf16CompliantLoadLibrary(l_sMensiaDLLPath.toASCIIString());
HINSTANCE l_oLibMensiaAcquisition = static_cast<HINSTANCE>(m_pLibMensiaAcquisition);
//if it can't be open return FALSE;
if( l_oLibMensiaAcquisition == NULL)
......@@ -243,7 +244,7 @@ CAcquisitionServerGUI::CAcquisitionServerGUI(const IKernelContext& rKernelContex
strcpy(l_sDriverIdentifier, l_fpGetDriverID(l_uiDeviceIndex));
if (strcmp(l_sDriverIdentifier, "") != 0)
{
m_pAcquisitionServer->getDriverContext().getLogManager() << LogLevel_Trace << "Found driver [" << l_sDriverIdentifier << "] in Mensia Driver Collection" << "\n";
m_pAcquisitionServer->getDriverContext().getLogManager() << LogLevel_Info << "Found driver [" << l_sDriverIdentifier << "] in Mensia Driver Collection" << "\n";
m_vDriver.push_back(new CDriverMensiaAcquisition(m_pAcquisitionServer->getDriverContext(), l_sDriverIdentifier));
}
......@@ -346,6 +347,16 @@ CAcquisitionServerGUI::~CAcquisitionServerGUI(void)
m_vDriver.clear();
m_pDriver=NULL;
// BEGIN MENSIA ACQUISITION DRIVERS
// For future implementation
#if defined TARGET_OS_Windows && defined TARGET_HasMensiaAcquisitionDriver
typedef int32 (*MACQ_ReleaseMensiaAcquisitionLibrary)();
MACQ_ReleaseMensiaAcquisitionLibrary l_fpReleaseMensiaAcquisitionLibrary;
l_fpReleaseMensiaAcquisitionLibrary = (MACQ_ReleaseMensiaAcquisitionLibrary)::GetProcAddress(static_cast<HINSTANCE>(m_pLibMensiaAcquisition), "releaseAcquisitionLibrary");
// l_fpReleaseMensiaAcquisitionLibrary();
#endif
// END MENSIA ACQUISITION DRIVERS
delete m_pThread;
m_pThread=NULL;
......
......@@ -85,6 +85,9 @@ namespace OpenViBEAcquisitionServer
std::vector < ::GtkWidget* > m_vLevelMesure;
std::thread* m_pThread;
#if defined TARGET_OS_Windows && defined TARGET_HasMensiaAcquisitionDriver
void* m_pLibMensiaAcquisition;
#endif
};
};
......
......@@ -39,6 +39,8 @@ namespace OpenViBEAcquisitionServer
virtual OpenViBE::boolean setImpedanceCheckRequested(const OpenViBE::boolean bImpedanceCheckRequested);
virtual OpenViBE::boolean isImpedanceCheckRequested(void) const;
virtual OpenViBE::uint32 getImpedanceLimit(void) const;
virtual OpenViBE::boolean setImpedanceLimit(const OpenViBE::uint32 ui32ImpedanceLimit);
// Chanel information
virtual OpenViBE::boolean setChannelCount(const OpenViBE::uint32 ui32ChannelCount);
......@@ -84,6 +86,7 @@ namespace OpenViBEAcquisitionServer
// Impedance check
OpenViBE::boolean m_bIsImpedanceCheckRequested;
OpenViBE::uint32 m_ui32ImpedanceLimit;
};
};
};
......@@ -98,6 +101,7 @@ CHeaderImpl::CHeaderImpl(void)
,m_ui32ChannelCount(_NoValueI_)
,m_ui32SamplingFrequency(_NoValueI_)
,m_bIsImpedanceCheckRequested(false)
,m_ui32ImpedanceLimit(_NoValueI_)
{
}
......@@ -116,6 +120,7 @@ void CHeaderImpl::reset(void)
m_vChannelUnits.clear();
m_ui32SamplingFrequency=_NoValueI_;
m_bIsImpedanceCheckRequested=false;
m_ui32ChannelCount=_NoValueI_;
}
//___________________________________________________________________//
......@@ -166,6 +171,17 @@ boolean CHeaderImpl::isImpedanceCheckRequested(void) const
return m_bIsImpedanceCheckRequested;
}
uint32 CHeaderImpl::getImpedanceLimit(void) const
{
return m_ui32ImpedanceLimit;
}
bool CHeaderImpl::setImpedanceLimit(const uint32 ui32ImpedanceLimit)
{
m_ui32ImpedanceLimit = ui32ImpedanceLimit;
return true;
}
boolean CHeaderImpl::isExperimentIdentifierSet(void) const
{
return m_ui32ExperimentIdentifier!=_NoValueI_;
......@@ -383,6 +399,15 @@ boolean CHeader::isImpedanceCheckRequested(void) const
return m_pHeaderImpl->isImpedanceCheckRequested();
}
uint32 CHeader::getImpedanceLimit(void) const
{
return m_pHeaderImpl->getImpedanceLimit();
}
bool CHeader::setImpedanceLimit(const uint32 ui32ImpedanceLimit)
{
return m_pHeaderImpl->setImpedanceLimit(ui32ImpedanceLimit);
}
//___________________________________________________________________//
// //
......
......@@ -28,6 +28,8 @@ namespace OpenViBEAcquisitionServer
virtual OpenViBE::boolean setImpedanceCheckRequested(const OpenViBE::boolean bImpedanceCheckRequested);
virtual OpenViBE::boolean isImpedanceCheckRequested(void) const;
virtual OpenViBE::uint32 getImpedanceLimit(void) const;
virtual OpenViBE::boolean setImpedanceLimit(const OpenViBE::uint32 ui32ImpedanceLimit);
// Chanel information
virtual OpenViBE::boolean setChannelCount(const OpenViBE::uint32 ui32ChannelCount);
......@@ -83,6 +85,8 @@ namespace OpenViBEAcquisitionServer
virtual OpenViBE::boolean setImpedanceCheckRequested(const OpenViBE::boolean bImpedanceCheckRequested){ return m_rAdaptedHeader.setImpedanceCheckRequested(bImpedanceCheckRequested); }
virtual OpenViBE::boolean isImpedanceCheckRequested(void) const { return m_rAdaptedHeader.isImpedanceCheckRequested(); }
virtual OpenViBE::uint32 getImpedanceLimit(void) const { return m_rAdaptedHeader.getImpedanceLimit(); }
virtual OpenViBE::boolean setImpedanceLimit(const OpenViBE::uint32 ui32ImpedanceLimit) { return m_rAdaptedHeader.setImpedanceLimit(ui32ImpedanceLimit); }
// Channel information
virtual OpenViBE::boolean setChannelCount(const OpenViBE::uint32 ui32ChannelCount) { return m_rAdaptedHeader.setChannelCount(ui32ChannelCount); }
......
......@@ -21,7 +21,7 @@ build/windows/sdk-brainproducts-liveamp.zip;sdk-brainproducts-liveamp;0.0.0
build/windows/sdk-eemagine-eego.zip;sdk-eemagine-eego;0.0.0
build/windows/sdk-enobio3g.zip;sdk-enobio3g;0.0.0
build/windows/sdk-mcs.zip;sdk-mcs;0.0.0
build/windows/sdk-mensia-acquisition-driver.zip;sdk-mensia-acquisition-driver;0.0.0
build/windows/sdk-mensia-acquisition-driver-3.0.99.zip;sdk-mensia-acquisition-driver;3.0.99
build/windows/sdk-micromed.zip;sdk-micromed;0.0.0
build/windows/sdk-mitsar.zip;sdk-mitsar;0.0.0
build/windows/sdk-nexus.zip;sdk-nexus;0.0.0
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment