Hi
The new release of C++ SDK v1.8.5 as an issue with the OpcUaDi::DeviceType, this code was working with v1.8.3.
If I run this line:
device.setDeviceHealth (OpcUaDi::DeviceHealthEnumeration_NORMAL);
I got this error.
.../UA_SDK_1.8.5/src/uaserver/uaservercpp/coremodule/nodemanagerroot.cpp:3169: static OpcUa_Boolean NodeManagerRoot::isOfType(const OpcUa_Variant*, const UaNodeId&): Assertion `false' failed.
Knowing that:
OpcUa::BaseDataVariableType * deviceHealth; // type 6244 OpcUaDi::DeviceHealthEnumeration
void DeviceTypeBase::setDeviceHealth(OpcUaDi::DeviceHealthEnumeration DeviceHealth)
{
...
UaVariant value;
value.setInt32(DeviceHealth);
UaDataValue dataValue;
dataValue.setValue(value, OpcUa_True, OpcUa_True);
m_pDeviceHealth->setValue(NULL, dataValue, OpcUa_False);
}
Looks like there is a type mismatch between variant<int32> and dataValue expecting OpcUaDi::DeviceHealthEnumeration
maybe an automatic conversion was expected.
Thanks for your support
Issue with DeviceTypeBase with v1.8.5
Moderator: uasdkcpp
- Support Team
- Hero Member
- Posts: 3213
- Joined: 18 Mar 2011, 15:09
Re: Issue with DeviceTypeBase with v1.8.5
Hi,
this looks indeed like a bug in the code we have generated for the DI model.
We are working on a solution for it, probably need to re-generate with updated template.
Please contact support team via the contact form for getting patch/workaround.
this looks indeed like a bug in the code we have generated for the DI model.
We are working on a solution for it, probably need to re-generate with updated template.
Please contact support team via the contact form for getting patch/workaround.
Best regards
Unified Automation Support Team
Unified Automation Support Team