question

Luis Gaytan avatar image
0 Likes"
Luis Gaytan asked Luis Gaytan commented

Conditional decide Verify only 2 items each shift

Good evening, I have the idea to verify only 2 items each shift but I want some help to improve this weak logic, the idea is that each day the operator check 2 items in the conveyor using this custom code with the conditional decide:

double currentHour = Model.dateTime.hour;

if (currentHour == 9)
{
return 1;
}
return 2;

Thank you for the support!

Best regards,

Luis Gaytán

Verify2Items.fsm

FlexSim 23.2.1
process flowconditional decideconveyor process flow
verify2items.fsm (54.4 KiB)
· 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.

Felix Möhlmann avatar image Felix Möhlmann commented ·

In what way do you want to improve the logic? Check items at set times each day or in a set interval? Randomize which items are checked and if so are there any constraints?

1 Like 1 ·
Luis Gaytan avatar image Luis Gaytan Felix Möhlmann commented ·

good morning, to improve the logic checking just 2 items each 4 hours of the day, using flexscript.flowchart.PNG

0 Likes 0 ·
flowchart.png (21.9 KiB)
Felix Möhlmann avatar image Felix Möhlmann Luis Gaytan commented ·

You could use a zone with a max. content of 2 and hold the tokens in there until the next 4h-period starts. Any other tokens, that can not enter are sent directly to the sink.

verify2items_2.fsm

1 Like 1 ·
verify2items-2.fsm (58.9 KiB)

1 Answer

Julio R avatar image
2 Likes"
Julio R answered Luis Gaytan commented

Hello @Luis Gaytan ,

Here is a different idea to do what you are trying to do. Perhaps I overcomplicated things, but it does what you are expecting.

I am using processFlow, and the verification process you can change to whererver you want. If you need any explanation of the model please let me know.

EjemploPreguntaAnswers.fsm


· 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.

Luis Gaytan avatar image Luis Gaytan commented ·
Amazing! thank you both very much that´s how I want this logic, simply, efficient, and two different ways to implement the attached flowchart.

Have a nice day! @Julio R @Felix Möhlmann

0 Likes 0 ·