How does keil debug online to see the value of peripheral registers

1. Introduction

This article takes GPIO as an example, and mainly introduces how to use the online debugging function of keil to view the register configuration of GPIO.

Two, operation steps

2.1 Keil project settings

Choose to generate debug information
insert image description here

2.2 Online debugging

Click the "Debug" button.
insert image description here
Select the address of the peripheral device to be viewed, and add it to the watch interface:
insert image description here
you can see the register of the corresponding peripheral device in the watch interface:
insert image description here
add a breakpoint to the GPIO initialization position, run in a single step, and you can see that the value of the peripheral register has changed:
insert image description here
Other Registers can also be viewed online in a similar manner to the value of the corresponding register.

Three, summary

This article mainly introduces how to use keil online debugging to view the value of peripheral registers for reference.

Guess you like

Origin blog.csdn.net/xuxu_123_/article/details/131434311