You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
956 lines
29 KiB
956 lines
29 KiB
//----------------------------------------------------------------------------
|
|
// Laser Guard Ltd.
|
|
// Copyright © 2000-2002. All Rights Reserved.
|
|
// Version 1.0 01/01/2000
|
|
// Last modification: 08/10/2003
|
|
// PROJECT:
|
|
// SUBSYSTEM:
|
|
// FILE: kernel_.cpp
|
|
// AUTHOR: Sergey Chizhevskiy
|
|
// OVERVIEW
|
|
// ~~~~~~~~
|
|
// Source file of kernel_.cpp
|
|
//----------------------------------------------------------------------------
|
|
|
|
#include "stdafx.h"
|
|
#include "..\LgLib\Version.h"
|
|
#include "Kernel.h"
|
|
|
|
CKernel *CKernel::_instance = NULL;
|
|
|
|
CKernel *CKernel::getInstance(){
|
|
if( _instance == NULL ) {
|
|
_instance = new CKernel();
|
|
};
|
|
return _instance;
|
|
};
|
|
|
|
CKernel::CKernel() : CIsr(){
|
|
m_nInitErrorSkipCounter = 20;
|
|
m_pBoard = NULL;
|
|
m_pShadow = NULL;
|
|
//#ifdef ALS_300
|
|
// m_pShadowS = NULL;
|
|
//#endif
|
|
m_bIsCreated = false;
|
|
#ifndef NO_EMBED_CAMERA
|
|
m_pCamera = NULL;
|
|
m_pCameraComm = NULL;
|
|
#endif
|
|
m_bTimerISR = false;
|
|
nTimerISRCount = 0;
|
|
#ifdef BOARD_NO_RESPONCE_COUNT_INIT
|
|
m_nBoardNoRespoceCount = BOARD_NO_RESPONCE_COUNT_INIT;
|
|
#endif
|
|
m_bRun = true;
|
|
m_nSerialNumber = 0;
|
|
memset( m_pSerialNumber, 0, sizeof(m_pSerialNumber) );
|
|
m_nAddress = 0;
|
|
// init error timing
|
|
memset( m_dwTimeErrorOverflowSST, 0, sizeof(m_dwTimeErrorOverflowSST)*4 );
|
|
memset( m_dwTimeErrorOverflow, 0, sizeof(m_dwTimeErrorOverflow)*4 );
|
|
memset( m_dwTimeErrorSun, 0, sizeof(m_dwTimeErrorSun)*4 );
|
|
m_dwTimeErrorDelay_EA = 0UL;
|
|
m_dwTimeErrorDelay_IQ = 0UL;
|
|
m_dwTimePower = 0UL;
|
|
#ifdef DETECTION_MULTI_PROFILES
|
|
m_bActiveMasterDetectionProfile = 1;
|
|
m_bActiveSlaveDetectionProfile = 4;
|
|
#endif
|
|
|
|
|
|
#ifndef LGS_PLS_1
|
|
m_LRFDisable.bMaster = m_LRFDisable.bSlave = false;
|
|
#else
|
|
m_LRFDisable.bMaster = false;
|
|
#ifdef INFINITE_SAF_STUDY
|
|
m_LRFDisable.bSlave = false;
|
|
#else
|
|
m_LRFDisable.bSlave = true;
|
|
#endif
|
|
#endif
|
|
|
|
m_bWaitFirstZero = true;
|
|
#ifndef LGS_DISABLE_FILE_SYSTEM
|
|
// file system
|
|
m_pFSHelper = new NFSHelper();
|
|
//memset( &m_FileSystemPacket, 0, sizeof(m_FileSystemPacket) );
|
|
//m_pFSFileHandle = NULL;
|
|
|
|
#endif
|
|
// prepare software version
|
|
#ifdef LGS_MIRROR
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM,%s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#ifdef BOARD_A2D_FOUR_SAMPLES
|
|
"4"
|
|
#else
|
|
"1"
|
|
#endif
|
|
#ifdef COMPILE_AS_ANGLES
|
|
",AN"
|
|
#endif
|
|
#ifdef COMPILE_AS_GETFILE
|
|
",GF"
|
|
#endif
|
|
#ifdef DEBUG_BOARD_SET_TEST_BIT
|
|
",B"
|
|
#endif
|
|
#ifdef DEBUG_ENABLE_OLD_BOARD
|
|
",O"
|
|
#endif
|
|
#ifdef DEBUG_ENABLE_SEND_BOARDDATA
|
|
",S"
|
|
#endif
|
|
#ifdef COMM_RS485_PREVENT_ECHO
|
|
",E,ASDFGHJJ,"
|
|
#endif
|
|
#ifdef COMM_WITHOUT_INTERRUPTS
|
|
",I"
|
|
#endif
|
|
#ifdef BOARD_DEFFERED_PROCESSING
|
|
",D"
|
|
#endif
|
|
#ifdef BOARD_SUN_BIT_DISABLE
|
|
",S"
|
|
#endif
|
|
#ifdef LGS_PROTOCOL_TRANSMIT_DELAY
|
|
",T"
|
|
#endif
|
|
#ifdef BOARD_LINEARIZATION_ENABLE
|
|
",L"
|
|
#endif
|
|
#ifdef WATCHDOG_ENABLED
|
|
",W"
|
|
#endif
|
|
#ifdef BOARD_POWER_ENABLE
|
|
",P"
|
|
#endif
|
|
#ifndef EMBEDDED_CAMERA_DISABLED
|
|
",C"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_MIGVAN
|
|
"O"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_MIC
|
|
"M"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_JVC
|
|
"J"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_PHILIPS
|
|
"B"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_VICON
|
|
"V"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_PELCO
|
|
"P"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_CHINA
|
|
"X"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_FLIR
|
|
"F"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_HEBRON
|
|
"H"
|
|
#endif
|
|
#ifdef EMBEDDED_CAMERA_AMERICAN_DYNAMICS
|
|
"A"
|
|
#endif
|
|
);
|
|
}
|
|
|
|
CKernel::~CKernel(){
|
|
if( m_bIsCreated ) Destroy();
|
|
#ifndef LGS_DISABLE_FILE_SYSTEM
|
|
if( m_pFSHelper ) delete( m_pFSHelper );
|
|
#endif
|
|
}
|
|
|
|
#ifdef DETECTION_MULTI_PROFILES
|
|
bool CKernel::setActiveDetectionProfile( uint8_t profileID ){
|
|
if( profileID != m_bActiveMasterDetectionProfile ){
|
|
char APFN[32];
|
|
FILE *APFD;
|
|
if( profileID > 2 ) profileID = 2;
|
|
sprintf( APFN, "%c:\\profile.ini", (char)(65+m_pBoard->GetNotVolatileFileSystem()) );
|
|
|
|
//printf( "Save Settings to: %s\n", APFN );
|
|
|
|
APFD = fopen( APFN, "w+" );
|
|
|
|
if( APFD!=NULL ){
|
|
fprintf( APFD, "%d\n", profileID );
|
|
fclose( APFD );
|
|
} else {
|
|
//printf( "Cannot access file: %s\n", APFN );
|
|
return false;
|
|
};
|
|
|
|
m_bActiveMasterDetectionProfile = profileID;
|
|
m_bActiveSlaveDetectionProfile = profileID+3;
|
|
|
|
return true;
|
|
} else {
|
|
return false;
|
|
};
|
|
};
|
|
|
|
LPCTSTR m_pDetectionProfiles[] = {
|
|
{ "init_m01.ini" },
|
|
{ "init_m02.ini" },
|
|
{ "init_m03.ini" },
|
|
{ "init_s01.ini" },
|
|
{ "init_s02.ini" },
|
|
{ "init_s03.ini" }
|
|
};
|
|
#endif
|
|
|
|
bool CKernel::Create(){
|
|
m_bWaitFirstZero = true;
|
|
if( m_bIsCreated ) Destroy();
|
|
m_pBoard = CBoard::getInstance();
|
|
m_pShadow = new CShadow();
|
|
if( m_pShadow == NULL ) return false;
|
|
if( !m_pShadow->Load() ) return false;
|
|
//#ifdef ALS_300
|
|
// m_pShadowS = new CShadow( true );
|
|
// if( m_pShadowS == NULL ) return false;
|
|
//#endif
|
|
m_pComm485 = new CComm485();
|
|
if( m_pComm485 == NULL ) return false;
|
|
#ifdef DEBUG_SHOW_COMMUNICATION
|
|
m_pComm485->ShowCommunication( true );
|
|
#endif
|
|
int32_t nSpeed = LGS_COMM_BAUDRATE;
|
|
|
|
#ifndef COMPILE_AS_GETFILE
|
|
// load comm speed
|
|
FILE *pFile = fopen( "SERIAL.INI", "rt" );
|
|
if( pFile ){
|
|
fscanf( pFile, "%ld\n", &nSpeed );
|
|
fclose( pFile );
|
|
};
|
|
#endif
|
|
|
|
if( !m_pComm485->Create( CComm485::_COM2, nSpeed, 8, CComm485::_NOPARITY )) return false;
|
|
// create transport protocol
|
|
if( !m_Protocol.Create( m_pComm485 ) ) return false;
|
|
|
|
// assume that no relay
|
|
LGS::RELAY_PARAMETERS rp;
|
|
rp.bAuto = 0;
|
|
rp.nAutoDelay = 0;
|
|
rp.bNormallyClose = 0;
|
|
|
|
// no voltage control by default
|
|
LGS::VOLTAGE_PARAMETERS vp;
|
|
vp.bControl = false;
|
|
|
|
// both lasers enabled
|
|
m_LRFDisable.bMaster = false;
|
|
m_LRFDisable.bSlave = false;
|
|
|
|
// load user settings
|
|
|
|
BOARD_SETTINGS BoardSettings;
|
|
ARESET_SETTINGS AutoReset;
|
|
BoardSettings.nHID = 255;
|
|
SWITCHER_SETTINGS SwitcherSettings;
|
|
|
|
#ifndef NO_EMBED_CAMERA
|
|
m_pCameraComm = new CComm485();
|
|
if( m_pCameraComm == NULL ) return false;
|
|
|
|
#ifdef DEBUG_SHOW_COMMUNICATION
|
|
m_pCameraComm->ShowCommunication( true );
|
|
#endif
|
|
|
|
// assume that no camera
|
|
LGS::CAMERA_PARAMETERS cp;
|
|
cp.eType = LGS::CAMERA_TYPE_NONE;
|
|
cp.nShift = 0;
|
|
cp.bAuto = false;
|
|
cp.nAutoDelay = 0;
|
|
// load settings
|
|
LoadSettings( (PCHAR)m_pSerialNumber, &m_nSerialNumber, &m_nAddress, &cp, &rp, &vp, &m_LRFDisable );
|
|
LoadUserSettings( &AutoReset, &BoardSettings, &SwitcherSettings , m_pComm485, pCameraComm );
|
|
BoardSettings.M_LRFDisable = m_LRFDisable.bMaster;
|
|
BoardSettings.S_LRFDisable = m_LRFDisable.bSlave;
|
|
LoadFSSettings( &AutoReset, &BoardSettings, &SwitcherSettings , m_pComm485, pCameraComm );
|
|
#else
|
|
// load settings
|
|
LoadSettings( (PCHAR)m_pSerialNumber, &m_nSerialNumber, &m_nAddress, NULL, &rp, &vp, &m_LRFDisable );
|
|
LoadUserSettings( &AutoReset, &BoardSettings, &SwitcherSettings , m_pComm485, NULL );
|
|
BoardSettings.M_LRFDisable = m_LRFDisable.bMaster;
|
|
BoardSettings.S_LRFDisable = m_LRFDisable.bSlave;
|
|
LoadFSSettings( &AutoReset, &BoardSettings, &SwitcherSettings , m_pComm485, NULL );
|
|
#endif
|
|
|
|
|
|
//Telling the board of Relay Default mode
|
|
if( rp.bAuto ){
|
|
BoardSettings.RelayDefaultMode = rp.bNormallyClose;
|
|
} else {
|
|
BoardSettings.RelayDefaultMode = false;
|
|
};
|
|
|
|
#ifndef NO_EMBED_CAMERA
|
|
m_pCamera = new CCamera;
|
|
if( m_pCamera == NULL ) return false;
|
|
if( !m_pCamera->Create( (LGS::E_CAMERA_TYPE)cp.eType, m_pCameraComm, CComm485::_COM1, &cp, &SwitcherSettings ) ) return false;
|
|
#endif
|
|
|
|
//#ifdef DEBUG_SHOW_COMMUNICATION
|
|
// g_LgsComm485.ShowCommunication( false );
|
|
// #ifndef NO_EMBED_CAMERA
|
|
// g_CameraComm485.ShowCommunication( true );
|
|
// #endif
|
|
//#endif
|
|
//printf("Create Relay\n");
|
|
if( !m_Relay.Create( m_pBoard, &rp ) ) return false;
|
|
//printf("Create Voltage\n");
|
|
if( !m_Voltage.Create( &vp ) ) return false;
|
|
#ifdef DEBUG
|
|
printf("Create Board\n");
|
|
#endif
|
|
if( !m_pBoard->Create( &BoardSettings ) ) return false;
|
|
//printf("Autoreset\n");
|
|
if( !m_AutoReset.Create( &AutoReset ) ) return false;
|
|
|
|
#ifndef COMPILE_AS_GETFILE
|
|
//printf("Create Tracker[0]\n");
|
|
#ifndef NO_EMBED_CAMERA
|
|
if( !m_Tracker[0].Create( BoardSettings.M_LRFDisable, m_pCamera, &m_Relay, &m_AutoReset ) ) {
|
|
#else
|
|
if( !m_Tracker[0].Create( BoardSettings.M_LRFDisable, NULL, &m_Relay, &m_AutoReset ) ) {
|
|
#endif
|
|
return false;
|
|
};
|
|
#ifdef DETECT_JUST_MOVING_TARGETS
|
|
m_Tracker[0].SetMovingFilter( m_nMovingRadialFilter, m_nMovingDistanceFilter );
|
|
m_Tracker[0].SetBlindZoneFilter( m_nBZSAngleFilter, m_nBZEAngleFilter, m_nBZSRangeFilter, m_nBZERangeFilter );
|
|
#endif
|
|
#ifdef DEBUG_GRAPH_SCREEN_SST
|
|
m_Tracker[0].SetIndex(0);
|
|
#endif
|
|
//printf("Done\n");
|
|
#ifndef LGS_MIRROR
|
|
#ifndef LGS_PLS_1 // ALS Systems
|
|
//printf("Create Tracker[1](ALS)\n");
|
|
#ifndef NO_EMBED_CAMERA
|
|
if( !m_Tracker[1].Create( BoardSettings.S_LRFDisable, m_pCamera, &m_Relay, &m_AutoReset ) ){
|
|
#else
|
|
if( !m_Tracker[1].Create( BoardSettings.S_LRFDisable, NULL, &m_Relay, &m_AutoReset ) ){
|
|
#endif
|
|
return false;
|
|
};
|
|
#ifdef DETECT_JUST_MOVING_TARGETS
|
|
m_Tracker[1].SetMovingFilter( m_nMovingRadialFilter, m_nMovingDistanceFilter );
|
|
m_Tracker[1].SetBlindZoneFilter( m_nBZSAngleFilter, m_nBZEAngleFilter, m_nBZSRangeFilter, m_nBZERangeFilter );
|
|
#endif
|
|
#ifdef DEBUG_GRAPH_SCREEN_SST
|
|
m_Tracker[1].SetIndex(1);
|
|
#endif
|
|
//printf("Done\n");
|
|
#endif
|
|
#endif
|
|
|
|
|
|
#ifdef DETECTION_MULTI_PROFILES
|
|
char APFN[32];
|
|
FILE *APFD;
|
|
sprintf( APFN, "%c:\\profile.ini", (char)( 65+BoardSettings.nHID ) );
|
|
APFD = fopen( APFN, "r" );
|
|
if( APFD!=NULL ){
|
|
uint8_t profileID;
|
|
fscanf( APFD, "%d\n", &m_bActiveMasterDetectionProfile );
|
|
m_bActiveSlaveDetectionProfile = m_bActiveMasterDetectionProfile+3;
|
|
fclose( APFD );
|
|
} else {
|
|
m_bActiveMasterDetectionProfile = 0; // to ensure no to exit from next function
|
|
setActiveDetectionProfile( 1 );
|
|
};
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef WATCHDOG_ENABLED
|
|
if( !m_Detector[0].Create( BoardSettings.M_LRFDisable, &m_Tracker[0], m_pShadow, 0, /*_T("init_m.ini")*/( PCHAR )m_pDetectionProfiles[m_bActiveMasterDetectionProfile], &m_WatchDog, LRF_ID_MASTER ) ) {
|
|
#else
|
|
if( !m_Detector[0].Create( BoardSettings.M_LRFDisable, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveMasterDetectionProfile], LRF_ID_MASTER ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[0].Create( BoardSettings.M_LRFDisable, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveMasterDetectionProfile] ) ) {
|
|
#endif
|
|
#else
|
|
//printf("Singleprofiles Detector\n");
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef WATCHDOG_ENABLED
|
|
if( !m_Detector[0].Create( BoardSettings.M_LRFDisable, &m_Tracker[0], m_pShadow, 0, _T("init_m.ini"), &m_WatchDog, LRF_ID_MASTER ) ) {
|
|
#else
|
|
if( !m_Detector[0].Create( BoardSettings.M_LRFDisable, &m_Tracker[0], m_pShadow, 0, _T("init_m.ini"), LRF_ID_MASTER ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[0].Create( BoardSettings.M_LRFDisable, &m_Tracker[0], m_pShadow, 0, _T("init_m.ini") ) ) {
|
|
#endif
|
|
|
|
#endif
|
|
return false;
|
|
};
|
|
#ifdef STORE_FIRST_SAF
|
|
if( g_bSAFFileEnable ){
|
|
m_Detector[0].load_stored_SAF();
|
|
};
|
|
#endif
|
|
#if defined( LGS_MIRROR ) && !defined( LGS_MND )
|
|
#ifdef DETECTION_MULTI_PROFILES
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef WATCHDOG_ENABLED
|
|
if( !m_Detector[1].Create( m_LRFDisable.bSlave, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], &m_WatchDog, LRF_ID_SLAVE ) ) {
|
|
#else
|
|
if( !m_Detector[1].Create( m_LRFDisable.bSlave, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], LRF_ID_SLAVE ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[1].Create( m_LRFDisable.bMaster, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile] ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[1].Create( m_LRFDisable.bSlave, &m_Tracker[0], m_pShadow, 0, "init_s.ini" ) ){
|
|
#endif
|
|
return false;
|
|
};
|
|
#ifdef DETECTION_MULTI_PROFILES
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef WATCHDOG_ENABLED
|
|
if( !m_Detector[2].Create( m_LRFDisable.bSlave, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], &m_WatchDog, LRF_ID_SLAVE ) ) {
|
|
#else
|
|
if( !m_Detector[2].Create( m_LRFDisable.bSlave, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], LRF_ID_SLAVE ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[2].Create( m_LRFDisable.bMaster, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile] ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[2].Create( m_LRFDisable.bMaster, &m_Tracker[0], m_pShadow, 0, "init_s.ini" ) ){
|
|
#endif
|
|
return false;
|
|
};
|
|
#ifdef DETECTION_MULTI_PROFILES
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef WATCHDOG_ENABLED
|
|
if( !m_Detector[3].Create( m_LRFDisable.bSlave, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], &m_WatchDog, LRF_ID_SLAVE ) ) {
|
|
#else
|
|
if( !m_Detector[3].Create( m_LRFDisable.bSlave, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], LRF_ID_SLAVE ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[3].Create( m_LRFDisable.bMaster, &m_Tracker[0], m_pShadow, 0, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile] ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[3].Create( m_LRFDisable.bSlave, &m_Tracker[0], m_pShadow, 0, "init_s.ini" ) ){
|
|
#endif
|
|
return false;
|
|
};
|
|
#else
|
|
//printf("Single Profile\n");
|
|
#if !defined ( LGS_PLS_1 ) && !defined( LGS_MND ) //ALS Systems
|
|
#ifdef DETECTION_MULTI_PROFILES
|
|
#ifdef ALS_300
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef WATCHDOG_ENABLED
|
|
if( !m_Detector[1].Create( BoardSettings.S_LRFDisable, &m_Tracker[1], m_pShadowS, LGS_MAX_DETECTOR_ANGLES / 2, /*_T("init_s.ini")*/( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], &m_WatchDog, LRF_ID_SLAVE ) ) {
|
|
#else
|
|
if( !m_Detector[1].Create( BoardSettings.S_LRFDisable, &m_Tracker[1], m_pShadowS, LGS_MAX_DETECTOR_ANGLES / 2, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], LRF_ID_SLAVE ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[1].Create( BoardSettings.S_LRFDisable, &m_Tracker[1], m_pShadowS, LGS_MAX_DETECTOR_ANGLES / 2, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile] ) ) {
|
|
#endif
|
|
#else
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef WATCHDOG_ENABLED
|
|
if( !m_Detector[1].Create( m_LRFDisable.bSlave, &m_Tracker[1], m_pShadow, LGS_MAX_DETECTOR_ANGLES / 2, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], &m_WatchDog, LRF_ID_SLAVE ) ) {
|
|
#else
|
|
if( !m_Detector[1].Create( m_LRFDisable.bSlave, &m_Tracker[1], m_pShadow, LGS_MAX_DETECTOR_ANGLES / 2, ( PCHAR )m_pDetectionProfiles[m_bActiveSlaveDetectionProfile], LRF_ID_SLAVE ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[1].Create( m_LRFDisable.bSlave, &m_Tracker[1], m_pShadow, LGS_MAX_DETECTOR_ANGLES / 2, ( PCHAR ) m_pDetectionProfiles[m_bActiveSlaveDetectionProfile] ) ) {
|
|
#endif
|
|
#endif
|
|
#else
|
|
#ifdef ALS_300
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef WATCHDOG_ENABLED
|
|
if( !m_Detector[1].Create( BoardSettings.S_LRFDisable, &m_Tracker[1], m_pShadowS, LGS_MAX_DETECTOR_ANGLES / 2, _T("init_s.ini"), &m_WatchDog, LRF_ID_SLAVE ) ) {
|
|
#else
|
|
if( !m_Detector[1].Create( BoardSettings.S_LRFDisable, &m_Tracker[1], m_pShadowS, LGS_MAX_DETECTOR_ANGLES / 2, _T("init_s.ini"), LRF_ID_SLAVE ) ) {
|
|
#endif
|
|
#else
|
|
if( !m_Detector[1].Create( m_LRFDisable.bSlave, &m_Tracker[1], m_pShadow, LGS_MAX_DETECTOR_ANGLES / 2, _T("init_s.ini") ) ){
|
|
#endif
|
|
#else
|
|
if( !m_Detector[1].Create( m_LRFDisable.bSlave, &m_Tracker[1], m_pShadow, LGS_MAX_DETECTOR_ANGLES / 2, _T("init_s.ini") ) ){
|
|
#endif
|
|
#endif
|
|
return false;
|
|
};
|
|
#endif
|
|
#endif
|
|
#ifdef DEBUG_EXTRA
|
|
printf("Done\n");
|
|
#endif
|
|
#ifndef RANGE_16BIT
|
|
//printf("Calibrator\n");
|
|
if( !m_Calibrator[0].Create( "lt0.ini" ) ) return false;
|
|
#ifndef LGS_MIRROR
|
|
#ifndef LGS_PLS_1
|
|
if( !m_Calibrator[1].Create( "lt1.ini" ) ) return false;
|
|
#endif
|
|
#endif
|
|
//printf("Done\n");
|
|
#endif
|
|
#endif // ! COMPILE_AS_GETFILE
|
|
|
|
if( !m_GetFile.Create() ) return false;
|
|
|
|
#ifdef DEBUG_EXTRA
|
|
printf("Get File Done\n");
|
|
#endif
|
|
|
|
//********************************************************
|
|
//*
|
|
//* GENERATING VERSION STRING
|
|
//*
|
|
//********************************************************
|
|
#ifdef DEBUG
|
|
printf("Creating SW String\n");
|
|
#endif
|
|
#ifdef COMPILE_AS_GETFILE
|
|
#ifdef LGS_MIRROR
|
|
#if defined( LGS_STEPPER ) || defined( LGS_FOD )
|
|
#ifdef LGS_FOD
|
|
#ifdef RANGE_16BIT
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"FODGFX"
|
|
#else
|
|
"FODGF"
|
|
#endif
|
|
#else
|
|
#ifdef RANGE_16BIT
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"LFSSGFX"
|
|
#else
|
|
"LFSSGF"
|
|
#endif
|
|
#endif
|
|
#else
|
|
#ifdef LGS_MND
|
|
#ifdef RANGE_16BIT
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"MNDGFX"
|
|
#else
|
|
"MNDGF"
|
|
#endif
|
|
#else
|
|
#ifdef RANGE_16BIT
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"LFSGFX"
|
|
#else
|
|
"LFSGF"
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#else
|
|
#ifdef LGS_PLS_1
|
|
#ifdef RANGE_16BIT
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
#ifdef LGS_PLS_200
|
|
"PLSGFX100"
|
|
#else
|
|
"PLSGFX1"
|
|
#endif
|
|
#else
|
|
#ifdef LGS_PLS_200
|
|
"PLSGFX100"
|
|
#else
|
|
"PLSGFX1"
|
|
#endif
|
|
#endif
|
|
#else
|
|
#ifdef RANGE_16BIT
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"ALSGFX"
|
|
#else
|
|
"ALSGF"
|
|
#endif
|
|
#endif
|
|
#endif // LGS_MIRROR
|
|
#else // ! COMPILE_AS_GETFILE
|
|
#ifdef LGS_MIRROR
|
|
#if defined( LGS_STEPPER ) || defined( LGS_FOD )
|
|
#ifdef LGS_FOD
|
|
#ifdef RANGE_16BIT
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#else
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"FODX"
|
|
#else
|
|
"FOD"
|
|
#endif
|
|
#else
|
|
#ifdef RANGE_16BIT
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#else
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"LFSSX"
|
|
#else
|
|
"LFSS"
|
|
#endif
|
|
#endif
|
|
#else
|
|
#ifdef LGS_MND
|
|
#ifdef RANGE_16BIT
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#else
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"MNDX"
|
|
#else
|
|
"MND"
|
|
#endif
|
|
#else
|
|
#ifdef RANGE_16BIT
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#else
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %dM, %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(), LGS_MIRROR,
|
|
#endif
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
"LFSX"
|
|
#else
|
|
"LFS"
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#else
|
|
#ifdef LGS_PLS_1
|
|
#ifdef RANGE_16BIT
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
|
|
#else
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
#ifdef LGS_PLS_200
|
|
"PLSX100"
|
|
#else
|
|
"PLSX1"
|
|
#endif
|
|
#else
|
|
#ifdef LGS_PLS_200
|
|
"PLS100"
|
|
#else
|
|
"PLS1"
|
|
#endif
|
|
#endif
|
|
#else
|
|
#ifdef RANGE_16BIT
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s 16b %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#else
|
|
#ifdef STORE_FIRST_SAF
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s F%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#else
|
|
s_nSoftwareVersion = sprintf( s_pSoftwareVersion, "%s %s%s%s%s%s %s %s %s", CLgVersion::GetBuildTimeStr(),
|
|
#endif
|
|
#endif
|
|
#ifdef NO_EMBED_CAMERA
|
|
#ifdef ALS_300
|
|
#ifdef ALS_300_BM
|
|
"ALSX20K"
|
|
#else
|
|
"ALSX300"
|
|
#endif
|
|
#else
|
|
"ALSX"
|
|
#endif
|
|
#else
|
|
#ifdef ALS_300
|
|
#ifdef ALS_300_BM
|
|
"ALS20K"
|
|
#else
|
|
"ALS300"
|
|
#endif
|
|
#else
|
|
"ALS"
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#endif // LGS_MIRROR
|
|
#endif // COMPILE_AS_GETFILE
|
|
,( m_pBoard->getBoardType() == BT_VORTEX_SX || m_pBoard->getBoardType() == BT_VORTEX_DX || m_pBoard->getBoardType() == BT_VORTEX_MX )?"d":"i"
|
|
,( g_bNoBlackTargets )?"B":""
|
|
,(m_pBoard->workingEnabled())?((( m_pBoard->getBoardWM() == WM_BLO_ONLY ) || ( m_pBoard->getBoardWM() == WM_FW_UPGRADE ) )?"BLO":""):"NLC"
|
|
,( g_bWatchDogEnable )?"W":""
|
|
#ifdef STORE_FIRST_SAF
|
|
#ifdef INFINITE_SAF_STUDY
|
|
,( g_bSAFFreezEnable )?((m_Detector[0].isSAFFrozen())?((g_bSAFFileEnable)?"F":"M"):"S"):"D"
|
|
#else
|
|
,( g_bSAFFreezEnable )?((g_bSAFFileEnable)?"F":"M"):"D"
|
|
#endif
|
|
#endif
|
|
//#if defined( LGS_PLS_1 ) || defined( LGS_FOD ) || defined( LGS_STEPPER ) || defined( LGS_MND )
|
|
, m_pBoard->GetBFW()
|
|
, m_pBoard->GetBSW()
|
|
//#endif
|
|
, m_pBoard->GetBSN() );
|
|
//printf("SW:%s\n", s_pSoftwareVersion );
|
|
//printf("Done\n");
|
|
#ifdef WATCHDOG_ENABLED
|
|
//printf("Start Watchdog\n");
|
|
// start watchdog
|
|
if( g_bWatchDogEnable ) if( !m_WatchDog.Create() ) return false;
|
|
//printf("Done\n");
|
|
#endif
|
|
#ifndef COMPILE_AS_GETFILE
|
|
|
|
//printf("Issue Board Reset\n");
|
|
//m_pBoard->Reset();
|
|
// printf("Done\n");
|
|
#endif
|
|
|
|
#ifndef COMM_WITHOUT_INTERRUPTS
|
|
|
|
// m_pComm485->SetFCT( false ); // Disable usage of timer with Main Programm Port
|
|
// m_pCameraComm->SetFCT( false ); // Disable usage of timer with Camera Programm Port
|
|
if ( ! m_bTimerISR ){ // setup Timer Interupt Procedure
|
|
printf("ISR -> Setup Timer!\n");
|
|
#ifndef NO_EMBED_CAMERA
|
|
if( m_pCameraComm->m_bFollowControlTimer || m_pComm485->m_bFollowControlTimer ) ){
|
|
#else
|
|
if( m_pComm485->m_bFollowControlTimer ){
|
|
#endif
|
|
intTimerCC();
|
|
m_bTimerISR = initISR( 10 );
|
|
} else {
|
|
#ifndef NO_EMBED_CAMERA
|
|
m_pCameraComm->SetFCT( false ); // Disable usage of WD timer
|
|
#endif
|
|
m_pComm485->SetFCT( false ); // Disable usage of timer with Main Programm Port
|
|
};
|
|
#ifdef DEBUG
|
|
printf("Done\n");
|
|
#endif
|
|
};
|
|
#endif
|
|
m_bIsCreated = true;
|
|
return m_bIsCreated;
|
|
};
|
|
|
|
void CKernel::Destroy(){
|
|
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
if( m_bIsCreated ){
|
|
debug("Kernel Destroy");
|
|
} else {
|
|
debug("Reset Components in Create!");
|
|
};
|
|
#endif
|
|
#ifndef NO_EMBED_CAMERA
|
|
if( m_pCamera ){
|
|
delete( m_pCamera );
|
|
m_pCamera = NULL;
|
|
};
|
|
if( m_pCameraComm ) {
|
|
delete( m_pCameraComm );
|
|
m_pCameraComm = NULL;
|
|
};
|
|
#endif
|
|
if( m_pComm485 ) {
|
|
delete( m_pComm485 );
|
|
m_pComm485 = NULL;
|
|
};
|
|
#ifndef COMPILE_AS_GETFILE
|
|
if ( m_bTimerISR ) resignISR();
|
|
#endif
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("GetFile Destroy");
|
|
#endif
|
|
m_GetFile.Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
debugProcBegin("Protocol Destroy");
|
|
#endif
|
|
m_Protocol.Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
debugProcBegin("Detector[0] Destroy");
|
|
#endif
|
|
m_Detector[0].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
#if !defined( LGS_PLS_1 ) && !defined( LGS_MND )
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("Detector[1] Destroy");
|
|
#endif
|
|
m_Detector[1].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
#endif
|
|
#if defined( LGS_MIRROR ) && !defined( LGS_MND )
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("Detector[2] Destroy");
|
|
#endif
|
|
m_Detector[2].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
debugProcBegin("Detector[3] Destroy");
|
|
#endif
|
|
m_Detector[3].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
debugProcBegin("Tracker[0] Destroy");
|
|
#endif
|
|
m_Tracker[0].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
#else
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("Tracker[0] Destroy");
|
|
#endif
|
|
m_Tracker[0].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
#if !defined(LGS_PLS_1) && !defined( LGS_MND )
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("Tracker[1] Destroy");
|
|
#endif
|
|
m_Tracker[1].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("Voltage Control Destroy");
|
|
#endif
|
|
m_Voltage.Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
debugProcBegin("Relay Destroy");
|
|
#endif
|
|
m_Relay.Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
#ifndef RANGE_16BIT
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("Calibrator[0] Destroy");
|
|
#endif
|
|
m_Calibrator[0].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
#endif
|
|
#ifndef LGS_MIRROR
|
|
#if !defined( LGS_PLS_1 ) && !defined( LGS_MND )
|
|
#ifndef RANGE_16BIT
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("Calibrator[1] Destroy");
|
|
#endif
|
|
m_Calibrator[1].Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcBegin("Auto-Reset Destroy");
|
|
#endif
|
|
m_AutoReset.Destroy();
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debugProcEnd();
|
|
#endif
|
|
m_pBoard = NULL;
|
|
m_pShadow = NULL;
|
|
m_bRun = true;
|
|
m_bIsCreated = false;
|
|
#ifdef DEBUG_PRINTOUT_MSGS
|
|
debug("Exit From Kernel Destroy!");
|
|
#endif
|
|
}
|
|
|