Try a breakpoint in the while loop after a few thousand iterations to see if you are actually incrementing some kind of time counter. If whatever updates uwTick isn't working you have an infinite loop. Also, bear in mind you are doing unsigned math without any check on overflows for th...
Regarding the hardfault, this could be caused by calling function like SCB_CleanDCache (or similar), while the D-cache is not initialized/enabled. After reset there are undefined data in cache and ECC error can be generated. One solution can be to call SCB_InvalidateDCache which marks all ...
Data_init.Beep = 100; TIM_Cmd(TIM4, ENABLE); // 使能计数器while (1) { // 线程 timer_loop(); // 定时器执行 #if KEY_OPEN // 按键监测 if (time25ms == MY_TRUE) { Check_Key_ON_OFF(); time25ms = MY_FALSE; } #endif } } 代码主要实现部分 // 更新设备状态 mySta Update_dev...
During my investigations, I figure out that even on "not working" boards (nucleo_l476rg mainly used to debug), it is possible to make it work: RTT is working when a debugger is attached, and I break CPU. It means that RTTviewer did not get live update of messages while cpu is runn...
if (offset >= p_fifo->used_num) { return (-1); } // Move Read Pointer to right position _pre_red_index = p_fifo->p_read_addr + p_fifo->unit_size * offset; while (_pre_red_index > p_fifo->p_end_addr) { _pre_red_index = _pre_red_index - p_fifo->p_end_addr + ...
(Run) Supply current in Run mode Reduced 81 Fibonacci 1.1 66 While(1) loop 1.0 59 1.3 78 1.4 88 1.4 88 Fibonacci 1.0 63 While(1) loop 1.0 60 345 173 400 200 400 200 Fibonacci 365 183 While(1) loop 415 Reduced Coremark Reduced SRAM code(3) Dhrystone 2.1 (2) Flash memory code(3...
;if(f_res == FR_OK){f_res = f_read(&SDFile,ReadBuffer,sizeof(ReadBuffer),&fnum);}HAL_Delay(100);f_res = f_close(&SDFile);HAL_Delay(100); /* USER CODE END 2 */ /* Infinite loop */ /* USER CODE BEGIN WHILE */ while (1) { /* USER CODE END WHILE */ ...
(ART Accelerator) allowing 0-wait-state execution from Flash memory, frequency up to 170 MHz with 213 DMIPS, MPU, DSP instructions • Operating conditions: – VDD, VDDA voltage range: 1.71 V to 3.6 V • Memories – 512 Kbytes of Flash memory with ECC support, two banks read-while-...
while (!Serial && millis() < 5000); Serial.print("\nStart AsyncHTTPRequest_STM32 on "); Serial.println(BOARD_NAME); Serial.println(ASYNC_HTTP_REQUEST_GENERIC_VERSION); #if defined(ASYNC_HTTP_REQUEST_GENERIC_VERSION_MIN) if (ASYNC_HTTP_REQUEST_GENERIC_VERSION_INT < ASYNC_HTTP_REQUE...
Each project template provides empty main loop function and can be used as a starting point to get familiar with project settings for STM32Cube. Their characteristics are the following: It contains sources of HAL, CMSIS and BSP drivers which are the minimal components to develop a code ...