.NET SDK Documentation

    Show / Hide Table of Contents

    Class LightCube

    Represents Vector’s Cube.

    The LightCube object has four LEDs that Vector can actively manipulate and communicate with.

    As Vector drives around, he uses the position of objects that he recognizes, including his cube, to localize himself, taking note of the Pose of the objects.

    You can subscribe to cube events including ObjectTapped, ObjectAppeared, and ObjectDisappeared.

    Vector supports 1 LightCube.

    Inheritance
    Object
    RobotObject
    ObservableObject
    ObjectWithId
    LightCube
    Implements
    INotifyPropertyChanged
    Inherited Members
    ObjectWithId.ObjectId
    ObjectWithId.ToString()
    ObservableObject.IsVisible
    ObservableObject.LastImageRect
    ObservableObject.LastObservedTime
    ObservableObject.LastObservedTimestamp
    ObservableObject.Pose
    ObservableObject.LastEventTime
    RobotObject.PropertyChanged
    Namespace: Anki.Vector.Objects
    Assembly: Anki.Vector.dll
    Syntax
    public class LightCube : ObjectWithId, INotifyPropertyChanged

    Properties

    | Improve this Doc View Source

    FactoryId

    Gets the unique hardware id of the physical cube.

    public string FactoryId { get; }
    Property Type
    String
    | Improve this Doc View Source

    IsConnected

    Gets a value indicating whether the cube is currently connected to the robot.

    public bool IsConnected { get; }
    Property Type
    Boolean
    | Improve this Doc View Source

    IsMoving

    Gets a value indicating whether the cube’s accelerometer indicates that the cube is moving.

    public bool IsMoving { get; }
    Property Type
    Boolean
    | Improve this Doc View Source

    LastMovedStartTime

    Gets the time the object most recently started moving

    public DateTime LastMovedStartTime { get; }
    Property Type
    DateTime
    | Improve this Doc View Source

    LastMovedStartTimestamp

    Gets the time the object most recently started moving in robot time.

    public uint LastMovedStartTimestamp { get; }
    Property Type
    UInt32
    | Improve this Doc View Source

    LastMovedTime

    Gets the time the object was last moved.

    public DateTime LastMovedTime { get; }
    Property Type
    DateTime
    | Improve this Doc View Source

    LastMovedTimestamp

    Gets the last moved robot timestamp.

    public uint LastMovedTimestamp { get; }
    Property Type
    UInt32
    | Improve this Doc View Source

    LastTappedTime

    Gets the time the object was last tapped

    public DateTime LastTappedTime { get; }
    Property Type
    DateTime
    | Improve this Doc View Source

    LastTappedTimestamp

    Gets the robot timestamp when the object was last tapped

    public uint LastTappedTimestamp { get; }
    Property Type
    UInt32
    | Improve this Doc View Source

    LastUpAxisTime

    Gets the time the object’s orientation last changed

    public DateTime LastUpAxisTime { get; }
    Property Type
    DateTime
    | Improve this Doc View Source

    LastUpAxisTimestamp

    Gets the robot timestamp when the object’s orientation last changed

    public uint LastUpAxisTimestamp { get; }
    Property Type
    UInt32
    | Improve this Doc View Source

    ObjectTypeName

    Gets the name of the object type.

    public override string ObjectTypeName { get; }
    Property Type
    String
    Overrides
    ObservableObject.ObjectTypeName
    | Improve this Doc View Source

    TopFaceOrientationRad

    Gets the angular distance from the current reported up axis.

    public float TopFaceOrientationRad { get; }
    Property Type
    Single
    | Improve this Doc View Source

    UpAxis

    Gets the object’s up_axis value from the last time it changed.

    public UpAxis UpAxis { get; }
    Property Type
    UpAxis

    Methods

    | Improve this Doc View Source

    SetLightCorners(Light)

    Set the light for all corners.

    public Task<StatusCode> SetLightCorners(Light light)
    Parameters
    Type Name Description
    Light light

    The settings for all the lights.

    Returns
    Type Description
    Task<StatusCode>

    A task that represents the asynchronous operation; the task result contains the result from the function.

    | Improve this Doc View Source

    SetLightCorners(Light, Light, Light, Light)

    Set the light for each corner.

    public Task<StatusCode> SetLightCorners(Light light1, Light light2, Light light3, Light light4)
    Parameters
    Type Name Description
    Light light1

    The settings for the first light.

    Light light2

    The settings for the second light.

    Light light3

    The settings for the third light.

    Light light4

    The settings for the fourth light.

    Returns
    Type Description
    Task<StatusCode>

    A task that represents the asynchronous operation; the task result contains the result from the function.

    | Improve this Doc View Source

    SetLightCorners(Light, Light, Light, Light, ColorProfile, Boolean)

    Set the light for each corner.

    public Task<StatusCode> SetLightCorners(Light light1, Light light2, Light light3, Light light4, ColorProfile colorProfile, bool rotate = false)
    Parameters
    Type Name Description
    Light light1

    The settings for the first light.

    Light light2

    The settings for the second light.

    Light light3

    The settings for the third light.

    Light light4

    The settings for the fourth light.

    ColorProfile colorProfile

    The color profile for the cube lights.

    Boolean rotate

    if set to true rotate the colors.

    Returns
    Type Description
    Task<StatusCode>

    A task that represents the asynchronous operation; the task result contains the result from the function.

    Exceptions
    Type Condition
    ArgumentNullException

    light1 or light2 or light3 or light4

    | Improve this Doc View Source

    SetLightsOff()

    Set all lights off on the cube

    public Task<StatusCode> SetLightsOff()
    Returns
    Type Description
    Task<StatusCode>

    A task that represents the asynchronous operation; the task result contains the result from the function.

    Implements

    System.ComponentModel.INotifyPropertyChanged

    See Also

    ObservableObject
    • Improve this Doc
    • View Source
    Back to top Copyright (c) 2019 by Wayne Venables