Compare commits

...

34 Commits

Author SHA1 Message Date
51da9ef7c2 http, hurl for api testing
txt for metrology proof

settings for vscode
2025-08-21 11:28:11 -07:00
722bc63bdb Changed VOID and PACKAGING LOT_EVENTS to COMMENT type events. Modified code to only add them if lot is in new LOT table. 2025-08-20 16:27:11 -07:00
1f2777cd18 Updated service to pass in a user id when placing a lot on hold 2025-08-20 15:29:52 -07:00
10bf8bf878 Consolidated OPEN to LOT_START. Consolidated INCREASE_WAFER_QTY to BONUS_WAFER_QTY. Fixed bug in Lot_Services. Fixed bug in Copy_Lot_Operation_Record_To_SQL. 2025-08-20 15:22:48 -07:00
1a572a31b2 modified legacy lot operation logging to be per lot instead of per date and legacy operation 2025-08-20 10:42:18 -07:00
098f740585 Removed lot events for non-epipro RDS lots in lieu of logging 2025-08-20 17:09:10 +00:00
89bb3e479b Reworded the error to be inclusive of all missing metrology results from WO_MAT_QA record 2025-08-18 15:01:04 -07:00
60522d74c1 Improvements suggested by Daniel. 2025-08-18 19:14:49 +00:00
3561b41a7b Resolve rebase oddities. 2025-08-18 19:14:49 +00:00
a636198128 Create new services.
Commit to switch branches.

Fix error text.

Fixed CassetteID variable typo.

Commit final changes.
2025-08-18 19:14:49 +00:00
adc247fd4c added CHRON_ID to LOT_EVENT table to have a sequential integer for debugging 2025-08-18 09:25:34 -07:00
a094971d7d ErrorMsg wasn't initialized. Added initialization at the top of the service 2025-08-18 01:42:35 +00:00
47b54f6a16 Had an instance of an RDS being deleted. Looking into root cause. Interim fix including blocking ALL RDS deletions. 2025-08-17 17:51:09 -07:00
804258a167 Mona_Services was interferring with error checking and returning. Used buffered error message to return and error properly 2025-08-15 17:44:26 -07:00
6d552ab824 Added error checking to scan_services to check for null wo_mat records 2025-08-15 17:27:29 -07:00
2fbf41d528 re-order the error checking 2025-08-16 00:22:07 +00:00
ba2faa8c9f Found most likely root cause of WO_MAT records getting cleared at 1UNLOAD. 2025-08-16 00:22:07 +00:00
0a2d53d173 added delete from sql routines for LOT_EVENT and related tables 2025-08-15 14:37:27 -07:00
844de71599 removed temporary 1D scan allowance that was in place to exhaust existing inventory with old labels 2025-08-14 16:51:30 -07:00
494988d394 Restored obj_RDS('MetPropFlag') to previous version for performance reasons. Refactored Supplement_Services to improve performance. 2025-08-14 13:15:21 -07:00
e1c7544fac Fixed bug for new PSN stage met tests 2025-08-14 15:58:52 +00:00
6d5c9c0ab7 removed code to add LOT_EVENT records for legacy WO_MAT log events 2025-08-13 16:31:38 -07:00
a8dff61cfa Enhanced Error Checking 2025-08-13 21:54:33 +00:00
09d2d13e63 Created methods to provide Metrology Services with JSON source for SLL Section 2025-08-13 21:54:33 +00:00
14331fcf49 Added in missing Lot Operation Id to event records 2025-08-13 20:28:59 +00:00
667831a003 added support for mestsa024ec 2025-08-13 12:25:34 -07:00
82b74f0b96 Enable BioRad Stratus pdsf usage 2025-08-13 09:41:52 -07:00
f4f63c28e3 Added JSON body and response logging to CreateNewOrder service. Modified how reactor log comments are added for ABORT_ALARM NICA orders. Modified ABORT_ALARM solution to not trigger on WAITING_FOR_MAINTENANCE_UNSCHEDULED 2025-08-12 16:24:12 -07:00
1f2b73797b Enable BioRad pdsf usage 2025-08-12 07:52:13 -07:00
54eaf15598 Increased the MAX_NUM_CASS$ equate to 150 as we have a workorder with more than 96 WO_MAT ID's 2025-08-08 11:44:44 -07:00
fffadaa1c3 Found that the location of the cassettes being added were first being sorted in an ascending order within a LOCATE loop. 2025-08-07 14:55:21 -07:00
a6da80dc3c Revert "Created temporary workarounds to QA Metrology not getting set correctly." 2025-08-07 18:07:28 +00:00
3125225639 Created temporary workarounds to QA Metrology not getting set correctly. 2025-08-06 16:20:43 -07:00
f54331eb0e Fixed HgCV frequency bug 2025-08-05 12:46:25 -07:00
46 changed files with 1270 additions and 3798 deletions

1
.gitignore vendored
View File

@ -1,3 +1,4 @@
LSL2/STPROC/TEST_DANIEL*.txt LSL2/STPROC/TEST_DANIEL*.txt
LSL2/STPROC/TEST_DAKOTA.txt LSL2/STPROC/TEST_DAKOTA.txt
LSL2/STPROC/JONATHAN_SERVICES.txt LSL2/STPROC/JONATHAN_SERVICES.txt
LSL2/STPROC/CHASE_SERVICES.txt

16
.vscode/.http vendored Normal file
View File

@ -0,0 +1,16 @@
###
GET https://messa020ec.infineon.com/api/oiWizard/reactors
Accept: application/json
###
GET https://messa020ec.infineon.com/api/oiWizard/materials/rds/1000416
Accept: application/json
###
GET https://oi-metrology-viewer-prod.mes.infineon.com/api/InfinityQSV3/1750770474/header
Accept: application/json
###

29
.vscode/.hurl vendored Normal file
View File

@ -0,0 +1,29 @@
###
GET https://messa020ec.infineon.com/api/oiWizard/reactors
Accept: application/json
HTTP 200
[Asserts]
header "Content-Type" == "application/hal+json"
###
GET https://messa020ec.infineon.com/api/oiWizard/materials/rds/1000416
Accept: application/json
HTTP 200
[Asserts]
header "Content-Type" == "application/hal+json"
###
GET https://oi-metrology-viewer-prod.mes.infineon.com/api/InfinityQSV3/1750770474/header
Accept: application/json
HTTP 200
[Asserts]
header "Content-Type" == "application/json; charset=utf-8"
jsonpath "$.TotalRows" == 1
###

234
.vscode/.txt vendored Normal file
View File

@ -0,0 +1,234 @@
// T:\met08resisrp2100\06_SourceCode\met08resisrp2100\Adaptation\FileHandlers\OpenInsight\FileRead.cs
// x.Date // 001
// x.Employee // 002
// x.Recipe // 003
// x.Reactor // 004
// x.RDS // 005
// x.PSN // 006
// x.Layer // 007
// x.Zone // 008
// T:\met08anlysdifaast230\06_SourceCode\met08anlysdifaast230\Adaptation\FileHandlers\OpenInsight\FileRead.cs
// x.PSN // 001
// x.Reactor // 002
// logistics.MesEntity // 003
// x.RDS // 004
// x.Recipe // 005
// x.Employee // 006
// x.SlotNumber // 007
// T:\met08thftirstratus\06_SourceCode\met08thftirstratus\Adaptation\FileHandlers\OpenInsight\FileRead.cs
// "Stratus_" // 001
// x.Date // 002
// logistics.JobID // 003
// "FQA Thickness" // 004
// x.Employee // 005
// x.Recipe // 006
// x.Reactor // 007
// x.RDS // 008
// x.PSN // 009
// x.Lot // 010
// x.Cassette // 011
// x.MeanThickness // 012
// descriptions[i].Slot // 013
// descriptions[i].Mean // 014
// T:\met08thftirqs408m\06_SourceCode\met08thftirqs408m\Adaptation\FileHandlers\OpenInsight\FileRead.cs
// Bio-Rad UniqueId // 001
// Date // 002
// ThicknessFourteenCriticalPointsAverage // 003
// Recipe // 004
// Reactor // 005
// RDS // 006
// PSN // 007
// Layer // 008
// Zone // 009
// Cassette // 010
// Wafer // 011
// RVThickness // 012
// Position // 013
// Thickness // 014
// T:\met08resimapcde\06_SourceCode\met08resimapcde\Adaptation\FileHandlers\OpenInsight\FileRead.cs
// x.UniqueId // 001
// x.Run // 002
// x.Date // 003
// x.Lot // 004
// x.Recipe // 005
// x.Reactor // 006
// x.RDS // 007
// x.PSN // 008
// x.Layer // 009
// x.Zone // 010
// logistics.MesEntity // 011
// x.Employee // 012
// x.Engineer // 013
// x.DLRatio // 014
// x.Temp // 015
// x.AutoOptimizeGain // 016
// x.AutoProbeHeightSet // 017
// x.DataReject // 018
// x.FileName // 019
// x.Avg // 020
// x.StdDev // 021
// x.SemiRadial // 022
// description.Pt // 023
// description.R // 024
// description.T // 025
// description.Rs // 026
// description.Merit // 027
// T:\met08resihgcv\06_SourceCode\met08resihgcv\Adaptation\FileHandlers\OpenInsight\FileRead.cs
// x.UniqueId // 001
// logistics.MesEntity // 002
// x.Reactor // 003
// x.RDS // 004
// x.PSN // 005
// x.Layer // 006
// x.Zone // 007
// x.Wafer // 008
// x.Lot // 009
// x.Plan // 010
// x.Date // 011
// x.WaferSize // 012
// x.Ccomp // 013
// x.Area // 014
// x.CondType // 015
// x.Model // 016
// x.StartVoltage // 017
// x.StopVoltage // 018
// x.RampRate // 019
// x.GLimit // 020
// x.SetupFile // 021
// x.SetupFile // 022
// x.Folder // 023
// x.Pattern // 024
// x.RhoMethod // 025
// x.NAvgMean // 026
// x.NAvgStdDev // 027
// x.NAvgRadialGradient // 028
// x.NslMean // 029
// x.NslStdDev // 030
// x.NslRadialGradient // 031
// x.VdMean // 032
// x.VdStdDev // 033
// x.VdRadialGradient // 034
// x.FlatZMean // 035
// x.FlatZStdDev // 036
// x.FlatZRadialGradient // 037
// x.RhoAvgMean // 038
// x.RhoAvgStdDev // 039
// x.RhoAvgRadialGradient // 040
// x.RhoslMean // 041
// x.RhoslStdDev // 042
// x.RhoslRadialGradient // 043
// x.PhaseMean // 044
// x.PhaseStdDev // 045
// x.PhaseRadialGradient // 046
// x.GradeMean // 047
// x.GradeStdDev // 048
// x.GradeRadialGradient // 049
// x.RsMean // 050
// x.RsStdDev // 051
// x.RsRadialGradient // 052
// description.Index // 053
// description.NAvg // 054
// description.Nsl // 055
// description.Vd // 056
// description.FlatZ // 057
// description.RhoAvg // 058
// description.Rhosl // 059
// description.Phase // 060
// description.Grade // 061
// T:\met08ddupsfs6420\06_SourceCode\met08ddupsfs6420\Adaptation\FileHandlers\OpenInsight\FileRead.cs
// x.AreaCountAvg // 001 - AreaCountAvg
// x.AreaCountMax // 002 - AreaCountMax
// x.AreaCountMin // 003 - AreaCountMin
// x.AreaCountStdDev // 004 - AreaCountStdDev
// x.AreaTotalAvg // 005 - AreaTotalAvg
// x.AreaTotalMax // 006 - AreaTotalMax
// x.AreaTotalMin // 007 - AreaTotalMin
// x.AreaTotalStdDev // 008 - AreaTotalStdDev
// x.Date // 009 -
// x.HazeAverageAvg // 010 - Haze Average
// x.HazeAverageMax // 011 -
// x.HazeAverageMin // 012 -
// x.HazeAverageStdDev // 013 -
// x.HazeRegionAvg // 014 -
// x.HazeRegionMax // 015 -
// x.HazeRegionMin // 016 -
// x.HazeRegionStdDev // 017 -
// x.Lot // 018 -
// x.LPDCM2Avg // 019 -
// x.LPDCM2Max // 020 -
// x.LPDCM2Min // 021 -
// x.LPDCM2StdDev // 022 -
// x.LPDCountAvg // 023 -
// x.LPDCountMax // 024 -
// x.LPDCM2Min // 025 -
// x.LPDCountStdDev // 026 -
// x.Employee // 027 -
// x.RDS // 028 - Lot
// x.Reactor // 029 - Process
// x.Recipe // 030 - Part
// x.ScratchCountAvg // 031 - Scratch Count
// x.ScratchCountMax // 032 -
// x.ScratchCountMin // 033 -
// x.ScratchTotalStdDev // 034 -
// x.ScratchTotalAvg // 035 - Scratch Length
// x.ScratchTotalMax // 036 -
// x.ScratchTotalMin // 037 -
// x.ScratchTotalStdDev // 038 -
// x.SumOfDefectsAvg // 039 - Average Sum of Defects
// x.SumOfDefectsMax // 040 - Max Sum of Defects
// x.SumOfDefectsMin // 041 - Min Sum of Defects
// x.SumOfDefectsStdDev // 042 - SumOfDefectsStdDev
// logistics.MesEntity // 043 -
// T:\met08ddupsp1tbi\06_SourceCode\met08ddupsp1tbi\Adaptation\FileHandlers\OpenInsight\FileRead.cs
// x.DcnLpdMin // 001 -
// x.DcnLpdMax // 002 -
// x.DcnLpdMean // 003 - DCN LPD
// x.DcnAreaCountMin // 004 -
// x.DcnAreaCountMax // 005 -
// x.DcnAreaCountMean // 006 - DCN Area
// x.DcnAreaMin // 007 -
// x.DcnAreaMax // 008 -
// x.Date // 009 -
// x.DcnHazeAvgMean // 010 - Haze Average
// string.Empty // 011 -
// string.Empty // 012 -
// string.Empty // 013 -
// string.Empty // 014 -
// string.Empty // 015 -
// string.Empty // 016 -
// string.Empty // 017 -
// string.Empty // 018 -
// string.Empty // 019 -
// string.Empty // 020 -
// string.Empty // 021 -
// string.Empty // 022 -
// string.Empty // 023 -
// string.Empty // 024 -
// string.Empty // 025 -
// string.Empty // 026 -
// string.Empty // 027 -
// x.RDS // 028 - Lot
// x.Reactor // 029 - Process
// x.Recipe // 030 - Part
// x.DcnScrMean // 031 - Scratch Count
// string.Empty // 032 -
// string.Empty // 033 -
// string.Empty // 034 -
// x.DcnMicroScrMean // 035 - Scratch Length
// string.Empty // 036 -
// string.Empty // 037 -
// string.Empty // 038 -
// x.DcnAllMean // 039 - Average Sum of Defects
// x.DcnAllMax // 040 - Max Sum of defects
// x.DcnAllMin // 041 - Min Sum of Defects
// string.Empty // 042 -
// logistics.MesEntity // 043 -
// x.DcnAreaMean // 044 - DCN MM2

6
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,6 @@
{
"files.associations": {
"*.txt": "vb",
},
"cSpell.words": []
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -9,7 +9,7 @@ COMPILE FUNCTION Comm_PRS_Stage(EntID,Event,Parm1,Parm2,Parm3,Parm4,Parm5)
DECLARE SUBROUTINE Set_Property, Set_Status, ErrMsg, Set_Property, obj_AppWindow, Send_Event, Security_Err_Msg DECLARE SUBROUTINE Set_Property, Set_Status, ErrMsg, Set_Property, obj_AppWindow, Send_Event, Security_Err_Msg
DECLARE SUBROUTINE Send_Message, Btree.Extract, Comm_Prod_Spec, Forward_Event, Post_Event DECLARE SUBROUTINE Send_Message, Btree.Extract, Comm_Prod_Spec, Forward_Event, Post_Event
DECLARE FUNCTION Get_Property, Get_Status, Popup, Send_Message, Msg, Start_Window, MemberOf, Security_Check DECLARE FUNCTION Get_Property, Get_Status, Popup, Send_Message, Msg, Start_Window, MemberOf, Security_Check
DECLARE FUNCTION Comm_Prod_Spec DECLARE FUNCTION Comm_Prod_Spec, obj_Popup
$INSERT POPUP_EQUATES $INSERT POPUP_EQUATES
@ -192,7 +192,6 @@ NEXT I
Send_Message(@WINDOW:'.MET_TEST','COLFORMAT',COL$MET_PROP,PropCodes) Send_Message(@WINDOW:'.MET_TEST','COLFORMAT',COL$MET_PROP,PropCodes)
* Class Tools is set in the POSCHANGED event for the edit table. * Class Tools is set in the POSCHANGED event for the edit table.
/* /*
@ -235,6 +234,23 @@ Read:
GOSUB Refresh GOSUB Refresh
* Met Property Descriptions *
PSNo = Get_Property(@WINDOW : '.PS_NO', 'TEXT')
Stage = Get_Property(@WINDOW:'.STAGE','DEFPROP')
Props = Xlate('PRS_STAGE', PSNo:'*':Stage, PRS_STAGE_MET_PROP$, 'X')
PropDescs = obj_Popup('CodeDesc','MET_PROPERTY':@RM:Props)
CtrlEntID = @WINDOW:'.MET_TEST'
DescCount = DCount(PropDescs, @VM)
FOR Row = 1 to DescCount
PropDesc = PropDescs<1, Row>
Set_Property(CtrlEntId,"CELLPOS",PropDesc,COL$MET_PROP_DESC:@FM:Row)
Next Row
RETURN RETURN
@ -764,6 +780,12 @@ BEGIN CASE
RETURN RETURN
CASE CurrCol = COL$MET_PROP_DESC
PropCode = CurrLine<1,COL$MET_PROP>
DefProp = obj_Popup('CodeDesc','MET_PROPERTY':@RM:PropCode)
CASE CurrCol = COL$MET_MIN AND CurrLine<1,COL$MET_MIN> = '' CASE CurrCol = COL$MET_MIN AND CurrLine<1,COL$MET_MIN> = ''
MetTest = CurrLine<1,COL$MET_TEST> MetTest = CurrLine<1,COL$MET_TEST>
@ -1229,3 +1251,4 @@ return

View File

@ -2015,7 +2015,7 @@ HoldClick:
HoldData = Dialog_Box('DIALOG_HOLD',@WINDOW,Transition:@FM:@FM:HoldType:@FM:Stage:@FM:Interrupted) HoldData = Dialog_Box('DIALOG_HOLD',@WINDOW,Transition:@FM:@FM:HoldType:@FM:Stage:@FM:Interrupted)
If HoldData NE 'Cancel' then If HoldData NE 'Cancel' then
Hold_Services('ToggleHold', WOMatKey, HoldEntity, HoldEntityID, CtrlEnt, '', HoldData, '') Hold_Services('ToggleHold', WOMatKey, HoldEntity, HoldEntityID, CtrlEnt, '', HoldData, @User4)
IF Error_Services("HasError") THEN IF Error_Services("HasError") THEN
ErrCode = Error_Services("GetMessage") ErrCode = Error_Services("GetMessage")
ErrMsg(errCode) ErrMsg(errCode)

View File

@ -434,7 +434,7 @@ RejMat:
WfrID = SlotList<SelectedRows<I>, COL$WAFER_ID> WfrID = SlotList<SelectedRows<I>, COL$WAFER_ID>
PrevNCR = SlotList<SelectedRows<I>, COL$SLOT_NCR> PrevNCR = SlotList<SelectedRows<I>, COL$SLOT_NCR>
MUWfrID = SlotList<SelectedRows<I>, COL$MU_WAFER_ID> MUWfrID = SlotList<SelectedRows<I>, COL$MU_WAFER_ID>
If (WfrId EQ '') then If (WfrID EQ '') then
AllSlotsPermitted = False$ AllSlotsPermitted = False$
IneligibleSlots<0, -1> = SlotNo IneligibleSlots<0, -1> = SlotNo
end end
@ -1233,3 +1233,7 @@ LogRecord:
return return

View File

@ -32,7 +32,8 @@ DataFields := "EVENT_BEGIN_WAFER_QTY" :@VM:SQL_Format(Rec(LOT_EVENT_EVENT_BEGIN
DataFields := "EVENT_END_WAFER_QTY" :@VM:SQL_Format(Rec(LOT_EVENT_EVENT_END_WAFER_QTY$), "INT"):@FM DataFields := "EVENT_END_WAFER_QTY" :@VM:SQL_Format(Rec(LOT_EVENT_EVENT_END_WAFER_QTY$), "INT"):@FM
DataFields := "EVENT_OPERATION_ID" :@VM:SQL_Format(Rec(LOT_EVENT_EVENT_OPERATION_ID$), "STR"):@FM DataFields := "EVENT_OPERATION_ID" :@VM:SQL_Format(Rec(LOT_EVENT_EVENT_OPERATION_ID$), "STR"):@FM
DataFields := "EVENT_OPERATOR_ID" :@VM:SQL_Format(Rec(LOT_EVENT_EVENT_OPERATOR_ID$), "STR"):@FM DataFields := "EVENT_OPERATOR_ID" :@VM:SQL_Format(Rec(LOT_EVENT_EVENT_OPERATOR_ID$), "STR"):@FM
DataFields := "SEQUENCE" :@VM:SQL_Format(Rec(LOT_EVENT_SEQUENCE$), "INT") DataFields := "SEQUENCE" :@VM:SQL_Format(Rec(LOT_EVENT_SEQUENCE$), "INT"):@FM
DataFields := "CHRON_ID" :@VM:SQL_Format(Rec(LOT_EVENT_CHRON_ID$), "INT")
// Symbolics // Symbolics
@ -43,3 +44,4 @@ Ans = SQL_Write(Connection, "LOT_EVENT", Keys, DataFields);
// Multi-valued Fields // Multi-valued Fields
Return Ans Return Ans

View File

@ -14,7 +14,7 @@ Declare function SQL_Write, SQL_Write_MV, SQL_Format
Ans = "" Ans = ""
// Parse record into a dimensioned array for speed // Parse record into a dimensioned array for speed
Dim Rec(24) Dim Rec(25)
MatParse Record into Rec MatParse Record into Rec
// List of key names and their values // List of key names and their values
@ -54,3 +54,4 @@ Ans = SQL_Write(Connection, "LOT_OPERATION", Keys, DataFields);
// Multi-valued Fields // Multi-valued Fields
Return Ans Return Ans

View File

@ -0,0 +1,30 @@
Compile function Delete_LOT_EVENT_Record_From_SQL(Connection, Key, Record)
/*****************************************************************************\
Deletes the given LOT_EVENT record from the MSSQL database.
History
-------
08/15/2025 DJS Original Programmer
\*****************************************************************************/
Declare function SQL_Delete, SQL_Format
Ans = ""
// List of key names and their values
Keys = "LOT_EVENT_ID":@VM:SQL_Format(Key, "STR")
//-------------------------------------------------------------------------------------------------
// Multi-valued Fields
!! Delete records from MV tables first !!
// Currently no multi-value (child) tables
// LOT_EVENT
If Ans EQ "" then
Ans = SQL_Delete(Connection, "LOT_EVENT", Keys)
end
Return Ans

View File

@ -0,0 +1,30 @@
Compile function Delete_LOT_EVENT_TYPE_Record_From_SQL(Connection, Key, Record)
/*****************************************************************************\
Deletes the given LOT_EVENT_TYPE record from the MSSQL database.
History
-------
08/15/2025 DJS Original Programmer
\*****************************************************************************/
Declare function SQL_Delete, SQL_Format
Ans = ""
// List of key names and their values
Keys = "LOT_EVENT_TYPE_ID":@VM:SQL_Format(Key, "STR")
//-------------------------------------------------------------------------------------------------
// Multi-valued Fields
!! Delete records from MV tables first !!
// Currently no multi-value (child) tables
// LOT_EVENT_TYPE
If Ans EQ "" then
Ans = SQL_Delete(Connection, "LOT_EVENT_TYPE", Keys)
end
Return Ans

View File

@ -0,0 +1,30 @@
Compile function Delete_LOT_OPERATION_Record_From_SQL(Connection, Key, Record)
/*****************************************************************************\
Deletes the given LOT_OPERATION record from the MSSQL database.
History
-------
08/15/2025 DJS Original Programmer
\*****************************************************************************/
Declare function SQL_Delete, SQL_Format
Ans = ""
// List of key names and their values
Keys = "LOT_OPERATION_ID":@VM:SQL_Format(Key, "STR")
//-------------------------------------------------------------------------------------------------
// Multi-valued Fields
!! Delete records from MV tables first !!
// Currently no multi-value (child) tables
// LOT_OPERATION
If Ans EQ "" then
Ans = SQL_Delete(Connection, "LOT_OPERATION", Keys)
end
Return Ans

View File

@ -0,0 +1,30 @@
Compile function Delete_LOT_Record_From_SQL(Connection, Key, Record)
/*****************************************************************************\
Deletes the given LOT record from the MSSQL database.
History
-------
08/15/2025 DJS Original Programmer
\*****************************************************************************/
Declare function SQL_Delete, SQL_Format
Ans = ""
// List of key names and their values
Keys = "LOT_ID":@VM:SQL_Format(Key, "STR")
//-------------------------------------------------------------------------------------------------
// Multi-valued Fields
!! Delete records from MV tables first !!
// Currently no multi-value (child) tables
// LOT
If Ans EQ "" then
Ans = SQL_Delete(Connection, "LOT", Keys)
end
Return Ans

View File

@ -0,0 +1,30 @@
Compile function Delete_OPERATION_Record_From_SQL(Connection, Key, Record)
/*****************************************************************************\
Deletes the given OPERATION record from the MSSQL database.
History
-------
08/15/2025 DJS Original Programmer
\*****************************************************************************/
Declare function SQL_Delete, SQL_Format
Ans = ""
// List of key names and their values
Keys = "OPERATION_ID":@VM:SQL_Format(Key, "STR")
//-------------------------------------------------------------------------------------------------
// Multi-valued Fields
!! Delete records from MV tables first !!
// Currently no multi-value (child) tables
// OPERATION
If Ans EQ "" then
Ans = SQL_Delete(Connection, "OPERATION", Keys)
end
Return Ans

View File

@ -84,7 +84,7 @@ Service IsProd()
Machine = Environment_Services('GetServer') Machine = Environment_Services('GetServer')
IsProd = False$ IsProd = False$
If Machine _NEC "messa012" and Machine _NEC "mestsa01ec" and Machine _NEC "mestsa09ec" and Machine _NEC "mestsa010ec" and Machine _NEC "mestsa011ec" and Machine _NEC "mestsa012ec" and Machine _NEC "MESTST1010" and Machine _NEC "MESTST1009" then If Machine _NEC "messa012" and Machine _NEC "mestsa01ec" and Machine _NEC "mestsa09ec" and Machine _NEC "mestsa010ec" and Machine _NEC "mestsa011ec" and Machine _NEC "mestsa012ec" and Machine _NEC "mestsa024ec" and Machine _NEC "MESTST1010" and Machine _NEC "MESTST1009" then
IsProd = True$ IsProd = True$
end end
Response = IsProd Response = IsProd
@ -123,6 +123,7 @@ Service GetApplicationRootIP()
Case Machine EQ 'MESTSA010EC' ; ApplicationRootIP = '\\10.95.140.63' Case Machine EQ 'MESTSA010EC' ; ApplicationRootIP = '\\10.95.140.63'
Case Machine EQ 'MESTSA011EC' ; ApplicationRootIP = '\\10.95.140.64' Case Machine EQ 'MESTSA011EC' ; ApplicationRootIP = '\\10.95.140.64'
Case Machine EQ 'MESTSA012EC' ; ApplicationRootIP = '\\10.95.140.65' Case Machine EQ 'MESTSA012EC' ; ApplicationRootIP = '\\10.95.140.65'
Case Machine EQ 'MESTSA024EC' ; ApplicationRootIP = '\\10.95.140.66'
Case Machine EQ 'MESSA012' ; ApplicationRootIP = '\\10.95.176.50' Case Machine EQ 'MESSA012' ; ApplicationRootIP = '\\10.95.176.50'
Case Machine EQ 'MESST5201' ; ApplicationRootIP = '\\10.95.140.14' Case Machine EQ 'MESST5201' ; ApplicationRootIP = '\\10.95.140.14'
Case Machine EQ 'MESST5202' ; ApplicationRootIP = '\\10.95.140.14' Case Machine EQ 'MESST5202' ; ApplicationRootIP = '\\10.95.140.14'
@ -325,6 +326,7 @@ Service GetLocalRootPath()
Case Machine EQ 'MESTSA010EC' ; LocalRootPath = 'D:' Case Machine EQ 'MESTSA010EC' ; LocalRootPath = 'D:'
Case Machine EQ 'MESTSA011EC' ; LocalRootPath = 'D:' Case Machine EQ 'MESTSA011EC' ; LocalRootPath = 'D:'
Case Machine EQ 'MESTSA012EC' ; LocalRootPath = 'D:' Case Machine EQ 'MESTSA012EC' ; LocalRootPath = 'D:'
Case Machine EQ 'MESTSA024EC' ; LocalRootPath = 'D:'
Case Machine EQ 'MESST6501' ; LocalRootPath = 'C:' ; // This is a map to the user's actual C drive. Case Machine EQ 'MESST6501' ; LocalRootPath = 'C:' ; // This is a map to the user's actual C drive.
Case Machine EQ 'MESST6502' ; LocalRootPath = 'C:' ; // This is a map to the user's actual C drive. Case Machine EQ 'MESST6502' ; LocalRootPath = 'C:' ; // This is a map to the user's actual C drive.
Case Machine EQ 'MESTST1006' ; LocalRootPath = 'C:' ; // This is a map to the user's actual C drive. Case Machine EQ 'MESTST1006' ; LocalRootPath = 'C:' ; // This is a map to the user's actual C drive.

View File

@ -46,19 +46,19 @@ Compile function Hold_Services(@Service, @Params)
***********************************************************************************************************************/ ***********************************************************************************************************************/
#pragma precomp SRP_PreCompiler #pragma precomp SRP_PreCompiler
$insert LOGICAL
$Insert SERVICE_SETUP
$Insert APP_INSERTS
$Insert SERVICE_SETUP
$Insert MSG_EQUATES $Insert MSG_EQUATES
$Insert DICT_EQUATES $Insert DICT_EQUATES
$Insert WO_MAT_EQUATES $Insert WO_MAT_EQUATES
$INSERT NOTIFICATION_EQU $Insert NOTIFICATION_EQU
Declare function Database_Services, Error_Services, Obj_Wm_In, Obj_Wm_Out, Unassigned, Wm_In_Services, Wm_Out_Services Declare function Database_Services, Error_Services, Obj_Wm_In, Obj_Wm_Out, Unassigned, Wm_In_Services, Wm_Out_Services
Declare function PSN_Services, SRP_Rotate_Array, Datetime, Hold_Services, Memberof, Error_Services, Rds_Services Declare function PSN_Services, SRP_Rotate_Array, Datetime, Hold_Services, Memberof, Error_Services, Rds_Services
Declare function Environment_Services, Utility, Logging_Services
Declare subroutine Database_Services, Error_Services, Obj_notes, Hold_Services, Obj_Wm_In, Obj_Wm_Out, Wm_In_Services Declare subroutine Database_Services, Error_Services, Obj_notes, Hold_Services, Obj_Wm_In, Obj_Wm_Out, Wm_In_Services
Declare subroutine Wm_Out_Services, Rds_Services, Lot_Event_Services Declare subroutine Wm_Out_Services, Rds_Services, Lot_Event_Services, Logging_Services
GoToService else GoToService else
Error_Services('Add', Service : ' is not a valid service request within the ' : ServiceModule : ' module.') Error_Services('Add', Service : ' is not a valid service request within the ' : ServiceModule : ' module.')
@ -361,29 +361,42 @@ Service OnHold(WOMatKey, HoldEntity, HoldEntityID, HoldType, HoldData, OperatorI
If Error_Services("NoError") then If Error_Services("NoError") then
Hold_Services("HoldNotification", HoldEntity, HoldEntityID, Reason, True$, HoldType, OperatorID) Hold_Services("HoldNotification", HoldEntity, HoldEntityID, Reason, True$, HoldType, OperatorID)
Hold_Services("CreateComment", HoldEntity, HoldEntityID, Reason, True$, HoldType, OperatorID) Hold_Services("CreateComment", HoldEntity, HoldEntityID, Reason, True$, HoldType, OperatorID)
//Add in logging lot event LotKey = ''
If UserId EQ '' then
UserId = OperatorId
end
Begin Case Begin Case
Case HoldEntity EQ 'WM_IN' Case HoldEntity EQ 'WM_IN'
WONo = Field(WOMatKey, '*', 1) WONo = Field(WOMatKey, '*', 1)
StepNo = 1 StepNo = 1
CassNo = Field(WOMatKey, '*', 2) CassNo = Field(WOMatKey, '*', 2)
WMInKey = WONo : '*' : StepNo : '*' : CassNo WMInKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMInKey, CurrDTM, 'HOLD_ON', 'Lot placed on hold.', '', UserId, True$, 'WM_IN') LotKey = 'I':WMInKey
Convert '*' to '.' in LotKey
Case HoldEntity EQ 'WM_OUT' Case HoldEntity EQ 'WM_OUT'
WONo = Field(WOMatKey, '*', 1) WONo = Field(WOMatKey, '*', 1)
StepNo = 1 StepNo = 1
CassNo = Field(WOMatKey, '*', 2) CassNo = Field(WOMatKey, '*', 2)
WMOutKey = WONo : '*' : StepNo : '*' : CassNo WMOutKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMOutKey, CurrDTM, 'HOLD_ON', 'Lot placed on hold.', '', UserId, True$, 'WM_OUT') LotKey = 'O':WMOutKey
Convert '*' to '.' in LotKey
Case HoldEntity EQ 'RDS' Case HoldEntity EQ 'RDS'
RDSNo = Xlate('WO_MAT', WOMatKey, WO_MAT_RDS_NO$, 'X') RDSNo = Xlate('WO_MAT', WOMatKey, WO_MAT_RDS_NO$, 'X')
Lot_Event_Services('CreateLotEvent', RDSNo, CurrDTM, 'HOLD_ON', 'Lot placed on hold.', '', UserId, True$, 'RDS') LotKey = 'R':RDSNo
Convert '*' to '.' in LotKey
Case HoldEntity EQ 'WO_MAT' Case HoldEntity EQ 'WO_MAT'
Lot_Event_Services('CreateLotEvent', WOMatKey, CurrDTM, 'HOLD_ON', 'Lot placed on hold.', '', UserId, True$, 'WO_MAT') LotKey = 'W':WOMatKey
Convert '*' to '.' in LotKey
End Case End Case
Machine = Environment_Services('GetServer')
Headers = 'Logging DTM' : @FM : 'Machine' : @FM : 'Log'
ColumnWidths = 20 : @FM : 15 : @FM : 300
LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\Lot'
makeDirSuccess = Utility("MAKEDIR", LogPath)
LogFileName = LotKey:'.csv'
objLog = Logging_Services('NewLog', LogPath, LogFileName, CRLF$, ' ', Headers, ColumnWidths, False$, False$)
LogData = ''
LogData<1> = Oconv(Date(), 'D4/') : ' ' : Oconv(Time(), 'MTS') ; // Logging DTM
LogData<2> = Machine
LogData<3> = 'Lot ':LotKey:' of type ':HoldEntity:' placed on hold by user ':OperatorId
Logging_Services('AppendLog', objLog, LogData, @RM, @FM, False$)
end end
end else end else
Error_Services('Add', 'Lot is already on hold.') Error_Services('Add', 'Lot is already on hold.')
@ -497,29 +510,43 @@ Service OffHold(WOMatKey, HoldEntity, HoldEntityID, HoldType, HoldData, Operator
If Error_Services("NoError") then If Error_Services("NoError") then
Hold_Services("HoldNotification", HoldEntity, HoldEntityID, Reason, False$, HoldType, OperatorID) Hold_Services("HoldNotification", HoldEntity, HoldEntityID, Reason, False$, HoldType, OperatorID)
Hold_Services("CreateComment", HoldEntity, HoldEntityID, Reason, False$, HoldType, OperatorID) Hold_Services("CreateComment", HoldEntity, HoldEntityID, Reason, False$, HoldType, OperatorID)
//Add in logging lot event LotKey = ''
if UserID EQ '' then
UserId = OperatorId
end
Begin Case Begin Case
Case HoldEntity EQ 'WM_IN' Case HoldEntity EQ 'WM_IN'
WONo = Field(WOMatKey, '*', 1) WONo = Field(WOMatKey, '*', 1)
StepNo = 1 StepNo = 1
CassNo = Field(WOMatKey, '*', 2) CassNo = Field(WOMatKey, '*', 2)
WMInKey = WONo : '*' : StepNo : '*' : CassNo WMInKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMInKey, CurrDTM, 'HOLD_OFF', 'Lot taken off hold.', '', UserId, True$, 'WM_IN') LotKey = 'I':WMInKey
Convert '*' to '.' in LotKey
Case HoldEntity EQ 'WM_OUT' Case HoldEntity EQ 'WM_OUT'
WONo = Field(WOMatKey, '*', 1) WONo = Field(WOMatKey, '*', 1)
StepNo = 1 StepNo = 1
CassNo = Field(WOMatKey, '*', 2) CassNo = Field(WOMatKey, '*', 2)
WMOutKey = WONo : '*' : StepNo : '*' : CassNo WMOutKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMOutKey, CurrDTM, 'HOLD_OFF', 'Lot taken off hold.', '', UserId, True$, 'WM_OUT') LotKey = 'O':WMOutKey
Convert '*' to '.' in LotKey
Case HoldEntity EQ 'RDS' Case HoldEntity EQ 'RDS'
RDSNo = Xlate('WO_MAT', WOMatKey, WO_MAT_RDS_NO$, 'X') RDSNo = Xlate('WO_MAT', WOMatKey, WO_MAT_RDS_NO$, 'X')
Lot_Event_Services('CreateLotEvent', RDSNo, CurrDTM, 'HOLD_OFF', 'Lot taken off hold.', '', UserId, True$, 'RDS') LotKey = 'R':RDSNo
Case HoldEntity EQ 'WO_MAT' Case HoldEntity EQ 'WO_MAT'
Lot_Event_Services('CreateLotEvent', WOMatKey, CurrDTM, 'HOLD_OFF', 'Lot taken off hold.', '', UserId, True$, 'WO_MAT') LotKey = WOMatKey
Convert '*' to '.' in LotKey
End Case End Case
Machine = Environment_Services('GetServer')
Headers = 'Logging DTM' : @FM : 'Machine' : @FM : 'Log'
ColumnWidths = 20 : @FM : 15 : @FM : 300
LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\Lot'
makeDirSuccess = Utility("MAKEDIR", LogPath)
LogFileName = LotKey:'.csv'
objLog = Logging_Services('NewLog', LogPath, LogFileName, CRLF$, ' ', Headers, ColumnWidths, False$, False$)
LogData = ''
LogData<1> = Oconv(Date(), 'D4/') : ' ' : Oconv(Time(), 'MTS') ; // Logging DTM
LogData<2> = Machine
LogData<3> = 'Lot ':LotKey:' of type ':HoldEntity:' taken off hold by user ':OperatorId
Logging_Services('AppendLog', objLog, LogData, @RM, @FM, False$)
end end
end else end else
Error_Services('Add', 'Lot is not on hold.') Error_Services('Add', 'Lot is not on hold.')

View File

@ -55,7 +55,7 @@ $Insert LOT_EQUATES
$Insert LOT_OPERATION_EQUATES $Insert LOT_OPERATION_EQUATES
Declare function Error_Services, Logging_Services, Environment_Services, Database_Services, RTI_CreateGUID Declare function Error_Services, Logging_Services, Environment_Services, Database_Services, RTI_CreateGUID
Declare function Lot_Event_Services, Lot_Services Declare function Lot_Event_Services, Lot_Services, NextKey
Declare subroutine Error_Services, Logging_Services, Database_Services, Lot_Services, Service_Services Declare subroutine Error_Services, Logging_Services, Database_Services, Lot_Services, Service_Services
Declare subroutine Transaction_Services Declare subroutine Transaction_Services
@ -89,8 +89,11 @@ Service CreateLotEvent(LotId, EventDateTime, EventType=EVENT_TYPES, EventNote, E
end end
end end
If RowExists('LOT', LotId) then If RowExists('LOT', LotId) then
CurrLotOperation = Lot_Services('GetLotCurrOperationId', LotId)
NewEventId = RTI_CreateGUID() NewEventId = RTI_CreateGUID()
If NewEventId NE '' then If NewEventId NE '' then
NextEventChronId = NextKey('LOT_EVENT')
If NextEventChronId NE 0 then
NewEventSequence = Lot_Event_Services('GetLotEventNextSequence', LotId) NewEventSequence = Lot_Event_Services('GetLotEventNextSequence', LotId)
If Error_Services('NoError') then If Error_Services('NoError') then
NewEventRec = '' NewEventRec = ''
@ -98,9 +101,11 @@ Service CreateLotEvent(LotId, EventDateTime, EventType=EVENT_TYPES, EventNote, E
NewEventRec<LOT_EVENT_LOT_EVENT_TYPE$> = EventType NewEventRec<LOT_EVENT_LOT_EVENT_TYPE$> = EventType
NewEventRec<LOT_EVENT_EVENT_DATETIME$> = EventDatetime NewEventRec<LOT_EVENT_EVENT_DATETIME$> = EventDatetime
NewEventRec<LOT_EVENT_EVENT_NOTE$> = EventNote NewEventRec<LOT_EVENT_EVENT_NOTE$> = EventNote
NewEventRec<LOT_EVENT_EVENT_OPERATION_ID$> = CurrLotOperation
NewEventRec<LOT_EVENT_EQUIPMENT_ID$> = EventEquipmentId NewEventRec<LOT_EVENT_EQUIPMENT_ID$> = EventEquipmentId
NewEventRec<LOT_EVENT_EVENT_OPERATOR_ID$> = OperatorId NewEventRec<LOT_EVENT_EVENT_OPERATOR_ID$> = OperatorId
NewEventRec<LOT_EVENT_SEQUENCE$> = NewEventSequence NewEventRec<LOT_EVENT_SEQUENCE$> = NewEventSequence
NewEventRec<LOT_EVENT_CHRON_ID$> = NextEventChronId
Database_Services('WriteDataRow', 'LOT_EVENT', NewEventId, NewEventRec) Database_Services('WriteDataRow', 'LOT_EVENT', NewEventId, NewEventRec)
If Error_Services('NoError') then If Error_Services('NoError') then
Transaction_Services('PostWriteFieldTransaction', 'LOT', LotId, LOT_MOST_RECENT_LOT_EVENT_ID$, NewEventId) Transaction_Services('PostWriteFieldTransaction', 'LOT', LotId, LOT_MOST_RECENT_LOT_EVENT_ID$, NewEventId)
@ -111,6 +116,9 @@ Service CreateLotEvent(LotId, EventDateTime, EventType=EVENT_TYPES, EventNote, E
end else end else
ErrorMessage = Error_Services('GetMessage') ErrorMessage = Error_Services('GetMessage')
end end
end else
ErrorMessage = 'Error creating new event. Error calling NextKey("LOT_EVENT") to get LOT_EVENT_CHRON_ID.'
end
end else end else
ErrorMessage = 'Error creating an event Id.' ErrorMessage = 'Error creating an event Id.'
end end
@ -233,3 +241,5 @@ return

View File

@ -53,7 +53,8 @@ Declare function PSN_Services, Return_To_Fab_Services
Declare subroutine Database_Services, Btree.Extract, Lot_Services, Error_Services, Labeling_Services, SRP_Json, Logging_Services Declare subroutine Database_Services, Btree.Extract, Lot_Services, Error_Services, Labeling_Services, SRP_Json, Logging_Services
Declare subroutine SRP_Run_Command, Service_Services, obj_notes, Lot_Event_Services, Mona_Services Declare subroutine SRP_Run_Command, Service_Services, obj_notes, Lot_Event_Services, Mona_Services
$insert APP_INSERTS $Insert SERVICE_SETUP
$Insert APP_INSERTS
$Insert LOT_EQUATES $Insert LOT_EQUATES
$Insert TEST_WAFER_PROD_EQUATES $Insert TEST_WAFER_PROD_EQUATES
$Insert Lot_Operation_Equates $Insert Lot_Operation_Equates
@ -65,6 +66,7 @@ $Insert RDS_EQUATES
$Insert WO_LOG_EQUATES $Insert WO_LOG_EQUATES
$Insert PROD_VER_EQUATES $Insert PROD_VER_EQUATES
$Insert OPERATION_EQUATES $Insert OPERATION_EQUATES
$Insert IFX_EQUATES
LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\Lot' LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\Lot'
LogDate = Oconv(Date(), 'D4/') LogDate = Oconv(Date(), 'D4/')
@ -106,7 +108,9 @@ end else
MonaResource = 'GRP_OPENINSIGHT_MES_OP_FE_DEV_LOTSERVICES' MonaResource = 'GRP_OPENINSIGHT_MES_OP_FE_DEV_LOTSERVICES'
end end
GoToService GoToService else
Error_Services('Add', Service : ' is not a valid service request within the ' : ServiceModule : ' services module.')
end
Return Response or "" Return Response or ""
@ -1226,7 +1230,7 @@ Service OpenLot(LotId)
LotRec<LOT_OPEN$> = True$ LotRec<LOT_OPEN$> = True$
Database_Services('WriteDataRow', 'LOT', LotId, LotRec, True$, False$, False$) Database_Services('WriteDataRow', 'LOT', LotId, LotRec, True$, False$, False$)
If Error_Services('NoError') then If Error_Services('NoError') then
Lot_Event_Services('CreateLotEvent', LotId, Datetime(), 'OPEN', 'Lot status set to Open.', '', 'SYSTEM') Lot_Event_Services('CreateLotEvent', LotId, Datetime(), 'LOT_START', 'Lot created.', '', 'SYSTEM')
end else end else
ErrorMessage = 'Error setting lot ' : LotId : ' to open.' : Error_Services('GetMessage') ErrorMessage = 'Error setting lot ' : LotId : ' to open.' : Error_Services('GetMessage')
end end
@ -1409,7 +1413,7 @@ Service ReduceLotWaferCount(LotId, ReductionQty, OperatorId)
// Write Lot Event // Write Lot Event
Lot_Event_Services('CreateLotEvent', LotId, Datetime(), 'REDUCE_WAFER_QTY', 'Reduced wafer count by ' : ReductionQty, '', OperatorId, False$, '') Lot_Event_Services('CreateLotEvent', LotId, Datetime(), 'REDUCE_WAFER_QTY', 'Reduced wafer count by ' : ReductionQty, '', OperatorId, False$, '')
if LotNewWfrQty EQ 0 AND LotType EQ 'TW' then if LotNewWfrQty EQ 0 AND LotType EQ 'TW' then
ServiceParms = 'AutoCloseTestWaferLot' : @VM : LotId : @VM : 'SYSTEM' ServiceParms = 'AutoCloseTestWaferLot' : SD$ : LotId : SD$ : 'SYSTEM'
Service_Services('PostProcedure', 'LOT_SERVICES', ServiceParms) Service_Services('PostProcedure', 'LOT_SERVICES', ServiceParms)
If Error_Services('HasError') then If Error_Services('HasError') then
Recipients = Xlate('NOTIFICATION', 'FI_SUPPORT', NOTIFICATION_USER_ID$, 'X') Recipients = Xlate('NOTIFICATION', 'FI_SUPPORT', NOTIFICATION_USER_ID$, 'X')
@ -1465,7 +1469,7 @@ Service IncreaseLotWaferCount(LotId, IncreaseQty, OperatorId)
Database_Services('WriteDataRow', 'LOT', LotId, LotRec, True$, False$, False$) Database_Services('WriteDataRow', 'LOT', LotId, LotRec, True$, False$, False$)
If Error_Services('NoError') then If Error_Services('NoError') then
// Write Lot Event // Write Lot Event
Lot_Event_Services('CreateLotEvent', LotId, Datetime(), 'INCREASE_WAFER_QTY', 'Increased wafer count by ' : IncreaseQty, '', OperatorId, False$, '') Lot_Event_Services('CreateLotEvent', LotId, Datetime(), 'BONUS_WAFER_QTY', 'Increased wafer count by ' : IncreaseQty, '', OperatorId, False$, '')
end else end else
ErrorMessage = 'Error in Increase Lot Wafer Count service, Error writing Lot Id ' : LotId : ' with new quantity.' ErrorMessage = 'Error in Increase Lot Wafer Count service, Error writing Lot Id ' : LotId : ' with new quantity.'
end end
@ -1580,11 +1584,11 @@ Service CreateNewVoidedLotRecord(LotId, LegacyLotId, LotType=LOT_TYPES, Username
EndTick = GetTickCount() EndTick = GetTickCount()
Mona_Services('QueueLatencyAndCountMetrics', MonaResource, MetricName, StartTick, EndTick) Mona_Services('QueueLatencyAndCountMetrics', MonaResource, MetricName, StartTick, EndTick)
If ErrorMessage NE '' then Error_Services('Add', ErrorMessage) If ErrorMessage NE '' then Error_Services('Add', ErrorMessage)
end service end service
Service CanUserModifyLot(UserId) Service CanUserModifyLot(UserId)
Begin Case Begin Case
@ -1614,4 +1618,3 @@ end service
// Internal GoSubs // Internal GoSubs
//---------------------------------------------------------------------------------------------------------------------- //----------------------------------------------------------------------------------------------------------------------

View File

@ -254,19 +254,13 @@ Service ProcessPTIScanData(ScanData, ScanType = SCAN_TYPES, Param1, Param2, Para
If ErrorMsg EQ '' then Response = ScanSubLot If ErrorMsg EQ '' then Response = ScanSubLot
Case ScanType EQ 'CASSETTE1' Case ScanType EQ 'CASSETTE1'
debug
// Assume this is intended to be a Cassette ID scan (either WMO or RDS). Only if this is a // Assume this is intended to be a Cassette ID scan (either WMO or RDS). Only if this is a
// non-existent carrier will the scan data be considered invalid. // non-existent carrier will the scan data be considered invalid.
// Strip '1T', 'I', and 'O' prefixes. // Strip '1T', 'I', and 'O' prefixes.
ValidCassetteID = False$ ; // Assume Cassette ID is not valid for now. ValidCassetteID = False$ ; // Assume Cassette ID is not valid for now.
DelimCount = DCount(ScanData, '|') DelimCount = DCount(ScanData, '|')
Begin Case Begin Case
Case (ScanData[1, 1] EQ 'I') Case ( (ScanData[1, 2] EQ '1T') or (ScanData[1, 1] EQ 'O') or (ScanData[1, 1] EQ 'I') )
! Temporary exception while we exhaust current WMI inventory on KIT racks that
! do not have a 2D barcode.
CassetteID = ScanData
SeqNo = 'SEQ1'
Case ( (ScanData[1, 2] EQ '1T') or (ScanData[1, 1] EQ 'O') )
ErrorMsg = '1D Lot Label Scanned. 2D Lot Label Required.' ErrorMsg = '1D Lot Label Scanned. 2D Lot Label Required.'
Case (DelimCount NE 8) Case (DelimCount NE 8)
ErrorMsg = 'Invalid Lot Label Scan.' ErrorMsg = 'Invalid Lot Label Scan.'
@ -315,12 +309,7 @@ Service ProcessPTIScanData(ScanData, ScanType = SCAN_TYPES, Param1, Param2, Para
DelimCount = DCount(ScanData, '|') DelimCount = DCount(ScanData, '|')
Begin Case Begin Case
Case (ScanData[1, 1] EQ 'I') Case ( (ScanData[1, 2] EQ '1T') or (ScanData[1, 1] EQ 'O') or (ScanData[1, 1] EQ 'I') )
! Temporary exception while we exhaust current WMI inventory on KIT racks that
! do not have a 2D barcode.
CassetteID = ScanData
Seq2No = 'SEQ2'
Case ( (ScanData[1, 2] EQ '1T') or (ScanData[1, 1] EQ 'O') )
ErrorMsg = '1D Lot Label Scanned. 2D Lot Label Required.' ErrorMsg = '1D Lot Label Scanned. 2D Lot Label Required.'
Case (DelimCount NE 8) Case (DelimCount NE 8)
ErrorMsg = 'Invalid Lot Label Scan.' ErrorMsg = 'Invalid Lot Label Scan.'

View File

@ -414,36 +414,27 @@ Service ImportMetrologyFiles(Machine=MACHINE_TYPES)
Begin Case Begin Case
Case Machine _EQC 'Tencor' Case Machine _EQC 'Tencor'
SearchPattern = '*.pdsf';
DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08DDUPSFS6420\Source\MET08DDUPSFS6420\' DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08DDUPSFS6420\Source\MET08DDUPSFS6420\'
Case Machine _EQC 'HgCV' Case Machine _EQC 'HgCV'
SearchPattern = '*.pdsf';
DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08RESIHGCV\Source\MET08RESIHGCV\' DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08RESIHGCV\Source\MET08RESIHGCV\'
Case Machine _EQC 'CDE' Case Machine _EQC 'CDE'
SearchPattern = '*.pdsf';
DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08RESIMAPCDE\Source\MET08RESIMAPCDE\' DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08RESIMAPCDE\Source\MET08RESIMAPCDE\'
Case Machine _EQC 'Biorad' Case Machine _EQC 'Biorad'
SearchPattern = '*.txt';
DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08THFTIRQS408M\Source\MET08THFTIRQS408M\' DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08THFTIRQS408M\Source\MET08THFTIRQS408M\'
Case Machine _EQC 'Stratus' Case Machine _EQC 'Stratus'
SearchPattern = '*.txt';
DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08THFTIRSTRATUS\Source\MET08THFTIRSTRATUS\' DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08THFTIRSTRATUS\Source\MET08THFTIRSTRATUS\'
Case Machine _EQC 'SP1' Case Machine _EQC 'SP1'
SearchPattern = '*.pdsf';
DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08DDUPSP1TBI\Source\MET08DDUPSP1TBI\' DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08DDUPSP1TBI\Source\MET08DDUPSP1TBI\'
Case Machine _EQC 'SPV' Case Machine _EQC 'SPV'
SearchPattern = '*.txt';
DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08RESISRP2100\Source\MET08RESISRP2100\' DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08RESISRP2100\Source\MET08RESISRP2100\'
Case Machine _EQC 'SRP' Case Machine _EQC 'SRP'
SearchPattern = '*.txt';
DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08ANLYSDIFAAST230\Source\MET08ANLYSDIFAAST230\' DataPath = Environment_Services('GetApplicationRootPath') : '\Metrology\MET08ANLYSDIFAAST230\Source\MET08ANLYSDIFAAST230\'
Case Otherwise$ Case Otherwise$
SearchPattern = '*.txt';
Error_Services('Add', 'Error in ':Service:' service. Unsupported Machine "':Machine:'" passed into service') Error_Services('Add', 'Error in ':Service:' service. Unsupported Machine "':Machine:'" passed into service')
End Case End Case
If Error_Services('NoError') then If Error_Services('NoError') then
SearchPattern = '*.pdsf';
InitDir DataPath:SearchPattern InitDir DataPath:SearchPattern
FileList = DirList() FileList = DirList()
FileNames = '' FileNames = ''
@ -520,7 +511,6 @@ Service ImportMetrologyFiles(Machine=MACHINE_TYPES)
RepoPath = Environment_Services('GetApplicationRootPath') : '\Metrology\Run Data Repository\MET08ANLYSDIFAAST230\Source\MET08ANLYSDIFAAST230\' RepoPath = Environment_Services('GetApplicationRootPath') : '\Metrology\Run Data Repository\MET08ANLYSDIFAAST230\Source\MET08ANLYSDIFAAST230\'
End Case End Case
IF SearchPattern = '*.pdsf' THEN
OSREAD Text FROM DataPath:FileName THEN OSREAD Text FROM DataPath:FileName THEN
json = Metrology_Services('GetJsonFromProcessDataStandardFormat', Text); json = Metrology_Services('GetJsonFromProcessDataStandardFormat', Text);
END ELSE END ELSE
@ -531,31 +521,6 @@ Service ImportMetrologyFiles(Machine=MACHINE_TYPES)
END ELSE END ELSE
Metrology_Services('LogResults', PSN, Machine, 'UID002', Service : ' : ' : 'Failed to get PDSF json'); Metrology_Services('LogResults', PSN, Machine, 'UID002', Service : ' : ' : 'Failed to get PDSF json');
END END
END ELSE
OSREAD RunData FROM DataPath:FileName THEN
Set_Status(0)
OSWrite RunData to RepoPath:FileName
status_code = ''
If Get_Status(status_code) then
ErrorMessage = 'Error writing run data file to repository: status_code = ' : status_code
Metrology_Services('LogResults', '', Machine, 'UID001', Service : ' : ' : ErrorMessage)
Set_Status(0)
end
SWAP '|' WITH @VM IN RunData
SWAP CRLF$ WITH @FM IN RunData
LOOP
LastChar = RunData[-1,1]
UNTIL LastChar NE @FM
RunData[-1,1] = ''
REPEAT
Convert Tab$ to @FM in RunData
END else
Metrology_Services('LogResults', '', Machine, 'UID001', 'Read : ' : FileName : ', Size : ' : FileSize)
end
END
************************* *************************
* Import metrology data * * Import metrology data *

View File

@ -677,6 +677,3 @@ CheckSelectedForHolds:
return return

View File

@ -30,7 +30,7 @@ Compile function NDW_WAFER_COUNTER_EVENTS(CtrlEntId, Event, @PARAMS)
***********************************************************************************************************************/ ***********************************************************************************************************************/
#pragma precomp SRP_PreCompiler #pragma precomp SRP_PreCompiler
#window NDW_PACKAGING #window NDW_WAFER_COUNTER
$insert APP_INSERTS $insert APP_INSERTS
$insert EVENT_SETUP $insert EVENT_SETUP
@ -44,7 +44,7 @@ Equ MSG_WIDTH$ to 650
Equ Comma$ to ',' Equ Comma$ to ','
Declare function MemberOf, Form_Services, Wafer_Counter_Services, SRP_Json, WO_Mat_Services, Wm_Out_Services, Datetime Declare function MemberOf, Form_Services, Wafer_Counter_Services, SRP_Json, WO_Mat_Services, Wm_Out_Services, Datetime
Declare function Logging_Services, Environment_Services Declare function Logging_Services, Environment_Services, Wo_Mat_Qa_Services, Return_To_Fab_Services
Declare subroutine SRP_Json, PlaceDialog, Wafer_Counter_Services, Logging_Services Declare subroutine SRP_Json, PlaceDialog, Wafer_Counter_Services, Logging_Services
LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\WaferCounter' LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\WaferCounter'
@ -97,13 +97,26 @@ Event WINDOW.CREATE(CreateParam)
LogData<5> = ToolLoc LogData<5> = ToolLoc
LogData<6> = @Window:'.CREATE' LogData<6> = @Window:'.CREATE'
Logging_Services('AppendLog', objLog, LogData, @RM, @FM) Logging_Services('AppendLog', objLog, LogData, @RM, @FM)
QAMetComplete = ''
If CassID NE '' then
If RowExists('WM_OUT', CassID) then
WOMatKey = Xlate('WM_OUT', CassID, 'WO_MAT_KEY', 'X')
end else
WOMatKey = Xlate('RDS', CassID, 'WO_MAT_KEY', 'X')
end
QAMetComplete = Wo_Mat_Qa_Services('GetQAMetComplete', WOMatKey)
end
Convert '.' to '*' in CassID Convert '.' to '*' in CassID
ExpectedQty = '' ExpectedQty = ''
ExpectedWfrMap = '' ExpectedWfrMap = ''
If WfrCntAdj EQ '' then WfrCntAdj = 0 If WfrCntAdj EQ '' then WfrCntAdj = 0
Set_Property(@Window:'.EDL_CASS_ID', 'TEXT', CassID) Set_Property(@Window:'.EDL_CASS_ID', 'TEXT', CassID)
Begin Case Begin Case
Case (CassID NE '' AND QAMetComplete EQ False$)
ErrorMsg = 'Wafer Counter Operation Not Allowed. QA Metrology Incomplete.'
Case ( (CassID EQ '') and (ToolLoc EQ '') ) Case ( (CassID EQ '') and (ToolLoc EQ '') )
// Alternate workflow // Alternate workflow
Set_Property(@Window:'.LBL_CASS_ID', 'TEXT', 'Cass ID') Set_Property(@Window:'.LBL_CASS_ID', 'TEXT', 'Cass ID')
@ -319,6 +332,9 @@ Event EDL_CASS_BARCODE.LOSTFOCUS(Flag, FocusID)
Set_Property(@Window:'.EDL_CASS_ID', 'TEXT', CassetteID) Set_Property(@Window:'.EDL_CASS_ID', 'TEXT', CassetteID)
Begin Case Begin Case
Case RowExists('RDS', CassetteID) Case RowExists('RDS', CassetteID)
WOMatKey = Xlate('RDS', CassetteID, 'WO_MAT_KEY', 'X')
QAMetComplete = Wo_Mat_Qa_Services('GetQAMetComplete', WOMatKey)
If QAMetComplete EQ True$ then
ExpectedQty = Xlate('RDS', CassetteID, 'WFRS_OUT', 'X') ExpectedQty = Xlate('RDS', CassetteID, 'WFRS_OUT', 'X')
Set_Property(@Window:'.EDL_EXPECTED_QTY', 'TEXT', ExpectedQty) Set_Property(@Window:'.EDL_EXPECTED_QTY', 'TEXT', ExpectedQty)
Set_Property(@Window:'.LBL_CASS_ID', 'TEXT', 'Cass RDS') Set_Property(@Window:'.LBL_CASS_ID', 'TEXT', 'Cass RDS')
@ -331,8 +347,14 @@ Event EDL_CASS_BARCODE.LOSTFOCUS(Flag, FocusID)
end else end else
ErrorMsg = Error_Services('GetMessage') ErrorMsg = Error_Services('GetMessage')
end end
end else
ErrorMsg = 'Wafer Counter Operation Not Allowed. A Metrology stage is incomplete.'
end
Case RowExists('WM_OUT', CassetteID) Case RowExists('WM_OUT', CassetteID)
WOMatKey = Xlate('WM_OUT', CassetteID, 'WO_MAT_KEY', 'X')
QAMetComplete = Wo_Mat_Qa_Services('GetQAMetComplete', WOMatKey)
If QAMetComplete EQ True$ then
ExpectedQty = Xlate('WM_OUT', CassetteID, 'WAFER_CNT', 'X') ExpectedQty = Xlate('WM_OUT', CassetteID, 'WAFER_CNT', 'X')
Set_Property(@Window:'.EDL_EXPECTED_QTY', 'TEXT', ExpectedQty) Set_Property(@Window:'.EDL_EXPECTED_QTY', 'TEXT', ExpectedQty)
Set_Property(@Window:'.LBL_CASS_ID', 'TEXT', 'Cass WMO') Set_Property(@Window:'.LBL_CASS_ID', 'TEXT', 'Cass WMO')
@ -344,11 +366,15 @@ Event EDL_CASS_BARCODE.LOSTFOCUS(Flag, FocusID)
end else end else
ErrorMsg = Error_Services('GetMessage') ErrorMsg = Error_Services('GetMessage')
end end
end else
ErrorMsg = 'Wafer Counter Operation Not Allowed. QA Metrology Incomplete.'
end
End Case End Case
If ErrorMsg EQ '' then
Convert @VM to '' in ExpectedWfrMap Convert @VM to '' in ExpectedWfrMap
Set_Property(@Window, '@EXPECTED_WFR_MAP', ExpectedWfrMap) Set_Property(@Window, '@EXPECTED_WFR_MAP', ExpectedWfrMap)
end
end else end else
If CassetteID NE VerifyCassID then If CassetteID NE VerifyCassID then
ErrorMsg = 'Scanned cassette ID does not match cassette to verify!' ErrorMsg = 'Scanned cassette ID does not match cassette to verify!'
@ -598,3 +624,9 @@ ClearForm:
return return

View File

@ -425,7 +425,7 @@ Service CreateNewOrder(EntityType=ENTITY_TYPES, EntityID, OrderType=ORDER_TYPES,
SRP_JSON(objJson, 'SetValue', 'reactorNumber', ReactNo) SRP_JSON(objJson, 'SetValue', 'reactorNumber', ReactNo)
NewChecklistInstIds = Xlate('NICA_CHECKLISTS', NewSortedChecklistIds, 'NICA_BASE_INSTRUCTION_ID', 'X') NewChecklistInstIds = Xlate('NICA_CHECKLISTS', NewSortedChecklistIds, 'NICA_BASE_INSTRUCTION_ID', 'X')
SRP_JSON(objJson, 'SetValueArray', 'baseInstructionIds', NewChecklistInstIds, @VM) SRP_JSON(objJson, 'SetValueArray', 'baseInstructionIds', NewChecklistInstIds, @VM)
Body = SRP_JSON(objJson, 'Stringify', 'Styled') Body = SRP_JSON(objJson, 'Stringify', 'Fast')
Convert @FM to '' in Body Convert @FM to '' in Body
SRP_JSON(objJson, 'Release') SRP_JSON(objJson, 'Release')
end else end else
@ -443,6 +443,7 @@ Service CreateNewOrder(EntityType=ENTITY_TYPES, EntityID, OrderType=ORDER_TYPES,
IsSuccessful = False$ IsSuccessful = False$
If ErrorMsg EQ '' then If ErrorMsg EQ '' then
AttemptNo = 0
Retries = 3 Retries = 3
BackoffSeconds = 1 BackoffSeconds = 1
OrderId = '' OrderId = ''
@ -458,7 +459,32 @@ Service CreateNewOrder(EntityType=ENTITY_TYPES, EntityID, OrderType=ORDER_TYPES,
end else end else
Headers = 'Accept':@VM:'*/*' Headers = 'Accept':@VM:'*/*'
end end
LogData<1> = Oconv(Date(), 'D4/') : ' ' : Oconv(Time(), 'MTS') ; // Logging DTM
LogData<2> = Machine
AttemptNo += 1
LogData<3> = 'Attempt number ':AttemptNo:' to send HTTP POST request to ':NicaURL
Logging_Services('AppendLog', objLog, LogData, @RM, @FM, False$)
// Write directly to the log file to avoid mangling the JSON
OSRead LogBytes from LogPath:'\':LogFileName then
LogBytes := CRLF$:Body
OSWrite LogBytes to LogPath:'\':LogFileName
end
HttpResponseJson = Httpclient_Services('SendHTTPRequest', 'POST', NicaURL, Headers, Body, '', '', False$, False$, '', IgnoreCertErrors) HttpResponseJson = Httpclient_Services('SendHTTPRequest', 'POST', NicaURL, Headers, Body, '', '', False$, False$, '', IgnoreCertErrors)
LogData<1> = Oconv(Date(), 'D4/') : ' ' : Oconv(Time(), 'MTS') ; // Logging DTM
LogData<2> = Machine
LogData<3> = 'Attempt number ':AttemptNo:' HttpResponse from ':NicaURL:':'
Logging_Services('AppendLog', objLog, LogData, @RM, @FM, False$)
// Write directly to the log file to avoid mangling the JSON
OSRead LogBytes from LogPath:'\':LogFileName then
LogBytes := CRLF$:HttpResponseJson
OSWrite LogBytes to LogPath:'\':LogFileName
end
If HttpResponseJson NE '' then If HttpResponseJson NE '' then
ObjResponseJson = '' ObjResponseJson = ''
If SRP_JSON(ObjResponseJson, 'Parse', HttpResponseJson) EQ '' then If SRP_JSON(ObjResponseJson, 'Parse', HttpResponseJson) EQ '' then

View File

@ -92,6 +92,7 @@ RETURN Result
* * * * * * * * * * * * * *
Create: Create:
* * * * * * * * * * * * * *
StartTick = GetTickCount() StartTick = GetTickCount()
MetricName = 'Create' MetricName = 'Create'
@ -165,93 +166,12 @@ Create:
WOMatLogRec<WO_MAT_LOG_TOOL_ID$> = ToolID WOMatLogRec<WO_MAT_LOG_TOOL_ID$> = ToolID
WOMatLogRec<WO_MAT_LOG_SCAN_ENTRY$> = ScanEntry WOMatLogRec<WO_MAT_LOG_SCAN_ENTRY$> = ScanEntry
* OtParms = 'WO_MAT_LOG':@RM:WOMatLogKey:@RM:@RM:WOMatLogRec
* obj_Tables('WriteRec',OtParms)
*
* errCode = ''
* IF Get_Status(errCode) THEN
* ErrorMsg = 'obj_WO_Mat_Log':TAB$:'Create: Write error':TAB$:LogFile:TAB$:WONos:TAB$:CassNos:TAB$:WhCd:'*':LocCd:TAB$:Action:TAB$:TransDTM:TAB$:UserID:TAB$:Tags:TAB$:ToolID:TAB$:errCode
* END ElSE
* ErrorMsg = ''
* END
Database_Services('WriteDataRow', 'WO_MAT_LOG', WOMatLogKey, WOMatLogRec, True$, False$, True$) Database_Services('WriteDataRow', 'WO_MAT_LOG', WOMatLogKey, WOMatLogRec, True$, False$, True$)
If Error_Services('NoError') then If Error_Services('HasError') then ErrorMsg = Error_Services('GetMessage')
ReactType = XLATE('WO_LOG', WONos, WO_LOG_REACT_TYPE$, 'X')
If ReactType NE 'EPP' then
WONo = WoNos
CassNo = CassNos
WOMatKey = WONo : '*' : CassNo
RDSKey = XLATE('WO_MAT', WOMatKey, WO_MAT_RDS_NO$, 'X')
Lot_Event_Services('CreateLotEvent', RDSKey, Datetime(), Action, '', '', UserId, True$, 'RDS')
end else
Begin Case
Case Action EQ 'RCVD'
//WMI
WONo = WoNos
StepNo = 1
CassNo = CassNos
WMInKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMInKey, Datetime(), Action, '', '', UserId, True$, 'WM_IN')
Case Action EQ 'REL'
//WMI
WONo = WoNos
StepNo = 1
CassNo = CassNos
WMInKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMInKey, Datetime(), Action, '', '', UserId, True$, 'WM_IN')
Case Action EQ '1VER'
//RDS action, do nothing for now
Case Action EQ '1LOAD'
//RDS, do nothing for now
Case Action EQ '1UNLOAD'
//RDS, do nothing for now
Case Action EQ '1MO_PSTI'
WONo = WoNos
StepNo = 1
CassNo = CassNos
WMOutKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMOutKey, Datetime(), Action, '', '', UserId, True$, 'WM_OUT')
Case Action EQ '1MO_QA'
WONo = WoNos
StepNo = 1
CassNo = CassNos
WMOutKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMOutKey, Datetime(), Action, '', '', UserId, True$, 'WM_OUT')
Case Action EQ 'PACK'
WONo = WoNos
StepNo = 1
CassNo = CassNos
WMOutKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMOutKey, Datetime(), Action, '', '', UserId, True$, 'WM_OUT')
Case Action EQ 'PSVER'
WONo = WoNos
StepNo = 1
CassNo = CassNos
WMOutKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMOutKey, Datetime(), Action, '', '', UserId, True$, 'WM_OUT')
Case Action EQ 'SHIP'
WONo = WoNos
StepNo = 1
CassNo = CassNos
WMOutKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMOutKey, Datetime(), Action, '', '', UserId, True$, 'WM_OUT')
Case Action EQ 'LBLCHK'
//WMO
WONo = WoNos
StepNo = 1
CassNo = CassNos
WMOutKey = WONo : '*' : StepNo : '*' : CassNo
Lot_Event_Services('CreateLotEvent', WMOutKey, Datetime(), Action, '', '', UserId, True$, 'WM_OUT')
End Case
end
ErrorMsg = ''
end else
ErrorMsg = Error_Services('GetMessage')
end
EndTick = GetTickCount() EndTick = GetTickCount()
Mona_Services('QueueLatencyAndCountMetrics', MonaResource, MetricName, StartTick, EndTick) Mona_Services('QueueLatencyAndCountMetrics', MonaResource, MetricName, StartTick, EndTick)
RETURN RETURN
@ -406,5 +326,3 @@ Post:
RETURN RETURN

View File

@ -16,7 +16,7 @@ COMPILE FUNCTION obj_WO_React(Method,Parms)
DECLARE FUNCTION Get_Status, Msg, Utility, obj_Tables, NextKey, obj_Prod_Spec, obj_WO_Mat_QA, GetTickCount DECLARE FUNCTION Get_Status, Msg, Utility, obj_Tables, NextKey, obj_Prod_Spec, obj_WO_Mat_QA, GetTickCount
Declare function Environment_Services Declare function Environment_Services, Database_Services
DECLARE SUBROUTINE Set_Status, Msg, obj_Tables, RList, ErrMsg, Btree.Extract, obj_WO_Mat_QA, Mona_Services DECLARE SUBROUTINE Set_Status, Msg, obj_Tables, RList, ErrMsg, Btree.Extract, obj_WO_Mat_QA, Mona_Services
$INSERT MSG_EQUATES $INSERT MSG_EQUATES
@ -90,7 +90,6 @@ WOReactKey = WONo:'*':StepNo:'*':ReactNo
otParms = 'WO_REACT':@RM:WOReactKey otParms = 'WO_REACT':@RM:WOReactKey
WOReactRec = obj_Tables('ReadOnlyRec',otParms) WOReactRec = obj_Tables('ReadOnlyRec',otParms)
RDSNos = WOReactRec<WO_REACT_RDS_NO$> RDSNos = WOReactRec<WO_REACT_RDS_NO$>
CassNos = WOReactRec<WO_REACT_CASS_NO$> CassNos = WOReactRec<WO_REACT_CASS_NO$>
@ -105,13 +104,11 @@ Start = QAMetData<COL$QA_MET_START>
Interval = QAMetData<COL$QA_MET_INTERVAL> Interval = QAMetData<COL$QA_MET_INTERVAL>
Stage = QAMetData<COL$QA_MET_STAGE> Stage = QAMetData<COL$QA_MET_STAGE>
MetPropCd = QAMetData<COL$QA_MET_PROP> MetPropCd = QAMetData<COL$QA_MET_PROP>
GOSUB BuildAllTestPos ;* Set RDSNos, Start and Interval -> returns AllTestPos GOSUB BuildAllTestPos ;* Set RDSNos, Start and Interval -> returns AllTestPos
* * * Find where the the RDS being added will be in the list. * * * * * * Find where the the RDS being added will be in the list. * * *
LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> BY 'AR' USING @VM SETTING InsPos THEN LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> USING @VM SETTING InsPos THEN
otParms = 'WO_REACT':@RM:WOReactKey otParms = 'WO_REACT':@RM:WOReactKey
WOReactRec = obj_Tables('UnlockRec',otParms) WOReactRec = obj_Tables('UnlockRec',otParms)
@ -120,10 +117,9 @@ LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> BY 'AR' USING @VM SETTING InsPos TH
END ELSE END ELSE
LOCATE InsPos IN AllTestPos BY 'AR' USING @VM SETTING TrimPos ELSE Null LOCATE InsPos IN AllTestPos USING @VM SETTING TrimPos ELSE Null
ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt) ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt)
GOSUB RemSchedQA ;* Removes unsigned QAMet from cassettes scheduled past the box being removed GOSUB RemSchedQA ;* Removes unsigned QAMet from cassettes scheduled past the box being removed
END END
@ -137,7 +133,6 @@ CassNos = WOReactRec<WO_REACT_CASS_NO$> ;* List after insert
* * * Now build list for cassette * * * Now build list for cassette
GOSUB BuildAllTestPos GOSUB BuildAllTestPos
ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt) ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt)
GOSUB AddSchedQA ;* Add QAMet spec data to cassettes now associated with the test positions after removing the RDS & Cassno from the lists GOSUB AddSchedQA ;* Add QAMet spec data to cassettes now associated with the test positions after removing the RDS & Cassno from the lists
@ -194,19 +189,17 @@ MetPropCd = QAMetData<COL$QA_MET_PROP>
GOSUB BuildAllTestPos ;* Set RDSNos, Start and Interval -> returns AllTestPos GOSUB BuildAllTestPos ;* Set RDSNos, Start and Interval -> returns AllTestPos
IF AllTestPos NE '' THEN IF AllTestPos NE '' THEN
* * * Find where the the RDS being removed is in the list. * * * * * * Find where the the RDS being removed is in the list. * * *
LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> USING @VM SETTING RemPos THEN LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> USING @VM SETTING RemPos THEN
LOCATE RemPos IN AllTestPos BY 'AR' USING @VM SETTING TrimPos ELSE Null LOCATE RemPos IN AllTestPos USING @VM SETTING TrimPos ELSE Null
ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt) ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt)
GOSUB RemSchedQA ;* Removes unsigned QAMet from cassettes scheduled past the box being removed GOSUB RemSchedQA ;* Removes unsigned QAMet from cassettes scheduled past the box being removed
END ELSE END ELSE
otParms = 'WO_REACT':@RM:WOReactKey otParms = 'WO_REACT':@RM:WOReactKey
@ -225,11 +218,9 @@ CassNos = WOReactRec<WO_REACT_CASS_NO$> ;* List after removal
* * * Now build list for cassette * * * Now build list for cassette
GOSUB BuildAllTestPos GOSUB BuildAllTestPos
ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt) ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt)
GOSUB AddSchedQA ;* Add QAMet spec data to cassettes now associated with the test positions after removing the RDS & Cassno from the lists GOSUB AddSchedQA ;* Add QAMet spec data to cassettes now associated with the test positions after removing the RDS & Cassno from the lists
otParms = FIELDSTORE(otParms,@RM,4,0,WOReactRec) otParms = FIELDSTORE(otParms,@RM,4,0,WOReactRec)
// 10/12/18 Changed to WriteOnlyRec as per Francois' instructions. - djs // 10/12/18 Changed to WriteOnlyRec as per Francois' instructions. - djs
obj_Tables('WriteOnlyRec',otParms) ;* Done with updates to the WO_REACT record obj_Tables('WriteOnlyRec',otParms) ;* Done with updates to the WO_REACT record
@ -346,3 +337,4 @@ FOR I = 1 TO chgCnt
NEXT I NEXT I
RETURN RETURN

View File

@ -712,7 +712,7 @@ Service CreatePackagingRecord(LotId, UserId, EqpId)
NewPackagingRec<PACKAGING_COMPLETE_DTM$> = TransDtm NewPackagingRec<PACKAGING_COMPLETE_DTM$> = TransDtm
Database_Services('WriteDataRow', 'PACKAGING', NewRecId, NewPackagingRec, True$, 0, False$) Database_Services('WriteDataRow', 'PACKAGING', NewRecId, NewPackagingRec, True$, 0, False$)
If Error_Services('NoError') then If Error_Services('NoError') then
Lot_Event_Services('CreateLotEvent', LotId, TransDtm, 'PACKAGING', 'Lot Packaged.', EqpId, UserId) Lot_Event_Services('CreateLotEvent', LotId, TransDtm, 'COMMENT', 'Lot Packaged.', EqpId, UserId)
end else end else
ErrorMessage = Error_Services('GetMessage') ErrorMessage = Error_Services('GetMessage')
end end
@ -765,5 +765,3 @@ Service AddPackToLotOperation(LotOperationId, PackagingId, UserId)
end service end service

View File

@ -923,11 +923,23 @@ DELETE_RECORD_PRE:
LogData<3> = Name LogData<3> = Name
LogData<4> = Notes LogData<4> = Notes
Logging_Services('AppendLog', objLog, LogData, @RM, @FM) Logging_Services('AppendLog', objLog, LogData, @RM, @FM)
ActionFlow = ACTION_STOP$
return return
DELETE_RECORD: DELETE_RECORD:
Notes = RetStack()
Swap @FM with ' | ' in Notes
LogData = ''
LogData<1> = LoggingDTM
LogData<2> = @User4
LogData<3> = Name
LogData<4> = Notes
Logging_Services('AppendLog', objLog, LogData, @RM, @FM)
ActionFlow = ACTION_STOP$
return return
@ -990,3 +1002,4 @@ Restore_System_Variables:
return return

View File

@ -86,10 +86,10 @@ EQU READONLY_GREEN$ TO 192 + (220*256) + (192*65536)
Declare subroutine ErrMsg, Set_Status, obj_WO_Mat, obj_WO_Mat_Log, obj_RDS, Set_Property, Send_Event, Database_Services Declare subroutine ErrMsg, Set_Status, obj_WO_Mat, obj_WO_Mat_Log, obj_RDS, Set_Property, Send_Event, Database_Services
Declare subroutine Dialog_Box, Qa_Services, Obj_React_Ll, Start_Window, obj_React_Status, Reactor_Services, Rds_Services Declare subroutine Dialog_Box, Qa_Services, Obj_React_Ll, Start_Window, obj_React_Status, Reactor_Services, Rds_Services
Declare subroutine Lot_Event_Services, Override_Log_Services Declare subroutine Lot_Event_Services, Override_Log_Services, Logging_Services
Declare function Dialog_Box, Msg, MemberOf, obj_WO_Mat, Database_Services, Get_Property, obj_React_Status, Get_Status Declare function Dialog_Box, Msg, MemberOf, obj_WO_Mat, Database_Services, Get_Property, obj_React_Status, Get_Status
Declare function QA_Services, Database_Services, Rds_Services, Obj_Calendar, Override_Log_Services, Max, Supplement_Services Declare function QA_Services, Database_Services, Rds_Services, Obj_Calendar, Override_Log_Services, Max, Supplement_Services
Declare function Datetime, Test_Run_Services Declare function Datetime, Test_Run_Services, Environment_Services, Logging_Services
SubclassInfo = Form_Services('FindSubclassControl') SubclassInfo = Form_Services('FindSubclassControl')
Subclass = SubclassInfo<1> Subclass = SubclassInfo<1>
@ -100,11 +100,11 @@ If Event EQ 'OLE' then
Transfer Param1 to Event Transfer Param1 to Event
Transfer Param2 to Param1 Transfer Param2 to Param1
Transfer Param3 to Param2 Transfer Param3 to Param2
* Transfer Param4 to Param3 Transfer Param4 to Param3
* Transfer Param5 to Param4 Transfer Param5 to Param4
* Transfer Param6 to Param5 Transfer Param6 to Param5
* Transfer Param7 to Param6 Transfer Param7 to Param6
* Transfer Param8 to Param7 Transfer Param8 to Param7
end end
GoToEvent Event for CtrlEntID GoToEvent Event for CtrlEntID
@ -463,7 +463,19 @@ Event PUB_SIGN.CLICK()
OverrideUser = Response<2> OverrideUser = Response<2>
If Valid then If Valid then
Lot_Event_Services('CreateLotEvent', RDSNo, Datetime(), 'UNSIGN_LOAD', 'Load stage unsigned', 'Reactor', @User4, True$, 'RDS')
Machine = Environment_Services('GetServer')
Headers = 'Logging DTM' : @FM : 'Machine' : @FM : 'Log'
ColumnWidths = 20 : @FM : 15 : @FM : 300
LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\Lot'
makeDirSuccess = Utility("MAKEDIR", LogPath)
LogFileName = 'R':RDSNo:'.csv'
objLog = Logging_Services('NewLog', LogPath, LogFileName, CRLF$, ' ', Headers, ColumnWidths, False$, False$)
LogData = ''
LogData<1> = Oconv(Date(), 'D4/') : ' ' : Oconv(Time(), 'MTS') ; // Logging DTM
LogData<2> = Machine
LogData<3> = 'LOAD stage unsigned for RDS ':RDSNo:' by user ':@User4
Logging_Services('AppendLog', objLog, LogData, @RM, @FM, False$)
// 4. Remove WO_MAT Unload signature, date, and time // 4. Remove WO_MAT Unload signature, date, and time
WOMatRec = Database_Services('ReadDataRow', 'WO_MAT', WOMatKey) WOMatRec = Database_Services('ReadDataRow', 'WO_MAT', WOMatKey)
@ -728,4 +740,3 @@ OLE_LL_Status:
return return

View File

@ -59,7 +59,6 @@ $insert COMPANY_EQUATES
$insert WO_MAT_QA_EQUATES $insert WO_MAT_QA_EQUATES
$insert WAFER_COUNTER_EQUATES $insert WAFER_COUNTER_EQUATES
Equ COL$LOG_FILE to 1 Equ COL$LOG_FILE to 1
Equ COL$LOG_DTM to 2 Equ COL$LOG_DTM to 2
Equ COL$ACTION to 3 Equ COL$ACTION to 3
@ -90,8 +89,10 @@ EQU APPORANGE$ TO 255 + (176*256) + (0*65536)
Declare subroutine ErrMsg, Set_Status, obj_WO_Mat, obj_WO_Mat_Log, obj_RDS, RDS_Services, Signature_Services, obj_Notes Declare subroutine ErrMsg, Set_Status, obj_WO_Mat, obj_WO_Mat_Log, obj_RDS, RDS_Services, Signature_Services, obj_Notes
Declare subroutine Comm_RDS, WO_Mat_QA_Services, Wafer_Counter_Services, Dialog_Box, Lot_Event_Services Declare subroutine Comm_RDS, WO_Mat_QA_Services, Wafer_Counter_Services, Dialog_Box, Lot_Event_Services
Declare subroutine Logging_Services
Declare function Dialog_Box, Msg, MemberOf, obj_WO_Mat, Database_Services, QA_Services, Signature_Services Declare function Dialog_Box, Msg, MemberOf, obj_WO_Mat, Database_Services, QA_Services, Signature_Services
Declare function RDS_Services, Wafer_Counter_Services, Datetime, Supplement_Services Declare function RDS_Services, Wafer_Counter_Services, Datetime, Supplement_Services, Environment_Services
Declare function Logging_Services
SubclassInfo = Form_Services('FindSubclassControl') SubclassInfo = Form_Services('FindSubclassControl')
Subclass = SubclassInfo<1> Subclass = SubclassInfo<1>
@ -102,11 +103,11 @@ If Event EQ 'OLE' then
Transfer Param1 to Event Transfer Param1 to Event
Transfer Param2 to Param1 Transfer Param2 to Param1
Transfer Param3 to Param2 Transfer Param3 to Param2
* Transfer Param4 to Param3 Transfer Param4 to Param3
* Transfer Param5 to Param4 Transfer Param5 to Param4
* Transfer Param6 to Param5 Transfer Param6 to Param5
* Transfer Param7 to Param6 Transfer Param7 to Param6
* Transfer Param8 to Param7 Transfer Param8 to Param7
end end
GoToEvent Event for CtrlEntID GoToEvent Event for CtrlEntID
@ -603,8 +604,18 @@ Event SIGN_BUTTON.CLICK()
Set_Property(@Window : '.POST_EPI_SUP_SIG_DATE', 'TEXT', SigDt) Set_Property(@Window : '.POST_EPI_SUP_SIG_DATE', 'TEXT', SigDt)
Set_Property(@Window : '.POST_EPI_SUP_SIG_TIME', 'TEXT', SigTmPlusOne) Set_Property(@Window : '.POST_EPI_SUP_SIG_TIME', 'TEXT', SigTmPlusOne)
** Create LOT_EVENT ** Machine = Environment_Services('GetServer')
Lot_Event_Services('CreateLotEvent', RDSNo, Datetime(), 'SIGN_FQA', '', '', @USER4, True$, 'RDS') Headers = 'Logging DTM' : @FM : 'Machine' : @FM : 'Log'
ColumnWidths = 20 : @FM : 15 : @FM : 300
LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\Lot'
makeDirSuccess = Utility("MAKEDIR", LogPath)
LogFileName = 'R':RDSNo:'.csv'
objLog = Logging_Services('NewLog', LogPath, LogFileName, CRLF$, ' ', Headers, ColumnWidths, False$, False$)
LogData = ''
LogData<1> = Oconv(Date(), 'D4/') : ' ' : Oconv(Time(), 'MTS') ; // Logging DTM
LogData<2> = Machine
LogData<3> = 'FQA stage signed for RDS ':RDSNo:' by user ':@User4
Logging_Services('AppendLog', objLog, LogData, @RM, @FM, False$)
/* Sync up the RDS record with WO_MAT */ /* Sync up the RDS record with WO_MAT */
IOOptions = Get_Property(@Window, 'IOOPTIONS') IOOptions = Get_Property(@Window, 'IOOPTIONS')

View File

@ -282,6 +282,8 @@ Event PUB_SIGN.CLICK()
If ( (WONo NE '') and (CassNo NE '') ) then If ( (WONo NE '') and (CassNo NE '') ) then
WoMatKey = WONo:'*':CassNo WoMatKey = WONo:'*':CassNo
If RowExists('WO_MAT', WOMatKey) then If RowExists('WO_MAT', WOMatKey) then
WoMatRecord = Database_Services('ReadDataRow', 'WO_MAT', WoMatKey)
If Error_Services('NoError') then
IsLastCassetteInWo = WO_MAT_Services('CassetteIsLastInWo', WoMatKey) IsLastCassetteInWo = WO_MAT_Services('CassetteIsLastInWo', WoMatKey)
If Error_Services('NoError') then If Error_Services('NoError') then
If IsLastCassetteInWo then If IsLastCassetteInWo then
@ -295,8 +297,6 @@ Event PUB_SIGN.CLICK()
NextEventIsBlock = Schedule_Services('NextEventIsBlock', Reactor) NextEventIsBlock = Schedule_Services('NextEventIsBlock', Reactor)
end end
If NextEventScheduled EQ False$ or NextEventHasSamePsn EQ False$ or NextEventIsBlock EQ True$ then If NextEventScheduled EQ False$ or NextEventHasSamePsn EQ False$ or NextEventIsBlock EQ True$ then
WoMatRecord = Database_Services('ReadDataRow', 'WO_MAT', WoMatKey)
If Error_Services('NoError') then
If WOMatRecord NE '' then If WOMatRecord NE '' then
WoMatRecord<WO_MAT_LAST_CASSETTE_TEST_WAFER_ACK_REQ$> = True$ WoMatRecord<WO_MAT_LAST_CASSETTE_TEST_WAFER_ACK_REQ$> = True$
TestWaferRanSinceLoad = WoMatRecord<WO_MAT_LAST_CASSETTE_TEST_WAFER_RAN$> TestWaferRanSinceLoad = WoMatRecord<WO_MAT_LAST_CASSETTE_TEST_WAFER_RAN$>
@ -316,18 +316,23 @@ Event PUB_SIGN.CLICK()
If TWLogResult NE True$ then If TWLogResult NE True$ then
ErrMsg = 'Unload blocked! You must run a test wafer before signing the unload' ErrMsg = 'Unload blocked! You must run a test wafer before signing the unload'
end end
If ErrMsg NE '' then
Database_Services('WriteDataRow', 'WO_MAT', WoMatKey, WoMatRecord, True$, False$, False$)
If Error_Services('HasError') then
ErrMsg = Error_Services('GetMessage')
end
end
end end
end end
end else end else
ErrMsg = 'WO_MAT record for ':WOMatKey:' is null!' ErrMsg = 'WO_MAT record for ':WOMatKey:' is null!'
end end
end
end
end
end else end else
ErrMsg = Error_Services('GetMessage') ErrMsg = Error_Services('GetMessage')
end end
end
Database_Services('WriteDataRow', 'WO_MAT', WoMatKey, WoMatRecord, True$, False$, False$)
end
end
end else end else
ErrMsg = 'WO_MAT ':WOMatKey:' does not exist!' ErrMsg = 'WO_MAT ':WOMatKey:' does not exist!'
end end
@ -468,3 +473,4 @@ Setup_OLE_Controls:
return return

View File

@ -2064,6 +2064,11 @@ Service CreateReactModeChange(UserID, ReactNo, Mode, ModeSubCat, ModeText, Force
Case ( AbortAlarmOrderActive and (SelE10State _EQC 'Productive') ) Case ( AbortAlarmOrderActive and (SelE10State _EQC 'Productive') )
ErrorMsg = "An ABORT/ALARM Checklist is active for this reactor and must be completed or overridden in order to change to a productive state." ErrorMsg = "An ABORT/ALARM Checklist is active for this reactor and must be completed or overridden in order to change to a productive state."
Case ( (Mode _EQC 'WAITING_FOR_MAINTENANCE_UNSCHEDULED') and IndexC(ModeSubCat, 'ABORT/ALARM', 1) )
// Do not create an ABORT/ALARM NICA order yet as maintenance may determine the appropriate ABORT/ALARM sub mode to be different than
// the operator. This avoids creating a NICA order for the wrong flow.
CreateAbortAlarmOrder = False$
Case ( AbortAlarmFromIntrusiveMaintRequired and IndexC(ModeSubCat, 'ABORT/ALARM', 1) and (ModeSubCatFlowId NE '') and (ChecklistIds NE '') ) Case ( AbortAlarmFromIntrusiveMaintRequired and IndexC(ModeSubCat, 'ABORT/ALARM', 1) and (ModeSubCatFlowId NE '') and (ChecklistIds NE '') )
// INTRUSIVE_MAINT FIRST_PRODUCT_RUN_THICK or FIRST_PRODUCT_RUN_HGCV checklist started and // INTRUSIVE_MAINT FIRST_PRODUCT_RUN_THICK or FIRST_PRODUCT_RUN_HGCV checklist started and
// ABORT/ALARM mode entered, so create an ABORT/ALARM order to contain product in reactor. // ABORT/ALARM mode entered, so create an ABORT/ALARM order to contain product in reactor.
@ -2099,7 +2104,11 @@ Service CreateReactModeChange(UserID, ReactNo, Mode, ModeSubCat, ModeText, Force
If CreateAbortAlarmOrder then If CreateAbortAlarmOrder then
Nica_Orders_Services('CreateNewOrder', 'REACTOR', ReactNo, 'ABORT_ALARM', ModeSubCatFlowId, ModeSubCatRespLvl, ChecklistIds, Intrusive) Nica_Orders_Services('CreateNewOrder', 'REACTOR', ReactNo, 'ABORT_ALARM', ModeSubCatFlowId, ModeSubCatRespLvl, ChecklistIds, Intrusive)
If Error_Services('HasError') then
ErrorMsg = Error_Services('GetMessage')
end else
RlComment = 'ABORT/ALARM initiated for flow ':ModeSubCatFlowId:'.' RlComment = 'ABORT/ALARM initiated for flow ':ModeSubCatFlowId:'.'
end
end end
end end
@ -2171,17 +2180,21 @@ Service CreateReactModeChange(UserID, ReactNo, Mode, ModeSubCat, ModeText, Force
EntryId = UserID EntryId = UserID
RLRec = '' RLRec = ''
RLRec<reactor_log_start_date$> = CurDate RLRec<REACTOR_LOG_START_DATE$> = CurDate
RLRec<reactor_log_start_time$> = CurTime RLRec<REACTOR_LOG_START_TIME$> = CurTime
RLRec<reactor_log_reactor$> = ReactNo RLRec<REACTOR_LOG_REACTOR$> = ReactNo
if NewModeCategory EQ 'MAINTENANCE' then If NewModeCategory EQ 'MAINTENANCE' then
RLRec<reactor_log_category$> = 'M' ;* for maintenance RLRec<REACTOR_LOG_CATEGORY$> = 'M' ;* for maintenance
end
RLRec<REACTOR_LOG_ENTRY_ID$> = UserID
RLRec<REACTOR_LOG_ENTRY_DATE$> = CurDate
RLRec<REACTOR_LOG_REACT_UTIL_ID$> = NewRUKey
RLRec<REACTOR_LOG_REACT_PROB_CAT_ID$> = ModeSubCatID
If (RLComment NE '') then
RLRec<REACTOR_LOG_NOTES$> = RLComment
RLRec<REACTOR_LOG_NOTES_DTMS$> = CurDate + (CurTime / SECONDS_IN_DAY$)
RLRec<REACTOR_LOG_NOTES_USERS$> = UserID
end end
RLRec<reactor_log_entry_id$> = UserID
RLRec<reactor_log_entry_date$> = CurDate
RLRec<reactor_log_react_util_id$> = NewRUKey
RLRec<reactor_log_react_prob_cat_id$> = ModeSubCatID
CurrWoNo = Xlate('CONFIG', 'WO_DAILY_SCHED':ReactNo, 'F2', 'X') CurrWoNo = Xlate('CONFIG', 'WO_DAILY_SCHED':ReactNo, 'F2', 'X')
CurrWoNo = CurrWoNo[1, 'F '] CurrWoNo = CurrWoNo[1, 'F ']
If CurrWoNo NE '' then If CurrWoNo NE '' then
@ -2292,7 +2305,6 @@ Service CreateReactModeChange(UserID, ReactNo, Mode, ModeSubCat, ModeText, Force
// Reopen previous react mode // Reopen previous react mode
Database_Services('WriteDataRow', 'REACT_MODE_NG', NGPrevModeKey, PrevModeRec) Database_Services('WriteDataRow', 'REACT_MODE_NG', NGPrevModeKey, PrevModeRec)
end else end else
If RlComment NE '' then Reactor_Log_Services('AddComment', ReactNo, RlComment, UserID)
If SelE10State _EQC 'Productive' then If SelE10State _EQC 'Productive' then
// Reset ABORT/ALARM flag // Reset ABORT/ALARM flag
Open 'REACTOR' to hReactor then Open 'REACTOR' to hReactor then
@ -3562,6 +3574,53 @@ Service GetReactorDownLL(ReactNo)
end service end service
Service GetReactorsWithDownLLByDtm(DtmToCheck, ReactType)
ErrMsg = ''
SLLReactors = ''
If DtmToCheck NE '' then
AllReactors = Reactor_Services('GetReactorNumbers', ReactType)
If AllReactors NE '' then
for each ReactNo in AllReactors using @FM
PickPlaceFlag = XLATE('REACTOR', ReactNo, REACTOR_PICK_PLACE$, 'X')
If PickPlaceFlag then
Open 'DICT.REACT_LL' to DictReactLL then
SearchString = ''
SearchString := 'REACT_NO':@VM:ReactNo:@FM
ReactLLKeys = ''
Btree.Extract(SearchString, 'REACT_LL', DictReactLL, ReactLLKeys)
For each ReactLLKey in ReactLLKeys using @VM
ReactLLRec = Database_Services('ReadDataRow', 'REACT_LL', ReactLLKey, True$, 0, False$)
ReactLLStartDTM = Field(ReactLLKey, '*', 2)
ReactLLEndDTM = ReactLLRec<REACT_LL_STOP_DTM$>
ReactLLApplicable = false$
If ReactLLStartDTM LE DtmToCheck AND (ReactLLEndDTM EQ '' OR ReactLLEndDtm GT DtmToCheck) then
Locate ReactNo in SLLReactors using @VM setting iPos else
SLLReactors<1, -1> = ReactNo
end
end
Next ReactLLKey
end else
ErrMsg = 'Unable to open the REACT_LL dictionary.'
end
end
Next ReactNo
end else
ErrMsg = 'No Reactor IDs found!'
end
end else
ErrMsg = 'Datetime to check variable was null.'
end
If ErrMsg NE '' then
Error_Services('Add', ErrMsg)
end
Response = SLLReactors
end service
Service GetReactorLoadCountLimit(ReactNo) Service GetReactorLoadCountLimit(ReactNo)
@ -4361,3 +4420,4 @@ ClearCursors:
return return

View File

@ -137,6 +137,16 @@ CreateHALItem:
RepJSON = Report_Services('GetOpenTestWaferLotWIPReportJson') RepJSON = Report_Services('GetOpenTestWaferLotWIPReportJson')
Case ReportID = 'OpenNCRReport' Case ReportID = 'OpenNCRReport'
RepJson = Report_Services('GetOpenNCRReportJson') RepJson = Report_Services('GetOpenNCRReportJson')
Case ReportID = 'SLLReport'
//Single Load Lock Report from Metrology Services
ReportStartDtm = Http_Services('GetQueryField', 'StartDate')
ReportEndDtm = Http_Services('GetQueryField', 'EndDate')
If ReportStartDtm NE '' AND ReportEndDtm NE '' then
RepJson = Report_Services('GetSLLReportJson', ReportStartDtm, ReportEndDtm)
end else
Error_Services('Add', 'Missing parameters for report.')
end
Case Otherwise$ Case Otherwise$
Error_Services('Add', 'Unsupported report') Error_Services('Add', 'Unsupported report')
End Case End Case
@ -233,3 +243,4 @@ API reports.GET
HTTP_Resource_Services('LoremIpsum') HTTP_Resource_Services('LoremIpsum')
end api end api

View File

@ -82,7 +82,7 @@ Declare function Set_Printer, Get_Printer, Msg, Get_Status, Printer_Select, ob
Declare function Schedule_Services, Error_Services, Location_Services, SRP_Array, Signature_Services, obj_RDS_Test Declare function Schedule_Services, Error_Services, Location_Services, SRP_Array, Signature_Services, obj_RDS_Test
Declare function Epi_Part_Services, SRP_Math, Database_Services, SRP_JSON, Reactor_Services, SRP_Datetime Declare function Epi_Part_Services, SRP_Math, Database_Services, SRP_JSON, Reactor_Services, SRP_Datetime
Declare function SRP_Array, Environment_Services, Logging_Services, Datetime, Select_Into, Wafer_Counter_Services Declare function SRP_Array, Environment_Services, Logging_Services, Datetime, Select_Into, Wafer_Counter_Services
Declare function Lot_Services, Test_Run_Services, NCR_Services Declare function Lot_Services, Test_Run_Services, NCR_Services, Date_Services
Equ TAB TO \09\ Equ TAB TO \09\
@ -2367,6 +2367,53 @@ Service GetOpenNCRReportJson()
Response = OpenNCRReportJson Response = OpenNCRReportJson
end service end service
/* * * * * *
Called from Reporting Services
* * * * * */
Service GetSLLReportJson(FromDt, ToDt)
FromDt = IConv(FromDt, 'D')
ToDt = IConv(ToDt, 'D')
ErrorMessage = ''
SLLReportJson = ''
objSLLReportJson = ''
If FromDt NE '' OR ToDt NE '' then
If SRP_Json(objSLLReportJson, 'New', 'Array') then
For StartDt = FromDt to ToDt
ThisDate = Date_Services('ConvertDateTimeToISO8601', StartDt)
ThisDtASMDownLL = Reactor_Services('GetReactorsWithDownLLByDtm', StartDt + 1, 'ASM')
ThisDtASMPlusDownLL = Reactor_Services('GetReactorsWithDownLLByDtm', StartDt + 1, 'ASM+')
ThisDtHTRDownLL = Reactor_Services('GetReactorsWithDownLLByDtm', StartDt + 1, 'HTR')
ThisDtASMDownLLCount = DCount(ThisDtASMDownLL, @VM) + DCount(ThisDtASMPlusDownLL, @VM)
ThisDtHTRDownLLCount = DCount(ThisDtHTRDownLL, @VM)
objSLLDay = ''
If SRP_Json(objSLLDay, 'New', 'Object') then
SRP_Json(objSLLDay, 'SetValue', 'Date', ThisDate)
SRP_Json(objSLLDay, 'SetValue', 'ASM', ThisDtASMDownLLCount)
SRP_Json(objSLLDay, 'SetValue', 'HTR', ThisDtHTRDownLLCount)
SRP_Json(objSLLReportJson, 'Add', objSLLDay)
SRP_Json(objSLLDay, 'Release')
end
Next StartDt
SLLReportJson = SRP_Json(objSLLReportJson, 'Stringify', 'Fast')
SRP_Json(objSLLReportJson, 'Release')
end else
ErrorMessage = 'Error creating the root JSON for the report.'
end
end else
ErrorMessage = 'From Date or To Date was null.'
end
If ErrorMessage NE '' then
Error_Services('Add', ErrorMessage)
end
Response = SLLReportJson
end service
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Internal GoSubs // Internal GoSubs
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@ -2388,3 +2435,4 @@ OipiPrintError:
return return

View File

@ -1141,6 +1141,38 @@ Service OpenOIWizardReturnToFabInBrowser(RTFId)
end service end service
Service GetReturnedToFab(CassID)
If CassID NE '' then
RTFRecords = ''
ErrorMessage = ''
If CassId NE '' then
table = "RETURN_TO_FAB_LOTS"
Open "DICT ":table To @DICT Else
ErrorMessage = 'Error opening RETURN_TO_FAB_LOTS dictionary'
End
If ErrorMessage EQ '' then
srch_strng = "CASS_ID":@VM:CassId:@FM
option = ""
flag = ""
Btree.Extract(srch_strng, table, @DICT, RTFRecords, option, flag)
end
end else
ErrorMessage = 'Error getting return to fab record by cass. ID. Cassette ID was null'
end
end else
ErrorMessage = 'Missing CassID parameter.'
end
If ErrorMessage EQ '' then
If RTFRecords = '' then
Response = False$
end else
Response = True$
end
end else
Error_Services('Add', ErrorMessage)
end
end service
Service InitializeReturnToFabLotOperations(LotId) Service InitializeReturnToFabLotOperations(LotId)
ErrorMessage = '' ErrorMessage = ''

View File

@ -1142,6 +1142,8 @@ Service ProcessScanData(ScanID, ScanJSON)
CassNo = Xlate('RDS', RDSNo, 'RUN_ORDER_NUM', 'X') CassNo = Xlate('RDS', RDSNo, 'RUN_ORDER_NUM', 'X')
WoMatKey = WO:'*':CassNo WoMatKey = WO:'*':CassNo
WoMatRec = Database_Services('ReadDataRow', 'WO_MAT', WoMatKey) WoMatRec = Database_Services('ReadDataRow', 'WO_MAT', WoMatKey)
if Error_Services('NoError') then
If WoMatRec NE '' then
LastCassInWoTestWaferAckReq = WoMatRec<WO_MAT_LAST_CASSETTE_TEST_WAFER_ACK_REQ$> LastCassInWoTestWaferAckReq = WoMatRec<WO_MAT_LAST_CASSETTE_TEST_WAFER_ACK_REQ$>
LastCassInWoTestWaferAcked = WoMatRec<WO_MAT_LAST_CASSETTE_TEST_WAFER_ACKED$> LastCassInWoTestWaferAcked = WoMatRec<WO_MAT_LAST_CASSETTE_TEST_WAFER_ACKED$>
LastCassInWoTestWaferReqMsg = '' LastCassInWoTestWaferReqMsg = ''
@ -1187,6 +1189,14 @@ Service ProcessScanData(ScanID, ScanJSON)
end end
end end
end end
end else
ErrorMessage = 'WO_MAT record was null.'
Error_Services('Add', ErrorMessage)
end
end else
ErrorMessage = 'Failure to read cassette record. ' : Error_Services('GetMessage')
Error_Services('Add', ErrorMessage)
end
end end
end end
end else end else
@ -1487,6 +1497,7 @@ Service AcceptScan(ScanID, ScanJSON)
// Check if cassette field is populated. If so, then check the cassette's current status to // Check if cassette field is populated. If so, then check the cassette's current status to
// determine what the next action will be (i.e. Pre-Epi+Load, Unload, etc.) // determine what the next action will be (i.e. Pre-Epi+Load, Unload, etc.)
CassetteID = CassetteIDs<0, 1> CassetteID = CassetteIDs<0, 1>
*if CassetteId EQ 1005860 then debug
TestWaferLots = ScansRow<SCANS.TW_LOT_ID$> TestWaferLots = ScansRow<SCANS.TW_LOT_ID$>
Begin Case Begin Case
Case CassetteID NE '' Case CassetteID NE ''
@ -1534,6 +1545,7 @@ Service AcceptScan(ScanID, ScanJSON)
Continue = False$ Continue = False$
end end
If Continue then If Continue then
*if RDSNo EQ 1006721 then debug
PreStageSigned = QA_Services('SignPreEpiStage', RDSNo, Username, WaferQty, Reactor, 1) PreStageSigned = QA_Services('SignPreEpiStage', RDSNo, Username, WaferQty, Reactor, 1)
If PreStageSigned EQ True$ then If PreStageSigned EQ True$ then
LoadStageSigned = QA_Services('SignLoadStage', RDSNo, USername, WaferQty, LLSide, 1) LoadStageSigned = QA_Services('SignLoadStage', RDSNo, USername, WaferQty, LLSide, 1)
@ -2402,3 +2414,4 @@ ClearCursors:
return return

View File

@ -62,11 +62,11 @@ Equ COL$TAGS to 9
Equ COL$TOOL_ID to 10 Equ COL$TOOL_ID to 10
Declare function obj_Prod_Spec, RDS_Services, Error_Services, Signature_Services, Memory_Services, obj_RDS_Test Declare function obj_Prod_Spec, RDS_Services, Error_Services, Signature_Services, Memory_Services, obj_RDS_Test
Declare function SRP_Array Declare function SRP_Array, Environment_Services, GetTickCount, QA_Services, Datetime, Supplement_Services
Declare function Database_Services, obj_WO_Mat, Dialog_Box, MemberOf, Msg, QA_Services, Datetime, Supplement_Services Declare function Database_Services, obj_WO_Mat, Dialog_Box, MemberOf, Msg, Logging_Services
Declare function Environment_Services, GetTickCount
Declare subroutine Error_Services, Popup, Memory_Services, SRP_Stopwatch, Set_Status, Database_Services, obj_WO_Mat Declare subroutine Error_Services, Popup, Memory_Services, SRP_Stopwatch, Set_Status, Database_Services, obj_WO_Mat
Declare subroutine Obj_Notes, Signature_Services, Obj_WO_Mat_Log, ErrMsg, Obj_Rds, Lot_Event_Services, Mona_Services Declare subroutine Obj_Notes, Signature_Services, Obj_WO_Mat_Log, ErrMsg, Obj_Rds, Lot_Event_Services, Mona_Services
Declare subroutine Logging_Services
PSNKey = ServiceKeyID PSNKey = ServiceKeyID
ReactorKey = ServiceKeyID ReactorKey = ServiceKeyID
@ -224,6 +224,8 @@ end service
Service CheckSigOrder(WOMatKey, CurrStage, UseCaching, RDSNo) Service CheckSigOrder(WOMatKey, CurrStage, UseCaching, RDSNo)
ErrorMsg = ''
StartTick = GetTickCount() StartTick = GetTickCount()
MetricName = 'CheckSigOrder' MetricName = 'CheckSigOrder'
@ -260,17 +262,15 @@ Service CheckSigOrder(WOMatKey, CurrStage, UseCaching, RDSNo)
Begin Case Begin Case
Case ( Not(MemberOf(@User4, 'BYPASS') ) and ( (CurrStage EQ 'QA') or (CurrStage EQ 'MO_QA') ) and (PrevStageSig EQ @User4) ) Case ( Not(MemberOf(@User4, 'BYPASS') ) and ( (CurrStage EQ 'QA') or (CurrStage EQ 'MO_QA') ) and (PrevStageSig EQ @User4) )
ErrorMsg = 'FQA stage signature cannot match previous step ':PrevStage:' signature. ':WOMatKey:' (':Service:')' ErrorMsg = 'FQA stage signature cannot match previous step ':PrevStage:' signature. ':WOMatKey:' (':Service:')'
Error_Services('Add', ErrorMsg)
Case PrevStageComp EQ False$ Case PrevStageComp EQ False$
ErrorMsg = 'Previous step ':PrevStage:' is not signed. ':WOMatKey:' (':Service:')' ErrorMsg = 'Previous step ':PrevStage:' is not signed. ':WOMatKey:' (':Service:')'
Error_Services('Add', ErrorMsg)
Case CurrStageComp EQ True$ Case CurrStageComp EQ True$
// Allow user to re-sign. This may be necessary in certain cases such as when multiple surfscans // Allow user to re-sign. This may be necessary in certain cases such as when multiple surfscans
// have taken place and one still needs to be signed. // have taken place and one still needs to be signed.
Response = True$ Response = True$
Case Error_Services('HasError') EQ True$ Case Error_Services('HasError') EQ True$
// Error message already in stack. // Error message already in stack.
Null ErrorMsg = Error_Services('GetMessage')
Case Otherwise$ Case Otherwise$
// Ok // Ok
Response = True$ Response = True$
@ -282,6 +282,11 @@ Service CheckSigOrder(WOMatKey, CurrStage, UseCaching, RDSNo)
EndTick = GetTickCount() EndTick = GetTickCount()
Mona_Services('QueueLatencyAndCountMetrics', MonaResource, MetricName, StartTick, EndTick) Mona_Services('QueueLatencyAndCountMetrics', MonaResource, MetricName, StartTick, EndTick)
If ErrorMsg NE '' then
Error_Services('Add', ErrorMsg)
end
End Service End Service
@ -2844,6 +2849,14 @@ end service
Service UnsignFQAStage(RDSNo) Service UnsignFQAStage(RDSNo)
Machine = Environment_Services('GetServer')
Headers = 'Logging DTM' : @FM : 'Machine' : @FM : 'Log'
ColumnWidths = 20 : @FM : 15 : @FM : 300
LogPath = Environment_Services('GetApplicationRootPath') : '\LogFiles\Lot'
makeDirSuccess = Utility("MAKEDIR", LogPath)
LogFileName = 'R':RDSNo:'.csv'
objLog = Logging_Services('NewLog', LogPath, LogFileName, CRLF$, ' ', Headers, ColumnWidths, False$, False$)
IsEPP = Rds_Services('IsEpiPro', RDSNo) IsEPP = Rds_Services('IsEpiPro', RDSNo)
If IsEpp EQ False$ then If IsEpp EQ False$ then
Database_Services('ActivateRecord', 'RDS', RDSNo) Database_Services('ActivateRecord', 'RDS', RDSNo)
@ -2888,8 +2901,11 @@ Service UnsignFQAStage(RDSNo)
{SUP_VER_SIG_DATE} = '' {SUP_VER_SIG_DATE} = ''
{SUP_VER_SIG_TIME} = '' {SUP_VER_SIG_TIME} = ''
Database_Services('WriteDataRow', 'RDS', RDSNo, @Record, True$, False$, False$) Database_Services('WriteDataRow', 'RDS', RDSNo, @Record, True$, False$, False$)
** Create LOT_EVENT ** LogData = ''
Lot_Event_Services('CreateLotEvent', RDSNo, Datetime(), 'UNSIGN_FQA', '', '', @USER4, True$, 'RDS') LogData<1> = Oconv(Date(), 'D4/') : ' ' : Oconv(Time(), 'MTS') ; // Logging DTM
LogData<2> = Machine
LogData<3> = 'FQA stage unsigned for RDS ':RDSNo:' by user ':@User4
Logging_Services('AppendLog', objLog, LogData, @RM, @FM, False$)
end else end else
Error_Services('Add', 'Error accessing RDS.') Error_Services('Add', 'Error accessing RDS.')
end end
@ -2917,7 +2933,3 @@ GetMostRecentSig:
return return

View File

@ -128,6 +128,12 @@ Service CreateSupplement(LotType=LOTTYPES, LotID, Stage=STAGES, SupplText, Entry
NewSupRec<SUPPLEMENTS_SUPPL_TEXT$> = SupplText NewSupRec<SUPPLEMENTS_SUPPL_TEXT$> = SupplText
NewSupRec<SUPPLEMENTS_ENTRY_USER$> = EntryUser NewSupRec<SUPPLEMENTS_ENTRY_USER$> = EntryUser
NewSupRec<SUPPLEMENTS_ENTRY_DATETIME$> = Datetime() NewSupRec<SUPPLEMENTS_ENTRY_DATETIME$> = Datetime()
If Stages NE False$ then
StageList = Stages<1>
Locate Stage in StageList using @VM setting StageIndex then
NewSupRec<SUPPLEMENTS_STAGE_INDEX$> = StageIndex
end
end
Database_Services('WriteDataRow', 'SUPPLEMENTS', SupplID, NewSupRec, True$, False$, False$) Database_Services('WriteDataRow', 'SUPPLEMENTS', SupplID, NewSupRec, True$, False$, False$)
If Error_Services('NoError') then If Error_Services('NoError') then
Response = SupplID Response = SupplID
@ -305,32 +311,7 @@ Service GetSupplementsForLot(LotType=LOTTYPES, LotID, Stage=STAGES)
Response = False$ Response = False$
If ( (LotType NE '') and (LotID NE '') ) then If ( (LotType NE '') and (LotID NE '') ) then
If (Stage EQ '') then If Stage EQ '' then Stage = '#0'
KeyList = ''
Query = ''
Query<1> = 'LOT_TYPE' : @VM : LotType
Query<2> = 'LOT_ID' : @VM : LotID : @FM
Flag = ''
Open 'DICT.SUPPLEMENTS' to hDict then
Btree.Extract(Query, 'SUPPLEMENTS', hDict, KeyList, 'E', Flag)
If (Flag EQ 0) then
If (KeyList NE '') then
SupplementList = ''
Stages = Supplement_Services('GetStagesForLot', LotType, LotID)
StageCount = Dcount(Stages<1>, @VM)
For I = 1 to StageCount
SupplementStage = Supplement_Services('GetSupplementsForLot', LotType, LotID, Stages<1,I>)
If SupplementStage NE False$ then SupplementList<-1> = SupplementStage
Next I
If SupplementList NE '' then Response = SupplementList
end
end else
Error_Services('Add', 'Error in ':Service:' service. Error calling Btree.Extract')
end
end else
Error_Services('Add', 'Error in ':Service:' service. Error opening SUPPLEMENTS dictionary.')
end
end else
StageSupplementList = '' StageSupplementList = ''
Query = '' Query = ''
Query<1> = 'LOT_TYPE' : @VM : LotType Query<1> = 'LOT_TYPE' : @VM : LotType
@ -340,14 +321,20 @@ Service GetSupplementsForLot(LotType=LOTTYPES, LotID, Stage=STAGES)
Open 'DICT.SUPPLEMENTS' to hDict then Open 'DICT.SUPPLEMENTS' to hDict then
Btree.Extract(Query, 'SUPPLEMENTS', hDict, StageSupplementList, 'E', Flag) Btree.Extract(Query, 'SUPPLEMENTS', hDict, StageSupplementList, 'E', Flag)
If (Flag EQ 0) then If (Flag EQ 0) then
If StageSupplementList NE '' then Response = StageSupplementList If StageSupplementList NE '' then
StageIndexes = Xlate('SUPPLEMENTS', StageSupplementList, 'STAGE_INDEX', 'X')
SortArray = StageIndexes:@FM:StageSupplementList
SortArray = SRP_Array('SortRows', SortArray, 'AR1', 'ARRAY', @FM, @VM)
SortedStageSupplementList = SortArray<2>
Convert @VM to @FM in SortedStageSupplementList
Response = SortedStageSupplementList
end
end else end else
Error_Services('Add', 'Error in ':Service:' service. Error calling Btree.Extract') Error_Services('Add', 'Error in ':Service:' service. Error calling Btree.Extract')
end end
end else end else
Error_Services('Add', 'Error in ':Service:' service. Error opening SUPPLEMENTS dictionary.') Error_Services('Add', 'Error in ':Service:' service. Error opening SUPPLEMENTS dictionary.')
end end
end
end else end else
Error_Services('Add', 'LotType or LotID was missing in the ' : Service : ' service.') Error_Services('Add', 'LotType or LotID was missing in the ' : Service : ' service.')
end end
@ -683,6 +670,3 @@ Service SendNotifications(RDSList, EditEvent, Instructions, EntryUser)
end service end service

View File

@ -39,7 +39,7 @@ Function Wafercounter_API(@API)
#pragma precomp SRP_PreCompiler #pragma precomp SRP_PreCompiler
Declare function OI_Wizard_Services, Wafer_Counter_Services, Database_Services, Datetime, Wo_Mat_Services Declare function OI_Wizard_Services, Wafer_Counter_Services, Database_Services, Datetime, Wo_Mat_Services
Declare function Logging_Services, Environment_Services Declare function Logging_Services, Environment_Services, Wo_Mat_Qa_Services, Return_To_Fab_Services
Declare subroutine Logging_Services Declare subroutine Logging_Services
@ -127,7 +127,12 @@ API wafercounter.startnewwafercount.POST
CassNo = Field(CassId, '*', 3) CassNo = Field(CassId, '*', 3)
WoMatKey = WONo : '*' : CassNo WoMatKey = WONo : '*' : CassNo
End Case End Case
ReturnedToFab = Return_To_Fab_Services('GetReturnedToFab', CassID)
QAMetComplete = Wo_Mat_Qa_Services('GetQAMetComplete', WoMatKey)
ExpectedWfrMap = Wo_Mat_Services('GetWaferMap', WoMatKey) ExpectedWfrMap = Wo_Mat_Services('GetWaferMap', WoMatKey)
If (ReturnedToFab EQ False$) AND (QAMetComplete EQ False$) then
Error_Services('Add', 'Wafer Counter Operation Not Allowed. QA Metrology Incomplete.')
end
ExpectedCassetteArray = '' ExpectedCassetteArray = ''
for i = 25 to 1 step -1 for i = 25 to 1 step -1
Slot = i Slot = i
@ -376,3 +381,5 @@ API wafercounter.ID.GET
HTTP_Services('SetResponseStatus', ResponseCode, ErrorMessage) HTTP_Services('SetResponseStatus', ResponseCode, ErrorMessage)
end api end api

View File

@ -530,8 +530,8 @@ Service GetWaferCounterJSONTestData(WaferSize, ToolLocation, CassID)
If SRP_JSON(objJson, 'New', 'Object') then If SRP_JSON(objJson, 'New', 'Object') then
SRP_JSON(objJson, 'SetValue', 'dateTimeFormatted', Datetime(), 'String') SRP_JSON(objJson, 'SetValue', 'dateTimeFormatted', Datetime(), 'String')
SRP_JSON(objJson, 'SetValue', 'equipmentId', 'WC8INCH1', 'String') SRP_JSON(objJson, 'SetValue', 'equipmentId', 'WC8INCH1', 'String')
SRP_JSON(objJson, 'SetValue', 'total', 25, 'Number') SRP_JSON(objJson, 'SetValue', 'total', 24, 'Number')
SRP_JSON(objJson, 'SetValue', 'slotMap', '1111111111111111111111111', 'String') SRP_JSON(objJson, 'SetValue', 'slotMap', '1111111110111111111111111', 'String')
Response = SRP_Json(objJson, 'Stringify', 'Styled') Response = SRP_Json(objJson, 'Stringify', 'Styled')
SRP_JSON(objJSON, 'Release') SRP_JSON(objJSON, 'Release')
end end
@ -744,4 +744,3 @@ return

View File

@ -50,7 +50,7 @@ $Insert VOIDED_LOT_EQUATES
$Insert IFX_EQUATES $Insert IFX_EQUATES
$Insert CUST_EPI_PART_EQUATES $Insert CUST_EPI_PART_EQUATES
Equ MAX_NUM_CASS$ to 96 Equ MAX_NUM_CASS$ to 150
Declare subroutine Error_Services, Work_Order_Services, Memory_Services, RList, Database_Services, SRP_JSON Declare subroutine Error_Services, Work_Order_Services, Memory_Services, RList, Database_Services, SRP_JSON
Declare subroutine Btree.Extract, Set_Status, obj_WO_Log, obj_Notes, Print_Wo_Mat_In_Labels, Print_Wo_Mat_Out_Labels Declare subroutine Btree.Extract, Set_Status, obj_WO_Log, obj_Notes, Print_Wo_Mat_In_Labels, Print_Wo_Mat_Out_Labels
@ -1456,17 +1456,9 @@ Service CreateVoidedLotRecord(LotId, LegacyLotId, LegacyLotType, WoMatKey, UserI
if LegacyLotType NE '' then if LegacyLotType NE '' then
if LegacyLotType EQ 'RDS' OR LegacyLotType EQ 'WM_IN' OR LegacyLotType EQ 'WM_OUT' then if LegacyLotType EQ 'RDS' OR LegacyLotType EQ 'WM_IN' OR LegacyLotType EQ 'WM_OUT' then
LotId = Lot_Services('GetLotIdByLegacyLotIdAndType', LegacyLotId, LegacyLotType) LotId = Lot_Services('GetLotIdByLegacyLotIdAndType', LegacyLotId, LegacyLotType)
If Error_Services('NoError') then
If LotID EQ '' then
//No Lot ID was found, lets create one.
LotId = Lot_Services('CreateNewLot', 'RDS', '', '', '', '', '', UserId, '', LegacyLotId)
If Error_Services('HasError') then If Error_Services('HasError') then
ErrorMessage = Error_Services('GetMessage') ErrorMessage = Error_Services('GetMessage')
end end
end
end else
ErrorMessage = Error_Services('GetMessage')
end
end else end else
ErrorMessage = 'Invalid Legacy Lot Type passed to routine.' ErrorMessage = 'Invalid Legacy Lot Type passed to routine.'
end end
@ -1475,8 +1467,7 @@ Service CreateVoidedLotRecord(LotId, LegacyLotId, LegacyLotType, WoMatKey, UserI
end end
end end
If ErrorMessage NE '' then If (ErrorMessage EQ '') then
If RowExists('LOT', LotId) then
NewVoidedLotId = RTI_CreateGUID() NewVoidedLotId = RTI_CreateGUID()
NewVoidedLotRec = '' NewVoidedLotRec = ''
NewVoidedLotRec<VOIDED_LOT_WORK_ORDER_LOG_ID$> = Field(WoMatKey, '*', 1) NewVoidedLotRec<VOIDED_LOT_WORK_ORDER_LOG_ID$> = Field(WoMatKey, '*', 1)
@ -1490,9 +1481,6 @@ Service CreateVoidedLotRecord(LotId, LegacyLotId, LegacyLotType, WoMatKey, UserI
If Error_Services('HasError') then If Error_Services('HasError') then
ErrorMessage = Error_Services('GetMessage') ErrorMessage = Error_Services('GetMessage')
end end
end else
ErrorMessage = 'Unable to find lot record.'
end
end end
end else end else
ErrorMessage = 'Both the lot id and the legacy lot id were null.' ErrorMessage = 'Both the lot id and the legacy lot id were null.'
@ -1504,6 +1492,7 @@ Service CreateVoidedLotRecord(LotId, LegacyLotId, LegacyLotType, WoMatKey, UserI
end service end service
Service IsLotVoided(LotId) Service IsLotVoided(LotId)
//Todo: Move to Lot_Services //Todo: Move to Lot_Services
@ -1525,6 +1514,7 @@ Service IsLotVoided(LotId)
end service end service
Service SignVoidNonEpp(WOMatKeys, WONo, Username) Service SignVoidNonEpp(WOMatKeys, WONo, Username)
ErrorMessage = '' ErrorMessage = ''
@ -1545,9 +1535,14 @@ Service SignVoidNonEpp(WOMatKeys, WONo, Username)
if Error_Services('NoError') then if Error_Services('NoError') then
RDS_Services('DetachRDSFromWO', RDSNo) RDS_Services('DetachRDSFromWO', RDSNo)
If Error_Services('NoError') then If Error_Services('NoError') then
//Create a voided LOT record then record an event. // Create a voided LOT record.
Work_Order_Services('CreateVoidedLotRecord', '', RDSNo, 'RDS', WoMatKey, Username) Work_Order_Services('CreateVoidedLotRecord', '', RDSNo, 'RDS', WoMatKey, Username)
Lot_Event_Services('CreateLotEvent', RDSNo, Datetime(), 'VOID', 'Lot voided by ' : Username, '', Username, True$, 'RDS') LotId = Lot_Services('GetLotIdByLegacyLotIdAndType', RDSNo, 'RDS')
// Create a LOT_EVENT record if this lot is in the new LOT system.
If LotId NE '' then
Lot_Event_Services('CreateLotEvent', LotId, Datetime(), 'COMMENT', 'Lot voided by ' : Username, '', Username, True$, 'RDS')
If Error_Services('HasError') then ErrorMessage = Error_Services('GetMessage')
end
end else end else
ErrorMessage = Error_Services('GetMessage') ErrorMessage = Error_Services('GetMessage')
end end
@ -1610,9 +1605,15 @@ Service SignVoidWMI(WMInKeys, WONo, Username)
If Not(IsOnHold) then If Not(IsOnHold) then
WM_In_Services('SetVoidFlag', WmInKey, Username) WM_In_Services('SetVoidFlag', WmInKey, Username)
If Error_Services('NoError') then If Error_Services('NoError') then
Lot_Event_Services('CreateLotEvent', WmInKey, DateTime(), 'VOID', 'Lot voided by ' : Username, '', Username, True$, 'WM_IN')
Work_Order_Services('CreateVoidedLotRecord', '', WmInKey, 'WM_IN', WoMatKey, Username) Work_Order_Services('CreateVoidedLotRecord', '', WmInKey, 'WM_IN', WoMatKey, Username)
if Error_Services('NoError') then If Error_Services('NoError') then
LotId = Lot_Services('GetLotIdByLegacyLotIdAndType', WmInKey, 'WM_IN')
// Create a LOT_EVENT record if this lot is in the new LOT system.
If LotId NE '' then
Lot_Event_Services('CreateLotEvent', WmInKey, DateTime(), 'COMMENT', 'Lot voided by ' : Username, '', Username, True$, 'WM_IN')
If Error_Services('HasError') then ErrorMessage = Error_Services('GetMessage')
end
If ErrorMessage EQ '' then
//Check if WMO is also voided. If it is, remove it from the WO_MAT_KEY field in WO_LOG, and void the WO_MAT record //Check if WMO is also voided. If it is, remove it from the WO_MAT_KEY field in WO_LOG, and void the WO_MAT record
WMOKey = WMInKey; //the paired WMO key is the same as the WMIKey WMOKey = WMInKey; //the paired WMO key is the same as the WMIKey
IsWMOVoided = Database_Services('ReadDataColumn', 'WM_OUT', WMOKey, WM_OUT_VOID$) IsWMOVoided = Database_Services('ReadDataColumn', 'WM_OUT', WMOKey, WM_OUT_VOID$)
@ -1624,6 +1625,7 @@ Service SignVoidWMI(WMInKeys, WONo, Username)
ErrorMessage = 'Unable to locate WO_MAT key in WO_LOG record.' ErrorMessage = 'Unable to locate WO_MAT key in WO_LOG record.'
end end
end end
end
end else end else
ErrorMessage = Error_Services('GetMessage') ErrorMessage = Error_Services('GetMessage')
end end
@ -1683,7 +1685,7 @@ Service SignVoidWMO(WMOutKeys, WONo, Username)
ErrorMessage = '' ErrorMessage = ''
WOLogRecord = Database_Services('ReadDataRow', 'WO_LOG', WONo, True$, 0, False$) WOLogRecord = Database_Services('ReadDataRow', 'WO_LOG', WONo, True$, 0, False$)
if Error_Services('NoError') then If Error_Services('NoError') then
for each WmOutKey in WMOutKeys using @VM for each WmOutKey in WMOutKeys using @VM
if WmOutKey NE '' then if WmOutKey NE '' then
WONo = Field(WmOutKey, '*', 1) WONo = Field(WmOutKey, '*', 1)
@ -1698,13 +1700,16 @@ Service SignVoidWMO(WMOutKeys, WONo, Username)
IsOnHold = Hold_Services('CheckForHold', WoMatKey) IsOnHold = Hold_Services('CheckForHold', WoMatKey)
If Not(IsOnHold) then If Not(IsOnHold) then
WM_Out_Services('SetVoidFlag', WmOutKey, Username) WM_Out_Services('SetVoidFlag', WmOutKey, Username)
If Error_Services('NoError') then If Error_Services('NoError') then
If Error_Services('NoError') then
If Error_Services('NoError') then
Lot_Event_Services('CreateLotEvent', WmOutKey, DateTime(), 'VOID', 'Lot voided by ' : Username, '', Username, True$, 'WM_OUT')
Work_Order_Services('CreateVoidedLotRecord', '', WmOutKey, 'WM_OUT', WoMatKey, Username) Work_Order_Services('CreateVoidedLotRecord', '', WmOutKey, 'WM_OUT', WoMatKey, Username)
if Error_Services('NoError') then If Error_Services('NoError') then
LotId = Lot_Services('GetLotIdByLegacyLotIdAndType', WmOutKey, 'WM_OUT')
// Create a LOT_EVENT record if this lot is in the new LOT system.
If LotId NE '' then
Lot_Event_Services('CreateLotEvent', WmOutKey, DateTime(), 'COMMENT', 'Lot voided by ' : Username, '', Username, True$, 'WM_OUT')
If Error_Services('HasError') then ErrorMessage = Error_Services('GetMessage')
end
If ErrorMessage EQ '' then
//Check if WMI is also voided. If it is, remove it from the WO_MAT_KEY field in WO_LOG, and void the WO_MAT record //Check if WMI is also voided. If it is, remove it from the WO_MAT_KEY field in WO_LOG, and void the WO_MAT record
WMIKey = WmOutKey; //the paired WMO key is the same as the WMIKey WMIKey = WmOutKey; //the paired WMO key is the same as the WMIKey
IsWMIVoided = Database_Services('ReadDataColumn', 'WM_IN', WMOKey, WM_IN_VOID$) IsWMIVoided = Database_Services('ReadDataColumn', 'WM_IN', WMOKey, WM_IN_VOID$)
@ -1716,8 +1721,6 @@ Service SignVoidWMO(WMOutKeys, WONo, Username)
ErrorMessage = 'Unable to locate WO_MAT key in WO_LOG record.' ErrorMessage = 'Unable to locate WO_MAT key in WO_LOG record.'
end end
end end
end else
ErrorMessage = Error_Services('GetMessage')
end end
end else end else
ErrorMessage = Error_Services('GetMessage') ErrorMessage = Error_Services('GetMessage')
@ -1725,10 +1728,6 @@ Service SignVoidWMO(WMOutKeys, WONo, Username)
end else end else
ErrorMessage = Error_Services('GetMessage') ErrorMessage = Error_Services('GetMessage')
end end
end else
ErrorMessage = Error_Services('GetMessage')
end
end end
end else end else
ErrorMessage = 'Unable to void lot as it is already voided.' ErrorMessage = 'Unable to void lot as it is already voided.'

View File

@ -58,7 +58,7 @@ $Insert PRS_STAGE_EQUATES
$Insert PROD_VER_EQUATES $Insert PROD_VER_EQUATES
$Insert QA_MET_EQUATES ;* Used in GetQAMet data structure return variable $Insert QA_MET_EQUATES ;* Used in GetQAMet data structure return variable
Declare function Database_Services, SRP_JSON, Error_Services, obj_Prod_Spec Declare function Database_Services, SRP_JSON, Error_Services, obj_Prod_Spec, Wo_Mat_Qa_Services
Declare subroutine Database_Services, SRP_JSON, Error_Services Declare subroutine Database_Services, SRP_JSON, Error_Services
GoToService GoToService
@ -419,3 +419,80 @@ Service AllWafersWereTested(WoMatQAKey, StageToInspect)
end service end service
Service GetQAMetComplete(WOMatKey)
If WOMatKey NE '' then
If Rowexists('WO_MAT_QA', WOMatKey) then
Response = ''
QAMetRec = Database_Services('ReadDataRow', 'WO_MAT_QA', WOMatKey, '', True$, 0, False$)
Stages = QAMetRec<WO_MAT_QA_STAGE$>
Results = QAMetRec<WO_MAT_QA_RESULT$>
StageCount = Count(Stages, @VM)
For I = 1 to StageCount
If Results<1,I> EQ '' then
Response = False$
end
Until Response EQ False$
Next I
If Response = '' then
Response = Wo_Mat_Qa_Services('GetMUWaferQAComplete', WOMatKey)
end
end else
Response = True$
end
end else
Error_Services('Add', 'Missing WOMatKey parameter.')
end
end service
Service GetMUWaferQAComplete(WOMatKey)
If WOMatKey NE '' then
Response = True$
WOMatRec = Database_Services('ReadDataRow', 'WO_MAT', WoMatKey, True$, 0, False$)
If Error_Services('NoError') then
MUBoxes = ''
MUBoxesResults = ''
MUWafers = WOMatRec<WO_MAT_SLOT_MOVED_FROM$>
Counter = 0
If Count(MUWafers, @VM) GT 0 then
for each BoxNumber in MUWafers using @VM setting OrigIndex
if BoxNumber NE '' then
MUCassId = FIELD(BoxNumber,'.',1,2)
Locate MUCassId in MUBoxesResults using @VM setting BoxIndex then
MUThkResult = WOMatRec<WO_MAT_MU_WAFER_THK_RESULT$, OrigIndex>
If MUThkResult NE '' then
MUBoxesResults<BoxIndex, 2> = True$
end
end else
Counter += 1
MUBoxesResults<Counter> = MUCassID
MUThkResult = WOMatRec<WO_MAT_MU_WAFER_THK_RESULT$, OrigIndex>
If MUThkResult NE '' then
MUBoxesResults<Counter, 2> = True$
end
end
end
Next BoxNumber
for each Box in MUBoxesResults using @FM
if Box<1,2> EQ '' then
Response = False$
end
Until Response = False$
Next Box
end
end else
Error_Services('Add', 'Failed to open WO_MAT record.')
end
end else
Error_Services('Add', 'Missing WOMatKey parameter.')
end
end service

View File

@ -19,5 +19,7 @@ compile insert LOT_EVENT_EQUATES
equ LOT_EVENT_EVENT_OPERATION_ID$ to 10 equ LOT_EVENT_EVENT_OPERATION_ID$ to 10
equ LOT_EVENT_EVENT_OPERATOR_ID$ to 11 equ LOT_EVENT_EVENT_OPERATOR_ID$ to 11
equ LOT_EVENT_SEQUENCE$ to 12 equ LOT_EVENT_SEQUENCE$ to 12
equ LOT_EVENT_CHRON_ID$ to 13
#endif #endif

View File

@ -16,5 +16,5 @@ Equ SUPPLEMENTS_ACK_USER$ To 6
Equ SUPPLEMENTS_ACK_DTM$ To 7 Equ SUPPLEMENTS_ACK_DTM$ To 7
Equ SUPPLEMENTS_ENTRY_USER$ To 8 Equ SUPPLEMENTS_ENTRY_USER$ To 8
Equ SUPPLEMENTS_ENTRY_DATETIME$ To 9 Equ SUPPLEMENTS_ENTRY_DATETIME$ To 9
Equ SUPPLEMENTS_STAGE_INDEX$ To 10