system.mes.oee.splitEquipmentStateValue

Sepasoft MES Module Suite

Description

Split a single downtime event into two downtime events.

This is useful if there are two causes for a downtime event and different reasons can be assigned to each separately.

This script function can be called multiple times to split the downtime event into 3 or more separate events. 

Warning

If a downtime event that has a note is split, the note will only stay on the original downtime reason and not be copied over (duplicated) to the new split state.

Warning

Once a downtime event is split, only the original event may be split again. The newly-split portion cannot be split (but a Downtime Reason note can be added).

Syntax

system.mes.oee.splitEquipmentStateValue(baseEquipmentPath, reasonEquipmentPath, stateTimeStamp, eventTimeStamp, splitTimeStamp)


  • Parameters

String baseEquipmentPath - The equipment path for the line or if managing downtime events for a cell group, the equipment path for the cell group.

String reasonEquipmentPath - The equipment path for the original equipment that caused the downtime event.

Date stateTimeStamp- The timestamp of the state that is at the source of the downtime event.

Error

The state timestamp is not always the same as the downtime event timestamp and using the downtime event timestamp will not always produce consistent results.

Date eventTimeStamp- The timestamp of the line or cell group downtime event. Note that is not always the same as the timestamp of the state that cause the downtime event. 

Date splitTimeStamp- The timestamp of where to split the downtime event. It must be between the start and end of the line or cell group downtime event.

  • Returns

Nothing

  • Scope

All

Code Examples

Code Snippet

Code
# Splitting the downtime event on the filler 5 seconds after the state was recorded


base_equipment_path = 'Enterprise\Site\Area\Line 2'
reason_equipment_path = 'Enterprise\Site\Area\Line 2\Filler'
split_time_stamp = system.date.addSeconds(state_time_stamp, 5)


system.mes.oee.splitEquipmentStateValue(base_equipment_path, reason_equipment_path, state_time_stamp, event_time_stamp, split_time_stamp)  

Sepasoft MES Module Suite