From 9664782c2f85d550100e5622af623b393a0e9c96 Mon Sep 17 00:00:00 2001 From: payton Date: Tue, 2 Jan 2024 15:42:01 +0800 Subject: [PATCH 1/4] =?UTF-8?q?1.=E4=BF=AE=E6=94=B9iq=20test=E7=BC=96?= =?UTF-8?q?=E8=AF=91=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- rtos/code/driver/na51089/source/mcu/sf_mcu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rtos/code/driver/na51089/source/mcu/sf_mcu.c b/rtos/code/driver/na51089/source/mcu/sf_mcu.c index 59998b393..b00a28952 100755 --- a/rtos/code/driver/na51089/source/mcu/sf_mcu.c +++ b/rtos/code/driver/na51089/source/mcu/sf_mcu.c @@ -2171,7 +2171,6 @@ void sf_file_thumb_cfg_sava(void) UINT8 fileIndex = 0; INT32 ret_fs = 0; FST_FILE_STATUS FileStat; - char tmp[64] = {'\0'}; UIMenuStoreInfo *puiPara = sf_ui_para_get(); if (pThumbFileCfg != NULL) { @@ -2183,6 +2182,7 @@ void sf_file_thumb_cfg_sava(void) //static int flag = 0; //struct stat st; #if SF_IQ_TEST != ENABLE + char tmp[64] = {'\0'}; INT32 uiStatus = 0; UINT8 ucAttrib = 0; snprintf(tmp, sizeof(tmp), "%c%s", 'A', PHOTO_THUMB_PATH); From c54e521de29eaf2687d38e0a2d7508611c7eaca0 Mon Sep 17 00:00:00 2001 From: payton Date: Tue, 2 Jan 2024 15:42:26 +0800 Subject: [PATCH 2/4] =?UTF-8?q?1.=E4=BF=AE=E6=94=B9battery=E6=B5=8B?= =?UTF-8?q?=E8=AF=95log?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../source/sf_app/code/source/battery/sf_battery.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/code/application/source/sf_app/code/source/battery/sf_battery.c b/code/application/source/sf_app/code/source/battery/sf_battery.c index 14318a85c..648f16b7b 100755 --- a/code/application/source/sf_app/code/source/battery/sf_battery.c +++ b/code/application/source/sf_app/code/source/battery/sf_battery.c @@ -895,7 +895,19 @@ void sf_battery_level_polling(void) LibatCnt++; } readBatCnt++; + if(puiPara->BatteryLogSwitch) + { + printf("\nDC Adc:%d After Convert:(%d.%dV),Is Dc In=%s, TemperAdc:%d \n", sf_battery_convert_to_adc(24, 100, DcVoltageVal), DcVoltageVal / 10, DcVoltageVal % 10, IsPowerDcIn == 1? "Yes" : "No", TemperAdc); + if(LiPolymerVoltageVal) + { + printf("Li Battery Adc:%d After Convert:(%d.%dV)\n\n", sf_battery_convert_to_adc(24, 100, LiPolymerVoltageVal), LiPolymerVoltageVal / 10, LiPolymerVoltageVal % 10); + } + else + { + printf("Other Battery Adc:%d After Convert:(%d.%dV)\n\n", sf_aa_battery_convert_to_adc(24, 100, BatVoltageVal),BatVoltageVal / 10, BatVoltageVal % 10); + } + } if(readBatCnt >= 10) { _DcVoltageVal = dcTemp / 10; From fd04e228d5d24f82130ba782d6ca5e1fdb5023f7 Mon Sep 17 00:00:00 2001 From: payton Date: Tue, 2 Jan 2024 16:43:43 +0800 Subject: [PATCH 3/4] =?UTF-8?q?1.=E6=8F=92=E5=85=A5usb=E6=97=A0=E9=9C=80?= =?UTF-8?q?=E6=A3=80=E6=B5=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../source/cardv/SrcCode/System/SF_SysStrgMng.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/code/application/source/cardv/SrcCode/System/SF_SysStrgMng.c b/code/application/source/cardv/SrcCode/System/SF_SysStrgMng.c index 8dad83164..05d76076e 100755 --- a/code/application/source/cardv/SrcCode/System/SF_SysStrgMng.c +++ b/code/application/source/cardv/SrcCode/System/SF_SysStrgMng.c @@ -18,7 +18,7 @@ #include #include #include - +#include "sf_mcu.h" typedef struct { int event; @@ -90,7 +90,12 @@ static UINT32 SF_StrgSpaceCheckFull(MMC_DEV_TYPE mmc_dev) { UINT64 diskFree = 0; UINT32 ret = 0; - + #if HUNTING_CAMERA_MCU == ENABLE + if(sf_get_power_off_flag() || sf_is_usb_flag()) + { + return ret; + } + #endif /*check disk free size*/ if(mmc_dev == MMC_DEV_SD) { @@ -341,7 +346,7 @@ static void* mmc_monitoring_thread(void *arg) int sf_mmc_dev_check_start(void) { - SF_StrgInit();// 初始化sf_mmc设备Obj + SF_StrgInit();// 初始化sf_mmc设备Obj int ret = pthread_create(&MMCMonitorTskCfg.TskId, NULL, mmc_monitoring_thread, NULL); if(ret != SF_SUCCESS) From 20b4440a105b2a37383ca56fe0671f58e7580d98 Mon Sep 17 00:00:00 2001 From: payton Date: Tue, 2 Jan 2024 16:45:04 +0800 Subject: [PATCH 4/4] =?UTF-8?q?1.=E6=8F=92=E5=85=A5usb=E5=90=8E=E8=8F=9C?= =?UTF-8?q?=E5=8D=95=E7=9A=84icon=E4=B8=8D=E9=9C=80=E8=A6=81=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=EF=BC=9B2.=E6=8B=94=E6=8E=89SD=E5=8D=A1=E5=90=8E?= =?UTF-8?q?=E6=97=A0=E9=9C=80=E6=A3=80=E6=9F=A5A=E7=9B=98=E4=BF=A1?= =?UTF-8?q?=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../UIFlowPhoto/UIFlowPhotoEventCallback.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/code/application/source/cardv/SrcCode/UIWnd/LVGL_SPORTCAM/UIFlowLVGL/UIFlowPhoto/UIFlowPhotoEventCallback.c b/code/application/source/cardv/SrcCode/UIWnd/LVGL_SPORTCAM/UIFlowLVGL/UIFlowPhoto/UIFlowPhotoEventCallback.c index af2ebfe7e..7909f6344 100755 --- a/code/application/source/cardv/SrcCode/UIWnd/LVGL_SPORTCAM/UIFlowLVGL/UIFlowPhoto/UIFlowPhotoEventCallback.c +++ b/code/application/source/cardv/SrcCode/UIWnd/LVGL_SPORTCAM/UIFlowLVGL/UIFlowPhoto/UIFlowPhotoEventCallback.c @@ -774,8 +774,14 @@ static void update_sd_card_status(lv_obj_t* obj) LV_PLUGIN_IMG_ID_SF_SD_256GB, LV_PLUGIN_IMG_ID_SF_SD_FULL }; - UINT64 diskSize = FileSys_GetDiskInfoEx('A', FST_INFO_DISK_SIZE); - unsigned int index = check_sd_size(diskSize); + UINT64 diskSize = 0; + unsigned int index = 0; + UINT32 cardStatus = System_GetState(SYS_STATE_CARD); + if (cardStatus != CARD_REMOVED) + { + diskSize = FileSys_GetDiskInfoEx('A', FST_INFO_DISK_SIZE); + index = check_sd_size(diskSize); + } if (index > 7) { return; @@ -947,6 +953,12 @@ static void update_dzoom(void) static void update_icons(void) { // printf(" update_icons\n "); + #if HUNTING_CAMERA_MCU == ENABLE + if(sf_get_power_off_flag() || sf_is_usb_flag()) + { + return; + } + #endif update_selftimer(); update_size(); update_quality();