# Load and Unload Solder Paste Printer Durables ## Overview This feature enables the load and unload of durable materials on Solder Paste Printer machines, triggered by Fuji Nexim equipment events. The following durable types are supported: - **Screen** — attached at position 1 (`Screen`) - **Squeegee Holders** — attached at positions 4 and 5 (`HolderFront` and `HolderRear`) - **Backup Block** — attached at position 6 (`BackupBlock`) ### Relevant Artifacts | Name | Type | Is Mandatory | Data Type | Description | | :------------------------------------------------------------------------------- | :--------- | :----------: | :-------- | :--------------------------------------------------------------------------------------------------------------------- | | IoTMetadataDefinition | SmartTable | Yes | | Metadata configuration used to enable or bypass the durable handling feature per resource. | | [IoTFujiNeximHandleScreen](../../artifacts/dees.md#iotfujineximhandlescreen) | DEE | Yes | | Attaches or detaches a Screen durable at position `Screen` on a specified MES resource. | | [IoTFujiNeximHandleSqueegee](../../artifacts/dees.md#iotfujineximhandlesqueegee) | DEE | Yes | | Attaches or detaches Squeegee Holder durables at positions `HolderFront` and `HolderRear` on a specified MES resource. | | [IoTFujiNeximHandleBackupBlock](../../artifacts/dees.md#iotfujineximhandlebackupblock) | DEE | Yes | | Attaches or detaches a Screen durable at position `Screen` on a specified MES resource. | ## How It Works When a `LOADSCREEN`, `UNLOADSCREEN`, `LOADSQUEEGEE`, `UNLOADSQUEEGEE`, `LOADBACKUPBLOCK` or `UNLOADBACKUPBLOCK` event is received from the Fuji Nexim equipment, the following steps are executed: ### Area Feature Checks - Resolves the MES Sub-Resource Name using the pattern: `FUJI_LineNameMachineName_{EquipmentLineName}_{EquipmentMachineName}`. ### Resource Feature Checks - Checks whether the `UseFujiToHandleScreen`, `UseFujiToHandleSqueegee` or `UseFujiToHandleBackupBlock` feature is enabled for the resolved MES Resource in the `IoTMetadataDefinition` Smart Table. ### MES Operations If the feature is enabled, the Automation Controller calls the respective DEE. **IoTFujiNeximHandleScreen:** - Validates the screen durable material identified by `ScreenID`. - Performs the operation based on the `Operation` input: **Load:** - If a durable with the name matching `ScreenName` is already attached at position `Screen`, no action is performed and `Success` is returned immediately. - Otherwise, any durable currently attached at position `Screen` is detached and the new screen durable is attached at that position. **Unload:** - Any durable currently attached at position `Screen` is detached. - Sends a `LOADSCREEN_ACK` or `UNLOADSCREEN_ACK` message back to the equipment with: - A result (`0` = Ok, `1` = NOk) for the operation. --- **IoTFujiNeximHandleSqueegee:** - Validates the resource has at least 5 Durable Positions defined. - Performs the operation based on the `Operation` input: **Load:** - Iterates through the `SqueegeeComponents` list (one entry per holder). - Maps `Location 0` → position `HolderFront` and `Location 1` → position `HolderRear`. - If a holder is already attached at the correct position, no action is performed for that entry. - Otherwise, any durable currently at that position is detached and the new holder is attached. - If the holder material does not exist in MES, that entry is marked as failed (`Result = 1`). **Unload:** - All durables currently attached at positions `HolderFront` and `HolderRear` are detached. - Sends a `LOADSQUEEGEE_ACK` or `UNLOADSQUEEGEE_ACK` message back to the equipment with: - A list of components. - A result (`0` = Ok, `1` = NOk) for each component. **IoTFujiNeximHandleBackupBlock:** - Validates the screen durable material identified by `BackupBlockID`. - Performs the operation based on the `Operation` input: **Load:** - If a durable with the name matching `BackupBlockName` is already attached at position `BackupBlock`, no action is performed and `Success` is returned immediately. - Otherwise, any durable currently attached at position `BackupBlock` is detached and the new backup block durable is attached at that position. **Unload:** - Any durable currently attached at position `BackupBlock` is detached. - Sends a `LOADBACKUPBLOCK_ACK` or `UNLOADBACKUPBLOCK_ACK` message back to the equipment with: - A result (`0` = Ok, `1` = NOk) for the operation. **Error Handling** If any step fails during a DEE operation (e.g. material not found, insufficient durable positions, missing mandatory input), the operation is considered failed and an error is returned to the equipment. **Bypass Condition** If `UseFujiToHandleScreen`, `UseFujiToHandleSqueegee` or `UseFujiToHandleBackupBlock` is set to `False` or is not defined in `IoTMetadataDefinition`, the respective DEE call is bypassed entirely and no MES operation is performed. ### Assumptions The `IoTMetadataDefinition` Smart Table must be configured with the following entries for each station: | Resource | ResourceType | Area | Name | Value | | --------------------------- | ------------ | -------------- | ----------------------- | ----- | | | | Fuji Line Area | FUJI_LineNameMachineName_{EquipmentLineName}_{EquipmentMachineName} | MES ResourceName | | MES Fuji Station X Resource | | | UseFujiToHandleScreen | True | | MES Fuji Station X Resource | | | UseFujiToHandleSqueegee | True | | MES Fuji Station X Resource | | | UseFujiToHandleBackupBlock | True |