question

Sia Sengchoon193 avatar image
0 Likes"
Sia Sengchoon193 asked Felix Möhlmann commented

How to change the color of the goods in the double deep rack?

My rack uses double deep,

So some items will be at the front and some will be at the back,

Need to use different colors to be easier to observe,

Input is random,

Need to automatically distinguish colors.

1683149593030.png

1683149607213.png

dual asrs V2.fsm

FlexSim 21.0.10
racktriggerscolor changeinputcolor discrimination
1683149593030.png (623.1 KiB)
1683149607213.png (519.5 KiB)
dual-asrs-v2.fsm (86.8 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.

1 Answer

·
Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered Felix Möhlmann commented

Do you want random colors?


item.color=Colour.random()

or in a creation trigger:

1683152415025.png


1683152415025.png (8.1 KiB)
· 9
5 |100000

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

Sia Sengchoon193 avatar image Sia Sengchoon193 commented ·

@Jason Lightfoot I think need create a trigger, the front and back will be fixed with a different color, not random, for example, the front is fixed in red, and the back is fixed in blue

0 Likes 0 ·
Felix Möhlmann avatar image Felix Möhlmann Sia Sengchoon193 commented ·

The items in the slots will be moved around every time an item enters or exits. So you have to loop through all items and adjust their color.

The On Slot Entry/Exit triggers are best for this since they offer a reference to the respective slot. To identify which item is in the back or front, you can use the pickRank property of the Storage.Slot.Item. The relationship between pickRank and position depends on the slot stacking order, so the example code in Rack1 will likely not work if you change that setting and/or the slot size.

dual-asrs-v2-itemcolor-fm.fsm

0 Likes 0 ·
Sia Sengchoon193 avatar image Sia Sengchoon193 Felix Möhlmann commented ·

@Felix Möhlmann grateful! But the color will change when moving to the queue, so can the color be kept in the queue?

0 Likes 0 ·
Show more comments

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

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