.NET SDK Documentation

    Show / Hide Table of Contents

    Struct ProximitySensorData

    A distance sample from the time-of-flight sensor with metadata describing reliability of the measurement

    The proximity sensor is located near the bottom of Vector between the two front wheels, facing forward.The reported distance describes how far in front of this sensor the robot feels an obstacle is. The sensor estimates based on time-of-flight information within a field of view which the engine resolves to a certain quality value.

    Four additional flags are supplied by the engine to indicate whether this proximity data is considered valid for the robot’s internal path finding. Respecting these is optional, but will help your code respect the behavior of the robot’s innate object avoidance.

    Implements
    IEquatable<ProximitySensorData>
    Namespace: Anki.Vector
    Assembly: Anki.Vector.dll
    Syntax
    public struct ProximitySensorData : IEquatable<ProximitySensorData>

    Properties

    | Improve this Doc View Source

    DistanceMm

    Gets the distance between the sensor and a detected object

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

    FoundObject

    Gets a value indicating whether the sensor detected an object in the valid operating range.

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

    IsLiftInFov

    Gets a value indicating whether Vector’s lift is blocking the time-of-flight sensor. While the lift will send clear proximity signals, it’s not useful for object detection.

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

    SignalQuality

    Gets the quality of the detected object. The proximity sensor detects obstacles within a given field of view, this value represents the likelihood of the reported distance being a solid surface.

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

    Unobstructed

    Gets a value indicating whether the sensor has confirmed it has not detected anything up to its max range.

    public bool Unobstructed { get; }
    Property Type
    Boolean

    Methods

    | Improve this Doc View Source

    Equals(ProximitySensorData)

    Indicates whether the current object is equal to another object of the same type.

    public bool Equals(ProximitySensorData other)
    Parameters
    Type Name Description
    ProximitySensorData other

    An object to compare with this object.

    Returns
    Type Description
    Boolean

    true if the current object is equal to the other parameter; otherwise, false.

    | Improve this Doc View Source

    Equals(Object)

    Determines whether the specified Object, is equal to this instance.

    public override bool Equals(object obj)
    Parameters
    Type Name Description
    Object obj

    The Object to compare with this instance.

    Returns
    Type Description
    Boolean

    true if the specified Object is equal to this instance; otherwise, false.

    Overrides
    ValueType.Equals(Object)
    | Improve this Doc View Source

    GetHashCode()

    Returns a hash code for this instance.

    public override int GetHashCode()
    Returns
    Type Description
    Int32

    A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.

    Overrides
    ValueType.GetHashCode()
    | Improve this Doc View Source

    ToString()

    Converts to string.

    public override string ToString()
    Returns
    Type Description
    String

    A String that represents this instance.

    Overrides
    ValueType.ToString()

    Operators

    | Improve this Doc View Source

    Equality(ProximitySensorData, ProximitySensorData)

    Implements the operator ==.

    public static bool operator ==(ProximitySensorData lhs, ProximitySensorData rhs)
    Parameters
    Type Name Description
    ProximitySensorData lhs

    The LHS.

    ProximitySensorData rhs

    The RHS.

    Returns
    Type Description
    Boolean

    The result of the operator.

    | Improve this Doc View Source

    Inequality(ProximitySensorData, ProximitySensorData)

    Implements the operator !=.

    public static bool operator !=(ProximitySensorData lhs, ProximitySensorData rhs)
    Parameters
    Type Name Description
    ProximitySensorData lhs

    The LHS.

    ProximitySensorData rhs

    The RHS.

    Returns
    Type Description
    Boolean

    The result of the operator.

    Implements

    System.IEquatable<T>
    • Improve this Doc
    • View Source
    Back to top Copyright (c) 2019 by Wayne Venables