question

Paúl Alejandro R avatar image
0 Likes"
Paúl Alejandro R asked Paúl Alejandro R commented

STOP A PROCESSOR

HOW TO MAKE A PROCESSOR TO STOP ALWAYS THAT IT HAS BEEN PROCESSING FOR 40 MINUTES?

FlexSim 18.1.2
processor stop
· 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.

Joerg Vogel avatar image Joerg Vogel commented ·

Please unlock you caps lock on your keyboard writing your questions, thanks!

0 Likes 0 ·
Joerg Vogel avatar image
0 Likes"
Joerg Vogel answered Paúl Alejandro R commented

If you want a processor to stop every 40 minutes of processing time, you should use the Tool MTBF / MTTR. There you can set the states the first failure time and the mean time before failure are associated to. The function calls a stopobject command on the members set to the added MTBF/MTTR

· 2
5 |100000

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

Paúl Alejandro R avatar image Paúl Alejandro R commented ·

@Jörg Vogel it is not working, because it stops the object at 40 minutes of the simulation time, but I need it to stop the object after 40 minutes since it started processing

0 Likes 0 ·
Paúl Alejandro R avatar image Paúl Alejandro R commented ·

@Jörg Vogel we just solved the problem thank you

0 Likes 0 ·
Joerg Vogel avatar image
0 Likes"
Joerg Vogel answered Paúl Alejandro R commented

Assuming you need a repeating event every 40 Minutes, you can use a 40 * 60 Delay connected to a Custom Code activity. The exit of the Custom Code activity is connected to the entry of the delay activity. Those two activities are together a metronome. In another process you create on entry of the Custom Code activity a token. The token executes a Custom Code that executes the stopobject command.

A 3D - model approach uses an infinite delayed message loop, that works in an object that never get a stopobject call. On Reset you sends a delayed message to the same object (current in this source code or template). The message will trigger the OnMessage function. Here you execute the stopobject command for your processor and you send again a delayed message to the current object again. This message triggers the OnMessage function in the delaytime again.

Please read the description of the stopobject and resumeobject commands in the manual under Reference.

· 3
5 |100000

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

Paúl Alejandro R avatar image Paúl Alejandro R commented ·

@Jörg VogelCan I have an example please. I know how to make an object to stop through the process flow, but I don't know how to make this happen every 40 minutes. I'm sorry. can you help me ?

0 Likes 0 ·
Joerg Vogel avatar image Joerg Vogel Paúl Alejandro R commented ·

I am certain you are able to build a loop in a Process and include in this loop a delay activity. And then you can listen to the OnEntry event of the Delay activity to create a token. A more easier approach is to stop an object in a Custom Code activity in the loop.

0 Likes 0 ·
Paúl Alejandro R avatar image Paúl Alejandro R Joerg Vogel commented ·

@Jörg Vogel It is working but not as I expectted, I need the processor to stop only when i has benn processing for 40 minutes here the processor stops withou processing. How can I fix this ?stop-object.fsm

0 Likes 0 ·
stop-object.fsm (20.7 KiB)