21 FrameGrabberControls_Sender::FrameGrabberControls_Sender(
Port& port) : _port(port) {};
31 bool ret = _port.
write(cmd,response);
46 bool ret = _port.
write(cmd,response);
60 return _port.
write(cmd,response);
72 return _port.
write(cmd,response);
82 bool ret = _port.
write(cmd,response);
95 bool ret = _port.
write(cmd,response);
109 bool ret = _port.
write(cmd,response);
111 *_hasOnOff = response.
get(4).
asInt32() !=0?
true:
false;
123 return _port.
write(cmd,response);
133 bool ret = _port.
write(cmd,response);
135 *_isActive = response.
get(3).
asInt32() !=0?
true:
false;
146 bool ret = _port.
write(cmd,response);
148 *_hasAuto = response.
get(4).
asInt32() !=0?
true:
false;;
159 bool ret = _port.
write(cmd,response);
161 *_hasManual = response.
get(4).
asInt32() !=0?
true:
false;
172 bool ret = _port.
write(cmd,response);
174 *_hasOnePush = response.
get(4).
asInt32() !=0?
true:
false;
186 return _port.
write(cmd,response);
196 bool ret = _port.
write(cmd,response);
209 return _port.
write(cmd,response);
246 yError() <<
" Selected camera device has no IFrameGrabberControl interface";
301 yError() <<
"Unknown command 'HAS " <<
Vocab::decode(param) <<
"' received on IFrameGrabber2 interface";
340 yError() <<
"Unknown command 'SET " <<
Vocab::decode(param) <<
"' received on IFrameGrabber2 interface";
373 double value1, value2;
395 yError() <<
"Unknown command 'GET " <<
Vocab::decode(param) <<
"' received on IFrameGrabber2 interface";
constexpr yarp::conf::vocab32_t VOCAB_ACTIVE
constexpr yarp::conf::vocab32_t VOCAB_FEATURE2
constexpr yarp::conf::vocab32_t VOCAB_FEATURE
constexpr yarp::conf::vocab32_t VOCAB_MANUAL
constexpr yarp::conf::vocab32_t VOCAB_ONEPUSH
constexpr yarp::conf::vocab32_t VOCAB_MODE
constexpr yarp::conf::vocab32_t VOCAB_ONOFF
constexpr yarp::conf::vocab32_t VOCAB_CAMERA_DESCRIPTION
constexpr yarp::conf::vocab32_t VOCAB_HAS
constexpr yarp::conf::vocab32_t VOCAB_AUTO
constexpr yarp::conf::vocab32_t VOCAB_FRAMEGRABBER_CONTROL
constexpr yarp::conf::vocab32_t VOCAB_IS
constexpr yarp::conf::vocab32_t VOCAB_GET
constexpr yarp::conf::vocab32_t VOCAB_SET
bool configure(IFrameGrabberControls *interface)
FrameGrabberControls_Parser()
bool respond(const yarp::os::Bottle &cmd, yarp::os::Bottle &response) override
Respond to a message.
bool hasFeature(int feature, bool *hasFeature) override
Check if camera has the requested feature (saturation, brightness ...
bool setMode(int feature, FeatureMode mode) override
Set the requested mode for the feature.
bool setActive(int feature, bool onoff) override
Set the requested feature on or off.
bool hasManual(int feature, bool *hasManual) override
Check if the requested feature has the 'manual' mode.
bool getMode(int feature, FeatureMode *mode) override
Get the current mode for the feature.
bool setFeature(int feature, double value) override
Set the requested feature to a value (saturation, brightness ...
bool getFeature(int feature, double *value) override
Get the current value for the requested feature.
bool setOnePush(int feature) override
Set the requested feature to a value (saturation, brightness ...
bool hasOnOff(int feature, bool *HasOnOff) override
Check if the camera has the ability to turn on/off the requested feature.
bool hasAuto(int feature, bool *hasAuto) override
Check if the requested feature has the 'auto' mode.
bool getActive(int feature, bool *isActive) override
Get the current status of the feature, on or off.
bool getCameraDescription(CameraDescriptor *camera) override
Get a basic description of the camera hw.
bool hasOnePush(int feature, bool *hasOnePush) override
Check if the requested feature has the 'onePush' mode.
Control interface for frame grabber devices.
virtual bool setFeature(int feature, double value)=0
Set the requested feature to a value (saturation, brightness ...
virtual bool setOnePush(int feature)=0
Set the requested feature to a value (saturation, brightness ...
virtual bool getFeature(int feature, double *value)=0
Get the current value for the requested feature.
virtual bool hasManual(int feature, bool *hasManual)=0
Check if the requested feature has the 'manual' mode.
virtual bool setMode(int feature, FeatureMode mode)=0
Set the requested mode for the feature.
virtual bool hasOnOff(int feature, bool *HasOnOff)=0
Check if the camera has the ability to turn on/off the requested feature.
virtual bool hasAuto(int feature, bool *hasAuto)=0
Check if the requested feature has the 'auto' mode.
virtual bool getMode(int feature, FeatureMode *mode)=0
Get the current mode for the feature.
virtual bool getCameraDescription(CameraDescriptor *camera)=0
Get a basic description of the camera hw.
virtual bool getActive(int feature, bool *isActive)=0
Get the current status of the feature, on or off.
virtual bool setActive(int feature, bool onoff)=0
Set the requested feature on or off.
virtual bool hasFeature(int feature, bool *hasFeature)=0
Check if camera has the requested feature (saturation, brightness ...
virtual bool hasOnePush(int feature, bool *hasOnePush)=0
Check if the requested feature has the 'onePush' mode.
A simple collection of objects that can be described and transmitted in a portable way.
void addFloat64(yarp::conf::float64_t x)
Places a 64-bit floating point number in the bottle, at the end of the list.
void addVocab(int x)
Places a vocabulary item in the bottle, at the end of the list.
Value & get(size_type index) const
Reads a Value v from a certain part of the list.
void clear()
Empties the bottle of any objects it contains.
void addInt32(std::int32_t x)
Places a 32-bit integer in the bottle, at the end of the list.
void addString(const char *str)
Places a string in the bottle, at the end of the list.
std::string toString() const override
Gives a human-readable textual representation of the bottle.
A mini-server for network communication.
bool write(const PortWriter &writer, const PortWriter *callback=nullptr) const override
Write an object to the port.
bool isOpen() const
Check if the port has been opened.
virtual yarp::conf::float64_t asFloat64() const
Get 64-bit floating point value.
virtual std::int32_t asInt32() const
Get 32-bit integer value.
virtual std::int32_t asVocab() const
Get vocabulary identifier as an integer.
virtual std::string asString() const
Get string value.
An interface for the device drivers.
std::string decode(NetInt32 code)
Convert a vocabulary identifier into a string.
An interface to the operating system, including Port based communication.
std::string deviceDescription