Class MechanismRoot2d
java.lang.Object
org.wpilib.smartdashboard.MechanismObject2d
org.wpilib.smartdashboard.MechanismRoot2d
- All Implemented Interfaces:
TelemetryLoggable
Root Mechanism2d node.
A root is the anchor point of other nodes (such as ligaments).
Do not create objects of this class directly! Obtain instances from the Mechanism2d.getRoot(String, double, double) factory method.
Append other nodes by using MechanismObject2d.append(MechanismObject2d).
-
Method Summary
Modifier and TypeMethodDescriptionvoidlogTo(TelemetryTable table) Logs the object to aTelemetryTable.voidsetPosition(double x, double y) Set the root's position.Methods inherited from class MechanismObject2d
append, getNameMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface TelemetryLoggable
getTelemetryType
-
Method Details
-
setPosition
public void setPosition(double x, double y) Set the root's position.- Parameters:
x- new x coordinatey- new y coordinate
-
logTo
Description copied from interface:TelemetryLoggableLogs the object to aTelemetryTable.- Specified by:
logToin interfaceTelemetryLoggable- Overrides:
logToin classMechanismObject2d- Parameters:
table- telemetry table
-