Skip to main content
Version: 2.8

Device Information Model

This chapter describes how to write a device information file for device drivers. This file is interpreted by the HumanOS® Kernel. Here all information is needed to build an internal structure representing the hardware device.

The file is typically located in $AppSettingsDir$\Config\Devices

The json file contains following semantical information about the hardware device:

  • Device Information (including device UUID, connection address, driver id)
  • Data access points for reading, writing, or monitoring items.
  • Alarm and Event pooling
  • Commands (accessors to perform actions)
  • Groups containing data access points and commands.

The device info schema includes following information:

AttributeDescriptionData Type
IdUUID of the device. Make sure there exist no other device with the same id!!System.Guid
NameName of the deviceSystem.String
DriverIdId of the driver (see UHAL Connectors)System.Guid
AddressConnection address to hardware device.System.String
DataNodesList of the UHAL data nodesTUHALDataNodeInfo[]
ConstantNodesList of the constant nodesTConstantNodeInfo[]
CommandsList of UHAL commandsTUHALCommandNodeInfo[]
GroupsList of UHAL group nodesTUHALGroupRelationInfo[]
TaskProcessorsList of task processorsTTaskProcessorInfo[]
AlarmEventPoolUHAL Alarm event pool of the deviceTUHALAlarmEventPoolNodeInfo
ProcessingNetworksList of processing and correlation networks.TUHALProcessingNetworkInfo[]
SkillsList of device skills.TSkillNodeInfo[]
RulesList of rules.TUHALRuleInfo[]

Example:

{
"Id": "974f33ad-38e8-4d82-b3a4-37b22869651d",
"Name": "Balluff-BIS-V",
"DriverId": "ed53b0f7-0d3a-4b82-a9f6-191b0dd47ea5",
"Address": "10.197.12.50:10001",
"DataNodes": [],
"ConstantNodes": [],
"Commands": [],
"Groups": [],
"AlarmEventPool": {},
"ProcessingNetworks": [],
"Skills": [],
"TaskProcessors": [],
"Rules": []
}

Task Processor Information

The processor information describes a cyclic processing logic. The logic can be described in a separate script file.

AttributesDescriptionData Type
NameName of the processor. This should match the processor name of the driver configuration.System.String
IdUUID of the processor.System.Guid
ScriptFileFilename of the C# script.System.String

For script file coding, please check the driver manual for detailed information.

Example:

{
"TaskProcessors": [
{
"Id": "DABEA01B-CDA0-4DCD-9135-0FE1C17A46AE",
"Name": "MainTaskProcessor",
"ScriptFile": "TTestPayload.cs"
}
]
}