Questions on getting started with MTConnect

Posted By danieljjefferson 4/1/2015 6:28:02 PM
Add to Favorites0
Author Message
danieljjefferson
 Posted 4/1/2015 6:28:02 PM
Forum Expert

Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)

Group: Forum Members
Last Active: 4/22/2015 12:10:25 PM
Posts: 2, Visits: 21
955
Hi,

I am just starting out working with MTConnect and I have a few questions. I grabbed the Windows zip for the MTConnect Agent - I am able to get the ruby simulator running and the Agent seems to connect to the simulator fine. I am planning on supporting a multi-device setup with a single Agent. For now I am assuming each device has an Adapter already (I know this may not be the case). I am hoping someone can clarify a few things for me or if you can point me to a resource that will:

1. Since I want to be able to have a single Agent with multiple devices I need to have a devices.xml file. As I understand this file should define the data I want to pull from each machine and be formatted in the MTConnect Standard?

2. Since the devices.xml file will have multiple devices defined, I need to specify the IP address and port of each device on the network in the Agent config file?(this one seems straightforward)

3. I understand a probe request should provide an XML response, defining the devices and available data for those devices. However, this seems to be based on the devices.xml that I am already providing to the Agent. Is there a way to find out what data a device has available so I can build the devices.xml correctly? Do I need to get this from the device manufacturer?

Please let me know if I you have any questions.

Thanks,
Daniel
jdneidig
 Posted 4/2/2015 8:56:23 PM
Supreme Being

Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)

Group: Forum Members
Last Active: 1/27/2016 9:40:29 PM
Posts: 44, Visits: 156
Daniel,

All really good questions! I'll do my best to answer.

1. Yep you got it

2. Yes, here is an example of an Agent.cfg file we have for an Okuma LC40 with OSP-P200 control running multiple adapters. You'll see below that there is a data1 and data2 for the adapter, because there are multiple adapters on this agent. I kind of explain what each Host IP Address is below. Hope that makes sense. Then in the devices.xml you'll see what I mean how we are merging things together.

ServiceName = OkumaLC40Agent
Devices = Devices.xml
Port = 5003
BufferSize = 17
# CheckpointFrequency = 1000

# In UNIX
# PidFile = agent.pid

Adapters
{

data1 {
Device = OkumaLC40
Host = "IP ADDRESS OF OSP-P200 Control"
Port = 7878
}
data2 {
Device = OkumaLC40
Host = "IP ADDRESS OF OUR SERVER RUNNING MES stuff like work-orders, quantity of parts, employee ID of who's running the machine"
Port = 5003
}
}

# Logger Configuration
#logger_config
#{
# logging_level = info
# output = file agent.log
#}



3. So this next one really relies on the Machine Tool Builder to see what data they allow you to access and what the Adapter can access or provide. If you contact Mazak, Okuma, DMG/Mori, etc., ask about MTConnect they'll direct you to who you need to talk to, to get an Adapter. Or you can check out the MTConnect Github site and see if there is an open source adatper for your control. Probe command just returns what the Agent has for that device, so like if I have a standard 2 axis Lathe, it's just going to tell me dataitems like X,Z axis and spindle. Probe command sends you back potential dataitems that is available to collect.

Here is an example of devices.xml for the Okuma lathe above.

<?xml version="1.0" encoding="UTF-8"?>
<MTConnectDevices
xmlns:m="urn:mtconnect.org:MTConnectDevices:1.2"
xmlns="urn:mtconnect.org:MTConnectDevices:1.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="urn:mtconnect.org:MTConnectDevices:1.2 http://www.mtconnect.org/schemas/MTConnectDevices_1.2.xsd">

<Header creationTime="2009-03-22T01:50:29+00:00" sender="localhost" instanceId="1237628993" assetBufferSize="0" bufferSize="100000" assetCount ="0" version="1.2.0.9"/>
<Devices>
<Device uuid="OkumaLC40" name="OkumaLC40" sampleInterval="1000.0" id="dev1">
<Description manufacturer="OKUMA" serialNumber="123456">
Okuma MT Connect Adapter - Lathe
</Description>
<DataItems>
<DataItem type="WORKORDER" category="EVENT" id="wo1" name="wo"/>
<DataItem type="OPERATION" category="EVENT" id="sq1" name="sq"/>
<DataItem type="QUANTITY" category="EVENT" id="qty1" name="qty"/>
<DataItem type="DONEFLAG" category="EVENT" id="df1" name="df"/>
<DataItem category="EVENT" id="avail" type="AVAILABILITY" />
</DataItems>
<Components>
<Axes name="Axes" id="axes1">
<Components>
<!-- Main Spindle-->
<Rotary name="C" nativeName="S" id="c1" >
<DataItems>
<DataItem type="ROTARY_VELOCITY" category="SAMPLE" name="S1speed"
subType="ACTUAL" units="REVOLUTION/MINUTE" nativeUnits="REVOLUTION/MINUTE" id="S1speed"/>
<DataItem type="ROTARY_VELOCITY" category="SAMPLE" name="S1cmd"
subType="COMMANDED" units="REVOLUTION/MINUTE" nativeUnits="REVOLUTION/MINUTE" id="S1cmd"/>
<DataItem type="ROTARY_VELOCITY" category="SAMPLE" name="S1ovr"
subType="OVERRIDE" units="PERCENT" nativeUnits="PERCENT" id="S1ovr"/>
<DataItem type="LOAD" category="SAMPLE" name="S1load"
units="PERCENT" nativeUnits="PERCENT" id="S1load"/>
<DataItem category="EVENT" id="S1Mode" name="S1Mode" type="ROTARY_MODE">
<Constraints>
<Value>SPINDLE</Value>
</Constraints>
</DataItem>
</DataItems>
</Rotary>
<!-- Second Spindle - no spindle load-->
<Rotary name="C2" nativeName="S" id="c2" >
<DataItems>
<DataItem type="ROTARY_VELOCITY" category="SAMPLE" name="S2speed"
subType="ACTUAL" units="REVOLUTION/MINUTE" nativeUnits="REVOLUTION/MINUTE" id="S2speed"/>
<DataItem type="ROTARY_VELOCITY" category="SAMPLE" name="S2cmd"
subType="COMMANDED" units="REVOLUTION/MINUTE" nativeUnits="REVOLUTION/MINUTE" id="S2cmd"/>
<DataItem type="ROTARY_VELOCITY" category="SAMPLE" name="S2ovr"
subType="OVERRIDE" units="PERCENT" nativeUnits="PERCENT" id="S2ovr"/>
<DataItem category="EVENT" id="S2Mode" name="S2Mode" type="ROTARY_MODE">
<Constraints>
<Value>SPINDLE</Value>
</Constraints>
</DataItem>
</DataItems>
</Rotary>
<!-- Main Spindle function as C/CA-axis-->
<Rotary name="C5" id="c5" >
<DataItems>
<DataItem type="ANGLE" subType="ACTUAL" category="SAMPLE"
name="C5actm" units="DEGREE" nativeUnits="DEGREE" coordinateSystem="MACHINE" id="C5actm"/>
<DataItem type="LOAD" category="SAMPLE" name="C5load"
units="PERCENT" nativeUnits="PERCENT" id="C5load"/>
<DataItem category="EVENT" id="C5Mode" name="C5Mode" type="ROTARY_MODE">
<Constraints>
<Value>INDEX</Value>
</Constraints>
</DataItem>
</DataItems>
</Rotary>
<!-- Main Spindle function as CB-axis-->
<Rotary name="C6" id="c6" >
<DataItems>
<DataItem type="ANGLE" subType="ACTUAL" category="SAMPLE"
name="C6actm" units="DEGREE" nativeUnits="DEGREE" coordinateSystem="MACHINE" id="C6actm"/>
<DataItem type="LOAD" category="SAMPLE" name="C6load"
units="PERCENT" nativeUnits="PERCENT" id="C6load"/>
<DataItem category="EVENT" id="C6Mode" name="C6Mode" type="ROTARY_MODE">
<Constraints>
<Value>INDEX</Value>
</Constraints>
</DataItem>
</DataItems>
</Rotary>
<!-- Main Spindle function as CB-axis-->
<Rotary name="B" id="b1" >
<DataItems>
<DataItem type="ANGLE" subType="ACTUAL" category="SAMPLE"
name="B1actm" units="DEGREE" nativeUnits="DEGREE" coordinateSystem="MACHINE" id="B1actm"/>
<DataItem type="LOAD" category="SAMPLE" name="B1load"
units="PERCENT" nativeUnits="PERCENT" id="B1load"/>
<DataItem category="EVENT" id="B1Mode" name="B1Mode" type="ROTARY_MODE">
<Constraints>
<Value>INDEX</Value>
</Constraints>
</DataItem>
</DataItems>
</Rotary>
<!-- Standard Linear X axis respect to A turret-->
<Linear name="X" id="x1" >
<DataItems>
<DataItem type="POSITION" subType="ACTUAL" category="SAMPLE"
name="X1actm" units="MILLIMETER" nativeUnits="MILLIMETER" coordinateSystem="MACHINE" id="X1actm"/>
<DataItem type="LOAD" category="SAMPLE" name="X1load"
units="PERCENT" nativeUnits="PERCENT" id="X1load"/>
</DataItems>
</Linear>
<!-- Standard Linear X axis respect to B turret-->
<Linear name="X2" id="x2" >
<DataItems>
<DataItem type="POSITION" subType="ACTUAL" category="SAMPLE"
name="X2actm" units="MILLIMETER" nativeUnits="MILLIMETER" coordinateSystem="MACHINE" id="X2actm"/>
<DataItem type="LOAD" category="SAMPLE" name="X2load"
units="PERCENT" nativeUnits="PERCENT" id="X2load"/>
</DataItems>
</Linear>
<!-- Standard Linear Z axis respect to A turret-->
<Linear name="Z" id="z1">
<DataItems>
<DataItem type="POSITION" subType="ACTUAL" category="SAMPLE"
name="Z1actm" units="MILLIMETER" nativeUnits="MILLIMETER" coordinateSystem="MACHINE" id="Z1actm" />
<DataItem type="LOAD" category="SAMPLE" name="Z1load"
units="PERCENT" nativeUnits="PERCENT" id="Z1load"/>
</DataItems>
</Linear>
<!-- Standard Linear Z axis respect to B turret-->
<Linear name="Z2" id="z2">
<DataItems>
<DataItem type="POSITION" subType="ACTUAL" category="SAMPLE"
name="Z2actm" units="MILLIMETER" nativeUnits="MILLIMETER" coordinateSystem="MACHINE" id="Z2actm" />
<DataItem type="LOAD" category="SAMPLE" name="Z2load"
units="PERCENT" nativeUnits="PERCENT" id="Z2load"/>
</DataItems>
</Linear>
<!-- Optional Linear W axis-->
<Linear name="W" id="w1">
<DataItems>
<DataItem type="POSITION" subType="ACTUAL" category="SAMPLE"
name="W1actm" units="MILLIMETER" nativeUnits="MILLIMETER" coordinateSystem="MACHINE" id="W1actm" />
<DataItem type="LOAD" category="SAMPLE" name="W1load"
units="PERCENT" nativeUnits="PERCENT" id="W1load"/>
</DataItems>
</Linear>
</Components>
</Axes>
<Controller name="Controller" id="ct1">
<DataItems>
<DataItem type="EMERGENCY_STOP" name="estop" category="EVENT" id="estop" />
<DataItem type="SYSTEM" category="CONDITION" id="system" />


<DataItem type="CONTROLLER_MODE" name="mode" category="EVENT" id="p.mode"/>
<DataItem type="PROGRAM" name="p.program" category="EVENT" id="p.program"/>
<DataItem type="EXECUTION" name="execution" category="EVENT" id="p.execution"/>
<DataItem type="PATH_FEEDRATE" subType="OVERRIDE" name="p.Fovr" category="SAMPLE"
units="PERCENT" nativeUnits="PERCENT" id="p.Fovr" />
<DataItem type="PART_COUNT" name="p.partcount" category="EVENT" id="p.partcount"/>
<DataItem type="OPERATOR" category="EVENT" id="o1" name="op"/>
</DataItems>

<Components>
<!-- Path 1 related to upper A turret-->
<Path id="p1" name="path">
<DataItems>
<DataItem type="PATH_FEEDRATE" subType="ACTUAL" name="p1.Fact" category="SAMPLE" id="p1.Fact" units="MILLIMETER/SECOND" nativeUnits="MILLIMETER/MINUTE" />
<DataItem type="BLOCK" name="p1.block" category="EVENT" id="p1.block"/>
<DataItem type="LINE" name="p1.line" category="EVENT" id="p1.line"/>
<DataItem type="PATH_FEEDRATE" subType="COMMANDED" name="p1.Fcmd" category="SAMPLE" id="p1.Fcmd"
units="MILLIMETER/SECOND" nativeUnits="MILLIMETER/MINUTE" />
<DataItem type="PATH_POSITION" name="p1.LPathPos" category="SAMPLE" units="MILLIMETER_3D" nativeUnits="MILLIMETER_3D" coordinateSystem="WORK" id="p1.LPathPos" />
<DataItem type="xTongueATH_ANGLE" category="SAMPLE" name="p1.RPathPos" units="xBigGrinEGREE_3D" nativeUnits="xBigGrinEGREE_3D" coordinateSystem="WORK" id="p1.RPathPos" />
</DataItems>
</Path>
<!-- Path 2 related to lower B turret-->
<Path id="p2" name="path2">
<DataItems>
<DataItem type="PATH_FEEDRATE" subType="ACTUAL" name="p2.Fact" category="SAMPLE" id="p2.Fact" units="MILLIMETER/SECOND" nativeUnits="MILLIMETER/MINUTE" />
<DataItem type="BLOCK" name="p2.block" category="EVENT" id="p2.block"/>
<DataItem type="LINE" name="p2.line" category="EVENT" id="p2.line"/>
<DataItem type="PATH_FEEDRATE" subType="COMMANDED" name="p2.Fcmd" category="SAMPLE" id="p2.Fcmd"
units="MILLIMETER/SECOND" nativeUnits="MILLIMETER/MINUTE" />
<DataItem type="PATH_POSITION" name="p2.LPathPos" category="SAMPLE" units="MILLIMETER_3D" nativeUnits="MILLIMETER_3D" coordinateSystem="WORK" id="p2.LPathPos" />
<DataItem type="xTongueATH_ANGLE" category="SAMPLE" name="p2.RPathPos" units="xBigGrinEGREE_3D" nativeUnits="xBigGrinEGREE_3D" coordinateSystem="WORK" id="p2.RPathPos" />
</DataItems>
</Path>
</Components>
</Controller>
</Components>
</Device>
</Devices>
</MTConnectDevices>



Hope this helps! Also, I encourage you to come to this year's MC2(mc2confernce.com), it's in Chicago. You can get lots of good info Smile


Best,


Joel


4/2/2015 9:04:30 PM by jdneidig
danieljjefferson
 Posted 4/7/2015 7:41:41 PM
Forum Expert

Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)Forum Expert - (955 reputation)

Group: Forum Members
Last Active: 4/22/2015 12:10:25 PM
Posts: 2, Visits: 21
955
Joel,

Thanks for the clarification, I appreciate your response. I wasn't sure what you meant by the IP address for data2 though - is this for a custom adapter that provides an MTConnect compliant response from your MES (Manufacturing Execution System - is this right)?

I found that each Id in the devices.xml must be unique. How would this be handled in a multi-machine setup? Will I need to implement a custom Adapter to make sure the Ids are unique or would have I have to have a separate Agent (with a devices.xml) for each machine? Maybe I missed this concept in the documentation. It appears name does not have to be unique.

Another thing I was wondering is about having two of the same machine with one Agent. Based on your devices.xml it seems that I only need to have the data items I want to pull once for each model of machine?

Thanks,
Daniel
4/8/2015 4:38:08 PM by danieljjefferson
jdneidig
 Posted 4/11/2015 1:07:32 PM
Supreme Being

Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)Supreme Being - (21,505 reputation)

Group: Forum Members
Last Active: 1/27/2016 9:40:29 PM
Posts: 44, Visits: 156
Daniel,

Yep, we have an Adapter for our MES system that gives MTConnect compliant data. This is great when correlating jobs that are running on the shop floor with your ERP system and routings for cycle times.

Also, one thing to remember that Adapters are not part of the MTConnect standard, so there are lots of different ways to write an Adapter and pull data into MTConnect Agents, whether the Adapter is software or hardware or both. The reason for this is we didn't want to limit how users pulled/pushed data into their Agents.

Regarding Device id, not sure, I'd have to look at the standard documentation, maybe best practice would be that you would have unique device id's...?

Yep that's right, you can have multiple machines in one Agent, some software MTConnect implementers like to have only one Agent for an entire factory. The Agents are capable of this type of structure. We have kind of a mix, some Agents have many machines, some Agents reside on a machine control with Agent/Adapter combined, some have hardware Adapter and then Agent running on a server somewhere, some have Agent/Adapter running completely on a server in the cloud. There are lots of options and combos, but the best thing to do is choose the one that works for you or your specific machine.
4/11/2015 1:08:06 PM by jdneidig

Similar Topics

Expand / Collapse

Reading This Topic

Expand / Collapse

Back To Top

Advertisements