--- a +++ b/trunk/2.0.0.1/+CTRLBYTE/devdescr/MonarcoHAT2.0.0.1.devdesc.xml @@ -0,0 +1,178 @@ +<?xml version="1.0" encoding="utf-8"?> +<DeviceDescription xmlns="http://www.3s-software.com/schemas/DeviceDescription-1.0.xsd" xmlns:ts="http://www.3s-software.com/schemas/TargetSettings-0.1.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + <Types namespace="local"> + <BitfieldType basetype="std:BYTE" name="TBitStringByte"> + <Component identifier="Bit0" type="std:BOOL"> + <Default /> + <VisibleName name="local:TBitStringByte.Bit0">Bit0</VisibleName> + </Component> + <Component identifier="Bit1" type="std:BOOL"> + <Default /> + <VisibleName name="local:TBitStringByte.Bit1">Bit1</VisibleName> + </Component> + <Component identifier="Bit2" type="std:BOOL"> + <Default /> + <VisibleName name="local:TBitStringByte.Bit2">Bit2</VisibleName> + </Component> + <Component identifier="Bit3" type="std:BOOL"> + <Default /> + <VisibleName name="local:TBitStringByte.Bit3">Bit3</VisibleName> + </Component> + </BitfieldType> + <BitfieldType name="ControlByteSettings" basetype="std:BYTE"> + <Component identifier="Status LED CTRL" type="std:BOOL"> + <Default>FALSE</Default> + <VisibleName>Status LED CTRL</VisibleName> + <Description>System status indication - TRUE: control LED0 by Control Byte; FALSE: Default LED0 function</Description> + </Component> + <Component identifier="StatusLEDValue" type="std:BOOL"> + <Default>FALSE</Default> + <VisibleName>Status LED Value</VisibleName> + <Description>Only applicable if Control Byte LED CTRL set TRUE - TRUE: LED0 on; FALSE: LED0 off</Description> + </Component> + <Component identifier="OneWireShutdown" type="std:BOOL"> + <Default>FALSE</Default> + <VisibleName>1-Wire power shutdown</VisibleName> + <Description>Useful for bus reset in case of freeze - TRUE: for 1-Wire bus power down; FALSE: normal operation</Description> + </Component> + <Component identifier="RESERVED" type="std:BOOL"> + <Default>FALSE</Default> + <VisibleName>[RESERVED]</VisibleName> + <Description>RESERVED: Always FALSE</Description> + </Component> + <Component identifier="Counter1Reset" type="std:BOOL"> + <Default>FALSE</Default> + <VisibleName>Counter 1 Reset</VisibleName> + <Description>TRUE: COUNTER1 Value reset request; FALSE: normal operation</Description> + </Component> + <Component identifier="Counter2Reset" type="std:BOOL"> + <Default>FALSE</Default> + <VisibleName>Counter 2 Reset</VisibleName> + <Description>TRUE: COUNTER2 Value reset request; FALSE: normal operation</Description> + </Component> + <Component identifier="SignOfLife0" type="std:BOOL"> + <Default>FALSE</Default> + <VisibleName>[FUTURE]</VisibleName> + <Description>FUTURE: Sign of Life 0/1 - should be incremented with each data transfer as 2bit number low/high bit, used by firmware as health check of SPI Master</Description> + </Component> + <Component identifier="SignOfLife1" type="std:BOOL"> + <Default>FALSE</Default> + <VisibleName>[FUTURE]</VisibleName> + <Description>FUTURE: Sign of Life 0/1 - should be incremented with each data transfer as 2bit number low/high bit, used by firmware as health check of SPI Master</Description> + </Component> + </BitfieldType> + </Types> + <Strings namespace="local"> + <Language lang="en"> + </Language> + </Strings> + <Files namespace="local"> + <Language lang="en"> + <File fileref="local" identifier="ImageFile"> + <LocalFile>Monarco.png</LocalFile> + </File> + <File fileref="local" identifier="Icon"> + <LocalFile>Monarco.ico</LocalFile> + </File> + </Language> + </Files> + <Device hideInCatalogue="false" showParamsInDevDescOrder="true">> + <DeviceIdentification> + <Type>501</Type> + <Id>FFFF 0005</Id> + <Version>2.0.0.1</Version> + </DeviceIdentification> + <DeviceInfo> + <Name name="local:ModelName">Monarco HAT</Name> + <Description name="local:DeviceDescription">Monarco HAT SPI device library for Codesys</Description> + <Vendor name="local:VendorName">Monarco.io</Vendor> + <OrderNumber>-</OrderNumber> + <Image name="local:ImageFile">Monarco.png</Image> + <Icon name="local:Icon">Monarco.ico</Icon> + </DeviceInfo> + <Connector moduleType="500" interface="Raspberry.SPI" role="child" explicit="false" connectorId="1" hostpath="-1" alwaysmapping="true"> + <InterfaceName name="local:PCI">SPI devices</InterfaceName> + <Slot count="1" allowEmpty="false"> + </Slot> + <DriverInfo needsBusCycle="true"> + <RequiredLib libname="Monarco HAT library for Codesys" vendor="Monarco.io" version="2.0.0.1" identifier="MonarcoLib"> + <FBInstance basename="$(DeviceName)_Instance" fbname="IoDrvMonarco"> + <Initialize methodName="Initialize" /> + </FBInstance> + </RequiredLib> + </DriverInfo> + <HostParameterSet> + + <ParameterSection><!-- Mapje --> + <Name name="local:GeneralParameters">General Parameters</Name> + <Parameter ParameterId="100" type="std:USINT"> + <Attributes channel="none" download="true" functional="false" onlineaccess="read" /> + <Default>0</Default> + <Name name="local:SPI_channel">SPI master number</Name> + <Description name="local:Id393218.Desc">SPI controlling device name /dev/spidev0.X</Description> + </Parameter> + </ParameterSection> + + <ParameterSection> + <Name name="local:GeneralParameters">Monarco Parameters</Name> + <Parameter ParameterId="1" type="std:UINT"> + <Attributes channel="none" download="true" functional="false" onlineaccess="read" /> + <Default>100</Default> + <Unit>msec</Unit> + <Name name="local:wd">Watchdog Time</Name> + <Description>Watchdog time setting (Maximum time between two IO cycles)</Description> + </Parameter> + <Parameter ParameterId="10" type="local:ControlByteSettings"> + <Attributes channel="none" download="true" functional="false" onlineaccess="read" /> + <Default>0</Default> + <Name name="local:ControlByteSettings">Control Byte</Name> + <Description>Settings</Description> + </Parameter> + </ParameterSection> + + <ParameterSection> + <Name name="local:GeneralParameters">Digital In</Name> + <Parameter ParameterId="1000" type="local:TBitStringByte"> + <Attributes channel="input"/> + <Default>0</Default> + <Name name="local:digin">DigIn</Name> + </Parameter> + </ParameterSection> + <ParameterSection> + <Name name="local:GeneralParameters">Analog In</Name> + <Parameter ParameterId="1110" type="std:WORD"> + <Attributes channel="input"/> + <Default>0</Default> + <Name name="local:ai0-raw">AI0</Name> + </Parameter> + <Parameter ParameterId="1111" type="std:WORD"> + <Attributes channel="input"/> + <Default>0</Default> + <Name name="local:ai1-raw">AI1</Name> + </Parameter> + </ParameterSection> + <ParameterSection> + <Name name="local:GeneralParameters">Digital Out</Name> + <Parameter ParameterId="2000" type="local:TBitStringByte"> + <Attributes channel="output"/> + <Default>0</Default> + <Name name="local:digout">DigOut</Name> + </Parameter> + </ParameterSection> + <ParameterSection> + <Name name="local:GeneralParameters">Analog Out</Name> + <Parameter ParameterId="2100" type="std:WORD"> + <Attributes channel="output"/> + <Default>0</Default> + <Name name="local:ao0-raw">AO0</Name> + </Parameter> + <Parameter ParameterId="2101" type="std:WORD"> + <Attributes channel="output"/> + <Default>0</Default> + <Name name="local:ao1-raw">AO1</Name> + </Parameter> + </ParameterSection> + </HostParameterSet> + </Connector> + </Device> +</DeviceDescription> \ No newline at end of file