Upload files to "/"
This commit is contained in:
696
Comm.h
Normal file
696
Comm.h
Normal file
@@ -0,0 +1,696 @@
|
||||
#ifndef SOURCE_COMM_H_
|
||||
#define SOURCE_COMM_H_
|
||||
|
||||
typedef struct ClassCommCheck
|
||||
{
|
||||
Uint16 CarComputer;
|
||||
Uint16 Gcu;
|
||||
Uint16 Ecu;
|
||||
} CCommCheck;
|
||||
|
||||
typedef struct ClassTx100
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 Heartbit;
|
||||
|
||||
/* BYTE 2~4 Reserved */
|
||||
|
||||
/* BYTE 5 */
|
||||
Uint16 VersionMajor;
|
||||
|
||||
/* BYTE 6 */
|
||||
Uint16 VersionMinor;
|
||||
|
||||
/* BYTE 7 */
|
||||
Uint16 VersionPatch;
|
||||
} CTx100;
|
||||
|
||||
typedef struct ClassTx101
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 PlayState; // 0~3 bit
|
||||
|
||||
/* BYTE 1 */
|
||||
Uint16 DcuState; // bit 0:AlarmOccured, 1:Emergency, 2:PowerSwitch, 3:EcuFailSafe
|
||||
|
||||
/* BYTE 2~7 Reserved */
|
||||
|
||||
} CTx101;
|
||||
|
||||
typedef struct ClassTx102
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 GcuCommand; // bit 0~3:PlayCommand, 4:FaultReset, 5:Emergency
|
||||
|
||||
/* BYTE 1~7 Reserved */
|
||||
|
||||
} CTx102;
|
||||
|
||||
|
||||
typedef struct ClassTx103
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 EngineStart;
|
||||
|
||||
/* BYTE 1 */
|
||||
Uint16 EngineStop;
|
||||
|
||||
/* BYTE 2 */
|
||||
Uint16 FaultReset;
|
||||
|
||||
/* BYTE 3 Reserved */
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 RpmSetpoint;
|
||||
|
||||
/* BYTE 6 */
|
||||
Uint16 ActiveOverride;
|
||||
|
||||
/* BYTE 7 */
|
||||
Uint16 EmergencyStop;
|
||||
|
||||
} CTx103;
|
||||
|
||||
typedef struct ClassTx110
|
||||
{
|
||||
/* BYTE 0~3 */
|
||||
Uint16 DcuFaultB0;
|
||||
Uint16 DcuFaultB1;
|
||||
Uint16 DcuFaultB2;
|
||||
Uint16 DcuFaultB3;
|
||||
|
||||
/* BYTE 4~7 - Reserved */
|
||||
|
||||
} CTx110;
|
||||
|
||||
typedef struct ClassTx120
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 AuxTotal; // bit 0:EngineHeater, 1:GlowPlug, 2:Solenoid, 3:FuelPump, 4:CoolantPump, 5:Fan1, 6:Fan2
|
||||
|
||||
/* BYTE 1~7 - Reserved */
|
||||
|
||||
} CTx120;
|
||||
|
||||
typedef struct ClassTx121
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 EngHeatVoltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 EngHeatCurrent;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 GlowPlugVoltage;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 GlowPlugCurrent;
|
||||
} CTx121;
|
||||
|
||||
typedef struct ClassTx122
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 SolenoidVoltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 SolenoidCurrent;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 FuelPumpVoltage;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 FuelPumpCurrent;
|
||||
} CTx122;
|
||||
|
||||
typedef struct ClassTx123
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 CoolantPumpVoltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 CoolantPumpCurrent;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 Fan1Voltage;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 Fan1Current;
|
||||
} CTx123;
|
||||
|
||||
typedef struct ClassTx124
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 Fan2Voltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 Fan2Current;
|
||||
|
||||
/* BYTE 4~7 - Reserved */
|
||||
|
||||
} CTx124;
|
||||
|
||||
typedef struct ClassRx200
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 HeartBit;
|
||||
|
||||
/* BYTE 2~4 - Reserved */
|
||||
|
||||
/* BYTE 5 */
|
||||
Uint16 VersionMajor;
|
||||
|
||||
/* BYTE 6 */
|
||||
Uint16 VersionMinor;
|
||||
|
||||
/* BYTE 7 */
|
||||
Uint16 VersionPatch;
|
||||
} CRx200;
|
||||
|
||||
typedef struct ClassRx201
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 PlayState; // 0:3 bit PlayState
|
||||
|
||||
/* BYTE 1 */
|
||||
Uint16 State; // bit 0:AlarmOccured, 1:Shutdown
|
||||
|
||||
/* BYTE 2~7 - Reserved */
|
||||
|
||||
} CRx201;
|
||||
|
||||
typedef struct ClassRx210
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:PcbOverHeat
|
||||
* 1:FetOverHeat
|
||||
* 2:GenOverHeat1
|
||||
* 3:GenOverHeat2
|
||||
*/
|
||||
Uint16 GcuWarning;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:HwTrip
|
||||
* 1:HwIgbt
|
||||
* 2:HwDc
|
||||
* 3:GenOverCurrentU
|
||||
* 4:GenOverCurrentV
|
||||
* 5:GenOverCurrentW
|
||||
* 6:DcOverVoltage
|
||||
* 7:DcOverCurrent
|
||||
*
|
||||
* 8:CrankningOverCurrent
|
||||
* 9:PcbOverHeat
|
||||
* 10:FetOverHeat
|
||||
* 11:GenTempOverHeat1
|
||||
* 12:GenTempOverHeat2
|
||||
* 13:GenOverSpeed
|
||||
* 14:ResolverIC
|
||||
* 15:ResolverParity
|
||||
*/
|
||||
Uint16 GcuFault;
|
||||
|
||||
/* BYTE 4~7 - Reserved*/
|
||||
|
||||
} CRx210;
|
||||
|
||||
typedef struct ClassRx220
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 DcVoltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 DcCurrent;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 Rpm;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 Power;
|
||||
} CRx220;
|
||||
|
||||
typedef struct ClassRx221
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 PcbTemperature;
|
||||
|
||||
/* BYTE 1 */
|
||||
Uint16 FetTemperature;
|
||||
|
||||
/* BYTE 2 */
|
||||
Uint16 GenTemperature1;
|
||||
|
||||
/* BYTE 3 */
|
||||
Uint16 GenTemperature2;
|
||||
|
||||
/* BYTE 4~7 - Reserved */
|
||||
|
||||
} CRx221;
|
||||
|
||||
typedef struct ClassRx300
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 VersionMajor;
|
||||
|
||||
/* BYTE 1 */
|
||||
Uint16 VersionMinor;
|
||||
|
||||
/* BYTE 2 */
|
||||
Uint16 VersionPatch;
|
||||
|
||||
/* BYTE 3~7 - Reserved */
|
||||
|
||||
} CRx300;
|
||||
|
||||
typedef struct ClassRx301
|
||||
{
|
||||
|
||||
/* BYTE 0 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:AlarmOccured
|
||||
* 1~3:PlayState
|
||||
* 4:OverrideActive
|
||||
* 5:GlowPlugActive
|
||||
* 6:HeaterActive
|
||||
* 7:OilPressureMissing
|
||||
*/
|
||||
Uint16 State;
|
||||
|
||||
/* BYTE 1~7 - Reserved */
|
||||
|
||||
} CRx301;
|
||||
|
||||
typedef struct ClassRx310
|
||||
{
|
||||
/* BYTE 0 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:EngineOverHeat
|
||||
* 1:Reserved
|
||||
* 2:LoOilPressure
|
||||
* 3:IntakeOverHeat
|
||||
* 4:IntakeLoPressure
|
||||
* 5:EngineLoTemperature
|
||||
* 6:EngineSensor
|
||||
* 7:DefaltValueActive
|
||||
*/
|
||||
Uint16 EcuWarning;
|
||||
|
||||
/* BYTE 1 - Reserved */
|
||||
|
||||
/* BYTE 2 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:OilPressureMissing
|
||||
* 1:IntakeOverHeat
|
||||
* 2:EngineOverHeat
|
||||
* 3:Actuator
|
||||
* 4:RpmSignal
|
||||
* 5:EngineStartFail
|
||||
* 6:Reserved
|
||||
* 7:Reserved
|
||||
*/
|
||||
Uint16 EcuFault;
|
||||
|
||||
/* BYTE 3~7 - Reserved */
|
||||
|
||||
} CRx310;
|
||||
|
||||
typedef struct ClassRx320
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 ActualRpm;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 SetRpm;
|
||||
|
||||
/* BYTE 4 */
|
||||
Uint16 ActualTorque;
|
||||
|
||||
/* BYTE 5 */
|
||||
Uint16 SetTorque;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 SystemVoltage;
|
||||
} CRx320;
|
||||
|
||||
typedef struct ClassRx321
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 CoolantTemperature;
|
||||
|
||||
/* BYTE 1 */
|
||||
Uint16 Fan1Speed;
|
||||
|
||||
/* BYTE 2 */
|
||||
Uint16 Fan2Speed;
|
||||
|
||||
/* BYTE 3 */
|
||||
Uint16 CoolantPumpSpeed;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 BarometricPressure;
|
||||
|
||||
/* BYTE 6~7 - Reserved */
|
||||
|
||||
} CRx321;
|
||||
|
||||
typedef struct ClassRx322
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 TotalOperTimeL : 16;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 TotalOperTimeH : 16;
|
||||
|
||||
/* BYTE 4~7 - Reserved*/
|
||||
|
||||
} CRx322;
|
||||
|
||||
typedef struct ClassTx700
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 HeartBit;
|
||||
|
||||
/* BYTE 2 */
|
||||
Uint16 DCUversionMajor;
|
||||
|
||||
/* BYTE 3 */
|
||||
Uint16 DCUversionMinor;
|
||||
|
||||
/* BYTE 4 */
|
||||
Uint16 GCUversionMajor;
|
||||
|
||||
/* BYTE 5 */
|
||||
Uint16 GCUversionMinor;
|
||||
|
||||
/* BYTE 6 */
|
||||
Uint16 ECUversionMajor;
|
||||
|
||||
/* BYTE 7 */
|
||||
Uint16 ECUversionMinor;
|
||||
} CTx700;
|
||||
|
||||
typedef struct ClassTx701
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 DcuPlayState; // bit 0~3:PlayState
|
||||
|
||||
/* BYTE 1 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:DcuAlarmOccured
|
||||
* 1:DcuEmergencyStop
|
||||
* 2:PowerSwitchPush
|
||||
* 3:EcuFailSafe
|
||||
*/
|
||||
Uint16 DcuState;
|
||||
|
||||
/* BYTE 2 */
|
||||
Uint16 GcuPlayState; // bit 0~2:GcuPlayState
|
||||
|
||||
/* BYTE 3 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:GcuAlarmOccured
|
||||
* 1:GcuShutdown
|
||||
*/
|
||||
Uint16 GcuState;
|
||||
|
||||
/* BYTE 4 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:EcuAlarmOccured
|
||||
* 1~3:EcuPlayState
|
||||
* 4:ActiveOverride
|
||||
* 5:ActiveGlowPlug
|
||||
* 6:ActiveEngHeater
|
||||
* 7:OilPressureMissing
|
||||
*/
|
||||
Uint16 EcuState;
|
||||
|
||||
/* BYTE 5~7 - Reserved */
|
||||
|
||||
} CTx701;
|
||||
|
||||
typedef struct ClassTx710
|
||||
{
|
||||
/* BYTE 0 - GCU Warning */
|
||||
/*
|
||||
* bit description
|
||||
* 0:PcbOverHeat
|
||||
* 1:FetOverHeat
|
||||
* 2:Winding1OverHeat
|
||||
* 3:Winding2OverHeat
|
||||
*/
|
||||
Uint16 GcuWarning;
|
||||
|
||||
/* BYTE 1 - ECU Warning */
|
||||
/*
|
||||
* bit description
|
||||
* 0:EngineOverHeat
|
||||
* 1:Reserved
|
||||
* 2:LoOilPressure
|
||||
* 3:IntakeOverHeat
|
||||
* 4:IntakeLoPressure
|
||||
* 5:EngineLoTemperature
|
||||
* 6:EngineSensorFault
|
||||
* 7:DefaultValueActive
|
||||
*/
|
||||
Uint16 EcuWarning;
|
||||
|
||||
/* BYTE 2~7 - Reserved */
|
||||
|
||||
} CTx710;
|
||||
|
||||
typedef struct ClassTx720
|
||||
{
|
||||
/* BYTE 0~3 - DCU Fault */
|
||||
Uint16 DcuFault0;
|
||||
Uint16 DcuFault1;
|
||||
Uint16 DcuFault2;
|
||||
Uint16 DcuFault3;
|
||||
|
||||
/* BYTE 4~5 - GCU Fault */
|
||||
Uint16 GcuFault0;
|
||||
Uint16 GcuFault1;
|
||||
|
||||
/* BYTE 6 - Reserved */
|
||||
|
||||
/* BYTE 7 */
|
||||
Uint16 EcuFault;
|
||||
} CTx720;
|
||||
|
||||
typedef struct ClassTx730
|
||||
{
|
||||
/* BYTE 0 */
|
||||
/*
|
||||
* bit description
|
||||
* 0:EngineHeater
|
||||
* 1:GlowPlug
|
||||
* 2:Solenoid
|
||||
* 3:FuelPump
|
||||
* 4:CoolantPump
|
||||
* 5:Fan1
|
||||
* 6:Fan2
|
||||
* 7:Reserved
|
||||
*/
|
||||
Uint16 AuxState;
|
||||
|
||||
/* BYTE 1~7 - Reserved */
|
||||
|
||||
} CTx730;
|
||||
|
||||
typedef struct ClassTx731
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 EngineHeaterVoltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 EngineHeaterCurrent;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 GlowPlugVoltage;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 GlowPlugCurrent;
|
||||
} CTx731;
|
||||
|
||||
typedef struct ClassTx732
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 SolenoidVoltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 SolenoidCurrent;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 FuelPumpVoltage;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 FuelPumpCurrent;
|
||||
} CTx732;
|
||||
|
||||
typedef struct ClassTx733
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 CoolantPumpVoltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 CoolantPumpCurrent;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 Fan1Voltage;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 Fan1Current;
|
||||
} CTx733;
|
||||
|
||||
typedef struct ClassTx734
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 Fan2Voltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 Fan2Current;
|
||||
|
||||
/* BYTE 4~7 - Reserved */
|
||||
|
||||
} CTx734;
|
||||
|
||||
typedef struct ClassTx740
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 Voltage;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 Current;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 Rpm;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 Power;
|
||||
} CTx740;
|
||||
|
||||
typedef struct ClassTx741
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 PcbTemperature;
|
||||
|
||||
/* BYTE 1 */
|
||||
Uint16 FetTemperature;
|
||||
|
||||
/* BYTE 2 */
|
||||
Uint16 Winding1Temperature;
|
||||
|
||||
/* BYTE 3 */
|
||||
Uint16 Winding2Temperature;
|
||||
|
||||
/* BYTE 4~7 - Reserved */
|
||||
|
||||
} CTx741;
|
||||
|
||||
typedef struct ClassTx750
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 ActualRpm;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 SetRpm;
|
||||
|
||||
/* BYTE 4 */
|
||||
Uint16 ActualTorque;
|
||||
|
||||
/* BYTE 5 */
|
||||
Uint16 SetTorque;
|
||||
|
||||
/* BYTE 6~7 */
|
||||
Uint16 SystemVoltage;
|
||||
} CTx750;
|
||||
|
||||
typedef struct ClassTx751
|
||||
{
|
||||
/* BYTE 0 */
|
||||
Uint16 CoolantTemperature;
|
||||
|
||||
/* BYTE 1 */
|
||||
Uint16 Fan1Speed;
|
||||
|
||||
/* BYTE 2 */
|
||||
Uint16 Fan2Speed;
|
||||
|
||||
/* BYTE 3 */
|
||||
Uint16 CoolantPumpSpeed;
|
||||
|
||||
/* BYTE 4~5 */
|
||||
Uint16 Barometric;
|
||||
|
||||
/* BYTE 6~7 - Reserved */
|
||||
|
||||
} CTx751;
|
||||
|
||||
typedef struct ClassTx752
|
||||
{
|
||||
/* BYTE 0~1 */
|
||||
Uint16 OperationTimeL;
|
||||
|
||||
/* BYTE 2~3 */
|
||||
Uint16 OperationTimeH;
|
||||
|
||||
/* BYTE 4~7 - Reserved */
|
||||
|
||||
} CTx752;
|
||||
|
||||
interrupt void CECanInterruptA(void);
|
||||
interrupt void CECanInterruptB(void);
|
||||
void CSendECanDataA(void);
|
||||
void CSendECanDataB(void);
|
||||
void CInitEcan(void);
|
||||
|
||||
extern CCommCheck CommCheck;
|
||||
extern CRx200 Rx200;
|
||||
extern CRx210 Rx210;
|
||||
extern CRx220 Rx220;
|
||||
extern CRx221 Rx221;
|
||||
extern CRx300 Rx300;
|
||||
extern CRx301 Rx301;
|
||||
extern CRx310 Rx310;
|
||||
extern CRx320 Rx320;
|
||||
extern CRx321 Rx321;
|
||||
extern CRx322 Rx322;
|
||||
|
||||
typedef struct ClassRx400
|
||||
{
|
||||
struct
|
||||
{
|
||||
Uint16 BYTE0 : 8;
|
||||
Uint16 BYTE1 : 8;
|
||||
Uint16 BYTE2 : 8;
|
||||
Uint16 BYTE3 : 8;
|
||||
Uint16 BYTE4 : 8;
|
||||
Uint16 BYTE5 : 8;
|
||||
Uint16 BYTE6 : 8;
|
||||
Uint16 BYTE7 : 8;
|
||||
} Bytes;
|
||||
struct
|
||||
{
|
||||
Uint16 EngineHeater : 1;
|
||||
Uint16 GlowPlug : 1;
|
||||
Uint16 Solenoid : 1;
|
||||
Uint16 FuelPump : 1;
|
||||
Uint16 CoolantPump : 1;
|
||||
Uint16 Fan1 : 1;
|
||||
Uint16 Fan2 : 1;
|
||||
Uint16 AuxTestStart : 1;
|
||||
Uint16 rsvd_padding : 8;
|
||||
} AuxControl;
|
||||
} CRx400;
|
||||
|
||||
extern CRx400 Rx400;
|
||||
|
||||
#endif /* SOURCE_COMM_H_ */
|
||||
156
Display.h
Normal file
156
Display.h
Normal file
@@ -0,0 +1,156 @@
|
||||
#ifndef SOURCE_DISPLAY_H_
|
||||
#define SOURCE_DISPLAY_H_
|
||||
|
||||
#define ZONE6_DAT *(volatile Uint16*)0x00100001
|
||||
#define ZONE6_COM *(volatile Uint16*)0x00100000
|
||||
|
||||
#define OLED_WIDTH (128U) // ER-OLEDM024 Vertical Pixel 0~127
|
||||
#define OLED_HEIGHT (64U)
|
||||
#define OLED_PAGE (8U) // ER-OLEDM024 Page 0~7
|
||||
|
||||
#define TXT_ENG_WIDTH (6U)
|
||||
#define TXT_ENG_HEIGHT (12U)
|
||||
|
||||
#define TXT_TYPE_ENG (0U)
|
||||
#define TXT_TYPE_ETC (1U)
|
||||
|
||||
#define TXT_MAX_LEN (22U)
|
||||
#define TXT_LINE_LEN (5U)
|
||||
|
||||
#define OLED_LOAD_PROGRESS_X (14U)
|
||||
#define OLED_LOAD_PROGRESS_Y (52U)
|
||||
#define OLED_LOAD_PROGRESS_W (114U)
|
||||
#define OLED_LOAD_PROGRESS_H (10U)
|
||||
|
||||
#define MODE_COMMAND (0U)
|
||||
#define MODE_DATA (1U)
|
||||
|
||||
#define DIR_UP (1U)
|
||||
#define DIR_DOWN (0U)
|
||||
|
||||
typedef signed char int8;
|
||||
typedef unsigned char Uint8;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IDX_OLED_LINE_TITLE = 0U,
|
||||
IDX_OLED_LINE_1 = 14U,
|
||||
IDX_OLED_LINE_2 = 27U,
|
||||
IDX_OLED_LINE_3 = 40U,
|
||||
IDX_OLED_LINE_4 = 53U
|
||||
} E_IDX_OLED_LINE;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IDX_OLED_ROW_0 = 0U,
|
||||
IDX_OLED_ROW_1,
|
||||
IDX_OLED_ROW_2,
|
||||
IDX_OLED_ROW_3,
|
||||
IDX_OLED_ROW_4
|
||||
} E_IDX_OLED_ROW;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IDX_OLED_PASS_DIGIT_1 = 0U,
|
||||
IDX_OLED_PASS_DIGIT_2,
|
||||
IDX_OLED_PASS_DIGIT_3,
|
||||
IDX_OLED_PASS_DIGIT_4
|
||||
} E_IDX_OLED_PASS;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IDX_OLED_PAGE_APU1 = 0U, // 0
|
||||
IDX_OLED_PAGE_APU2, // 1
|
||||
IDX_OLED_PAGE_MENU1, // 2
|
||||
IDX_OLED_PAGE_MENU2, // 3
|
||||
IDX_OLED_PAGE_TEMP, // 4
|
||||
IDX_OLED_PAGE_SENSOR1, // 5
|
||||
IDX_OLED_PAGE_SENSOR2, // 6
|
||||
IDX_OLED_PAGE_SENSOR3, // 7
|
||||
IDX_OLED_PAGE_SENSOR4, // 8
|
||||
IDX_OLED_PAGE_WARNING1, // 9
|
||||
IDX_OLED_PAGE_WARNING2, // 10
|
||||
IDX_OLED_PAGE_FAULT1, // 11
|
||||
IDX_OLED_PAGE_FAULT2, // 12
|
||||
IDX_OLED_PAGE_FAULT3, // 13
|
||||
IDX_OLED_PAGE_FAULT4, // 14
|
||||
IDX_OLED_PAGE_FAULT5, // 15
|
||||
IDX_OLED_PAGE_FAULT6, // 16
|
||||
IDX_OLED_PAGE_FAULT7, // 17
|
||||
IDX_OLED_PAGE_RESET_ALARM, // 18
|
||||
IDX_OLED_PAGE_PASSWORD, // 19
|
||||
IDX_OLED_PAGE_MAINTENANCE, // 20
|
||||
IDX_OLED_PAGE_VERSION, // 21
|
||||
IDX_OLED_PAGE_KEY_TEST, // 21
|
||||
IDX_OLED_PAGE_SHUTDOWN, // 23
|
||||
IDX_OLED_PAGE_MAX
|
||||
} E_IDX_OLED_PAGE;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IDX_OLED_MENU_APU = 0U, // 0
|
||||
IDX_OLED_MENU_TEMP, // 1
|
||||
IDX_OLED_MENU_SENSOR, // 2
|
||||
IDX_OLED_MENU_WARNING, // 3
|
||||
} E_IDX_OLED_MENU1;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IDX_OLED_MENU_FAULT = 0U, // 0
|
||||
IDX_OLED_MENU_RESET, // 1
|
||||
IDX_OLED_MENU_DEBUG // 2
|
||||
} E_IDX_OLED_MENU2;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IDX_OLED_LINE_FOCUS_1 = 0U,
|
||||
IDX_OLED_LINE_FOCUS_2,
|
||||
IDX_OLED_LINE_FOCUS_3,
|
||||
IDX_OLED_LINE_FOCUS_4
|
||||
} E_IDX_OLED_LINE_FOCUS;
|
||||
|
||||
typedef struct ClassPageHandler
|
||||
{
|
||||
Uint16 uiPage;
|
||||
void (*pAction) (void); // PageTable 참조
|
||||
} CPageHandler;
|
||||
|
||||
typedef struct ClassOledOperValue
|
||||
{
|
||||
Uint16 uiBuff[OLED_WIDTH][OLED_PAGE];
|
||||
Uint16 uiPageNum;
|
||||
Uint16 uiOldPageNum;
|
||||
Uint16 uiFocusLine;
|
||||
Uint16 uiPrevFocusLine;
|
||||
Uint16 uiFocusDigit;
|
||||
Uint16 uiProgressValue;
|
||||
Uint16 uiProgressDone;
|
||||
Uint16 uiResetAlarmAnswer;
|
||||
Uint16 uiResetHourAnswer;
|
||||
int8 cStrBuff[TXT_LINE_LEN][TXT_MAX_LEN];
|
||||
int8 cAlignBuffer[TXT_MAX_LEN];
|
||||
struct
|
||||
{
|
||||
Uint16 TxtColor;
|
||||
Uint16 BgColor;
|
||||
} Color;
|
||||
struct
|
||||
{
|
||||
Uint16 X;
|
||||
Uint16 Y;
|
||||
} Point;
|
||||
} COledOperValue;
|
||||
|
||||
void CInitXintf(void);
|
||||
void CInitOled(void);
|
||||
void COledReflash(Uint16 x, Uint16 y, Uint16 width, Uint16 height);
|
||||
void CDisplayPostFail(void);
|
||||
void CSetPage(Uint16 PageNum);
|
||||
void CInitKeyOperValue(void);
|
||||
void CInitializePage(void);
|
||||
void COledBufferReset(void);
|
||||
void CDisplayAntiNoiseRefresh(void);
|
||||
|
||||
extern COledOperValue OledOperValue;
|
||||
|
||||
#endif /* SOURCE_DISPLAY_H_ */
|
||||
140
ci.ini
Normal file
140
ci.ini
Normal file
@@ -0,0 +1,140 @@
|
||||
;
|
||||
;
|
||||
; PA 의 설정입니다.
|
||||
;
|
||||
;-------------------------------------------------------------------------
|
||||
[PA]
|
||||
; 최초 PA 실행시에 테이블의 레코드를 모두 제거한 후 PA 가 수행됩니다.
|
||||
; default 값은 N 입니다.
|
||||
CLEAN_MODE=N
|
||||
;UTF-8로 인코딩된 파일도 인스펙션이 가능하도록 설정하는 옵션입니다.
|
||||
; default 값은 N 입니다.
|
||||
AUTO_ENCODING_UTF8=N
|
||||
|
||||
; 프로젝트 DB 에 대한 초기화 쿼리
|
||||
INIT_QUERY=PRAGMA mmap_size=2147418112;
|
||||
|
||||
; 람다 코드를 CFG에 포함할지 여부입니다.
|
||||
; 초기 값은 'N' 입니다.
|
||||
DISABLE_LAMBDA_CFG=N
|
||||
|
||||
|
||||
; 멀티 쓰레드 환경에서 refined 디렉토리를 유일하게 생성
|
||||
; 초기 값은 'Y' 입니다.
|
||||
MAKE_UNIQUE_REFINED_DIR=Y
|
||||
;
|
||||
;-------------------------------------------------------------------------
|
||||
;Violation 테이블에 violation 삽입 전에 인덱싱을 삭제하고 삽입 후에 다시 인덱싱 할지를 결정합니다.
|
||||
;default 값은 Y 입니다.
|
||||
[CI]
|
||||
REINDEX_MODE=Y
|
||||
|
||||
;
|
||||
;
|
||||
; DFA 의 설정입니다.
|
||||
;
|
||||
;-------------------------------------------------------------------------
|
||||
[DFA]
|
||||
DFA_ENABLE=Y
|
||||
SCFG_OUT=N
|
||||
LIMIT_ITER=N
|
||||
RESULT_OUT=N
|
||||
ITER_OUT=N
|
||||
TRANSFER_OUT=N
|
||||
FYCYC_ITER=40
|
||||
;
|
||||
;
|
||||
; Abstract Interpreter 설정
|
||||
;-------------------------------------------------------------------------
|
||||
[ABSINT]
|
||||
; ENABLE WHEN CI
|
||||
ABSINT_ENABLE=Y
|
||||
; MUST | MAY
|
||||
ABSINT_STRATEGY=MUST
|
||||
|
||||
|
||||
;-------------------------------------------------------------------------
|
||||
;
|
||||
; ExtendedDeclarations를 db에 저장할지 결정합니다.
|
||||
; db에 저장된 정보는 linking time에 사용됩니다.
|
||||
; default 값은 Y 입니다(Y or N).
|
||||
;
|
||||
;-------------------------------------------------------------------------
|
||||
[ExtendedDeclaration]
|
||||
SAVE_TO_PROJECT_REPOSITORY=Y
|
||||
|
||||
;-------------------------------------------------------------------------
|
||||
;
|
||||
; Report 시에 매크로 또는 시스템 매크로를 제외할 지 결정합니다.
|
||||
; SKIP_SYSTEM_MACRO, SKIP_ALL_MACRO, SKIP_NONE, SKIP_DEFINED_IN_FILE 이 옵션으로 가능합니다.
|
||||
; MACRO_SKIP_MODE=SKIP_DEFINED_IN_FILE:.*_Math\.h
|
||||
; default 값은 SKIP_SYSTEM_MACRO 입니다.
|
||||
;
|
||||
;-------------------------------------------------------------------------
|
||||
[REPORT]
|
||||
MACRO_SKIP_MODE=SKIP_SYSTEM_MACRO
|
||||
|
||||
;-------------------------------------------------------------------------
|
||||
; 전처리 과정과 파싱 과정이 동시에 수행되는 경우,
|
||||
; 전처리 파일을 생성할지 여부.
|
||||
; 전처리 과정을 따로 수행하는 경우 이 key와 무관하게 항상 생성함.
|
||||
; default 값은 Y이고, 특별한 경우(용량 문제 등)가 아닌 이상 항상 생성함.
|
||||
; 이 key가 없는 경우에도 Y로 동작함.
|
||||
GEN_PP_OUTPUT=Y
|
||||
|
||||
;-------------------------------------------------------------------------
|
||||
;
|
||||
; 아래는 FunctionUnit 들에 대해 옵션들입니다.
|
||||
; 특별한 경우가 아니라면 아래의 옵션들은 전문가의 손길이 필요합니다^^.
|
||||
;
|
||||
;
|
||||
;-------------------------------------------------------------------------
|
||||
[FunctionMapBuilder]
|
||||
SYMBOL_MAPPER=default
|
||||
;SYMBOL_MAPPER=physical
|
||||
; default
|
||||
; physical (헤더 파일내 static 함수를 물리적 파일 관점에서 보고, Translation Unit 이 달라도 동일한 것으로 처리)
|
||||
|
||||
|
||||
;-------------------------------------------------------------------------
|
||||
[CFGWriter]
|
||||
; debugging purpose - 각 함수에 대한 GML 표현을 Working Directory 에 기록합니다. yEd 를 이용하여 볼 수 있습니다.
|
||||
GML_OUT=N
|
||||
|
||||
;-------------------------------------------------------------------------
|
||||
[MetricGenerator]
|
||||
; FUNCR 을 물리적인 관점에서 추출할지 여부에 대한 설정입니다. 기본값 N
|
||||
PHYSICAL_FUNCR=N
|
||||
|
||||
;-------------------------------------------------------------------------
|
||||
[TestValidator]
|
||||
; debugging purpose - 저장된 Database 레코드의 참조 무결성을 확인합니다.
|
||||
CHECK_ALL=N
|
||||
CHECK_FUNCTION_MAP=N
|
||||
CHECK_CFG=N
|
||||
CHECK_FUNCTION_INFO=N
|
||||
CHECK_TYPE_INFO=N
|
||||
CHECK_USE_DEF=N
|
||||
TYPE_INFO_GML_OUT=N
|
||||
;-------------------------------------------------------------------------
|
||||
[ANALYSIS]
|
||||
; RTE annoatation 설정입니다. 초기 값은 'Y' 입니다.
|
||||
ANNOTATION=Y
|
||||
; psionic 엔진 수행 설정입니다. 초기 값은 'Y' 입니다.
|
||||
RUN_PSIONIC=Y
|
||||
; 분석기에서 type 이름을 짧게 납기는 옵션입니다.
|
||||
OPTIMIZE=Y
|
||||
; 시스템 코드를 제외한 사용자 코드만 변환하는 옵션입니다. 초기 값은 'N' 입니다.
|
||||
USER_CODE_ONLY=N
|
||||
; CAL 전처리기를 사용해서 CAL 의 사이즈를 줄입니다.
|
||||
RUN_PREPROC=Y
|
||||
; 특정 라이브러리에 대한 Over-Approximation 을 적용합니다.
|
||||
; ';' 를 구분자로 여러항목을 입력할 수 있습니다.
|
||||
OVER_APPROXIMATION=std::vector
|
||||
;-------------------------------------------------------------------------
|
||||
[ASTFactory]
|
||||
; AST를 생성할 때 lambda를 unknown expression 으로 취급할지 여부
|
||||
; 초기 값은 'N' 입니다.
|
||||
ENABLE_LAMBDA_AS_UNKNOWN=N
|
||||
|
||||
;현재 IniLoader 에 버그가 있어 마지막 줄은 읽지 않습니다. 반드시 마지막줄에 공백라인을 추가해주시기 바랍니다.
|
||||
Reference in New Issue
Block a user