Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
1. Download the operating environment that Eclipse requires, jdk/jre.
In Http://wiki.eclipse.org/Eclipse/Installation, find the Java version required for the latest version of Eclipse, and then go to the appropriate website to download java. Here I'm using Eclipse 4.5 (Mars), which requires Java 7.
2. Download Eclipse
Download Eclipse IDE for C + + developers on Eclipse's website
3. Download Bleeding-edge-toolchain,openocd,windows-build-tool.
On the site http://www.freddiechopin.info/en/download, find download, choose Bleeding-edge-toolchain, Download the latest can.
Then click Download, download Openocd, and download the latest.
The Windows-build-tool version provided on this website is too old to be used and recommended to http://gnuarmeclipse.github.io/windows-build-tools/ Download the latest windows-build-tools.
4. Download Eclipse GNU ARM Plug-in
Download the latest on https://sourceforge.net/projects/gnuarmeclipse/.
5. Download Zadig
Download on http://zadig.akeo.ie/
So far, all the needs have been downloaded, all extracted, except Eclipse plug-in.
6. Commissioning
Insert the Development Board, I use the atom of the mini version, open Zadig, select Options->list all devices, select Jlink in the drop-down menu. Select Winusb to the right of the arrow and click Replace Driver.
I have changed here, so both sides are winusb.
7. Install/start Eclipse. Installation of GNU Arm plug-in
Install the JDK, then go directly to the Eclipse directory and start Eclipse. Then install the plugin. Select Help->install new software
Select Add,location to select the path of the plugin, as in ilg*.zip,name with you, then OK. Then go down all the way next.
8. New Project
Open Eclipse, choose File->new->c Project, choose the type that matches your board, I'm stm32f10x c/S/C + + project, and Next, here's the change according to the actual situation, Note that the parameters of the basic need to change, in the actual use of the chip you are based on, in next, here according to your preferences, I left the default settings, and next, here generally keep a debug on the line, the following release can be ticked off; Here Toolchain path choose you to download the extracted toolchain path, I here is D:\STM32\STM32-Toolchain\gcc-arm-none-eabi-5_3-160412\bin, click Finish.
9. Start work
After the project is new, right-click the project name and select Build Project. Will normally be completed smoothly. The next step is to put the program behind the build into the stm32. Select the triangle next to external Tools configurations. On the program, right-click on new, select the path of OPENOCD in location, as follows
Select the Debug directory for the project in working directory, as follows
In arguments, according to the debugger you used to write the corresponding parameters, I use the Jlink, configured as follows:
If you are using a different debugger, you can go to the OPENOCD installation directory in the Scripts/interface directory under the corresponding file. The same chip can also be found in the Scripts/target directory. When the configuration is complete, click Apply, then click Run. All right, in the console window you can see the information about the chip that has been read:
Then continue to click on the triangle next to the icon, in just that configuration, right-click on the duplicate, then there will be an identical configuration, in the new configuration will argument in the last three lines of parameters, select Apply, then click Run.
10.Debug
Select the triangle next to the bug icon on the toolbar, select Debug Configurations, right-click on the left-hand side of GDB Hardware debugging, select New. Select the Debugger tab and select the path of the downloaded gnu-arm-none-eabi-gdb in the GDB command:
The following configuration is in remote target:
Click Apply. On the Startup tab, configure the following:
Then click Apply, and finally click Debug. In the dialog box that pops up, select No.
To do this, debug stm32 with Eclipse is complete.
Eclipse C Development Stm32