ATTENTION

This FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices.


flexsim.com

Go Back   FlexSim Community Forum > FlexSim Software > Q&A
Downloads

Q&A Using Flexsim and building models

  #1  
Old 04-05-2010
Pablo Concha Pablo Concha is offline
Flexsim User
 
Join Date: Aug 2007
Posts: 104
Downloads: 100
Uploads: 1
Thanks: 103
Thanked 52 Times in 37 Posts
Rep Power: 232
Pablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nice
Default How to get the speed of an item at the end of a basic conveyor?..

Hi,

I'm playing around with the basic conveyor, and set it so that i have a variable starting speed, variable final speed and variable acceleration, how can i capture the speed of the item at the end of the conveyor?...

regards

Pablo Concha Erilkin
  #2  
Old 04-05-2010
Anthony Johnson's Avatar
Anthony Johnson Anthony Johnson is offline
Manager of Product Development
 
Join Date: Jul 2007
Posts: 440
Downloads: 86
Uploads: 4
Thanks: 171
Thanked 899 Times in 288 Posts
Rep Power: 735
Anthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond repute
Default

Call bcgetitemkinematics() to get the item's main kinematic. Then call getkinematics() for KINEMATIC_VX.
The Following User Says Thank You to Anthony Johnson For This Useful Post:
Pablo Concha (04-05-2010)
  #3  
Old 04-05-2010
Pablo Concha Pablo Concha is offline
Flexsim User
 
Join Date: Aug 2007
Posts: 104
Downloads: 100
Uploads: 1
Thanks: 103
Thanked 52 Times in 37 Posts
Rep Power: 232
Pablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nice
Default

I tried that but i guess i'm making some mistake when using the commands. What i did is:

treenode nodo_kin= bcgetitemkinematics(current,item,0);

pf
(getkinematics(nodo_kin,KINEMATIC_VX));

setlabelnum
(item,"vel_final",getkinematics(nodo_kin,KINEMATIC_VX));

I keep getting 0.0000 at the console and the label...

regards

Pablo Concha Erilkin.

  #4  
Old 04-05-2010
Anthony Johnson's Avatar
Anthony Johnson Anthony Johnson is offline
Manager of Product Development
 
Join Date: Jul 2007
Posts: 440
Downloads: 86
Uploads: 4
Thanks: 171
Thanked 899 Times in 288 Posts
Rep Power: 735
Anthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond repute
Default

Yeah, in flexscript, at least for now, you need to pass parameter 3 and 4 explicitly, so this should work:

getkinematics(nodo_kin,KINEMATIC_VX, 0, time());

We'll fix this for version 5.
The Following User Says Thank You to Anthony Johnson For This Useful Post:
Pablo Concha (04-05-2010)
  #5  
Old 04-05-2010
Pablo Concha Pablo Concha is offline
Flexsim User
 
Join Date: Aug 2007
Posts: 104
Downloads: 100
Uploads: 1
Thanks: 103
Thanked 52 Times in 37 Posts
Rep Power: 232
Pablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nice
Default

Still getting 0.0000, the code using now is:

treenode nodo_kin = bcgetitemkinematics(current,item,0);
pf(getkinematics(nodo_kin,KINEMATIC_VX),0,time());
setlabelnum(item,"vel_final",getkinematics(nodo_kin,KINEMATIC_VX),0,time());

Attaching the model, i'm using the code on the decision point OnClear

i also tried bcgetitemkinematics(current,item,1); just in case, it's supposed to be 0 for the main conveying kinematic right?...

regards

Pablo Concha Erilkin
Attached Files
File Type: zip test_bconv_01.zip (33.5 KB, 177 views)
  #6  
Old 04-05-2010
Anthony Johnson's Avatar
Anthony Johnson Anthony Johnson is offline
Manager of Product Development
 
Join Date: Jul 2007
Posts: 440
Downloads: 86
Uploads: 4
Thanks: 171
Thanked 899 Times in 288 Posts
Rep Power: 735
Anthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond repute
Default

You actually passed the parameters: ,0,time() as parameters to the pf() and setlabelnum() commands, instead of into the getkinematics() command.

Also, make sure you're calling bcgetitemkinematics(current,item,0); not bcgetitemkinematics(current,item,1); That's what the model you sent me has in it.

Can't wait for version 5 (version 5 would yell at you for this error)!!!
The Following User Says Thank You to Anthony Johnson For This Useful Post:
Pablo Concha (04-05-2010)
  #7  
Old 04-05-2010
Pablo Concha Pablo Concha is offline
Flexsim User
 
Join Date: Aug 2007
Posts: 104
Downloads: 100
Uploads: 1
Thanks: 103
Thanked 52 Times in 37 Posts
Rep Power: 232
Pablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nice
Default

doh!... that happened because i was just leaving office, and tried it in a hurry, gonna check it againg tomorrow, thanks for your help!...

regards

Pablo Concha Erilkin.
  #8  
Old 04-06-2010
Pablo Concha Pablo Concha is offline
Flexsim User
 
Join Date: Aug 2007
Posts: 104
Downloads: 100
Uploads: 1
Thanks: 103
Thanked 52 Times in 37 Posts
Rep Power: 232
Pablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nicePablo Concha is just really nice
Default

That was it, now it's working, thanks again Anthony..

regards

Pablo Concha Erilkin


Thread Thread Starter Forum Replies Last Post
Basic Use of the Experimenter Gavin Douglas Q&A 8 09-08-2009 04:17 PM
What is the difference between a Conveyor and Basic Conveyor shivrash Q&A 2 07-21-2009 04:09 AM
Model Speed Alistair Smitheman Q&A 14 04-06-2009 12:45 PM
Basic Conveyor tobias.biemueller Q&A 16 05-23-2008 08:12 AM
Increasing Run Speed Alex Christensen Tips and Tricks 3 05-14-2008 04:11 PM


All times are GMT -6.
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Copyright 1993-2018 FlexSim Software Products, Inc.