Auto: twincat-1.2 — native UA TIME/DATE/DT/TOD
IEC 61131-3 TIME/TOD now surface as TimeSpan (UA Duration); DATE/DT surface as DateTime (UTC). The wire form stays UDINT — AdsTwinCATClient post-processes raw values in ReadValueAsync and OnAdsNotificationEx, and accepts native CLR types in ConvertForWrite. Added Duration to DriverDataType (back-compat: existing switches default to BaseDataType for unknown enum values) and mapped it to DataTypeIds.Duration in DriverNodeManager. Closes #306
This commit is contained in:
@@ -310,6 +310,7 @@ public sealed class DriverNodeManager : CustomNodeManager2, IAddressSpaceBuilder
|
||||
DriverDataType.Float64 => DataTypeIds.Double,
|
||||
DriverDataType.String => DataTypeIds.String,
|
||||
DriverDataType.DateTime => DataTypeIds.DateTime,
|
||||
DriverDataType.Duration => DataTypeIds.Duration,
|
||||
_ => DataTypeIds.BaseDataType,
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user