question

Ryosuke S avatar image
0 Likes"
Ryosuke S asked Eric M commented

How to get the information of subnode under travelPath

How can I get the subnode information under model/AGVNetwork/variable>agvs/TaskExecuter1/travelPath?

I've got the node of the travelPath, but then I don't know what to do next.

capture006.jpg

PathTest.fsm

FlexSim 21.0.6
processflowflexscriptagvpathtreenodeflexsim 21.0.6
capture006.jpg (145.0 KiB)
pathtest.fsm (47.7 KiB)
· 1
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Eric M avatar image Eric M commented ·

Hi @Ryosuke S, was Felix Möhlmann's answer helpful? If so, please click the red "Accept" button at the bottom of their answer. Or if you still have questions, add a comment and we'll continue the conversation.

If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always unaccept and comment back to reopen your question.

0 Likes 0 ·

1 Answer

Felix Möhlmann avatar image
1 Like"
Felix Möhlmann answered

From the travelPath node go "down" one more level to point to the actual node containing the information. Then you can use getsdtvalue() to read the values from it.

getstdvalue.png

In the screenshot i use

getvarnode(Model.find("AGVNetwork"), "agvs").find("1/2/1");

to go directly to the subnode. This is the same as if writing

getvarnode(Model.find("AGVNetwork"), "agvs").subnodes[1].subnodes[2].subnodes[1];

getstdvalue.png (77.1 KiB)
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.