WPILibC++  unspecified
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Pages
LiveWindow Class Reference

The LiveWindow class is the public interface for putting sensors and actuators on the LiveWindow. More...

#include <LiveWindow.h>

Public Member Functions

void Run ()
 This method is called periodically to cause the sensors to send new values to the SmartDashboard.
 
void AddSensor (std::string type, int channel, LiveWindowSendable *component)
 Meant for internal use in other WPILib classes.
 
void AddActuator (std::string type, int channel, LiveWindowSendable *component)
 Meant for internal use in other WPILib classes.
 
void AddActuator (std::string type, int module, int channel, LiveWindowSendable *component)
 Meant for internal use in other WPILib classes.
 
bool IsEnabled () const
 
void SetEnabled (bool enabled)
 Change the enabled status of LiveWindow If it changes to enabled, start livewindow running otherwise stop it.
 
AddSensor(subsystem, name, component)

Add a Sensor associated with the subsystem and call it by the given name.

Parameters
subsystemThe subsystem this component is part of.
nameThe name of this component.
componentA LiveWindowSendable component that represents a sensor.
void AddSensor (const std::string &subsystem, const std::string &name, LiveWindowSendable *component)
 Use a raw pointer to the LiveWindow. More...
 
void AddSensor (const std::string &subsystem, const std::string &name, LiveWindowSendable &component)
 Pass a reference to LiveWindow and retain ownership of the component.
 
void AddSensor (const std::string &subsystem, const std::string &name, std::shared_ptr< LiveWindowSendable > component)
 Use a STL smart pointer to share ownership of component.
 
AddActuator(subsystem, name, component)

Add an Actuator associated with the subsystem and call it by the given name.

Parameters
subsystemThe subsystem this component is part of.
nameThe name of this component.
componentA LiveWindowSendable component that represents a actuator.
void AddActuator (const std::string &subsystem, const std::string &name, LiveWindowSendable *component)
 Use a raw pointer to the LiveWindow. More...
 
void AddActuator (const std::string &subsystem, const std::string &name, LiveWindowSendable &component)
 Pass a reference to LiveWindow and retain ownership of the component.
 
void AddActuator (const std::string &subsystem, const std::string &name, std::shared_ptr< LiveWindowSendable > component)
 Use a STL smart pointer to share ownership of component.
 

Static Public Member Functions

static LiveWindowGetInstance ()
 Get an instance of the LiveWindow main class This is a singleton to guarantee that there is only a single instance regardless of how many times GetInstance is called.
 

Protected Member Functions

 LiveWindow ()
 LiveWindow constructor. More...
 

Detailed Description

The LiveWindow class is the public interface for putting sensors and actuators on the LiveWindow.

Author
Brad Miller

Constructor & Destructor Documentation

LiveWindow::LiveWindow ( )
protected

LiveWindow constructor.

Allocate the necessary tables.

Member Function Documentation

void LiveWindow::AddActuator ( const std::string &  subsystem,
const std::string &  name,
LiveWindowSendable component 
)

Use a raw pointer to the LiveWindow.

Deprecated:
Prefer smart pointers or references.
void LiveWindow::AddSensor ( const std::string &  subsystem,
const std::string &  name,
LiveWindowSendable component 
)

Use a raw pointer to the LiveWindow.

Deprecated:
Prefer smart pointers or references.

The documentation for this class was generated from the following files: