Tinkerforge::Device - Base class for all Bricks and Bricklets (for internal use only)
Registers a callback with ID $id to the function named $callback.
Returns the API version (major, minor, revision) of the bindings for this device.
Returns the response expected flag for the function specified by the *function_id* parameter. It is *true* if the function is expected to send a response, *false* otherwise.
For getter functions this is enabled by default and cannot be disabled, because those functions will always send a response. For callback configuration functions it is enabled by default too, but can be disabled via the set_response_expected function. For setter functions it is disabled by default and can be enabled.
Enabling the response expected flag for a setter function allows to detect timeouts and other error conditions calls of this setter as well. The device will then send a response for this purpose. If this flag is disabled for a setter function then no response is send and errors are silently ignored, because they cannot be detected.
Changes the response expected flag of the function specified by the *function_id* parameter. This flag can only be changed for setter (default value: *false*) and callback configuration functions (default value: *true*). For getter functions it is always enabled and callbacks it is always disabled.
Changes the response expected flag for all setter and callback configuration functions of this device at once.
To install Tinkerforge, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Tinkerforge
CPAN shell
perl -MCPAN -e shell install Tinkerforge
For more information on module installation, please visit the detailed CPAN module installation guide.