Using ERP-Scale’s built in web-server, a weighing-meter (or progress bar) can be displayed in the PI-Sheet. This is idea for use when dispensing materials.
- Does not require an OPC server
- Does not require SAP Plant Connectivity (PCo)
- This works with any scale (with a PC interface)
The progress bar is used to indicate to the operator if the weight is within the target range, however there is no validation that the actual weight falls within allowed tolerances. This validation functionality must be added to the PI-Sheet before it is used in a productive environment.
- Install the latest version of ERP-Scale (Version 4.0.1 build B13.A14 or later).
- Connect the scale to the PC and define the communication settings (see ERP-Scale user manual)
- Get a trial licence for ERP-Scale
Add data-fields to the parsing settings in ERP-Scale
Data-fields are used to write the target values from SAP ODA.
In ERP-Scale, create the following data-fields on the Data parsing page :
Also, create the following mapping of the data-fields WEIGHT and UNIT on the HUPAST tab:
Activate ERP-Scale’s web-server and define the HTML and JSON templates
The web-server built in to ERP-Scale is used to display the weighing progress bar in the PI-Sheet. First activate the web-server using the ERP-Scale configuration utility:
To display the progress bar in the PI-Sheet, ERP-Scale requires 2 web-templates:
- BAR – Type text/html used to display the weighing progress bar
- JSON – Type text/json
The content of each template is defined below:
“weight” : “[%Weight%] “,
“unit” : “[%Unit%]”,
“text” : “[%request_text%]”,
“tweight” : “[%target_weight%]”,
“tunit” : “[%target_unit%]”,
“tmin” : “[%target_min%]”,
“tmax” : “[%target_max%]”,
“thigh” : “[%target_tol_high%]”,
“tlow” : “[%target_tol_low%]”
At this stage you can test the ERP-Scale web-server templates.
Using Internet Explorer (use IE as this is what the SAP GUI uses, do not use Chrome) to browse to:
Create an OPC server for ERP-Scale in SAP ODA
ERP-Scale uses an RFC destination to communicate with SAP ODA. To create the RFC destination in SAP follow these steps:
- in the SAP IMG, select the task “Define RFC Destination for SAP ODA”
- Create a new TCP/IP connection:
Add Data Access Items for the target weight in SAP ODA
The PI-Sheet use ODA to communicate with ERP-Scale. Data access items are required to write the target values (weight, unit and tolerances) and read the actual weight and unit.
Use transaction COOPC1 to add new ODA data access items.
The data access item SCALE_ACTUAL_WEIGHT is used to read the actual weight from ERP-Scale. It is mapped to the data-field WEIGHT as follows:
The data access item SCALE_ACTUAL_UNIT is used to read the current unit from ERP-Scale. It is mapped to the data-field UNIT as follows:
- SCALE_REQUEST_TEXT mapped to SCALE.REQUEST_TEXT
- SCALE_TARGET mapped to SCALE.TARGET_WEIGHT
- TARGET_UNIT mapped to SCALE.TARGET_UNIT
- SCALE_TOLERANCE_LOW mapped to SCALE.TARGET_TOLERANCE_LOW
- SCALE_TOLERANCE_HIGH mapped to SCALE.TARGET_TOLERANCE_HIGH
Create two new PI characteristics in SAP
In the prototype the PI-Characteristics Z_ES_TOLERANCE_LOW and Z_ES_TOLERANCE_HIGH are used to define the under and over tolerance (as a factor, e.g. 0.1 = 10%). The prototype PI-Sheet uses fixed values, however material specific tolerances could be determined using a function module.
Create the following PI-Characteristics using transaction O25C:
Create a General Process Instruction Category
The table that displays the material list in the PI-Sheet is defined as a Process Instruction Category (General) in SAP.
Use transaction O12C to create a new category:
See the attached Excel workbook for the required PI-Instructions. The low and high tolerances are defined in lines 130 and 140.
Assign the Process instruction category to the control recipe destination
The newly created process instruction category must be assigned to the control recipe destination using transaction O10C.
Add process instructions for the weighing bar to the master recipe
In the master receipe, add process instructions to display the progress bar. Use transaction C202:
The long-text of the PPPI_LAYOUT (0002) is as follows:
The text is below: