SendableBuilder

class wpilib.SendableBuilder(self: wpilib.SendableBuilder) → None

Bases: pybind11_builtins.pybind11_object

addBooleanArrayProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[], List[int]], setter: Callable[[List[int]], None]) → None

Add a boolean array property.

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addBooleanProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[], bool], setter: Callable[[bool], None]) → None

Add a boolean property.

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addDoubleArrayProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[], List[float]], setter: Callable[[List[float]], None]) → None

Add a double array property.

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addDoubleProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[], float], setter: Callable[[float], None]) → None

Add a double property.

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addRawProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[], str], setter: Callable[[str], None]) → None

Add a raw property.

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addSmallBooleanArrayProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[[List[int]], List[int]], setter: Callable[[List[int]], None]) → None

Add a boolean array property (SmallVector form).

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addSmallDoubleArrayProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[[List[float]], List[float]], setter: Callable[[List[float]], None]) → None

Add a double array property (SmallVector form).

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addSmallRawProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[[List[str]], str], setter: Callable[[str], None]) → None

Add a raw property (SmallVector form).

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addSmallStringArrayProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[[List[str]], List[str]], setter: Callable[[List[str]], None]) → None

Add a string array property (SmallVector form).

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addSmallStringProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[[List[str]], str], setter: Callable[[str], None]) → None

Add a string property (SmallString form).

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addStringArrayProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[], List[str]], setter: Callable[[List[str]], None]) → None

Add a string array property.

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addStringProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[], str], setter: Callable[[str], None]) → None

Add a string property.

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

addValueProperty(self: wpilib.SendableBuilder, key: str, getter: Callable[], _pyntcore._ntcore.Value], setter: Callable[[_pyntcore._ntcore.Value], None]) → None

Add a NetworkTableValue property.

Parameters
  • key – property name

  • getter – getter function (returns current value)

  • setter – setter function (sets new value)

getEntry(self: wpilib.SendableBuilder, key: str) → _pyntcore._ntcore.NetworkTableEntry

Add a property without getters or setters. This can be used to get entry handles for the function called by SetUpdateTable().

Parameters

key – property name

Returns

Network table entry

getTable(self: wpilib.SendableBuilder) → _pyntcore._ntcore.NetworkTable

Get the network table.

Returns

The network table

setActuator(self: wpilib.SendableBuilder, value: bool) → None

Set a flag indicating if this sendable should be treated as an actuator. By default this flag is false.

Parameters

value – true if actuator, false if not

setSafeState(self: wpilib.SendableBuilder, func: Callable[], None]) → None

Set the function that should be called to set the Sendable into a safe state. This is called when entering and exiting Live Window mode.

Parameters

func – function

setSmartDashboardType(self: wpilib.SendableBuilder, type: str) → None

Set the string representation of the named data type that will be used by the smart dashboard for this sendable.

Parameters

type – data type

setUpdateTable(self: wpilib.SendableBuilder, func: Callable[], None]) → None

Set the function that should be called to update the network table for things other than properties. Note this function is not passed the network table object; instead it should use the entry handles returned by GetEntry().

Parameters

func – function