Import joint angles as Text File

Hello,

I want to import joint angles as text file. I used the AnyFunInterpol and AnyKinEqInterPolDriver Functions. When I want to run the model, it always stuck at “evaluating constants…”

Can someone tell me what I’m doing wrong?

I started working with AnyBody recently, so a step by step introduction would be fine… :slight_smile:

Regards
Julika

Hello Julika,

Could you specify the version of AMMR you are using? Then I will have a look at your model.

Best,
Kasper Pihl Rasmussen

Hello Kasper,

I’m using AnyBody Version 5.3., with AMMR.v1.5.1

Thank you!

Regards
Julika

Hello Julika,

It is a bit difficult for me to help with these old versions. If you look at the reference manual for your two proposed classes, you will get a lot of information on how to implement them. If you look at the bottom page for AnyFunInterPol, you will find a demo. The example from here looks like this:

/// Example 2: Simple interpolation function importing data from a csv file
AnyFolder Ex2_simple_data_import = {

/// Definition of an interpol function
/// that retieves the data from an external file
AnyFunInterpol TestFfile = {
  Type = Bspline;
  FileName = "AnyFunInterpol.dat";
};

AnyVector vfile = 0.025*TestFfile(1.5); 

};

I will, of course, recommend a newer version of AnyBody.

Best,
Kasper Pihl Rasmussen

Hi Kasper,

I already read this example, but I don’t know what I’m doing wrong.
I made it like this:

//Neck driver
AnyFunInterpol InterpolNeck = {
Type = Bspline;
FileName = “C:/Users/kisch.LFE/Desktop/AnyBody/AMMR.v1.5.1-MyDemo/Application/Examples/FreePostureMove/Input/NeckFlexExt.txt”;
};
AnyKinEqInterPolDriver NeckJntDriver = {
Type = Bspline;
T = .InterpolNeck.T0.52364/3365;
Data = .InterpolNeck.Data
pi/180;
AnyKinMeasureOrg &ref1 = …HumanModel.Interface.Trunk.NeckJoint;
};

Unfortunately, I have to work with the version which is installed at the university.

Regards
Julika

Dear Kasper,

I found the problem, it was a parsing error…

But I have to other questions.
When I run the Kinematics I get the message:

  • 3 unsolvable constraint(s) found
  • 264 independent constraints and 273 unknowns

How can I change that?

and another question…
how can I check if the joint angles of the model match with the joint angles of my measurement System?
[SIZE=2]For example for the hip angles means an angle >=0° Extension and <0° Flexion (See Picture in the attachement)[/SIZE]
[SIZE=2]Where can I see if the model of AnyBody has the same settings?[/SIZE]

[SIZE=2]Regards[/SIZE]
[SIZE=2]Julika
[/SIZE]