From 5489a513d57d8a3c469e75801f6579277515aa38 Mon Sep 17 00:00:00 2001 From: Evgeny Gagua Date: Wed, 18 Dec 2024 21:26:29 +0200 Subject: [PATCH] Kaikela --- Projects/la_mojo/la_mojo.vpj | 2 +- Projects/la_mojo/makefile | 2 +- lib/App/common/deviceNodeCamera.cpp | 13 +++++++++++++ lib/App/common/deviceNodeSensor.cpp | 1 + lib/App/common/kernelModuleEmbedVideo.h | 7 ++++--- lib/data/protocol/protocol.cpp | 8 +++----- lib/data/protocol/protocolLGS2D.cpp | 12 ++++++------ 7 files changed, 29 insertions(+), 16 deletions(-) diff --git a/Projects/la_mojo/la_mojo.vpj b/Projects/la_mojo/la_mojo.vpj index 7cee4a7f..f6bd43b9 100644 --- a/Projects/la_mojo/la_mojo.vpj +++ b/Projects/la_mojo/la_mojo.vpj @@ -14,7 +14,7 @@ Version="1" OutputFile="%bdmojo_d" CompilerConfigName="Latest Version" - Defines='"/DDEBUG" "/DDEBUG_EXTRA" "/D__STDC_CONSTANT_MACROS__" "/D_CLIENT_APPLICATION_" "/D_OPENCV_" "/DRASPI_HARDWARE"'> + Defines='"/DDEBUG" "/D__STDC_CONSTANT_MACROS__" "/D_CLIENT_APPLICATION_" "/D_OPENCV_" "/DRASPI_HARDWARE"'> ts_ms > 3000 ) +#ifdef DEBUG + { + LOG("Targetd too old! ---> Skiping"); + utilizeROI( tVAL ); + + }; +#else + utilizeROI( tVAL ); +#endif + }; return tVAL; }; diff --git a/lib/App/common/deviceNodeSensor.cpp b/lib/App/common/deviceNodeSensor.cpp index 8d62b826..cc42da20 100644 --- a/lib/App/common/deviceNodeSensor.cpp +++ b/lib/App/common/deviceNodeSensor.cpp @@ -249,6 +249,7 @@ deviceNodeSensor::deviceNodeSensor( DBC_NODE_DATA *Data ):deviceNode( Data ),m_o deviceNodeSensor::~deviceNodeSensor(){ + LOG("Finish Destructor!"); }; bool deviceNodeSensor::reloadDeviceNodeFromDB(){ diff --git a/lib/App/common/kernelModuleEmbedVideo.h b/lib/App/common/kernelModuleEmbedVideo.h index 87ba1385..9fee3461 100644 --- a/lib/App/common/kernelModuleEmbedVideo.h +++ b/lib/App/common/kernelModuleEmbedVideo.h @@ -26,7 +26,8 @@ class kernelModuleEmbedVideo; #ifndef MEKOROT_PROJECT__ #define EVE_ENABLE_VIDEO #endif -//#define USE_SCALING_IN + +#define USE_SCALING_IN #ifndef DB_SHMEM_POINT #define DB_SHMEM_POINT "/dev/shm/argus" @@ -211,7 +212,7 @@ typedef map mapSTREAMMAPS; //#define ENCODER_DISABLED 0 //#define ENCODER_ENABLED 1 -//#define EVE_ENABLE_EASE_OUTPUT_FPS +#define EVE_ENABLE_EASE_OUTPUT_FPS #ifdef EVE_ENABLE_EASE_OUTPUT_FPS #define EVE_EASE_FPS_DIVIDER_MINIMUM 1 @@ -219,7 +220,7 @@ typedef map mapSTREAMMAPS; #define EVE_EASE_FPS_QUEUE_SIZE_MAXIMUM 8 #define EVE_EASE_FPS_QUEUE_SIZE_MINIMUM 2 #else - //#define EVE_ENABLE_DROP_OUTPUT_FPS + #define EVE_ENABLE_DROP_OUTPUT_FPS #endif #ifdef EVE_ENABLE_VIDEO diff --git a/lib/data/protocol/protocol.cpp b/lib/data/protocol/protocol.cpp index 4c6f1f5a..0184ac73 100644 --- a/lib/data/protocol/protocol.cpp +++ b/lib/data/protocol/protocol.cpp @@ -101,11 +101,11 @@ bool protocolParser::setTransport( basicTransport* Transport, bool CAE ){ LOG_ERROR("Transport Already Assigned!"); return false; }; - };/* else { //Danger -> If transport Object is deleted the pointer is wrong! + } else { //Danger -> If transport Object is deleted the pointer is wrong! if ( m_oDataTransport != NULL ) { m_oDataTransport->removeRecipient( this ); }; - };*/ + }; m_oDataTransport = Transport; if( Transport != NULL ){ setConnectionStatus( CS_CONNECTED ); @@ -116,9 +116,7 @@ bool protocolParser::setTransport( basicTransport* Transport, bool CAE ){ basicTransport *protocolParser::getCurrentTransport( void ){ LOG("Get Transport Req"); - if( m_oDataTransport == NULL ) { - LOG("Transport is NULL"); - } + if( m_oDataTransport == NULL ) LOG("Transport is NULL"); return m_oDataTransport; }; diff --git a/lib/data/protocol/protocolLGS2D.cpp b/lib/data/protocol/protocolLGS2D.cpp index 7d02196c..edc1f708 100644 --- a/lib/data/protocol/protocolLGS2D.cpp +++ b/lib/data/protocol/protocolLGS2D.cpp @@ -15,18 +15,18 @@ protocolLGS_2D::protocolLGS_2D( basicTransport *Transport, U8 DeviceID ):protocolParser(){ m_pLog = basicLogCollection::getInstance(); m_bDeviceID = DeviceID; - m_oDataTransport = Transport; - if( m_oDataTransport != NULL ) { - m_oDataTransport->addRecipient( ( protocolParser *) this ); - }; + //m_oDataTransport = Transport; + setTransport( Transport ); + //if( m_oDataTransport != NULL ) m_oDataTransport->addRecipient( ( protocolParser *) this ); }; protocolLGS_2D::~protocolLGS_2D(){ # ifdef DEBUG_EXTRA LOG("Destructor Begin"); # endif - m_mInquiryMutex.unlock(); -# ifdef DEBUG_EXTRA + setTransport( NULL, false ); + m_mInquiryMutex.unlock(); +# ifdef DEBUG LOG("Destructor End"); # endif };