API apply loads on nodes

API apply loads on nodes

AbelSV78
Enthusiast Enthusiast
1,208 Views
2 Replies
Message 1 of 3

API apply loads on nodes

AbelSV78
Enthusiast
Enthusiast

Hi, 

 

From VB.net, I have a Robot model with bars, nodes and loads cases that I have created.

 

I can't find the way to apply forces on nodes. Could you indicate me the variable for this and how to use it in VB.net?

 

Thank you in advance, regards

0 Likes
Accepted solutions (2)
1,209 Views
2 Replies
Replies (2)
Message 2 of 3

rsousa_
Advocate
Advocate
Accepted solution

See the tutorial, You can learn a lot there:

'Generate new load case.

   Dim cas As IRobotSimpleCase

Set cas = robapp.Project.Structure.Cases.CreateSimple(robapp.Project.Structure.Cases.FreeNumber, _

"Case_1", I_CN_EXPLOATATION, I_CAT_STATIC_LINEAR)

 

 

 '  Define load record types.

cas.Records.New I_LRT_NODE_FORCE

cas.Records.New I_LRT_BAR_UNIFORM

 

  ' Get the first created load record

   Dim rec As IRobotLoadRecord

Set rec = cas.Records.Get(1)

 

   'Define the list of objects to which load will be applied.

rec.Objects.FromText "1 2"

 

   'Definie the operation direction and load value.

rec.SetValue I_NFRV_FX, 50000

 

   'Define ALFA angle at which concentrated force acts in the structure node.

rec.SetValue I_NFRV_ALPHA, 0.52

 

   'Get the second created load record.

   Set rec = cas.Records.Get(2)

 

   'Define the list of objects to which load will be applied.

rec.Objects.FromText "2do4"

 

   'Define load direction and value.

rec.SetValue I_BURV_PZ, -110000

 

   'Set auxilliary load parameters.

rec.SetValue I_BURV_LOCAL, True

rec.SetValue I_BURV_PROJECTION, True

0 Likes
Message 3 of 3

AbelSV78
Enthusiast
Enthusiast
Accepted solution

Thank you so much, I got it:

 

cas = robapp.Project.Structure.Cases.Get(2)
cas.Records.[New](RobotOM.IRobotLoadRecordType.I_LRT_NODE_FORCE)
Dim rec As RobotOM.IRobotLoadRecord
rec = cas.Records.Get(1)
rec.Objects.FromText("1 2")
rec.SetValue(RobotOM.IRobotNodeForceRecordValues.I_NFRV_FZ, -55000)

 

Regards...

0 Likes