File tree Expand file tree Collapse file tree 3 files changed +13
-8
lines changed Expand file tree Collapse file tree 3 files changed +13
-8
lines changed Original file line number Diff line number Diff line change 2222/* Private includes ----------------------------------------------------------*/
2323/* USER CODE BEGIN Includes */
2424#include "os.h"
25+ #include "SEGGER_SYSVIEW.h"
2526
2627/* USER CODE END Includes */
2728
@@ -115,6 +116,9 @@ int main(void)
115116 OSInit (& err );
116117 checkError (& err );
117118
119+ SEGGER_SYSVIEW_Conf ();
120+ SEGGER_SYSVIEW_Start ();
121+
118122
119123 /* Create task starter broadcaster semaphore */
120124 OSSemCreate (& StartSem , "Start Semaphore" , 1 , & err );
Original file line number Diff line number Diff line change 3131#define OS_CFG_APP_HOOKS_EN 1u /* Enable (1) or Disable (0) application specific hooks */
3232#define OS_CFG_ARG_CHK_EN 1u /* Enable (1) or Disable (0) argument checking */
3333#define OS_CFG_CALLED_FROM_ISR_CHK_EN 1u /* Enable (1) or Disable (0) check for called from ISR */
34- #define OS_CFG_DBG_EN 0u /* Enable (1) or Disable (0) debug code/variables */
34+ #define OS_CFG_DBG_EN 1u /* Enable (1) or Disable (0) debug code/variables */
3535#define OS_CFG_TICK_EN 1u /* Enable (1) or Disable (0) the kernel tick */
3636#define OS_CFG_DYN_TICK_EN 0u /* Enable (1) or Disable (0) the Dynamic Tick */
3737#define OS_CFG_INVALID_OS_CALLS_CHK_EN 1u /* Enable (1) or Disable (0) checks for invalid kernel calls */
112112
113113
114114 /* ------------------------- TRACE RECORDER ---------------------------- */
115- #define OS_CFG_TRACE_EN 0u /* Enable (1) or Disable (0) uC/OS-III Trace instrumentation */
116- #define OS_CFG_TRACE_API_ENTER_EN 0u /* Enable (1) or Disable (0) uC/OS-III Trace API enter instrumentation */
117- #define OS_CFG_TRACE_API_EXIT_EN 0u /* Enable (1) or Disable (0) uC/OS-III Trace API exit instrumentation */
115+ #define OS_CFG_TRACE_EN 1u /* Enable (1) or Disable (0) uC/OS-III Trace instrumentation */
116+ #define OS_CFG_TRACE_API_ENTER_EN 1u /* Enable (1) or Disable (0) uC/OS-III Trace API enter instrumentation */
117+ #define OS_CFG_TRACE_API_EXIT_EN 1u /* Enable (1) or Disable (0) uC/OS-III Trace API exit instrumentation */
118118
119119#endif
Original file line number Diff line number Diff line change @@ -54,7 +54,8 @@ Revision: $Rev: 9599 $
5454*/
5555#include "SEGGER_SYSVIEW.h"
5656#include "os.h"
57- #include "bsp_clock.h"
57+ #include "stm32f4xx.h"
58+ //#include "bsp_clock.h"
5859
5960extern const SEGGER_SYSVIEW_OS_API SYSVIEW_X_OS_TraceAPI ;
6061
@@ -70,13 +71,13 @@ extern const SEGGER_SYSVIEW_OS_API SYSVIEW_X_OS_TraceAPI;
7071// The target device name
7172#define SYSVIEW_DEVICE_NAME "Cortex-M Device"
7273
73-
74+ CPU_ERR local_err ;
7475
7576// Frequency of the timestamp. Must match SEGGER_SYSVIEW_GET_TIMESTAMP in SEGGER_SYSVIEW_Conf.h
76- #define SYSVIEW_TIMESTAMP_FREQ (BSP_ClkFreqGet(BSP_CLK_ID_SYSCLK ))
77+ #define SYSVIEW_TIMESTAMP_FREQ (CPU_TS_TmrFreqGet(&local_err ))
7778
7879// System Frequency. SystemcoreClock is used in most CMSIS compatible projects.
79- #define SYSVIEW_CPU_FREQ (BSP_ClkFreqGet(BSP_CLK_ID_SYSCLK) )
80+ #define SYSVIEW_CPU_FREQ (SystemCoreClock )
8081
8182// The lowest RAM address used for IDs (pointers)
8283#define SYSVIEW_RAM_BASE (0x20000000)
You can’t perform that action at this time.
0 commit comments