Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify float/double types #10

Open
ndehio opened this issue Jan 9, 2017 · 1 comment
Open

Unify float/double types #10

ndehio opened this issue Jan 9, 2017 · 1 comment
Assignees
Labels

Comments

@ndehio
Copy link
Collaborator

ndehio commented Jan 9, 2017

Some of our realtime types use float values/vectors/matrices and some others are based on double.
Is there any reason for that? Otherwise we should unify the types...

The following types are based on double:

  • dynamics/Torques
  • dynamics/Forces
  • dynamics/Wrench
  • geometry/Rotation
  • geometry/Translation

The following types are based on float:

  • robot/Weights.hpp
  • robot/JointState.hpp
  • kinematics/JointAccelerations.hpp
  • kinematics/JointVelocities.hpp
  • kinematics/JointJerks.hpp
  • kinematics/JointAngles.hpp
  • dynamics/JointTorques.hpp
  • dynamics/JointImpedance.hpp

The KDL-library uses double vectors. At the moment we have to convert our float-based jointangles to double before employing KDL and afterwards we have to convert it back.
This wastes lots of time...
However, it seems that we can not log double-based types via the OCL::FileReporting component (I am not completely sure about that, but I had an issue with logging the dynamics/Wrench type).

@ndehio ndehio assigned ndehio and xwavex and unassigned ndehio Jan 9, 2017
@ndehio ndehio added the Proposal label Jan 9, 2017
@Pouya-moh
Copy link
Collaborator

I have the same issue with casting. From float->double->float seems pointless to me. At least there should be templating option for tst-rt types for those who do not care about OCL::FileReporting (e.g., me!)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants