📄 setpointregion.p1
字号:
[; ;SetPointRegion.h: 19: {
[; ;SetPointRegion.h: 20: int Threshold;
[; ;SetPointRegion.h: 21: int Hysteresis;
[; ;SetPointRegion.h: 22: } SETPOINT_ELEM_CONST_STRUC;
"29
[s S11 `*CS9 1 `uc 1 `*uc 1 ]
[n S11 . SetPointArray SetPointCount pOldValue ]
[v _SETPOINT_REGION_PB `S11 1 t ]
[; ;SetPointRegion.h: 24: typedef struct
[; ;SetPointRegion.h: 25: {
[; ;SetPointRegion.h: 26: SETPOINT_ELEM_STRUC const * SetPointArray;
[; ;SetPointRegion.h: 27: BYTE SetPointCount;
[; ;SetPointRegion.h: 28: BYTE * pOldValue;
[; ;SetPointRegion.h: 29: } SETPOINT_REGION_PB;
[; ;SetPointRegion.h: 31: BYTE SetPointRegion( SETPOINT_REGION_PB const *, int);
"12 ./TableLookup.h
[s S12 `*uc 1 `i 1 ]
[n S12 . pInputVar multiplier ]
[v _TABLE_LOOKUP_INPUT `S12 1 t ]
[; ;TableLookup.h: 8: typedef struct
[; ;TableLookup.h: 9: {
[; ;TableLookup.h: 10: BYTE * pInputVar;
[; ;TableLookup.h: 11: int multiplier;
[; ;TableLookup.h: 12: } TABLE_LOOKUP_INPUT;
"20
[s S13 `*CS12 1 `*Cuc 1 `uc 1 `uc 1 ]
[n S13 . InputList LookUpTable InputListCount LookUpTableSize ]
[v _TABLE_LOOKUP_PB `S13 1 t ]
[; ;TableLookup.h: 14: typedef struct
[; ;TableLookup.h: 15: {
[; ;TableLookup.h: 16: TABLE_LOOKUP_INPUT const * InputList;
[; ;TableLookup.h: 17: BYTE const * LookUpTable;
[; ;TableLookup.h: 18: BYTE InputListCount;
[; ;TableLookup.h: 19: BYTE LookUpTableSize;
[; ;TableLookup.h: 20: } TABLE_LOOKUP_PB;
[; ;TableLookup.h: 22: BYTE TableLookUp( TABLE_LOOKUP_PB const *);
[; ;CMXSystemFunction.h: 13: extern BYTE SetPointRegion(SETPOINT_REGION_PB const *, int);
[; ;CMXSystemFunction.h: 14: extern BYTE TableLookup(TABLE_LOOKUP_PB const * );
[; ;CMXSystemFunction.h: 17: extern SETPOINT_REGION_PB const pse_TempRange_SetPointRegion;
[; ;CMXSystemFunction.h: 18: extern TABLE_LOOKUP_PB const pse_Buzzer_TableLookup;
"25 ./SystemConst.h
[s S15 `CS10 1 `CS10 1 `CS10 1 `CS10 1 `CS10 1 `CS10 1 `CS10 1 `CS10 1 ]
[n S15 . SetPointParam0 SetPointParam1 SetPointParam2 SetPointParam3 SetPointParam4 SetPointParam5 SetPointParam6 SetPointParam7 ]
"30
[s S16 `uc -> 2 `i ]
[n S16 . title ]
"31
[s S14 `S15 1 `S16 1 ]
[n S14 . pse_TempRange_SetPointRegion ReserveBlock ]
[v _SYSTEM_CONSTANT_STRUC `S14 1 t ]
[; ;SystemConst.h: 15: typedef struct
[; ;SystemConst.h: 16: {
[; ;SystemConst.h: 17: struct { SETPOINT_ELEM_CONST_STRUC const SetPointParam0;
[; ;SystemConst.h: 18: SETPOINT_ELEM_CONST_STRUC const SetPointParam1;
[; ;SystemConst.h: 19: SETPOINT_ELEM_CONST_STRUC const SetPointParam2;
[; ;SystemConst.h: 20: SETPOINT_ELEM_CONST_STRUC const SetPointParam3;
[; ;SystemConst.h: 21: SETPOINT_ELEM_CONST_STRUC const SetPointParam4;
[; ;SystemConst.h: 22: SETPOINT_ELEM_CONST_STRUC const SetPointParam5;
[; ;SystemConst.h: 23: SETPOINT_ELEM_CONST_STRUC const SetPointParam6;
[; ;SystemConst.h: 24: SETPOINT_ELEM_CONST_STRUC const SetPointParam7;
[; ;SystemConst.h: 25: } pse_TempRange_SetPointRegion;
[; ;SystemConst.h: 27: struct
[; ;SystemConst.h: 28: {
[; ;SystemConst.h: 29: char title[2];
[; ;SystemConst.h: 30: } ReserveBlock;
[; ;SystemConst.h: 31: } SYSTEM_CONSTANT_STRUC;
"20 ./cmx.h
[v F470 `*v -> 0 `x t ]
[v F471 `*v 1 t ]
[; ;cmx.h: 20: extern void * const DriverParams[];
[; ;CMXSystemExtern.h: 8: extern SYSTEM_CONSTANT_STRUC const SystemConst;
"9 ./CMXSystemExtern.h
[v F474 `*v -> 0 `x t ]
[v F475 `*v 1 t ]
[; ;CMXSystemExtern.h: 9: extern void * const FunctionParams[];
[; ;CMXSystemExtern.h: 10: extern SYSTEM_VARS_STRUC SystemVars;
"20 ./setpointregion.c
[v _SetPointRegion `(uc 1 ef2`*CS11`i ]
{
[; ;setpointregion.c: 19: BYTE SetPointRegion( SETPOINT_REGION_PB const * pParamBlk, int nValue)
[; ;setpointregion.c: 20: {
[e :U _SetPointRegion ]
[v _pParamBlk `*CS11 1 r1 ]
[v _nValue `i 1 r2 ]
[f ]
"21
[v _nRegion `uc 1 a ]
[; ;setpointregion.c: 21: BYTE nRegion = 255;
[e = _nRegion -> -> 255 `i `uc ]
"22
[v _setPointParam `S11 1 a ]
[; ;setpointregion.c: 22: SETPOINT_REGION_PB setPointParam = *pParamBlk;
[e = _setPointParam *U _pParamBlk ]
"23
[v _nSetPointCount `uc 1 a ]
[; ;setpointregion.c: 23: BYTE nSetPointCount = (BYTE)setPointParam.SetPointCount;
[e = _nSetPointCount . _setPointParam 1 ]
"24
[v _setPointArray `*CS9 1 a ]
[; ;setpointregion.c: 24: SETPOINT_ELEM_STRUC const * setPointArray = setPointParam.SetPointArray;
[e = _setPointArray . _setPointParam 0 ]
"25
[v _nInnerIndex `uc 1 a ]
"26
[v _nTempIndex `i 1 a ]
[v _nOuterIndex `i 1 a ]
"27
[v _nDirection `c 1 a ]
[; ;setpointregion.c: 25: BYTE nInnerIndex;
[; ;setpointregion.c: 26: int nTempIndex, nOuterIndex;
[; ;setpointregion.c: 27: signed char nDirection = 0;
[e = _nDirection -> -> 0 `i `c ]
"28
[v _lowerSetPoint `S9 1 a ]
"29
[v _setPoint `S9 1 a ]
[; ;setpointregion.c: 28: SETPOINT_ELEM_STRUC lowerSetPoint;
[; ;setpointregion.c: 29: SETPOINT_ELEM_STRUC setPoint;
[; ;setpointregion.c: 34: lowerSetPoint = setPointArray[0];
"34
[e = _lowerSetPoint *U + _setPointArray * -> -> 0 `i `x -> -> # *U _setPointArray `i `x ]
[; ;setpointregion.c: 35: nTempIndex = *(lowerSetPoint.Threshold) - *(lowerSetPoint.Hysteresis);
"35
[e = _nTempIndex - *U . _lowerSetPoint 0 *U . _lowerSetPoint 1 ]
[; ;setpointregion.c: 36: if (nValue < nTempIndex)
"36
[e $ ! < _nValue _nTempIndex 18 ]
[; ;setpointregion.c: 37: {
"37
{
[; ;setpointregion.c: 38: nRegion = 0;
"38
[e = _nRegion -> -> 0 `i `uc ]
"39
}
[; ;setpointregion.c: 39: }
[e $U 19 ]
"40
[e :U 18 ]
[; ;setpointregion.c: 40: else
[; ;setpointregion.c: 41: {
"41
{
[; ;setpointregion.c: 42: lowerSetPoint = setPointArray[nSetPointCount - 1];
"42
[e = _lowerSetPoint *U + _setPointArray * -> - -> _nSetPointCount `i -> 1 `i `x -> -> # *U _setPointArray `i `x ]
[; ;setpointregion.c: 43: nTempIndex = *(lowerSetPoint.Threshold) + *(lowerSetPoint.Hysteresis);
"43
[e = _nTempIndex + *U . _lowerSetPoint 0 *U . _lowerSetPoint 1 ]
[; ;setpointregion.c: 44: if (nValue > nTempIndex)
"44
[e $ ! > _nValue _nTempIndex 20 ]
[; ;setpointregion.c: 45: {
"45
{
[; ;setpointregion.c: 47: nRegion = nSetPointCount;
"47
[e = _nRegion _nSetPointCount ]
"48
}
[; ;setpointregion.c: 48: }
[e $U 21 ]
"49
[e :U 20 ]
[; ;setpointregion.c: 49: else
[; ;setpointregion.c: 50: {
"50
{
[; ;setpointregion.c: 52: if (*(setPointParam.pOldValue) == nSetPointCount)
"52
[e $ ! == -> *U . _setPointParam 2 `i -> _nSetPointCount `i 22 ]
[; ;setpointregion.c: 53: {
"53
{
[; ;setpointregion.c: 54: setPoint = setPointArray[nSetPointCount-1];
"54
[e = _setPoint *U + _setPointArray * -> - -> _nSetPointCount `i -> 1 `i `x -> -> # *U _setPointArray `i `x ]
[; ;setpointregion.c: 55: if (nValue < *(setPoint.Threshold) - *(setPoint.Hysteresis))
"55
[e $ ! < _nValue - *U . _setPoint 0 *U . _setPoint 1 23 ]
[; ;setpointregion.c: 56: {
"56
{
[; ;setpointregion.c: 57: nDirection = -1;
"57
[e = _nDirection -> -U -> 1 `i `c ]
"58
}
[e :U 23 ]
"59
}
[; ;setpointregion.c: 58: }
[; ;setpointregion.c: 59: }
[e $U 24 ]
"60
[e :U 22 ]
[; ;setpointregion.c: 60: else if (*(setPointParam.pOldValue) == 0)
[e $ ! == -> *U . _setPointParam 2 `i -> 0 `i 25 ]
[; ;setpointregion.c: 61: {
"61
{
[; ;setpointregion.c: 62: setPoint = setPointArray[0];
"62
[e = _setPoint *U + _setPointArray * -> -> 0 `i `x -> -> # *U _setPointArray `i `x ]
[; ;setpointregion.c: 63: if (nValue > *(setPoint.Threshold) + *(setPoint.Hysteresis))
"63
[e $ ! > _nValue + *U . _setPoint 0 *U . _setPoint 1 26 ]
[; ;setpointregion.c: 64: {
"64
{
[; ;setpointregion.c: 65: nDirection = 1;
"65
[e = _nDirection -> -> 1 `i `c ]
"66
}
[e :U 26 ]
"67
}
[; ;setpointregion.c: 66: }
[; ;setpointregion.c: 67: }
[e $U 27 ]
"68
[e :U 25 ]
[; ;setpointregion.c: 68: else
[; ;setpointregion.c: 69: {
"69
{
[; ;setpointregion.c: 70: setPoint = setPointArray[*(setPointParam.pOldValue)];
"70
[e = _setPoint *U + _setPointArray * -> *U . _setPointParam 2 `ux -> -> # *U _setPointArray `ui `ux ]
[; ;setpointregion.c: 71: lowerSetPoint = setPointArray[*(setPointParam.pOldValue)-1];
"71
[e = _lowerSetPoint *U + _setPointArray * -> - -> *U . _setPointParam 2 `i -> 1 `i `x -> -> # *U _setPointArray `i `x ]
[; ;setpointregion.c: 72: if (nValue > (*(setPoint.Threshold) + *(setPoint.Hysteresis)))
"72
[e $ ! > _nValue + *U . _setPoint 0 *U . _setPoint 1 28 ]
[; ;setpointregion.c: 73: {
"73
{
[; ;setpointregion.c: 74: nDirection = 1;
"74
[e = _nDirection -> -> 1 `i `c ]
"75
}
[; ;setpointregion.c: 75: }
[e $U 29 ]
"76
[e :U 28 ]
[; ;setpointregion.c: 76: else if (nValue < (*(lowerSetPoint.Threshold) - *(lowerSetPoint.Hysteresis)))
[e $ ! < _nValue - *U . _lowerSetPoint 0 *U . _lowerSetPoint 1 30 ]
[; ;setpointregion.c: 77: {
"77
{
[; ;setpointregion.c: 78: nDirection = -1;
"78
[e = _nDirection -> -U -> 1 `i `c ]
"79
}
[e :U 30 ]
"80
[e :U 29 ]
}
[e :U 27 ]
[e :U 24 ]
[; ;setpointregion.c: 79: }
[; ;setpointregion.c: 80: }
[; ;setpointregion.c: 81: if (nDirection != 0)
"81
[e $ ! != -> _nDirection `i -> 0 `i 31 ]
[; ;setpointregion.c: 82: {
"82
{
[; ;setpointregion.c: 84: if (nDirection == 1)
"84
[e $ ! == -> _nDirection `i -> 1 `i 32 ]
[; ;setpointregion.c: 85: {
"85
{
[; ;setpointregion.c: 86: for (nInnerIndex = nSetPointCount - 1;(nInnerIndex >= *(setPointParam.pOldValue)) && (nRegion == 255);nInnerIndex--)
"86
{
[e = _nInnerIndex -> - -> _nSetPointCount `i -> 1 `i `uc ]
[e $U 36 ]
"87
[e :U 33 ]
[; ;setpointregion.c: 87: {
{
[; ;setpointregion.c: 89: setPoint = setPointArray[nInnerIndex];
"89
[e = _setPoint *U + _setPointArray * -> _nInnerIndex `ux -> -> # *U _setPointArray `ui `ux ]
[; ;setpointregion.c: 90: nTempIndex = *(setPoint.Threshold) + *(setPoint.Hysteresis);
"90
[e = _nTempIndex + *U . _setPoint 0 *U . _setPoint 1 ]
[; ;setpointregion.c: 91: if (nValue > nTempIndex)
"91
[e $ ! > _nValue _nTempIndex 37 ]
[; ;setpointregion.c: 92: {
"92
{
[; ;setpointregion.c: 93: nRegion = nInnerIndex+1;
"93
[e = _nRegion -> + -> _nInnerIndex `i -> 1 `i `uc ]
"94
}
[e :U 37 ]
"95
}
"86
[e -- _nInnerIndex -> -> 1 `i `uc ]
[e :U 36 ]
[e $ && >= -> _nInnerIndex `i -> *U . _setPointParam 2 `i == -> _nRegion `i -> 255 `i 33 ]
[e :U 34 ]
"95
}
"96
}
[; ;setpointregion.c: 94: }
[; ;setpointregion.c: 95: }
[; ;setpointregion.c: 96: }
[e $U 38 ]
"97
[e :U 32 ]
[; ;setpointregion.c: 97: else
[; ;setpointregion.c: 98: {
"98
{
[; ;setpointregion.c: 99: for (nInnerIndex = 1;(nInnerIndex < *(setPointParam.pOldValue)) && (nRegion == 255);nInnerIndex++)
"99
{
[e = _nInnerIndex -> -> 1 `i `uc ]
[e $U 42 ]
"100
[e :U 39 ]
[; ;setpointregion.c: 100: {
{
[; ;setpointregion.c: 102: setPoint = setPointArray[nInnerIndex];
"102
[e = _setPoint *U + _setPointArray * -> _nInnerIndex `ux -> -> # *U _setPointArray `ui `ux ]
[; ;setpointregion.c: 103: nTempIndex = *(setPoint.Threshold) - *(setPoint.Hysteresis);
"103
[e = _nTempIndex - *U . _setPoint 0 *U . _setPoint 1 ]
[; ;setpointregion.c: 104: if (nValue < nTempIndex)
"104
[e $ ! < _nValue _nTempIndex 43 ]
[; ;setpointregion.c: 105: {
"105
{
[; ;setpointregion.c: 106: nRegion = nInnerIndex;
"106
[e = _nRegion _nInnerIndex ]
"107
}
[e :U 43 ]
"108
}
"99
[e ++ _nInnerIndex -> -> 1 `i `uc ]
[e :U 42 ]
[e $ && < -> _nInnerIndex `i -> *U . _setPointParam 2 `i == -> _nRegion `i -> 255 `i 39 ]
[e :U 40 ]
"108
}
"109
}
[e :U 38 ]
"110
}
[; ;setpointregion.c: 107: }
[; ;setpointregion.c: 108: }
[; ;setpointregion.c: 109: }
[; ;setpointregion.c: 110: }
[e $U 44 ]
"111
[e :U 31 ]
[; ;setpointregion.c: 111: else
[; ;setpointregion.c: 112: {
"112
{
[; ;setpointregion.c: 114: nRegion = *(setPointParam.pOldValue);
"114
[e = _nRegion *U . _setPointParam 2 ]
"115
}
[e :U 44 ]
"116
}
[e :U 21 ]
"117
}
[e :U 19 ]
[; ;setpointregion.c: 115: }
[; ;setpointregion.c: 116: }
[; ;setpointregion.c: 117: }
[; ;setpointregion.c: 119: return nRegion;
"119
[e ) _nRegion ]
[e $UE 17 ]
"120
[; ;setpointregion.c: 120: }
[e :UE 17 ]
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -