Eclipse writes STM32 and Jlink debugging

Source: Internet
Author: User
Tags jlink

Eclipse can write a microcontroller code that replaces the MDK and IAR of charges.

First, download eclipse

Eclipse has more than one version, we need to be a C + + version, you can choose to download other versions, and then add the CDT plugin, in order to save trouble, we directly choose to download the CDT version, download link http://www.eclipse.org/downloads/ eclipse-packages/

Second, download the JRE

After the download is complete, the decompression is not busy open, also can not open. The Java runtime needs to be downloaded first to download the JSE. Can download the JDK, or JRE, we do not need to develop Java, so only need to download the JRE, the specific difference, the JRE is Java run ENVIRONMENT,JDK there are many development tools written in Java, we do not use.

Hang up the download link http://www.oracle.com/technetwork/java/javase/downloads/index.html

Click to enter, select download

The installation is complete, eclipse can open, if still cannot open, then add the bin directory of the JRE to the system environment variable, add environment variable method is not introduced.

Third, change the eclipse plugin download source

We need to download the plugin below, the foreign site download plugin is slow, here we replace the download source, to the domestic mirror address, specific methods, see a tutorial on the Web

Https://www.cnblogs.com/yangwen0228/p/6309463.html

It is important to note that when replacing all of the replacements, not all of them, just replace those links in the beginning of the http://download.eclipse.org/.

Iv. installation of the GNU ARM Eclipse Plugin

Open Eclipse,help->install New software...->add, enter the URL in location http://gnuarmeclipse.sourceforge.net/updates, Name Input GNU ARM

Pending out of the full selection of installation, the installation process may be prompted to have a security warning, still installed, after the installation is prompted to restart, restart after the completion of the plug-in installation.

V. Installing the compiler

The compiler needs to download the installation manually, download the link

Https://launchpad.net/gcc-arm-embedded/+download

Install the last step, remember to tick add to environment variable

If you forget, then add it manually.

Six, install make and other tools

Compile, need make, echo and other tools, this time need to download these tools, from Https://github.com/gnu-mcu-eclipse/windows-build-tools/releases, this is on GitHub, Prevent later may expire, add again an entrance, http://www.emb4fun.de/archive/gabmt/index.html.

After the installation is complete, locate the installation directory and add the bin path to the system environment variables, such as my D:\GNU MCU eclipse\build tools\2.9-20170629-1013\bin\bin

The installation is complete to create the project.

Vii. Creation of the project

File->new->project->c/c++->c Project

All the way to next.

Click on this icon to see the Code edit page.

Eight, compile

All of the above is correct, you can click on the icon to compile.

Compile complete

Nine, Jlink debugging settings

1. Install the Jlink package, such as setup_jlinkarm_v486a, install, restart Eclipse, and then you can see it in Windows->preference->run/debug->jlink

2. Set the device Pack package path

Note that this setting is from the online chip package packages, downloaded, it is not good to change. If you have a previous download, select the directory directly, and then restart Eclipse to go directly to the next step.

3. Download the device Pack package

Click on this icon to

Click Finish, will come out of the Pack window, click Refresh, update the chip directory from the Internet, and then select the directory, click Download, (button on the left of the refresh)

This process is slow, need to wait patiently, network bad will fail, no way.

The catalog file is. pdsc format, download good pack is. pack format, Keil inside also have similar, not clear directly copy past line not. Attach a picture of the fix

4. Setting the Chip

Although the new project can be compiled, but want to debug, you need to set the chip, right-click the Project button, and then select Properties, select the chip,

5.debug Configuration

Click Run->debug configgurations, double-click Jlink debugging

Among them, the default configuration inside, there are several parameters, and there is no way to identify, if laissez-faire, also can debug, if do not want to error, remove those parameters, (-strict-timeout 0-nogui) remove

Do not need to configure, link good stm32 board, directly click on Debug, you can debug debugging,

The above is all the steps

Resources:

http://blog.csdn.net/k331922164/article/details/44837487

Https://www.cnblogs.com/chihirosan/p/5258946.html

http://blog.csdn.net/neutree/article/details/50551919

Eclipse writes STM32 and Jlink debugging

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.