Class Spindle
- Namespace
- DuetAPI.ObjectModel
- Assembly
- DuetAPI.dll
Information about a CNC spindle
public class Spindle : ModelObject, INotifyPropertyChanging, IStaticModelObject, IModelObject, ICloneable, INotifyPropertyChanged
- Inheritance
-
Spindle
- Implements
- Inherited Members
Constructors
Spindle()
public Spindle()
Properties
Active
Active RPM
public int? Active { get; set; }
Property Value
- int?
CanReverse
Flags whether the spindle may spin in reverse direction
public bool? CanReverse { get; set; }
Property Value
- bool?
Current
Current RPM, negative if anticlockwise direction
[Live]
public int? Current { get; set; }
Property Value
- int?
Frequency
Frequency (in Hz)
[Verbose]
public int? Frequency { get; set; }
Property Value
- int?
IdlePwm
Idle PWM value (0..1)
[Verbose]
public float? IdlePwm { get; set; }
Property Value
Max
Maximum RPM
[Verbose]
public int? Max { get; set; }
Property Value
- int?
MaxPwm
Maximum PWM value when turned on (0..1)
[Verbose]
public float? MaxPwm { get; set; }
Property Value
Min
Minimum RPM when turned on
[Verbose]
public int? Min { get; set; }
Property Value
- int?
MinPwm
Minimum PWM value when turned on (0..1)
[Verbose]
public float? MinPwm { get; set; }
Property Value
State
Current state
[Live]
public SpindleState State { get; set; }
Property Value
Type
Spindle type
[Verbose]
public SpindleType? Type { get; set; }
Property Value
Methods
Assign(IStaticModelObject)
Assign the properties from another instance. This is required to update model properties which do not have a setter
public void Assign(IStaticModelObject from)
Parameters
fromIStaticModelObjectOther instance
Clone()
Clone this instance
public object Clone()
Returns
- object
Cloned instance
Remarks
This method is auto-generated
UpdateFromJson(JsonElement, bool)
Update this instance from a given JSON element
public void UpdateFromJson(JsonElement jsonElement, bool ignoreSbcProperties)
Parameters
jsonElementJsonElementElement to update this intance from
ignoreSbcPropertiesboolWhether SBC properties are ignored
Remarks
This method is auto-generated
Exceptions
- JsonException
Failed to deserialize data
UpdateFromJsonReader(ref Utf8JsonReader, bool)
Update this instance from a given JSON element
public void UpdateFromJsonReader(ref Utf8JsonReader reader, bool ignoreSbcProperties)
Parameters
readerUtf8JsonReaderReader to update this intance from
ignoreSbcPropertiesboolWhether SBC properties are ignored
Remarks
This method is auto-generated
Exceptions
- JsonException
Failed to deserialize data