Class MechanicalUnitServiceInterval
Holds information about service intervals for a mechanical unit.
Implements
Inherited Members
Namespace: ABB.Robotics.Controllers.MotionDomain
Assembly: ABB.Robotics.Controllers.PC.dll
Syntax
public class MechanicalUnitServiceInterval : ServiceInfo, IDeserializationCallback
Constructors
MechanicalUnitServiceInterval()
Initializes a new MechanicalUnitServiceInterval object.
Declaration
public MechanicalUnitServiceInterval()
MechanicalUnitServiceInterval(TimeSpan, TimeSpan)
Initializes a new MechanicalUnitServiceInterval object.
Declaration
public MechanicalUnitServiceInterval(TimeSpan calender, TimeSpan production)
Parameters
Type | Name | Description |
---|---|---|
TimeSpan | calender | Calender time. |
TimeSpan | production | Production time. |
Properties
CalenderTime
Gets the service interval in calender time as a TimeSpan object.
Declaration
public TimeSpan CalenderTime { get; set; }
Property Value
Type | Description |
---|---|
TimeSpan |
Examples
Controller c = new Controller();
MotionSystem msystem = c.MotionSystem;
MechanicalUnit munit = msystem.ActiveMechanicalUnit;
MechanicalUnitServiceInfo info = munit.ServiceInfo;
// Service interval in years, calender time
int serviceIntervalCalender = Convert.ToInt32(info.ServiceInterval.CalenderTime.TotalDays / 365);
ProductionTime
Get the service interval in production time as a TimeSpan object.
Declaration
public TimeSpan ProductionTime { get; set; }
Property Value
Type | Description |
---|---|
TimeSpan |
Examples
Controller c = new Controller();
MotionSystem msystem = c.MotionSystem;
MechanicalUnit munit = msystem.ActiveMechanicalUnit;
MechanicalUnitServiceInfo info = munit.ServiceInfo;
// Service interval in hours, production time
int serviceIntervalProduction = Convert.ToInt32(info.ServiceInterval.ProductionTime.TotalHours);