Keil MDK version: v4.03. For more information, see my other blog posts.
PC-Lint version: v8.0
There are many powerful functions of PC-lint on the Internet. I don't want to repeat them here. I just want to say: it can be tested by PC-lint.ProgramIt may not be a problem, but the quality improvement is self-evident when the PC-Lint test program is passed.
First, install the Keil MDK and PC-Lint software. Most of the PC-lint on the Internet is the installed compressed package, which can be directly decompressed to the C drive. Please support genuine edition !! (Cough, weak heart ...)
The method is very simple, because the Keil MDK has given the PC-Lint corresponding to the Keil arm compiler configuration file: CO-KCARM.LNT.
First open MDK and select Tools-setup PC lint. The PC-Lint configuration page shown in 1 is displayed.
Figure 1 PC-Lint configuration page
Click the area marked by Red 1 in Figure 1, select the lint tool, and then click the area marked by Red 2 in Figure 1, go to the CO-KCARM.LNT file under the/ARM/binfile under the Keil installation directory, which is the PC-Lint check configuration file for the corresponding Keil arm compiler. Click 'OK' to exit. The setting is complete.
Run the PC-Lint check program:Tools-Lint...Check the current C source file opened by the editor,Tools-Lint all C source filesChecks all C source files in the project. The information obtained by PC-Lint is displayed in the build-output window. Double-click the lint Information Line Editor and you will find the correspondingSource codeLine.
In my program, the compiler has 0 errors and 1 warning (). After the PC-Lint check, there are hundreds of errors, warnings, and other information, sweating...