Merged PR 15381: EPP BioRad Data Import BugFix

This commit is contained in:
Ouellette Jonathan (CSC FI SPS MESLEO) 2025-04-21 22:26:15 +02:00
parent e0b3557068
commit d626ebdf3c

View File

@ -98,7 +98,7 @@ Declare function SRP_Sort_Array, Metrology_Services, obj_RDS_Test, obj_Test_P
Declare function Work_Order_Services, SRP_JSON, Logging_Services, Environment_Services, SRP_Trim, Min, Max
Declare function QA_Services, SRP_Join_Arrays, Get_Status, Obj_Clean_Insp, Datetime, SRP_Datetime
Declare function Httpclient_Services, PM_Services, Signature_Services, SRP_Array, Math_Services
Declare function Tool_Class_Services
Declare function Tool_Class_Services, obj_wo_mat
LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\Metrology'
LogDate = Oconv(Date(), 'D4/')
@ -567,6 +567,7 @@ Service ImportStratusData(RunData)
Slots = WOMatQARec<WO_MAT_QA_SLOT$>
SpecQty = WOMatQARec<WO_MAT_QA_WFR_QTY$>
pPos = ''
WOMatSlotProfile = obj_WO_Mat('SlotWaferIDs',WOMatKey:@RM:WOMatRec)
For each Profile in Profiles using @VM setting pPos
Stage = Stages<0, pPos>
If ( (Profile EQ '1ADE') and ( (Stage EQ 'QA') or (Stage EQ 'MO_QA') ) ) then
@ -581,9 +582,15 @@ Service ImportStratusData(RunData)
end
Begin Case
Case Slot EQ '1'
WaferIndex = 1
For WaferIndex = 1 to 25
SlotIsEmpty = WOMatSlotProfile<1, WaferIndex> EQ ''
Until SlotIsEmpty EQ False$
Next WaferIndex
Case Slot EQ 'L'
WaferIndex = 25
For WaferIndex = 25 to 1 Step -1
SlotIsEmpty = WOMatSlotProfile<1, WaferIndex> EQ ''
Until SlotIsEmpty EQ False$
Next WaferIndex
Case Slot EQ 'A'
WaferIndex = 1
Case Otherwise$
@ -2221,8 +2228,26 @@ Service RemoveOldMetrology()
end service
Service ImportBioRadEPPFQAData(RunData, FileName)
/*
ImportBioRadEPPFQAData
Modified and annotated by JRO 4/18/2025
Written to import data specifically for EpiPro QA/FQA Thickness.
Note: Due to the nature of the forms used to validate EpiPro FQA, we currently only support single value data import.
If we wish to extend this to multi value data import than we need to write the values with Sub Value Marks at the Value Mark position of the test profile.
Then we also need to modify the form usage to support parsing those multi-values.
I am leaving the iterating methods in here with the possibility that we can extend this to support multi valued data should the business need it.
This service requires the following parameters:
1. RunData, The internal delimited run data from the parent calling routine ImportBioRadData.
The service does the following actions:
1. Parses through the run data to extract the WMO Lot id, reactor id, recipe id, and slot id.
2. Writes the data point to the slot position in the WM_OUT record - > MU_WAFER_THK_RESULT field, for all wafers whether they are MU wafers or not.
This allows us to detect that Any and all MU wafers have thickness data.
3. Reads the WO_MAT_QA record.
4. Iterates through WO_MAT_QA record -> PROFILE fields @VM values, IF the profile is 1ADE, or QA, or MO_QA then
5. Determines the spec slot by reading the WO_MAT_QA record -> SLOT field
6. If the detected RunDataSlot matches the spec slot, writes the datapoint to the WO_MAT_QA record - > RESULT field in the same @VM that the iterator is currently set to.
*/
Service ImportBioRadEPPFQAData(RunData)
Timestamp = RunData<2>
WMOKeyID = RunData<6>
@ -2232,12 +2257,15 @@ Service ImportBioRadEPPFQAData(RunData, FileName)
RunDataLayer = RunData<8>
ReactorID = RunData<5>
ScanRecipe = RunData<4>
DataSlotId = RunData<11>
DataSlotId = SRP_Trim(DataSlotId, 'F', 0)
FieldPos = 13
FieldPosIncrement = 2
Offset = 1
Decimals = 2
Positions = ''
DataPoints = ''
WMORec = Database_Services('ReadDataRow', 'WM_OUT', WMOKeyID)
WOMatQAKey = Field(WMOKeyID, '*', 1) : '*' : Field(WMOKeyID, '*', 3)
Loop
@ -2257,9 +2285,7 @@ Service ImportBioRadEPPFQAData(RunData, FileName)
Metrology_Services('LogResults', RDSNo@, Machine, 'UID001', Service : ' : ' : Error_Services('GetMessage'))
end
//Update the WM_OUT record for EpiPro
for each wafer in Positions using @VM setting dPos
WMORec<WM_OUT_MU_WAFER_THK_RESULT$, wafer> = DataPoints<0, dPos>
Next wafer
WMORec<WM_OUT_MU_WAFER_THK_RESULT$, DataSlotId> = DataPoints
Database_Services('WriteDataRow', 'WM_OUT', WMOKeyID, WMORec, True$, False$, True$)
end else
Metrology_Services('LogResults', RDSNo@, Machine, 'UID001', Service : ' : ' : Error_Services('GetMessage'))
@ -2279,18 +2305,27 @@ Service ImportBioRadEPPFQAData(RunData, FileName)
Stage = Stages<0, pPos>
If ( (Profile EQ '1ADE') and ( (Stage EQ 'QA') or (Stage EQ 'MO_QA') ) ) then
Slot = Slots<0, pPos>
//There is a specific scenario where when the spec wafers are 1 and L, and there is a makeup wafer in each of the first and last slots, they would then want to
//measure the next open slot, either incremented down from the last wafer position or incremented up from the first wafer position.
//We may need to add that in when the definition becomes clearer.
Begin Case
Case Slot EQ '1'
WaferIndex = 1
For WaferIndex = 1 to 25
SlotIsEmpty = Database_Services('ReadDataColumn', 'WM_OUT', WMOKeyID, WM_OUT_RDS$, True$, 0, False$)<1, WaferIndex> EQ ''
Until SlotIsEmpty EQ False$
Next WaferIndex
Case Slot EQ 'L'
WaferIndex = 25
For WaferIndex = 25 to 1 Step -1
SlotIsEmpty = Database_Services('ReadDataColumn', 'WM_OUT', WMOKeyID, WM_OUT_RDS$, True$, 0, False$)<1, WaferIndex> EQ ''
Until SlotIsEmpty EQ False$
Next WaferIndex
Case Slot EQ 'A'
WaferIndex = 1
Case Otherwise$
WaferIndex = Slot
End Case
Locate WaferIndex in Positions using @VM setting dPos then
WOMatQARec<WO_MAT_QA_RESULT$, pPos> = DataPoints<0, dPos>
If DataSlotId EQ WaferIndex then
WOMatQARec<WO_MAT_QA_RESULT$, pPos> = DataPoints
end
end
Next Profile
@ -2967,3 +3002,4 @@ LoadRunDataToDatabase:
return