YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
FakeDeviceUnwrapped.cpp
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2024-2024 Istituto Italiano di Tecnologia (IIT)
3 * SPDX-License-Identifier: BSD-3-Clause
4 */
5
7
8#include <yarp/os/Log.h>
10#include <yarp/os/LogStream.h>
11
12using namespace yarp::os;
13using namespace yarp::dev;
14
15namespace {
16 YARP_LOG_COMPONENT(FAKEDEVICEUNWRAPPED, "yarp.device.fakeDeviceUnwrapped")
17}
18
24
26{
27 yCInfo(FAKEDEVICEUNWRAPPED) << "testSetValue" << value;
28 m_value = value;
29 return ReturnValue_ok;
30}
31
33{
34 yCInfo(FAKEDEVICEUNWRAPPED) << "testGetValue" << m_value;
35 value=m_value;
36 return ReturnValue_ok;
37}
38
40{
41 yCInfo(FAKEDEVICEUNWRAPPED) << "FakeDeviceUnwrapped opened";
42 return true;
43}
44
46{
47 yCInfo(FAKEDEVICEUNWRAPPED) << "FakeDeviceUnwrapped closed";
48 return true;
49}
#define ReturnValue_ok
Definition ReturnValue.h:77
yarp::dev::ReturnValue testGetValue(int &value) override
This method is used to get a single value from a test device.
bool open(yarp::os::Searchable &config) override
Open the DeviceDriver.
yarp::dev::ReturnValue testSetValue(int value) override
This method is used to set a single value inside the test device.
yarp::dev::ReturnValue doSomething() override
A method for testing purposes.
bool close() override
Close the DeviceDriver.
A mini-server for performing network communication in the background.
A base class for nested structures that can be searched.
Definition Searchable.h:31
#define yCInfo(component,...)
#define YARP_LOG_COMPONENT(name,...)
For streams capable of holding different kinds of content, check what they actually have.
An interface to the operating system, including Port based communication.