📄 liftcomponents.c
字号:
#ifdef XTRACE
xTraceAssign("leastEffort := ", &(yVarP->
z_LiftComponents_0C_leastEffort),
(tSDLTypeInfo *)&ySDL_z_Interfaces_V_ServiceTime);
#endif
#ifdef XMSCE
xMSCEAssign(VarP, "leastEffort := ", &(yVarP->
z_LiftComponents_0C_leastEffort),
(tSDLTypeInfo *)&ySDL_z_Interfaces_V_ServiceTime);
#endif
XBETWEEN_STMTS(24, 577)
/* ----- ASSIGNMENT minimalEffort := ... ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#NRfa*I7yypLLPhN6TLgGSHKV|pos(1,29)") */
#ifdef XCASELABELS
case 24:
#endif
yAssF_SDL_PId(yVarP->z_LiftComponents_0B_minimalEffort, SDL_SENDER,
XASS_MR_ASS_FR);
#ifdef XTRACE
xTraceAssign("minimalEffort := ", &(yVarP->
z_LiftComponents_0B_minimalEffort), (tSDLTypeInfo *)&ySDL_SDL_PId);
#endif
#ifdef XMSCE
xMSCEAssign(VarP, "minimalEffort := ", &(yVarP->
z_LiftComponents_0B_minimalEffort), (tSDLTypeInfo *)&ySDL_SDL_PId);
#endif
}
#ifdef XTRACE
else {
xTraceAlg("IF (false)");
}
#endif
XBETWEEN_SYMBOLS(25, 600)
/* ----- DECISION ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#YpOxHI5JoILLzUtXLEPnRW2L|pos(1,26)") */
#ifdef XCASELABELS
case 25:
#endif
#ifdef XTRACE
yAssF_SDL_Boolean(yDcn_SDL_Boolean, xGE_SDL_Integer(yVarP->
z_LiftComponents_0A_respondedCtrl,
yLength_z_LiftComponents_02_AKReferenceControllerList(&(yVarP->
z_LiftComponents_07_controllers))), XASS_MR_ASS_FR);
xTraceDecision(&(yDcn_SDL_Boolean), (tSDLTypeInfo *)&ySDL_SDL_Boolean);
#ifdef XMSCE
xMSCEDecision(VarP, &(yDcn_SDL_Boolean),
(tSDLTypeInfo *)&ySDL_SDL_Boolean);
#endif
if (yDcn_SDL_Boolean) {
#else
if (xGE_SDL_Integer(yVarP->z_LiftComponents_0A_respondedCtrl,
yLength_z_LiftComponents_02_AKReferenceControllerList(&(yVarP->
z_LiftComponents_07_controllers)))) {
#endif
XBETWEEN_SYMBOLS(26, 623)
/* ----- OUTPUT handleRequest ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#R1STXL73ChFLW5gbkErEc9BV|pos(1,25)") */
#ifdef XCASELABELS
case 26:
#endif
ALLOC_SIGNAL_PAR(handleRequest, ySigN_z_Interfaces_B_handleRequest,
yVarP->z_LiftComponents_0B_minimalEffort,
ySignalPar_z_Interfaces_B_handleRequest)
SIGNAL_ALLOC_ERROR
yAssF_z_Interfaces_U_ptr_Request(((ySignalPar_z_Interfaces_B_handleRequest *)
OUTSIGNAL_DATA_PTR)->Param1, yVarP->z_LiftComponents_06_newRequest,
XASS_MR_ASS_NF);
SDL_2OUTPUT(xDefaultPrioSignal, (xIdNode *)0, handleRequest,
ySigN_z_Interfaces_B_handleRequest, yVarP->
z_LiftComponents_0B_minimalEffort,
sizeof(ySignalPar_z_Interfaces_B_handleRequest), "handleRequest")
SIGNAL_ALLOC_ERROR_END
XBETWEEN_SYMBOLS(27, 642)
/* ----- NEXTSTATE Idle ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#HbQVwLlz15lLe1faiI7aomJL|pos(1,25)") */
#ifdef XCASELABELS
case 27:
#endif
XAT_LAST_SYMBOL
SDL_NEXTSTATE(Idle, z_LiftComponents_03_Idle, "Idle")
} else {
XBETWEEN_SYMBOLS(28, 652)
/* ----- NEXTSTATE - ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#P0UrZV0*2FFLyPa7*IU7H3UI|pos(1,25)") */
#ifdef XCASELABELS
case 28:
#endif
XAT_LAST_SYMBOL
SDL_DASH_NEXTSTATE
}
}
}
/*****
* STATE Idle
* <<PACKAGE LiftComponents/PROCESS TYPE LiftManager>>
* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#DhDx-Eewnp5Lrjoc3Ercy1yI|pos(2,15)")
******/
static XCONST xInputAction yStaH_z_LiftComponents_03_Idle[] = {xInput, xInput,
xDiscard, xDiscard};
static XCONST XINPUTREFTYPE yStaI_z_LiftComponents_03_Idle[] = {2, 1, 0, 0};
#ifdef XCOVERAGE
static long int yStaC_z_LiftComponents_03_Idle[3+1];
#endif
XCONST struct xStateIdStruct yStaR_z_LiftComponents_03_Idle = {xStateEC ,
(xIdNode)0, (xIdNode)0, (xIdNode)&yPrsR_z_LiftComponents_0_LiftManager,
"Idle" xIdNumber(0) XCOMMON_EXTRAS, z_LiftComponents_03_Idle,
yStaH_z_LiftComponents_03_Idle, yStaI_z_LiftComponents_03_Idle, 0, 0, 0
xCoverage(yStaC_z_LiftComponents_03_Idle), (xStateIdNode)0
xBreakB("#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#DhDx-Eewnp5Lrjoc3Ercy1yI|pos(2,15)\")")
XSTA_EXTRAS};
/*****
* STATE *
* <<PACKAGE LiftComponents/PROCESS TYPE LiftManager>>
* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#DhDx-Eewnp5Lrjoc3Ercy1yI|pos(3,15)")
******/
static XCONST xInputAction yStaH_z_LiftComponents_04_Asterisk[] = {xInput,
xInput, xDiscard, xDiscard};
static XCONST XINPUTREFTYPE yStaI_z_LiftComponents_04_Asterisk[] = {2, 1, 0, 0};
#ifdef XCOVERAGE
static long int yStaC_z_LiftComponents_04_Asterisk[3+1];
#endif
XCONST struct xStateIdStruct yStaR_z_LiftComponents_04_Asterisk = {xStateEC ,
(xIdNode)0, (xIdNode)0, (xIdNode)&yPrsR_z_LiftComponents_0_LiftManager,
"*" xIdNumber(0) XCOMMON_EXTRAS, -1, yStaH_z_LiftComponents_04_Asterisk,
yStaI_z_LiftComponents_04_Asterisk, 0, 0,
0 xCoverage(yStaC_z_LiftComponents_04_Asterisk), (xStateIdNode)0
xBreakB("#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#DhDx-Eewnp5Lrjoc3Ercy1yI|pos(3,15)\")")
XSTA_EXTRAS};
/*****
* STATE WaitEstimation
* <<PACKAGE LiftComponents/PROCESS TYPE LiftManager>>
* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#wSJ-0VD3ubFLqqwgPI0hSe8V|pos(3,15)")
******/
static XCONST xInputAction yStaH_z_LiftComponents_05_WaitEstimation[] =
{xInput, xInput, xInput, xDiscard};
static XCONST XINPUTREFTYPE yStaI_z_LiftComponents_05_WaitEstimation[] = {2, 1,
4, 0};
#ifdef XCOVERAGE
static long int yStaC_z_LiftComponents_05_WaitEstimation[3+1];
#endif
XCONST struct xStateIdStruct yStaR_z_LiftComponents_05_WaitEstimation =
{xStateEC , (xIdNode)0, (xIdNode)0,
(xIdNode)&yPrsR_z_LiftComponents_0_LiftManager, "WaitEstimation" xIdNumber(0)
XCOMMON_EXTRAS, z_LiftComponents_05_WaitEstimation,
yStaH_z_LiftComponents_05_WaitEstimation,
yStaI_z_LiftComponents_05_WaitEstimation, 0, 0, 0
xCoverage(yStaC_z_LiftComponents_05_WaitEstimation), (xStateIdNode)0
xBreakB("#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#wSJ-0VD3ubFLqqwgPI0hSe8V|pos(3,15)\")")
XSTA_EXTRAS};
/*****
* PROCEDURE add
* <<PACKAGE LiftComponents/PROCESS TYPE LiftManager>>
* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#JcRSWLP4M2ELFR37lLwTsGvE|pos(1,19)")
******/
#ifdef XCOVERAGE
long int yPrdC_z_LiftComponents_01_add[ySym_z_LiftComponents_01_add+1];
#endif
static XCONST xStateIdNode yPrdT_z_LiftComponents_01_add[] =
{&xStartStateIdRec};
static xPrdNode yPrdA_z_LiftComponents_01_add = (xPrdNode)0;
XCONST struct xPrdIdStruct yPrdR_z_LiftComponents_01_add = {xProcedureEC ,
(xIdNode)0, (xIdNode)0, (xIdNode)&yPrsR_z_LiftComponents_0_LiftManager,
"add" xIdNumber(0) XCOMMON_EXTRAS, yPrdT_z_LiftComponents_01_add,
yPrsS_z_LiftComponents_0_LiftManager, z_LiftComponents_01_add,
yFree_z_LiftComponents_01_add,
(xptrint)sizeof(yVDef_z_LiftComponents_01_add),
&yPrdA_z_LiftComponents_01_add xBreakB(yRef_z_LiftComponents_01_add)
xBreakB(ySym_z_LiftComponents_01_add) xBreakB(3)
xCoverage(yPrdC_z_LiftComponents_01_add), (xPrdIdNode)0, (xPrdIdNode *)0
XPRD_EXTRAS};
void yFree_z_LiftComponents_01_add(void *yVarP)
{
}
/*+++++
* GR ref function for procedure add
* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#JcRSWLP4M2ELFR37lLwTsGvE|pos(1,22)")
++++++*/
#ifdef XBREAKBEFORE
char * yRef_z_LiftComponents_01_add (int SymbolNo, xSymbolType *SymbolType)
{
switch (SymbolNo) {
case 0: *SymbolType = xsStart;
return "#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#sTL3CEXphrSLPjA7SIqqcPkV|pos(1,13)\")";
case 1: *SymbolType = xsCreateRequest;
return "#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#1aUTHVs83xILrhH6KVOEgf2I|pos(1,17)\")";
case 2: *SymbolType = xsAssignmentStatement;
return "#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#J2G0EIIeywVLH6TWdIJ45jrV|pos(1,17)\")";
case 3: *SymbolType = xsAssignmentStatement;
return "#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#N5Eg9Vii*kvL7C-9*VMamFgI|pos(1,22)\")";
case 4: *SymbolType = xsCreateRequest;
return "#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#VubXDIurfR5Lvn4beIa799JV|pos(1,17)\")";
case 5: *SymbolType = xsAssignmentStatement;
return "#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#fdUPwV8w5sFLwQD6TV6B-8iE|pos(1,17)\")";
case 6: *SymbolType = xsReturn;
return "#SDTREF(U2,\"u2:F:\\UML\\LiftManagement20\\SystemDesign\\LiftManagement.u2#JcRSWLP4M2ELFR37lLwTsGvE|pos(1,17)\")";
default : *SymbolType = xsNoSuchSymbolType; return "";
}
}
#endif
/*+++++
* Function for procedure add
* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#JcRSWLP4M2ELFR37lLwTsGvE|pos(1,22)")
++++++*/
YPRD_FUNCTION(z_LiftComponents_01_add)
{
YPAD_YSVARP
YPRD_YVARP(yVDef_z_LiftComponents_0_LiftManager)
yVDef_z_LiftComponents_01_add * yPrdVarP;
YPRD_TEMP_VARS
YPRDNAME_VAR("add")
#ifndef XNOUSEOFSERVICE
if (yVarP->ActiveSrv != (xSrvNode)0)
yPrdVarP = (yVDef_z_LiftComponents_01_add *)yVarP->ActiveSrv->ActivePrd;
else
#endif
yPrdVarP = (yVDef_z_LiftComponents_01_add *)yVarP->ActivePrd;
LOOP_LABEL_PRD_NOSTATE
switch (yPrdVarP->RestartAddress) {
/* ----- START ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#sTL3CEXphrSLPjA7SIqqcPkV|pos(1,13)") */
case 0:
XAT_FIRST_SYMBOL(0)
yAssF_SDL_PId(yPrdVarP->z_LiftComponents_010_tmpCtrl_1, SDL_NULL,
XASS_MR_ASS_NF);
yAssF_SDL_PId(yPrdVarP->z_LiftComponents_011_newLift, SDL_NULL,
XASS_MR_ASS_NF);
XBETWEEN_SYMBOLS_PRD(1, 806)
/* ----- CREATE LiftController ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#1aUTHVs83xILrhH6KVOEgf2I|pos(1,17)") */
#ifdef XCASELABELS
case 1:
#endif
ALLOC_STARTUP(LiftController,ySigN_z_LiftComponents_1_LiftController,
ySignalPar_z_LiftComponents_1_LiftController)
STARTUP_ALLOC_ERROR
SDL_CREATE(LiftController,yPriN_z_LiftComponents_1_LiftController,
"LiftController")
STARTUP_ALLOC_ERROR_END
XBETWEEN_SYMBOLS_PRD(2, 819)
/* ----- ASSIGNMENT tmpCtrl_1 := ... ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#J2G0EIIeywVLH6TWdIJ45jrV|pos(1,17)") */
#ifdef XCASELABELS
case 2:
#endif
yAssF_SDL_PId(yPrdVarP->z_LiftComponents_010_tmpCtrl_1, SDL_OFFSPRING,
XASS_MR_ASS_FR);
#ifdef XTRACE
xTraceAssign("tmpCtrl_1 := ", &(yPrdVarP->z_LiftComponents_010_tmpCtrl_1),
(tSDLTypeInfo *)&ySDL_SDL_PId);
#endif
#ifdef XMSCE
xMSCEAssign(VarP, "tmpCtrl_1 := ", &(yPrdVarP->
z_LiftComponents_010_tmpCtrl_1), (tSDLTypeInfo *)&ySDL_SDL_PId);
#endif
XBETWEEN_SYMBOLS_PRD(3, 836)
/* ----- ASSIGNMENT append := ... ----- */
/* #SDTREF(U2,"u2:F:\UML\LiftManagement20\SystemDesign\LiftManagement.u2#N5Eg9Vii*kvL7C-9*VMamFgI|pos(1,22)") */
#ifdef XCASELABELS
case 3:
#endif
#ifdef XTRACE
xTraceAlg("CALL OPERATOR append");
#endif
yAppend_z_LiftComponents_02_AKReferenceControllerList(&(yVarP->
z_LiftComponents_07_controllers), &(yPrdVarP->
z_LiftComponents_010_tmpCtrl_1));
XBETWEEN_SYMBOLS_PRD(4, 849)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -