We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I noticed that the decimal values have a cast to Interger, then the exact value is lost here :
case OpenZWave::ValueID::ValueType_Decimal: { float val; OpenZWave::Manager::Get()->GetValueAsFloat(value, &val); valobj->Set(String::NewSymbol("value"), Integer::New(val)); break; }
I had to remove those lines, and add a new line above the String case to use the same procedure a keep the exact value (in string) :
case OpenZWave::ValueID::ValueType_Decimal: case OpenZWave::ValueID::ValueType_String: { std::string val; OpenZWave::Manager::Get()->GetValueAsString(value, &val); valobj->Set(String::NewSymbol("value"), String::New(val.c_str())); break; }
I'm not an expert, then maybe there's a better way to keep the Float type too ? What do you think, folks ?
The text was updated successfully, but these errors were encountered:
I had to do the same thing for my power meter.
Sorry, something went wrong.
No branches or pull requests
I noticed that the decimal values have a cast to Interger, then the exact value is lost here :
I had to remove those lines, and add a new line above the String case to use the same procedure a keep the exact value (in string) :
I'm not an expert, then maybe there's a better way to keep the Float type too ?
What do you think, folks ?
The text was updated successfully, but these errors were encountered: