Double-click SP7021_IDE_Setup.exe to start the installation environment, as follows
Select the installation path and start the installation; after the installation is complete, the following icon appears on the desktop
2.8.2 Using SP7021 IDE
Double-click the SP7021 IDE icon on the desktop, and the following icon will appear during the first run
Check the box shown in red, and then select the blue box to enter the development environment shown in the figure below. The current mode is edit mode, and users can write code:
2.8.3 Project compilation
After the project code has been modified, compile it as follows :
After the compilation is complete, the console window displays the results as shown
2.8.4 Project debugging serial port settings
Before the start of debugging, you need to confirm that the necessary hardware is complete, which mainly includes the Plus7021 development kit, and a PC for debugging simulation; Next, set the serial port in SP7021 IDE, as shown in the figure below
1: First switch to the Terminal window according to the red character 1 marked in the figure;
2: Then click the red character marked in the figure 2 and click the icon, the Terminal configuration window will pop up
3:According to the red character 3 marked in the figure, you can select the serial port corresponding to the matching debugging tool, here is COM5 (after different users install the debugging tool, the serial port number assigned by the windows system is different)
4: Click OK to end the Terminal setting, as shown in the figure below
5: The Plus7021 development platform is powered on, and the Terminal window is displayed as follows
2.8.5 Project debugging
Click the red box at the following picture, SP7021 IDE will download the compiled code to the DRAM on SP7021 chip
SP7021 IDE enters the following debugging mode from editing mode
The program running pointer stops at the red box 1 at the entry address of the main function, and waits for the user's next debug command. It can be debugged in one step or run all, as described below:
Single-step debugging: Red box 2 is Step Over; red box 3 is Step Into, which can be selected by users according to their own needs;
Run all: Red box 4 means the program starts to run. If the program has a breakpoint, it will stop at the breakpoint and wait for the user's next debug command;
End debugging: click the icon shown in the red box to end the program, exit the debugging mode, and return to the editing mode
Breakpoint setting:
You can set breakpoints in both edit mode and debug mode, there are two methods:
Method 1:Double-click at the red box shown in the figure below to set a breakpoint, double-click again to cancel the breakpoint setting
Method 2: Click the left mouse button at the red box shown in the figure above, the following menu pops up, the user can click the red box 2 to set or cancel the breakpoint
0 Comments