Compare commits

...

9 Commits

13 changed files with 313 additions and 103 deletions

View File

@ -1,11 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>STS_O7</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
</buildSpec>
<natures>
</natures>
</projectDescription>

View File

@ -245,9 +245,9 @@
#define STS_IOC_MODE_4_MASK STS_IOC_IN_0|STS_IOC_IN_1|STS_IOC_IN_2|STS_IOC_OUT_0|STS_IOC_OUT_1 //DUAL MODE
#define STS_IOC_MODE_5_MASK STS_IOC_IN_ALL|STS_IOC_OUT_ALL //UNI_MODE
#define MajorVer 24U
#define MinorVer 8U
#define SubMinorVer 15U
#define MajorVer 25U
#define MinorVer 3U
#define SubMinorVer 25U
#define FirmwareVersion 3U
#define YUNHORN_STS_MAX_NVM_CFG_SIZE 64U

View File

@ -64,12 +64,12 @@ enum p_cmd_order{
};
enum RSS_CFG_order{
// FOR SIMPLE CONFIG .... 8 BYTES
// FOR SIMPLE CONFIG .... 4 BYTES
RSS_CFG_START_M=0,
RSS_CFG_LENGTH_M,
RSS_CFG_THRESHOLD,
RSS_CFG_RECEIVER_GAIN,
// FOR SIMPLE CONFIG .... 8 BYTES
// FOR SIMPLE CONFIG .... 4 BYTES
RSS_CFG_PROFILE,
RSS_CFG_RATE_TRACKING,
RSS_CFG_RATE_PRESENCE,
@ -89,7 +89,12 @@ enum RSS_CFG_order{
#endif
#if defined(STS_O7)||defined(STS_O6)
#define STS_RSS_CONFIG_NON 0x00
#define STS_RSS_CONFIG_DEFAULT 0x01
#define STS_RSS_CONFIG_SIMPLE 0x02
#define STS_RSS_CONFIG_FULL 0x04
#define STS_RSS_CONFIG_FALL_DETECTION 0x08
#if 0
enum sts_rss_config_update_t {
STS_RSS_CONFIG_NON=0,
STS_RSS_CONFIG_DEFAULT,
@ -97,7 +102,7 @@ enum sts_rss_config_update_t {
STS_RSS_CONFIG_FULL,
STS_RSS_CONFIG_FALL_DETECTION
};
#endif
enum sts_ctrl_cmd_type {
STS_CTRL_CMD_TYPE_DUTYCYCLE_LEVEL_CHANGE,
STS_CTRL_CMD_MEMS_TUNE_TOF_VL53L0X=0x00,
@ -759,7 +764,7 @@ void STS_PRESENCE_SENSOR_Function_Test_Process(uint8_t *self_test_result, uint8_
void STS_PRESENCE_SENSOR_Distance_Measure_Process(void);
float KalmanFilter(float inData);
uint8_t STS_RSS_Filter(uint8_t pre_sts_rss_result);
/* USER CODE BEGIN Private defines */
/*
In this example TIM2 input clock (TIM2CLK) is set to APB1 clock (PCLK1),

View File

@ -23,6 +23,7 @@
#include "app_lorawan.h"
#include "gpio.h"
#include "usart.h"
#include "stdio.h"
/* Private includes ----------------------------------------------------------*/
/* USER CODE BEGIN Includes */
#include "spi.h"
@ -91,7 +92,6 @@ int main(void)
MX_TIM1_Init();
MX_SPI1_Init();
/* USER CODE END SysInit */
/* Initialize all configured peripherals */
MX_LoRaWAN_Init();

View File

@ -147,7 +147,7 @@ int sts_distance_rss_detector_distance(void)
if (deactivated && success)
{
APP_LOG(TS_OFF, VLEVEL_L, "Application finished OK\n");
APP_LOG(TS_OFF, VLEVEL_H, "Application finished OK\n");
return EXIT_SUCCESS;
}

View File

@ -58,7 +58,7 @@
#define DEFAULT_SENSOR_ID (1)
#define DEFAULT_START_M (0.8f) //(0.80f) //default 0.2 unit(meter) [1]
#define DEFAULT_LENGTH_M (3.5f) // (2.0f)) //default 1.0 unit(meter) [2]
#define DEFAULT_LENGTH_M (2.2f) // (2.0f)) //default 1.0 unit(meter) [2]
#define DEFAULT_ZONE_LENGTH (0.4f) //default 0.4 unit(meter)
#define DEFAULT_UPDATE_RATE_WAKEUP (2.0f) //default 80 unit(hz)
#define DEFAULT_UPDATE_RATE_TRACKING (10.0f) //default 80 unit(hz) [7]
@ -67,7 +67,7 @@
//#define DEFAULT_UPDATE_RATE_PRESENCE (80.0F) //(65.0f) //default 80 unit(hz)
#define DEFAULT_HWAAS (63) //default 10 unit(hz)
#define DEFAULT_THRESHOLD (1.5f) //default 1.5 level float [3]
#define DEFAULT_THRESHOLD (1.2f) //default 1.5 level float [3]
//acc_detector_presence_configuration_filter_parameters_t
#define DEFAULT_INTER_FRAME_DEVIATION_TIME_CONST (0.5f) //default 0.5 unit(seconds) [6]
@ -83,7 +83,7 @@
#define DEFAULT_DOWNSAMPLING_FACTOR (2) //default 1
//#define DEFAULT_RECEIVER_GAIN (0.65f) //default 0.9 gain mdB [4]
#define DEFAULT_RECEIVER_GAIN (0.40f) //default 0.9 gain mdB [4]
#define DEFAULT_RECEIVER_GAIN (0.65f) //default 0.9 gain mdB [4]
#define DEFAULT_MOTION_DATASET_LEN (128) //MOTION DATASET/PATTERN COLLECTION
#define DEFAULT_MOTION_FEATURE_LEN (10) //MOTION FEATURE IDENDIFIED
@ -262,6 +262,7 @@ static void set_default_fall_rise_configuration(acc_detector_presence_configurat
// if detection toggles too often, increase the following, if too sluggish, decrease it instead
filter.output_time_const = DEFAULT_OUTPUT_TIME_CONST; //0.0f;
acc_detector_presence_configuration_filter_parameters_set(presence_configuration, &filter);
acc_detector_presence_configuration_nbr_removed_pc_set(presence_configuration, DEFAULT_NBR_REMOVED_PC);
acc_detector_presence_configuration_power_save_mode_set(presence_configuration, ACC_POWER_SAVE_MODE_ACTIVE);
}
@ -272,8 +273,9 @@ static void sts_rss_set_current_configuration_full(acc_detector_presence_configu
acc_detector_presence_configuration_sensor_set(presence_configuration, DEFAULT_SENSOR_ID);
// acc_service_profile_t presence_profile = sts_presence_rss_config.default_profile;
// acc_detector_presence_configuration_service_profile_set(presence_configuration, presence_profile);
// acc_detector_presence_configuration_service_profile_set(presence_configuration, presence_profile); 2024-08-21 update
acc_detector_presence_configuration_service_profile_set(presence_configuration, sts_presence_rss_config.default_profile);
acc_detector_presence_configuration_update_rate_set(presence_configuration, sts_presence_rss_config.default_update_rate_presence); //DEFAULT_UPDATE_RATE_2);
acc_detector_presence_configuration_detection_threshold_set(presence_configuration, sts_presence_rss_config.default_threshold);//DEFAULT_DETECTION_THRESHOLD_2);
@ -300,17 +302,54 @@ static void sts_rss_set_current_configuration_full(acc_detector_presence_configu
static void sts_rss_set_current_configuration_simple(acc_detector_presence_configuration_t presence_configuration)
{
acc_detector_presence_configuration_sensor_set(presence_configuration, DEFAULT_SENSOR_ID);
acc_detector_presence_configuration_update_rate_set(presence_configuration, DEFAULT_UPDATE_RATE_PRESENCE);
APP_LOG(TS_OFF, VLEVEL_M, "\r\nsts_rss_cfg-start: %4d ,length: %4d ,threshold: %4d ,gain: %2d ,rate: %2d ,profile: %1d \r\n",
(int)(sts_presence_rss_config.default_start_m*1000),
(int)(sts_presence_rss_config.default_length_m*1000),
(int)(sts_presence_rss_config.default_threshold*1000),
(int)(sts_presence_rss_config.default_receiver_gain*100),
(int)(sts_presence_rss_config.default_update_rate_presence),
(int)(sts_presence_rss_config.default_profile));
acc_detector_presence_configuration_sensor_set(presence_configuration, DEFAULT_SENSOR_ID);
//acc_detector_presence_configuration_update_rate_set(presence_configuration, DEFAULT_UPDATE_RATE_PRESENCE); 2024-08-21 update
acc_detector_presence_configuration_update_rate_set(presence_configuration, sts_presence_rss_config.default_update_rate_presence);
acc_detector_presence_configuration_start_set(presence_configuration, sts_presence_rss_config.default_start_m);
acc_detector_presence_configuration_length_set(presence_configuration, sts_presence_rss_config.default_length_m); //DEFAULT_LENGTH_M_2);
acc_detector_presence_configuration_detection_threshold_set(presence_configuration, sts_presence_rss_config.default_threshold);//DEFAULT_DETECTION_THRESHOLD_2);
acc_detector_presence_configuration_receiver_gain_set(presence_configuration, sts_presence_rss_config.default_receiver_gain);
acc_detector_presence_configuration_service_profile_set(presence_configuration, sts_presence_rss_config.default_profile);
}
static void print_current_configuration(acc_detector_presence_configuration_t presence_configuration)
{
float sts_run_start = acc_detector_presence_configuration_start_get(presence_configuration);
float sts_run_length = acc_detector_presence_configuration_length_get(presence_configuration);
float sts_run_threshold = acc_detector_presence_configuration_detection_threshold_get(presence_configuration);
float sts_run_gain = acc_detector_presence_configuration_receiver_gain_get(presence_configuration);
float sts_run_update_rate = acc_detector_presence_configuration_update_rate_get(presence_configuration);
float sts_run_profile = acc_detector_presence_configuration_service_profile_get(presence_configuration);
acc_detector_presence_configuration_filter_parameters_t sts_run_filter = acc_detector_presence_configuration_filter_parameters_get(presence_configuration);
float sts_run_f_inter_fast_cutoff = sts_run_filter.inter_frame_fast_cutoff;
float sts_run_f_inter_slow_cutoff = sts_run_filter.inter_frame_slow_cutoff;
float sts_run_f_inter_frame_dev_time_const = sts_run_filter.inter_frame_deviation_time_const;
float sts_run_f_intra_frame_time_const = sts_run_filter.intra_frame_time_const;
float sts_run_f_intra_frame_weight = sts_run_filter.intra_frame_weight;
float sts_run_f_output_time_const = sts_run_filter.output_time_const;
APP_LOG(TS_OFF, VLEVEL_M, "\r\nStart: %4d (mm) Length: %4d (mm) Threshold: %4d (*) Gain= %2d (%) UpdateRate=%2d Profile= %1d \r\n",
(int)(1000.0*sts_run_start), (int)(1000.0*sts_run_length), (int)(1000.0*sts_run_threshold), (int)(100.0*sts_run_gain),(int)sts_run_update_rate, (int)sts_run_profile);
APP_LOG(TS_OFF, VLEVEL_H, "\rn\n(1)FastCut:%4u (2)SlowCut:%4u (3)InterFrameDevTime:%4u "
"(4)IntraFrameTimeConst:%4d (5)IntraWeight:%4u (5)OutputTime:%4u \r\n",
(int)(1000.0*sts_run_f_inter_fast_cutoff), (int)(1000*sts_run_f_inter_slow_cutoff), (int)(1000*sts_run_f_inter_frame_dev_time_const),
(int)(1000*sts_run_f_intra_frame_time_const),(int)(1000*sts_run_f_intra_frame_weight),(int)(1000*sts_run_f_output_time_const));
}
static void print_result(acc_detector_presence_result_t result)
{
if (result.presence_detected)
@ -318,13 +357,13 @@ static void print_result(acc_detector_presence_result_t result)
//uint32_t detected_zone = (uint32_t)((float)(result.presence_distance - DEFAULT_START_M) / (float)DEFAULT_ZONE_LENGTH);
// 2024-08-05
uint32_t detected_zone = (uint32_t)((float)(result.presence_distance) / (float)DEFAULT_ZONE_LENGTH);
APP_LOG(TS_OFF, VLEVEL_H,"Motion in zone: %u, distance: %d, score: %d\n", (unsigned int)detected_zone,
APP_LOG(TS_OFF, VLEVEL_M,"Motion in zone: %u, distance: %d, score: %d\n", (unsigned int)detected_zone,
(int)(result.presence_distance * 1000.0f),
(int)(result.presence_score * 1000.0f));
}
else
{
APP_LOG(TS_OFF, VLEVEL_H,"No motion, score: %u\n", (int)(result.presence_score * 1000.0f));
APP_LOG(TS_OFF, VLEVEL_M,"No motion, score: %u\n", (int)(result.presence_score * 1000.0f));
}
}
@ -356,24 +395,51 @@ int sts_presence_rss_fall_rise_detection(void)
switch (sts_rss_config_updated_flag)
{
case STS_RSS_CONFIG_NON:
APP_LOG(TS_OFF, VLEVEL_M,"\r\n##### YUNHORN STS *** Non *** cfg \n");
APP_LOG(TS_OFF, VLEVEL_H,"\r\n##### YUNHORN STS *** Non *** cfg \n");
return EXIT_SUCCESS;
break;
case STS_RSS_CONFIG_DEFAULT:
set_default_configuration(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_M,"\r\n##### YUNHORN STS *** Default *** cfg applied\n");
APP_LOG(TS_OFF, VLEVEL_H,"\r\n##### YUNHORN STS *** Default *** cfg applied\n");
break;
case STS_RSS_CONFIG_SIMPLE:
sts_rss_set_current_configuration_simple(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_M,"\r\n##### YUNHORN STS *** Simple *** cfg applied\n");
APP_LOG(TS_OFF, VLEVEL_H,"\r\n##### YUNHORN STS *** Simple *** cfg applied\n");
break;
case STS_RSS_CONFIG_FULL:
sts_rss_set_current_configuration_full(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_M,"\r\n######### YUNHORN STS *** FULL *** cfg applied\n");
APP_LOG(TS_OFF, VLEVEL_H,"\r\n######### YUNHORN STS *** FULL *** cfg applied\n");
break;
case STS_RSS_CONFIG_FALL_DETECTION:
set_default_fall_rise_configuration(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_M,"\r\n######### YUNHORN STS *** FALL DETECTION *** cfg applied\n");
APP_LOG(TS_OFF, VLEVEL_H,"\r\n######### YUNHORN STS *** FALL DETECTION *** cfg applied\n");
break;
#if 1
case STS_RSS_CONFIG_DEFAULT|STS_RSS_CONFIG_SIMPLE:
set_default_configuration(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_H,"\r\n##### YUNHORN STS *** Default *** cfg applied\n");
sts_rss_set_current_configuration_simple(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_H,"\r\n##### YUNHORN STS *** Simple *** cfg applied\n");
break;
#endif
case STS_RSS_CONFIG_DEFAULT|STS_RSS_CONFIG_FULL:
set_default_configuration(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_H,"\r\n##### YUNHORN STS *** Default *** cfg applied\n");
sts_rss_set_current_configuration_full(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_H,"\r\n######### YUNHORN STS *** FULL *** cfg applied\n");
break;
case STS_RSS_CONFIG_FULL|STS_RSS_CONFIG_FALL_DETECTION:
set_default_fall_rise_configuration(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_H,"\r\n######### YUNHORN STS *** FALL DETECTION *** cfg applied\n");
sts_rss_set_current_configuration_full(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_H,"\r\n######### YUNHORN STS *** FULL *** cfg applied\n");
break;
case STS_RSS_CONFIG_SIMPLE|STS_RSS_CONFIG_FALL_DETECTION:
set_default_fall_rise_configuration(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_H,"\r\n##### YUNHORN STS *** Default *** cfg applied\n");
sts_rss_set_current_configuration_simple(presence_configuration);
APP_LOG(TS_OFF, VLEVEL_H,"\r\n##### YUNHORN STS *** Simple *** cfg applied\n");
break;
default:
break;
@ -389,6 +455,12 @@ int sts_presence_rss_fall_rise_detection(void)
acc_rss_deactivate();
return EXIT_FAILURE;
}
print_current_configuration(presence_configuration);
acc_detector_presence_configuration_destroy(&presence_configuration);
// BEFORE MERGE FIRST AND SECOND HALF FALL RISE DETECTION
if (!acc_detector_presence_activate(handle))
@ -448,9 +520,10 @@ int sts_presence_rss_fall_rise_detection(void)
//if (detected_hs_zone == 0)
//APP_LOG(TS_OFF, VLEVEL_L, "\r\nPresence_Distance=%u \r\n", (int)result.presence_distance*1000.0);
//APP_LOG(TS_OFF, VLEVEL_L, "\r\nHS_ZONE=%u", (int)detected_hs_zone);
detected_hs_zone = 10 - detected_zone;
motion_in_hs_zone[detected_hs_zone][(motion_detected_count)]++;
//detected_hs_zone = 12 - detected_zone;
detected_hs_zone = (sts_sensor_install_height/1000)/(DEFAULT_ZONE_LENGTH) - detected_zone;
//motion_in_hs_zone[detected_hs_zone][(motion_detected_count)]++;
motion_in_hs_zone[detected_hs_zone][motion_detected_count]++;
sts_motion_dataset[motion_count].presence_distance = 1000*result.presence_distance;
sts_motion_dataset[motion_count].presence_score = 1000*result.presence_score;
@ -460,15 +533,16 @@ int sts_presence_rss_fall_rise_detection(void)
}
}
acc_integration_sleep_ms(1000 / DEFAULT_UPDATE_RATE_PRESENCE); // 15ms, DEFAULT_UPDATE_RATE);
//acc_integration_sleep_ms(1);
//acc_integration_sleep_ms(1000 / DEFAULT_UPDATE_RATE_PRESENCE); // 15ms, DEFAULT_UPDATE_RATE);
//acc_integration_sleep_ms(10); // --- around 1500 ms in total
acc_integration_sleep_ms(5); //--- around 1000ms in total
}
deactivated = acc_detector_presence_deactivate(handle);
acc_detector_presence_destroy(&handle);
acc_rss_deactivate();
APP_LOG(TS_OFF, VLEVEL_H, "\r\n First Half --- Motion Count = %u \r\n", motion_count);
APP_LOG(TS_OFF, VLEVEL_M, "\r\n First Half --- Motion Count = %u \r\n", motion_count);
//acc_detector_presence_deactivate(handle);
}
@ -515,7 +589,7 @@ int sts_presence_rss_fall_rise_detection(void)
if (!result.data_saturated)
{
//APP_LOG(TS_OFF, VLEVEL_H,"\n%u ", i);
//APP_LOG(TS_OFF, VLEVEL_L,"\n%u ", i);
//print_result(result);
if ((result.presence_detected) && (result.presence_score > DEFAULT_THRESHOLD))
{
@ -535,7 +609,8 @@ int sts_presence_rss_fall_rise_detection(void)
//APP_LOG(TS_OFF, VLEVEL_L, "\r\nHS_ZONE=%u", detected_hs_zone);
//(sts_sensor_install_height/1000)/(DEFAULT_ZONE_LENGTH)
detected_hs_zone = (sts_sensor_install_height/1000)/(DEFAULT_ZONE_LENGTH) - detected_zone;
motion_in_hs_zone[detected_hs_zone][(motion_detected_count)]++;
//motion_in_hs_zone[detected_hs_zone][(motion_detected_count)]++;
motion_in_hs_zone[detected_hs_zone][motion_detected_count]++;
sts_motion_dataset[motion_count].presence_distance = 1000*result.presence_distance;
sts_motion_dataset[motion_count].presence_score = 1000*result.presence_score;
@ -547,8 +622,8 @@ int sts_presence_rss_fall_rise_detection(void)
}
// ~12 ms per RSS scan
// acc_integration_sleep_ms(1000 / DEFAULT_UPDATE_RATE_PRESENCE); // 15 ms, DEFAULT_UPDATE_RATE);
//acc_integration_sleep_ms(10); --- around 1500 ms in total
acc_integration_sleep_ms(2); //--- around 1000ms in total
//acc_integration_sleep_ms(10); //--- around 1500 ms in total
acc_integration_sleep_ms(5); //--- around 1000ms in total
}
deactivated = acc_detector_presence_deactivate(handle);
acc_detector_presence_destroy(&handle);
@ -576,11 +651,17 @@ int sts_presence_rss_fall_rise_detection(void)
sts_presence_rss_distance = average_distance;
sts_presence_rss_score = average_score;
// uint8_t pre_sts_rss_result = (average_result > (DEFAULT_UPDATE_RATE_PRESENCE/5))? 1: 0;
// sts_rss_result=STS_RSS_Filter(pre_sts_rss_result);
sts_rss_result = (average_result > (DEFAULT_UPDATE_RATE_PRESENCE/5))? 1: 0;
//if (average_result) //if (average_score !=0) //if (sts_rss_result)
if (sts_rss_result) //if (average_score !=0) //if (sts_rss_result)
{
APP_LOG(TS_OFF, VLEVEL_L,"\r\n######## Motion: %u Distance=%u mm, Score=%u Average_result=%u out of %u \r\n",
APP_LOG(TS_OFF, VLEVEL_M,"\r\n######## MotionLevel=%4u (level) Gain=%2u (%) Start=%4u (mm) Length=%4u (mm)\r\n",
(int)(1000.0f*sts_presence_rss_config.default_threshold),(int)(100.0f*sts_presence_rss_config.default_receiver_gain),
(int)(1000.0f*sts_presence_rss_config.default_start_m), (int)(1000.0f*sts_presence_rss_config.default_length_m));
APP_LOG(TS_OFF, VLEVEL_M,"\r\n######## Motion: %u Distance=%u mm, Score=%u Average_result=%u out of %u \r\n",
(uint8_t)sts_rss_result,(int) sts_presence_rss_distance, (int)(sts_presence_rss_score), (int)average_result, (int)iterations);
}
@ -601,7 +682,7 @@ int sts_presence_rss_fall_rise_detection(void)
* Fall Detection settings
*/
if (sts_fall_rising_detected_result)
if (sts_fall_rising_detected_result != STS_PRESENCE_NORMAL)
{
LED1_ON;
OnSensorRSS3BStateChanged();
@ -612,19 +693,23 @@ int sts_presence_rss_fall_rise_detection(void)
}
// RSS feature 3: No motion, or stay still , or unconscious process
uint8_t thiscnt= motion_detected_count;
if (motion_detected_count++ == 10) {
// APP_LOG(TS_OFF, VLEVEL_M,"\r\n|Motion Detected Count =%u \r\n", motion_detected_count);
uint8_t thiscnt= motion_detected_count++;
// APP_LOG(TS_OFF, VLEVEL_M,"\r\n|Motion Detected Count =%u and thiscnt=%u \r\n", motion_detected_count, thiscnt);
if (motion_detected_count == 10) {
//for (uint8_t j=0; j<12; j++) motion_in_hs_zone[j][thiscnt]=0;
motion_detected_count=0;
} else {
OnSensorRSS3CStateChanged();
}
//#ifdef LOG_RSS
OnSensorRSS3CStateChanged();
#ifdef LOG_RSS
if (sts_work_mode == STS_UNI_MODE)
{
APP_LOG(TS_OFF, VLEVEL_M,"\r\nSensor at Ceiling Height: %u cm\r\n",(uint16_t)sts_sensor_install_height/10);
APP_LOG(TS_OFF, VLEVEL_M,"\r\n|Motion Distance Zone| ##### |Height cm|\r\n");
uint8_t kk = (uint8_t)((uint16_t)(sts_sensor_install_height/1000)/(DEFAULT_ZONE_LENGTH));
uint8_t kk = (uint8_t)(((int)sts_sensor_install_height/1000)/(DEFAULT_ZONE_LENGTH));
APP_LOG(TS_OFF, VLEVEL_M,"\r\n|-----------Ceiling-------Sensor---V-----|\r\n");
for (uint8_t k=0; k <=kk; k++)
{
@ -638,12 +723,12 @@ int sts_presence_rss_fall_rise_detection(void)
}
APP_LOG(TS_OFF, VLEVEL_M,"\r\n|-----------Floor Ground-----------^-----|\r\n");
}
//#endif
#endif
if (deactivated && success)
{
//APP_LOG(TS_OFF, VLEVEL_M,"Application finished OK\n");
APP_LOG(TS_OFF, VLEVEL_H,"Application finished OK\n");
return EXIT_SUCCESS;
}

View File

@ -275,37 +275,40 @@ void STS_YunhornSTSEventP2_Process(void)
{
switch (sts_work_mode) {
case STS_RSS_MODE:
sts_rss_config_updated_flag = STS_RSS_CONFIG_DEFAULT;
sts_rss_config_updated_flag |= STS_RSS_CONFIG_DEFAULT;
break;
case STS_DUAL_MODE:
sts_rss_config_updated_flag = STS_RSS_CONFIG_DEFAULT;
sts_rss_config_updated_flag |= STS_RSS_CONFIG_DEFAULT;
break;
case STS_UNI_MODE:
sts_rss_config_updated_flag = STS_RSS_CONFIG_FALL_DETECTION;
sts_rss_config_updated_flag |= STS_RSS_CONFIG_FALL_DETECTION;
break;
default:
break;
}
sts_presence_rss_fall_rise_detection();
int res = sts_presence_rss_fall_rise_detection();
if (res == 0)
{
sts_rss_result_changed_flag = (sts_rss_result == last_sts_rss_result)? 0:1;
sts_rss_result_changed_flag = (sts_rss_result == last_sts_rss_result)? 0:1;
last_sts_rss_result = sts_rss_result;
last_sts_rss_result = sts_rss_result;
//sts_fall_rising_detected_result_changed_flag = (sts_fall_rising_detected_result == last_sts_fall_rising_detected_result)?0:1;
//sts_fall_rising_detected_result_changed_flag = (sts_fall_rising_detected_result != last_sts_fall_rising_detected_result)?1:0;
//sts_fall_rising_detected_result_changed_flag = (sts_fall_rising_detected_result == last_sts_fall_rising_detected_result)?0:1;
//sts_fall_rising_detected_result_changed_flag = (sts_fall_rising_detected_result != last_sts_fall_rising_detected_result)?1:0;
last_sts_fall_rising_detected_result = sts_fall_rising_detected_result;
last_sts_fall_rising_detected_result = sts_fall_rising_detected_result;
if (sts_service_mask > 0 ) {
sts_rss_result_changed_flag =0;
sts_reed_hall_changed_flag = 0;
sts_fall_rising_detected_result_changed_flag =0;
}
if (sts_service_mask > 0 ) {
sts_rss_result_changed_flag =0;
sts_reed_hall_changed_flag = 0;
sts_fall_rising_detected_result_changed_flag =0;
}
STS_Combined_Status_Processing();
STS_Combined_Status_Processing();
} else APP_LOG(TS_OFF, VLEVEL_H, "\r\n RSS detection error =%d \r\n", res);
}
}
@ -711,7 +714,7 @@ void STS_PRESENCE_SENSOR_NVM_CFG(void)
sts_presence_rss_config.default_downsampling_factor = (float)(sts_cfg_nvm.p[RSS_CFG_DOWNSAMPLING_FACTOR]);
sts_presence_rss_config.default_power_save_mode = (float)(sts_cfg_nvm.p[RSS_CFG_POWER_MODE]);
sts_rss_config_updated_flag = STS_RSS_CONFIG_FULL; //set to 2 for FULL config effect in next detection
sts_rss_config_updated_flag = (sts_rss_config_updated_flag|STS_RSS_CONFIG_FULL); //set to 2 for FULL config effect in next detection
}
void STS_PRESENCE_SENSOR_NVM_CFG_SIMPLE(void)
@ -721,7 +724,15 @@ void STS_PRESENCE_SENSOR_NVM_CFG_SIMPLE(void)
sts_presence_rss_config.default_threshold = (float)(sts_cfg_nvm.p[RSS_CFG_THRESHOLD]*0.1f);
sts_presence_rss_config.default_receiver_gain = (float)(sts_cfg_nvm.p[RSS_CFG_RECEIVER_GAIN]*0.01f);
sts_rss_config_updated_flag = STS_RSS_CONFIG_SIMPLE; //set to 1 for simple config effect in next detection
sts_presence_rss_config.default_zone_length_m = DEFAULT_ZONE_LENGTH;
sts_presence_rss_config.default_profile = (float)(sts_cfg_nvm.p[RSS_CFG_PROFILE]);
sts_presence_rss_config.default_update_rate_tracking = (float)(sts_cfg_nvm.p[RSS_CFG_RATE_TRACKING]);
sts_presence_rss_config.default_update_rate_presence = (float)(sts_cfg_nvm.p[RSS_CFG_RATE_PRESENCE]);
sts_presence_rss_config.default_hwaas = (float)(sts_cfg_nvm.p[RSS_CFG_HWAAS]);
sts_presence_rss_config.default_nbr_removed_pc = (float)(sts_cfg_nvm.p[RSS_CFG_NBR_REMOVED_PC]);
sts_rss_config_updated_flag = (sts_rss_config_updated_flag|STS_RSS_CONFIG_SIMPLE); //set to 1 for simple config effect in next detection
}
void STS_PRESENCE_SENSOR_Init_Send_Data(void)
@ -802,10 +813,10 @@ void STS_PRESENCE_SENSOR_Prepare_Send_Data(STS_OO_SensorStatusDataTypeDef *senso
// uint8_t sts_unconscious_state;
// uint16_t sts_unconscious_threshold, sts_unconscious_threshold_duration;
}
//else {
// sensor_data->rss_presence_distance = 0x0;
// sensor_data->rss_presence_score = 0x0;
// }
else {
sensor_data->rss_presence_distance = 0x0;
sensor_data->rss_presence_score = 0x0;
}
// no_movement or unconscious duration
sensor_data->unconscious_state = ((sts_fall_rising_detected_result == STS_PRESENCE_UNCONSCIOUS) ||
@ -966,14 +977,14 @@ void STS_PRESENCE_SENSOR_RSS_Init(void)
switch (sts_work_mode)
{
case STS_RSS_MODE:
sts_rss_config_updated_flag = STS_RSS_CONFIG_DEFAULT;
sts_rss_config_updated_flag |= STS_RSS_CONFIG_DEFAULT;
break;
case STS_DUAL_MODE:
sts_rss_config_updated_flag = STS_RSS_CONFIG_DEFAULT;
sts_rss_config_updated_flag |= STS_RSS_CONFIG_DEFAULT;
break;
case STS_UNI_MODE:
sts_rss_config_updated_flag = STS_RSS_CONFIG_FALL_DETECTION;
sts_rss_config_updated_flag |= STS_RSS_CONFIG_FALL_DETECTION;
break;
default:
break;
@ -986,7 +997,7 @@ void STS_PRESENCE_SENSOR_Distance_Measure_Process(void)
{
uint8_t exit_status = EXIT_SUCCESS, i=0;
APP_LOG(TS_OFF, VLEVEL_L, "\r\n ****start_m=%u length_m=%u profile=%u hwaas=%u \r\n",
APP_LOG(TS_OFF, VLEVEL_M, "\r\n ****start_m=%u length_m=%u profile=%u hwaas=%u \r\n",
(unsigned int)(distance_cfg.start_m*1000),(unsigned int)(distance_cfg.length_m*1000),
(unsigned int)(distance_cfg.acc_profile),(unsigned int)(distance_cfg.hwaas));
do
@ -1272,11 +1283,11 @@ void OnSensorRSS3CStateChanged(void)
return ;
}
#endif
if (sts_rss_result == STS_RESULT_MOTION)
if ((sts_rss_result == STS_RESULT_MOTION)&&(last_sts_rss_result == STS_RESULT_NO_MOTION))
{
sts_o7_sensorData.event_sensor3_motion_start_time = sensor_event_time.Seconds;
sts_o7_sensorData.event_sensor3_motion_duration = 0;
} else if (sts_rss_result == STS_RESULT_NO_MOTION)
} else if ((sts_rss_result == STS_RESULT_NO_MOTION)&&(last_sts_rss_result==STS_RESULT_MOTION))
{
sts_o7_sensorData.event_sensor3_motion_stop_time = sensor_event_time.Seconds;
//sts_o7_sensorData.event_sensor3_motion_duration = 0;
@ -1368,6 +1379,114 @@ float KalmanFilter(float inData)
}
#if 0
uint8_t Radar_Data_Analysis(void)
{
uint8_t xReturn = 0;
const char* person = "Motion ";
const char* noperson = "No motion";
if(Radar_Data_Flag == 1)
{
if(strncmp((char *)USART3_RX_Buffer,person,strlen(person)) == 0){
xReturn = 1;
}
else if( strncmp((char *)USART3_RX_Buffer,noperson,strlen(noperson)) == 0){
xReturn = 0;
}
}
return xReturn;
}
void Radar_Filtering_clutter(volatile uint8_t *color)
{
_Bool pNew_Motion_Flag = 0;
static uint8_t Motion_Changed_Flag = 0;
static uint8_t numerator = 0;
static uint8_t denominator = 0;
pNew_Motion_Flag = Radar_Data_Analysis();
if(pNew_Motion_Flag != Motion_Flag){
Motion_Changed_Flag = 1;
}
if(Motion_Changed_Flag == 1)
{
denominator++;
if(pNew_Motion_Flag != Motion_Flag){
numerator++;
}
if(denominator >= Preset_denominator)
{
if(numerator >= Preset_numerator) //的确改变
{
Motion_Flag = !Motion_Flag;
if(Motion_Flag)
{
//M100C_Send_Data(10,0,ZhanYong);
*color = 2;
}
else
{
//M100C_Send_Data(10,0,KeYong);
*color = 1;
}
}
denominator = 0;
numerator = 0;
Motion_Changed_Flag = 0;
}
}
}
#endif
#define PRESET_DENOMINATOR 8
#define PRESET_NUMERATOR 5
uint8_t STS_RSS_Filter(uint8_t pre_sts_rss_result)
{
_Bool pNew_Motion_Flag = 0;
static uint8_t Motion_Changed_Flag = 0;
static uint8_t numerator = 0;
static uint8_t denominator = 0;
uint8_t Motion_Flag = sts_rss_result, xReturn=0;
pNew_Motion_Flag = pre_sts_rss_result;
if(pNew_Motion_Flag != Motion_Flag){
Motion_Changed_Flag = 1;
}
if(Motion_Changed_Flag == 1)
{
denominator++;
if(pNew_Motion_Flag != Motion_Flag){
numerator++;
}
if(denominator >= PRESET_DENOMINATOR)
{
if(numerator >= PRESET_NUMERATOR) //SURE CHANGED
{
Motion_Flag = !Motion_Flag;
if(Motion_Flag)
{
//M100C_Send_Data(10,0,ZhanYong);
xReturn = 1;
}
else
{
//M100C_Send_Data(10,0,KeYong);
xReturn = 0;
}
}
denominator = 0;
numerator = 0;
Motion_Changed_Flag = 0;
}
}
return xReturn;
}
/* USER CODE BEGIN EF */

View File

@ -75,7 +75,7 @@ extern volatile uint32_t event_start_time, event_stop_time;
extern volatile uint16_t sts_unconscious_threshold;
volatile uint8_t sts_occupancy_overtime_state = 0;
volatile uint8_t sts_presence_fall_detection=FALSE;
volatile uint32_t SamplingPeriodicity = 3000; //unit ms
volatile uint32_t SamplingPeriodicity = 1000; //unit ms
volatile uint32_t HeartBeatPeriodicity = 120000; //unit ms
volatile uint8_t STS_LoRa_WAN_Joined = 0;
@ -93,7 +93,7 @@ volatile sts_cfg_nvm_t sts_cfg_nvm = {
sts_hardware_ver,
0x05,
'M', //Uplink data interval for heart-beat uplink
0x03,
0x01,
'S', //Sampling sensor interval for real-time sensing of MEMS
0x04, // dual mode=4, uni_mode =5
0x00, // sts service mask
@ -1110,7 +1110,8 @@ static void SendTxData(void)
}
}
//else { APP_LOG(TS_OFF, VLEVEL_M, "\r\n ######## LmHandlerIsBusy ************** \r\n"); }
heart_beat_timer = 0;
sensor_data_ready = 0;
if ((EventType == TX_ON_TIMER)) //||((EventType == TX_ON_EVENT)&&(nextTxIn >0)))
{
UTIL_TIMER_Stop(&TxTimer);
@ -1430,7 +1431,7 @@ static void OnJoinRequest(LmHandlerJoinParams_t *joinParams)
UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
//UTIL_TIMER_Start(&TxTimer);
//UTIL_TIMER_Start(&STSDurationCheckTimer);
UTIL_TIMER_Start(&STSDurationCheckTimer);
OnYunhornSTSHeartBeatPeriodicityChanged(HeartBeatPeriodicity);
//UTIL_TIMER_Create(&YunhornSTSRSSWakeUpTimer, YUNHORN_STS_RSS_WAKEUP_CHECK_TIME, UTIL_TIMER_PERIODIC, OnYunhornSTSOORSSWakeUpTimerEvent, NULL);
@ -2553,22 +2554,21 @@ void USER_APP_AUTO_RESPONDER_Parse(char *tlv_buf, uint8_t tlv_buf_size)
#if 1
for (j =0; j < CFG_CMD_RSS_SIMPLE_SIZE-3; j++)
{
if ((tlv_buf[CFG_CMD4+j] >='0') && (tlv_buf[CFG_CMD4+j]<='9'))
if ((tlv_buf[CFG_CMD4+j] < '0') || (tlv_buf[CFG_CMD4+j] >'9'))
{
//sts_cfg_nvm.p[j] = (uint8_t)((tlv_buf[CFG_CMD4+j] - 0x30)&0xff);
//APP_LOG(TS_OFF,VLEVEL_H,"\r\n tlv_buf %d = %02x cfg->p[%d]=%02x \r\n",j,tlv_buf[CFG_CMD4+j], j, sts_cfg_nvm.p[j]);
} else {
invalid_flag = 1;
}
}
#endif
sts_cfg_nvm.p[RSS_CFG_START_M] = (uint8_t)((tlv_buf[CFG_CMD4] - 0x30)*10+(tlv_buf[CFG_CMD5] - 0x30));
sts_cfg_nvm.p[RSS_CFG_LENGTH_M] = (uint8_t)((tlv_buf[CFG_CMD6] - 0x30)*10+(tlv_buf[CFG_CMD7] - 0x30));
sts_cfg_nvm.p[RSS_CFG_THRESHOLD] = (uint8_t)((tlv_buf[CFG_CMD8] - 0x30)*10+(tlv_buf[CFG_CMD9] - 0x30));
sts_cfg_nvm.p[RSS_CFG_RECEIVER_GAIN] = (uint8_t)((tlv_buf[CFG_CMD10]- 0x30)*10+(tlv_buf[CFG_CMD11]- 0x30));
if (invalid_flag == 0)
{
sts_cfg_nvm.p[RSS_CFG_START_M] = (uint8_t)((tlv_buf[CFG_CMD4] - 0x30)*10+(tlv_buf[CFG_CMD5] - 0x30));
sts_cfg_nvm.p[RSS_CFG_LENGTH_M] = (uint8_t)((tlv_buf[CFG_CMD6] - 0x30)*10+(tlv_buf[CFG_CMD7] - 0x30));
sts_cfg_nvm.p[RSS_CFG_THRESHOLD] = (uint8_t)((tlv_buf[CFG_CMD8] - 0x30)*10+(tlv_buf[CFG_CMD9] - 0x30));
sts_cfg_nvm.p[RSS_CFG_RECEIVER_GAIN] = (uint8_t)((tlv_buf[CFG_CMD10]- 0x30)*10+(tlv_buf[CFG_CMD11]- 0x30));
APP_LOG(TS_OFF, VLEVEL_H,"\r\nStart,Lenght,threshold,gain=%02x %02x %02x %02x \r\n",
sts_cfg_nvm.p[RSS_CFG_START_M],sts_cfg_nvm.p[RSS_CFG_LENGTH_M],sts_cfg_nvm.p[RSS_CFG_THRESHOLD],sts_cfg_nvm.p[RSS_CFG_RECEIVER_GAIN]);
STS_PRESENCE_SENSOR_NVM_CFG_SIMPLE();
i=0; // Step 1: Prepare status update message

View File

@ -135,7 +135,7 @@
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.target_board.2109882892" name="Board" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.target_board" useByScannerDiscovery="false" value="NUCLEO-WL55JC1" valueType="string"/>
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.defaults.239742593" name="Defaults" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.defaults" useByScannerDiscovery="false" value="com.st.stm32cube.ide.common.services.build.inputs.revA.1.0.5 || Release || false || Executable || com.st.stm32cube.ide.mcu.gnu.managedbuild.option.toolchain.value.workspace || NUCLEO-WL55JC1 || 0 || 0 || arm-none-eabi- || ${gnu_tools_for_stm32_compiler_path} || ../../Core/Inc | ../../LoRaWAN/Target | ../../../../../../../Utilities/misc | ../../../../../../../Middlewares/Third_Party/SubGHz_Phy | ../../../../../../../Utilities/lpm/tiny_lpm | ../../../../../../../Middlewares/Third_Party/SubGHz_Phy/stm32_radio_driver | ../../../../../../../Drivers/CMSIS/Device/ST/STM32WLxx/Include | ../../../../../../../Utilities/sequencer | ../../../../../../../Middlewares/Third_Party/LoRaWAN/LmHandler/Packages | ../../LoRaWAN/App | ../../../../../../../Middlewares/Third_Party/LoRaWAN/Mac/Region | ../../../../../../../Drivers/STM32WLxx_HAL_Driver/Inc | ../../../../../../../Drivers/STM32WLxx_HAL_Driver/Inc/Legacy | ../../../../../../../Utilities/trace/adv_trace | ../../../../../../../Drivers/BSP/STM32WLxx_Nucleo | ../../../../../../../Utilities/timer | ../../../../../../../Middlewares/Third_Party/LoRaWAN/Mac | ../../../../../../../Middlewares/Third_Party/LoRaWAN/Utilities | ../../../../../../../Middlewares/Third_Party/LoRaWAN/Crypto | ../../../../../../../Middlewares/Third_Party/LoRaWAN/LmHandler | ../../../../../../../Drivers/CMSIS/Include || || || USE_HAL_DRIVER | STM32WL55xx | CORE_CM4 || || || || || ${workspace_loc:/${ProjName}/STM32WL55JCIX_FLASH.ld} || true || NonSecure || || secure_nsclib.o || || None || " valueType="string"/>
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.nanoscanffloat.1874218879" name="Use float with scanf from newlib-nano (-u _scanf_float)" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.nanoscanffloat" useByScannerDiscovery="false" value="false" valueType="boolean"/>
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.nanoprintffloat.1776401448" name="Use float with printf from newlib-nano (-u _printf_float)" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.nanoprintffloat" useByScannerDiscovery="false" value="false" valueType="boolean"/>
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.nanoprintffloat.1776401448" name="Use float with printf from newlib-nano (-u _printf_float)" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.nanoprintffloat" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.convertbinary.639397767" name="Convert to binary file (-O binary)" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.convertbinary" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.converthex.2096511505" name="Convert to Intel Hex file (-O ihex)" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.converthex" useByScannerDiscovery="false" value="false" valueType="boolean"/>
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.listfile.769752034" name="Generate list file" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.listfile" useByScannerDiscovery="false" value="false" valueType="boolean"/>
@ -154,7 +154,6 @@
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.optimization.level.1119592399" name="Optimization level" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.optimization.level" useByScannerDiscovery="false" value="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.optimization.level.value.os" valueType="enumerated"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.definedsymbols.2024044405" name="Define symbols (-D)" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.definedsymbols" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="CORE_CM4"/>
<listOptionValue builtIn="false" value="STS_BAT"/>
<listOptionValue builtIn="false" value="CLOCK_SYNC"/>
<listOptionValue builtIn="false" value="RM2_1"/>
<listOptionValue builtIn="false" value="STS_O7"/>
@ -202,7 +201,7 @@
<listOptionValue builtIn="false" value=":libSTM32Cryptographic_CM4.a"/>
</option>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.linker.option.directories.1886557558" name="Library search path (-L)" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.linker.option.directories" useByScannerDiscovery="false" valueType="libPaths">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/rss/lib}&quot;"/>
<listOptionValue builtIn="false" value="../../rss/lib"/>
<listOptionValue builtIn="false" value="../../../../../../../Middlewares/ST/STM32_Cryptographic/lib"/>
</option>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.linker.option.otherflags.612263897" name="Other flags" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.linker.option.otherflags" useByScannerDiscovery="false" valueType="stringList">

View File

@ -1,6 +1,6 @@
################################################################################
# Automatically-generated file. Do not edit!
# Toolchain: GNU Tools for STM32 (12.3.rel1)
# Toolchain: GNU Tools for STM32 (13.3.rel1)
################################################################################
-include ../makefile.init
@ -12,9 +12,12 @@ RM := rm -rf
-include Utilities/subdir.mk
-include Middlewares/SubGHz_Phy/subdir.mk
-include Middlewares/LoRaWAN/subdir.mk
-include Drivers/vl53l1x_uld/subdir.mk
-include Drivers/STM32WLxx_HAL_Driver/subdir.mk
-include Drivers/CMSIS/subdir.mk
-include Drivers/BSP/STM32WLxx_Nucleo/subdir.mk
-include Application/User/TOF/Target/subdir.mk
-include Application/User/TOF/App/subdir.mk
-include Application/User/Startup/subdir.mk
-include Application/User/LoRaWAN/Target/subdir.mk
-include Application/User/LoRaWAN/App/subdir.mk
@ -68,7 +71,7 @@ main-build: STS_O7.elf secondary-outputs
# Tool invocations
STS_O7.elf STS_O7.map: $(OBJS) $(USER_OBJS) D:\ONEDRIVE\STM32WLV13\Projects\NUCLEO-WL55JC\Applications\LoRaWAN\YUNHORN_STS_E5CC_AS923_POC\STM32CubeIDE\STM32WLE5CCUX_FLASH.ld makefile objects.list $(OPTIONAL_TOOL_DEPS)
arm-none-eabi-gcc -o "STS_O7.elf" @"objects.list" $(USER_OBJS) -Wl,--start-group $(LIBS) -Wl,--end-group -mcpu=cortex-m4 -T"D:\ONEDRIVE\STM32WLV13\Projects\NUCLEO-WL55JC\Applications\LoRaWAN\YUNHORN_STS_E5CC_AS923_POC\STM32CubeIDE\STM32WLE5CCUX_FLASH.ld" --specs=nosys.specs -Wl,-Map="STS_O7.map" -Wl,--gc-sections -static -L"D:\ONEDRIVE\STM32WLV13\Projects\NUCLEO-WL55JC\Applications\LoRaWAN\STS_O7\STM32CubeIDE\rss\lib" -L../../../../../../../Middlewares/ST/STM32_Cryptographic/lib -Xlinker -no-enum-size-warning -z noexecstack --specs=nano.specs -mfloat-abi=soft -mthumb -Wl,--start-group -lc -lm -Wl,--end-group
arm-none-eabi-gcc -o "STS_O7.elf" @"objects.list" $(USER_OBJS) -Wl,--start-group $(LIBS) -Wl,--end-group -mcpu=cortex-m4 -T"D:\ONEDRIVE\STM32WLV13\Projects\NUCLEO-WL55JC\Applications\LoRaWAN\YUNHORN_STS_E5CC_AS923_POC\STM32CubeIDE\STM32WLE5CCUX_FLASH.ld" --specs=nosys.specs -Wl,-Map="STS_O7.map" -Wl,--gc-sections -static -L../../rss/lib -L../../../../../../../Middlewares/ST/STM32_Cryptographic/lib -Xlinker -no-enum-size-warning -z noexecstack --specs=nano.specs -mfloat-abi=soft -mthumb -u _printf_float -Wl,--start-group -lc -lm -Wl,--end-group
@echo 'Finished building target: $@'
@echo ' '

View File

@ -10,8 +10,8 @@
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.enable_swv" value="false"/>
<intAttribute key="com.st.stm32cube.ide.mcu.debug.launch.formatVersion" value="2"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.ip_address_local" value="localhost"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.limit_swo_clock.enabled" value="false"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.limit_swo_clock.value" value=""/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.limit_swo_clock.enabled" value="true"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.limit_swo_clock.value" value="2000000"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.loadList" value="{&quot;fItems&quot;:[{&quot;fIsFromMainTab&quot;:true,&quot;fPath&quot;:&quot;Release/STS_O7.elf&quot;,&quot;fProjectName&quot;:&quot;STS_O7&quot;,&quot;fPerformBuild&quot;:true,&quot;fDownload&quot;:true,&quot;fLoadSymbols&quot;:true}]}"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.override_start_address_mode" value="default"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.remoteCommand" value="target remote"/>
@ -20,8 +20,9 @@
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.startuptab.exception.unaligned" value="false"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.startuptab.haltonexception" value="true"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.swd_mode" value="true"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.swv_config_enabled" value="true"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.swv_port" value="61235"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.swv_trace_hclk" value="16000000"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.swv_trace_hclk" value="48000000"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.useRemoteTarget" value="true"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.vector_table" value=""/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.verify_flash_download" value="true"/>
@ -41,6 +42,15 @@
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.watchdog_config" value="none"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlinkenable_rtos" value="false"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlinkrestart_configurations" value="{&quot;fVersion&quot;:1,&quot;fItems&quot;:[{&quot;fDisplayName&quot;:&quot;Reset&quot;,&quot;fIsSuppressible&quot;:false,&quot;fResetAttribute&quot;:&quot;Software system reset&quot;,&quot;fResetStrategies&quot;:[{&quot;fDisplayName&quot;:&quot;Software system reset&quot;,&quot;fLaunchAttribute&quot;:&quot;system_reset&quot;,&quot;fGdbCommands&quot;:[&quot;monitor reset\r\n&quot;],&quot;fCmdOptions&quot;:[&quot;-g&quot;]},{&quot;fDisplayName&quot;:&quot;Hardware reset&quot;,&quot;fLaunchAttribute&quot;:&quot;hardware_reset&quot;,&quot;fGdbCommands&quot;:[&quot;monitor reset hardware\r\n&quot;],&quot;fCmdOptions&quot;:[&quot;-g&quot;]},{&quot;fDisplayName&quot;:&quot;Core reset&quot;,&quot;fLaunchAttribute&quot;:&quot;core_reset&quot;,&quot;fGdbCommands&quot;:[&quot;monitor reset core\r\n&quot;],&quot;fCmdOptions&quot;:[&quot;-g&quot;]},{&quot;fDisplayName&quot;:&quot;None&quot;,&quot;fLaunchAttribute&quot;:&quot;no_reset&quot;,&quot;fGdbCommands&quot;:[],&quot;fCmdOptions&quot;:[&quot;-g&quot;]}],&quot;fGdbCommandGroup&quot;:{&quot;name&quot;:&quot;Additional commands&quot;,&quot;commands&quot;:[]},&quot;fStartApplication&quot;:true}]}"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.datatrace_0" value="Enabled=false:Address=0x0:Access=Read/Write:Size=Word:Function=Data Value"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.datatrace_1" value="Enabled=false:Address=0x0:Access=Read/Write:Size=Word:Function=Data Value"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.datatrace_2" value="Enabled=false:Address=0x0:Access=Read/Write:Size=Word:Function=Data Value"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.datatrace_3" value="Enabled=false:Address=0x0:Access=Read/Write:Size=Word:Function=Data Value"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.itmports" value="1:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.itmports_priv" value="0:0:0:0"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.pc_sample" value="0:16384"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.timestamps" value="1:1"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.swv.trace_events" value="Cpi=0:Exc=0:Sleep=0:Lsu=0:Fold=0:Exetrc=0"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.rtosproxy.enableRtosProxy" value="false"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.rtosproxy.rtosProxyCustomProperties" value=""/>
<stringAttribute key="com.st.stm32cube.ide.mcu.rtosproxy.rtosProxyDriver" value="threadx"/>