keil的軟件邏輯分析儀( logic analyzer)使用教程
以keil里自帶的stm32的CPU為例,對PWM波形跟蹤觀測,打開C:KeilARMBoardsKeilMCBSTM32PWM_2目錄下的stm32的Dome,第一步:進(jìn)行仿真配置,如圖:

把開工程中的Abstract.txt文件有對工程的描述,PWM從PB0.8和PB0.9輸出,稍后將它加入軟件邏輯分析儀里。
The PWM project is a simple program for the STM32F103RBT6
using Keil MCBSTM32 Evaluation Board and demonstrating
the use of PWM (Pulse Width Modulation) with Timer TIM4 .
Example functionality:
- Clock Settings:
- TIM4 is running at
The Timer program is available in different targets:
第二、選擇軟件仿真

第三、編譯程序,如果程序沒有錯(cuò)的話,將出現(xiàn)以下線框編譯信息,然后進(jìn)入調(diào)試,點(diǎn)出紅色的“D"按,如下圖所示

第四步、把軟件邏輯分析儀把,并把要觀察的波形信號拉到邏輯分析儀里,如果進(jìn)入調(diào)試狀態(tài)下沒有"sysbols"標(biāo)簽話,點(diǎn)擊“View”菜單彈出來,從“Peripheral Register”里把要觀察的(GPIOB_IDR輸出的PWM信號會從這個(gè)寄存器反映出來)信號拖到邏輯析分析里,

第五步、把不用的bit屏蔽掉,并按bit形式顯示,配置如圖

第六步,點(diǎn)“GO”按鈕進(jìn)入全速運(yùn)行,OK,PWM波形出來了,用IN和OUT可以調(diào)掃描時(shí)間,如下圖

評論