A place to discuss everything related to Newton Dynamics.
Moderators: Sascha Willems, walaber
by JohnSmith » Wed Mar 29, 2017 5:19 pm
Hello,
I want to have a motorized hinge joint. I have setup the joint and parent and child objects and the joint. When Newton runs the objects do fall and are jointed so I think I have everything setup correctly so far.
But I want the hinge to be powered so it turns slowly and forces the parent and child objects to move.
What options do I have to do this in Newton?
Thanks.
-
JohnSmith
-
- Posts: 4
- Joined: Wed Mar 29, 2017 5:15 pm
by Julio Jerez » Wed Mar 29, 2017 6:26 pm
use dCustomHingeActuator instead of plain dCustomHinge
the you can control it with function void SetTargetAngle(dFloat angle)
which works as a precise robotic actuator.
-
Julio Jerez
- Moderator
-
- Posts: 12249
- Joined: Sun Sep 14, 2003 2:18 pm
- Location: Los Angeles
-
by JohnSmith » Wed Mar 29, 2017 7:03 pm
I am using the older v2.36 pascal headers and do not see dCustomHingeActuator. In fact there is no "actuator" text found in the wntire header translation.
Same for the newer v3.03 pascal translation.
Are the actuators not included/possible with the pascal translations?
-
JohnSmith
-
- Posts: 4
- Joined: Wed Mar 29, 2017 5:15 pm
by Julio Jerez » Thu Mar 30, 2017 4:51 pm
I do not remember if that joint is in 3.03
I assume 3.03 is the newton version,
if you are on 3.03 converting to 3.13 is a matter of recompiling, there are very few changes.
-
Julio Jerez
- Moderator
-
- Posts: 12249
- Joined: Sun Sep 14, 2003 2:18 pm
- Location: Los Angeles
-
by JohnSmith » Thu Mar 30, 2017 5:12 pm
Bummer. The latest delphi header seems to be for 3.03.
Maybe Stuart will be kind enough to update it to support 3.13 and actuators. I will send him a PM.
-
JohnSmith
-
- Posts: 4
- Joined: Wed Mar 29, 2017 5:15 pm
by Dave Gravel » Fri Mar 31, 2017 1:58 pm
Stucuk : thanks for the updated file.
-
Dave Gravel
-
- Posts: 800
- Joined: Sat Apr 01, 2006 9:31 pm
- Location: Quebec in Canada.
-
by JohnSmith » Sat Apr 01, 2017 2:12 am
Thanks for the quick update!
But, as before there is no dCustomHingeActuator (or any mention of "actuator") in the header?
So I still cannot create a motorized joint in Newton/Delphi?
-
JohnSmith
-
- Posts: 4
- Joined: Wed Mar 29, 2017 5:15 pm
by d.l.i.w » Sat Apr 01, 2017 4:33 am
Of course you can, but you have to do it yourself.
dCustomHingeActuator is part of the
dCustomJoints package and not in the core Newton library itself.
So you need to either port these classes to Pascal or put the C++ code into a
library with a pure C interface, so it can be used with Pascal.
-
d.l.i.w
-
- Posts: 81
- Joined: Mon Sep 26, 2011 4:35 am
by Stucuk » Sat Apr 01, 2017 5:29 am
Basically the dCustomJoints is using standard newton stuff. Its just helper classes. So you can as d.l.i.w states port it or you can write your own joints.
-
Stucuk
-
- Posts: 801
- Joined: Sat Mar 12, 2005 3:54 pm
- Location: Scotland
-
Return to General Discussion
Who is online
Users browsing this forum: No registered users and 48 guests