Hello everybody!
Recently I've been developing a new driver on OpenViBE.
The problem I encountered is that I cannot adjust the range of the impedance checking module.
The full range of impedance check seems to be 20k, and any value higher than 20k will be described as "too bad", .
Is there any way that I can raise the range of the impedance check? 20k is not high enough for me in my experiment.
Thanks a lot!
Usian
About raising the range of the impedance check
-
- Posts: 775
- Joined: Tue Dec 04, 2012 3:53 pm
- Location: INRIA Rennes, FRANCE
Re: About raising the range of the impedance check
Hi Usain,
you'll find the following magic in the code
This suggests that you may be able to change the limit by adding AcquisitionServer_DefaultImpedanceLimit token with a value something else than 5000 to openvibe-acquisition-server.conf (under $APPDATA/Roaming/openvibe/ on Win). Otherwise, you'll just have to modify the code above and recompile. Its in CAcquisitionServerGUI::setImpedance(...).
Hope this helps,
Jussi
you'll find the following magic in the code
Code: Select all
//float64 l_dFraction=(f64Impedance*.001/20); With fixed impedance limit, 20kOhm max / 25%=5kOhm to be good
float64 l_dFraction=(f64Impedance / (m_rKernelContext.getConfigurationManager().expandAsFloat("${AcquisitionServer_DefaultImpedanceLimit}",5000) * 4));
if(l_dFraction>1) l_dFraction=1;
char l_sImpedance[1024];
char l_sStatus[1024];
// ... some code cut...
if(l_dFraction==1)
{
::sprintf(l_sImpedance, "Too high !");
}
else
{
::sprintf(l_sImpedance, "%.2f kOhm", f64Impedance*.001);
}
::sprintf(l_sStatus, "%s", l_dFraction<.25?"Good !":"Bad...");
Hope this helps,
Jussi
Re: About raising the range of the impedance check
Thank you so much, Jussi! This is exactly what I want to know!
But finally I solved the problem by editing the file "openvibe.conf" in \share\openvibe\kernel\
I think that this is also a configuration file for the OpenViBE platform, isn't it?
Usain
But finally I solved the problem by editing the file "openvibe.conf" in \share\openvibe\kernel\
I think that this is also a configuration file for the OpenViBE platform, isn't it?
Usain
jtlindgren wrote:Hi Usain,
you'll find the following magic in the code
This suggests that you may be able to change the limit by adding AcquisitionServer_DefaultImpedanceLimit token with a value something else than 5000 to openvibe-acquisition-server.conf (under $APPDATA/Roaming/openvibe/ on Win). Otherwise, you'll just have to modify the code above and recompile. Its in CAcquisitionServerGUI::setImpedance(...).Code: Select all
//float64 l_dFraction=(f64Impedance*.001/20); With fixed impedance limit, 20kOhm max / 25%=5kOhm to be good float64 l_dFraction=(f64Impedance / (m_rKernelContext.getConfigurationManager().expandAsFloat("${AcquisitionServer_DefaultImpedanceLimit}",5000) * 4)); if(l_dFraction>1) l_dFraction=1; char l_sImpedance[1024]; char l_sStatus[1024]; // ... some code cut... if(l_dFraction==1) { ::sprintf(l_sImpedance, "Too high !"); } else { ::sprintf(l_sImpedance, "%.2f kOhm", f64Impedance*.001); } ::sprintf(l_sStatus, "%s", l_dFraction<.25?"Good !":"Bad...");
Hope this helps,
Jussi
-
- Posts: 775
- Joined: Tue Dec 04, 2012 3:53 pm
- Location: INRIA Rennes, FRANCE
Re: About raising the range of the impedance check
Several different config files are typically loaded in 'certain' order: the more specific override the more generic ones, if they have the same tokens in them.
Cheers,
Jussi
Cheers,
Jussi