Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  Filo - Calculating weight on cable point
#2
(18-03-2020, 08:32 AM)MarcPilgaard Wrote: Hi Virtual Method

I just recently bought Filo and I am so far very pleased. The physics is stable and it was easy to setup. In the application we are working on there is a 30-ton element lifted up by four different cables which you can hoist and lower. We would like to calculate the weight each cable is lifting and display this information to the user. How could we do this? Are there any build-in metrics we can read for the cables class or do we have to calculate it ourselves?

Hi there,

Yes, a cable is made up of multiple cable joints, that attach to links. Each link can be of 4 different types (attachment, rolling, pinhole or hybrid). So a cable looks like this:
Code:
Link ----(cable joint)--- Link ----(cable joint)---- Link ---...etc

Each cable joint stores a value (impulse magnitude) that is basically the amount of "instant" force applied by each joint. To convert an impulse to a force you need to divide by the delta time, so you can get a tension force in Newtons. To get the mass in Kilograms "seen" by the cable at its ends, divide by acceleration (since F = ma). In case of a simple load hanging from the cable, use gravity (-9.81f m/s2). This will print out the force applied and mass lifted by each cable joint in a cable:

Code:
IList<CableJoint> joints = cable.Joints;
foreach (CableJoint j in joints){
           float force = j.ImpulseMagnitude / Time.fixedDeltaTime;
           Debug.Log(force + " N, Mass:" + force/-9.81f +" Kg");
}
Reply


Messages In This Thread
RE: Filo - Calculating weight on cable point - by josemendez - 18-03-2020, 09:32 AM