set_tool_offset.h
Go to the documentation of this file.
1 /*********************************************************************
2 * FSRobo-R Package BSDL
3 * ---------
4 * Copyright (C) 2019 FUJISOFT. All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without modification,
7 * are permitted provided that the following conditions are met:
8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice,
11 * this list of conditions and the following disclaimer in the documentation and/or
12 * other materials provided with the distribution.
13 * 3. Neither the name of the copyright holder nor the names of its contributors
14 * may be used to endorse or promote products derived from this software without
15 * specific prior written permission.
16 *
17 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
18 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
19 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
20 * IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
21 * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
22 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
23 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
24 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
25 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 *********************************************************************/
28 
29 #ifndef FSROBO_R_DRIVER_SIMPLE_MESSAGE_SET_TOOL_OFFSET_H
30 #define FSROBO_R_DRIVER_SIMPLE_MESSAGE_SET_TOOL_OFFSET_H
31 
35 #include <vector>
36 
37 namespace fsrobo_r_driver
38 {
39 namespace simple_message
40 {
41 namespace set_tool_offset
42 {
43 
61 {
62 public:
69  SetToolOffset(void);
70 
75  ~SetToolOffset(void);
76 
81  void init();
82 
93 
100  {
101  this->x_ = x;
102  }
103 
110  {
111  this->y_ = y;
112  }
113 
120  {
121  this->z_ = z;
122  }
123 
130  {
131  this->rz_ = rz;
132  }
133 
140  {
141  this->ry_ = ry;
142  }
143 
150  {
151  this->rx_ = rx;
152  }
153 
160  {
161  return this->x_;
162  }
163 
170  {
171  return this->y_;
172  }
173 
180  {
181  return this->z_;
182  }
183 
190  {
191  return this->rz_;
192  }
193 
200  {
201  return this->rx_;
202  }
203 
210  {
211  return this->ry_;
212  }
213 
219  void copyFrom(SetToolOffset &src);
220 
226  bool operator==(SetToolOffset &rhs);
227 
228  // Overrides - SimpleSerialize
231  unsigned int byteLength()
232  {
233  return 6 * sizeof(industrial::shared_types::shared_int);
234  }
235 
236 private:
246 };
247 }
248 }
249 }
250 
251 #endif // FSROBO_R_DRIVER_SIMPLE_MESSAGE_SET_TOOL_OFFSET_H
void setRx(industrial::shared_types::shared_real rx)
Sets offset.
industrial::shared_types::shared_real x_
Values of tool origin.
industrial::shared_types::shared_real getX()
Returns offset.
industrial::shared_types::shared_real getZ()
Returns offset.
industrial::shared_types::shared_real getRx()
Returns offset.
Class encapsulated tool offset data. FSRobo-R specific interface to set tool offset on the controller...
TFSIMD_FORCE_INLINE const tfScalar & y() const
void setRy(industrial::shared_types::shared_real ry)
Sets offset.
void setY(industrial::shared_types::shared_real y)
Sets offset.
bool unload(industrial::byte_array::ByteArray *buffer)
TFSIMD_FORCE_INLINE const tfScalar & x() const
void setX(industrial::shared_types::shared_real x)
Sets offset.
void init()
Initializes a empty set tool offset command.
void copyFrom(SetToolOffset &src)
Copies the passed in value.
industrial::shared_types::shared_real getRz()
Returns offset.
void setZ(industrial::shared_types::shared_real z)
Sets offset.
industrial::shared_types::shared_real getY()
Returns offset.
void setRz(industrial::shared_types::shared_real rz)
Sets offset.
bool load(industrial::byte_array::ByteArray *buffer)
bool operator==(SetToolOffset &rhs)
== operator implementation
industrial::shared_types::shared_real getRy()
Returns offset.


fsrobo_r_driver
Author(s): F-ROSROBO
autogenerated on Sun Feb 9 2020 03:58:29