Class CWirelessPower
Defined in File CWirelessPower.h
Inheritance Relationships
Base Type
public mrpt::hwdrivers::CGenericSensor(Class CGenericSensor)
Class Documentation
-
class CWirelessPower : public mrpt::hwdrivers::CGenericSensor
This class implements a wireless power probe.
See also
mrpt::maps::CWirelessPowerGridMap2D, mrpt::obs::CObservationWirelessPower
Public Functions
-
CWirelessPower()
Default constructor.
-
~CWirelessPower() override = default
-
void setNet(std::string ssid, std::string guid)
Set the SSID and GUID of the target network.
- Throws:
std::exception – In case there is a failure
- Parameters:
ssid – SSID of the target network
guid – GUID of the network interface
-
virtual void doProcess() override
This method will be invoked at a minimum rate of “process_rate” (Hz)
- Throws:
This – method must throw an exception with a descriptive message if some critical error is found.
-
virtual void loadConfig_sensorSpecific(const mrpt::config::CConfigFileBase &configSource, const std::string §ion) override
Loads specific configuration for the device from a given source of configuration parameters, for example, an “.ini” file, loading from the section “[iniSection]” (see config::CConfigFileBase and derived classes)
- Throws:
This – method must throw an exception with a descriptive message if some critical parameter is missing or has an invalid value.
-
std::vector<std::string> ListInterfaces()
Gets a list of the interfaces
- Throws:
std::exception – In case there is a failure
- Returns:
std::vector returns the identifiers (GUID) of the available interfaces
-
int GetPower()
Gets the power of a given network
- Throws:
std::exception – In case there is a failure
- Returns:
Returns the power (0-100).
-
bool getObservation(mrpt::obs::CObservationWirelessPower &outObservation)
Gets the power of a given network as a timestamped observation NOTE: Deprecated, use getObservations instead. See CGenericSensor documentation. This function is kept for internal use of the module
See also
- Returns:
Returns true if the observation was correct, and false otherwise
-
std::vector<std::string> ListNetworks()
Gets a list of the networks available for an interface
- Throws:
std::exception – In case there is a failure
- Returns:
std::vector returns handles to the available networks of a given interface
-
CWirelessPower()