en:uhsdr_dev:toolchain

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revisionBoth sides next revision
en:uhsdr_dev:toolchain [06.02.2018 08:54] df9ts_useren:uhsdr_dev:toolchain [06.02.2018 23:03] df9ts_user
Line 13: Line 13:
  
 === GNU ARM toolchain for Linux === === GNU ARM toolchain for Linux ===
-<bootnote>Important: use ltest version of tool chain from web sites below. DO NOT use the ARM toolchain that comes with your Linux distribution</bootnote> +<bootnote>Important: use latest version of tool chain from web sites below. DO NOT use the ARM toolchain that comes with your Linux distribution</bootnote>
-<bootnote>Important: At the time of writing (Jan 2018) this gcc needs to be used: "gcc-arm-none-eabi-6-2017-q2-update-linux". The latest q4 version compiles UHSDR but the resulting UHSDR does not run. Under further investigation</bootnote>+
  
 See [[https://gnu-mcu-eclipse.github.io/toolchain/arm/install/]] for general explanations See [[https://gnu-mcu-eclipse.github.io/toolchain/arm/install/]] for general explanations
  
 === Install Arm toolchain for Linux === === Install Arm toolchain for Linux ===
-  * Download the latest Linux install tarball file from ARMDeveloper **(use Version 6-2017-q2-update, released: June 28, 2017)**+  * Download the latest Linux install tarball file from ARMDeveloper 
   * Link to download: https://developer.arm.com/open-source/gnu-toolchain/gnu-rm/downloads   * Link to download: https://developer.arm.com/open-source/gnu-toolchain/gnu-rm/downloads
   * Assuming downloaded file is in /home/gerd/Downloads, open terminal with user gerd:   * Assuming downloaded file is in /home/gerd/Downloads, open terminal with user gerd:
Line 25: Line 24:
 $ mkdir -p ${HOME}/opt $ mkdir -p ${HOME}/opt
 $ cd ${HOME}/opt $ cd ${HOME}/opt
-$ tar xjf ~/Downloads/gcc-arm-none-eabi-6-2017-q2-update-linux.tar.bz2 +$ tar xjf ~/Downloads/gcc-arm-none-eabi-7-2017-q4-major-linux.tar.bz2  
-$ chmod -R -w /home/gerd/opt/gcc-arm-none-eabi-6-2017-q2-update/+$ chmod -R -w /home/gerd/opt/gcc-arm-none-eabi-7-2017-q4-major 
 </code> </code>
   * Test if the compiler is functional; use the actual install path:   * Test if the compiler is functional; use the actual install path:
 <code> <code>
-$ /home/gerd/opt/gcc-arm-none-eabi-6-2017-q2-update//bin/arm-none-eabi-gcc-6.3.1 --version+$ /home/gerd/opt/gcc-arm-none-eabi-7-2017-q4-major/bin/arm-none-eabi-gcc-7.2.1 --version
 </code> </code>
   * Output should be like this:   * Output should be like this:
 <code> <code>
-arm-none-eabi-gcc-6.3.1 (GNU Tools for ARM Embedded Processors 6-2017-q2-update6.3.1 20170620 (release) [ARM/embedded-6-branch revision 249437+arm-none-eabi-gcc-7.2.1 (GNU Tools for Arm Embedded Processors 7-2017-q4-major7.2.1 20170904 (release) [ARM/embedded-7-branch revision 255204
-Copyright (C) 2016 Free Software Foundation, Inc.+Copyright (C) 2017 Free Software Foundation, Inc.
 This is free software; see the source for copying conditions.  There is NO This is free software; see the source for copying conditions.  There is NO
 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Line 42: Line 41:
 \\ \\
 === GDB - GNU Debugger & OpenOCD === === GDB - GNU Debugger & OpenOCD ===
-GDB 7.12 distributed with the initial GCC 6.2 (gcc-arm-none-eabi-6_2-2016q4-20161216) has several issues (crashes on macOS and is incompatible with Neon.2). +Check that GDB is installed in your Linux distribution by entering
-The recommendation is to use the update version gcc-arm-none-eabi-6-2017-q1-update, or later. +
-\\ +
-=== Install OpenOCD === +
-  * See [[https://gnu-mcu-eclipse.github.io/openocd/install/]] +
-  * Download from [[https://github.com/gnu-mcu-eclipse/openocd/releases]] +
-  * Latest version is gnu-mcu-eclipse-openocd-0.10.0-5-20171110-1117-debian64.tgz+
 <code> <code>
-sudo mkdir -p /opt/gnuarmeclipse +gdb
-$ cd /opt/gnuarmeclipse +
-$ tar xvf /home/gerd/Downloads/gnu-mcu-eclipse-openocd-0.10.0-5-20171110-1117-debian64.tgz +
 </code> </code>
-  * Test installation:+The output should look like this:
 <code> <code>
-/opt/gnuarmeclipse/gnu-mcu-eclipse/openocd/0.10.0-5-20171110-1117/bin/openocd --version+GNU gdb (Debian 7.12-6+b1) 7.12.0.20161007-git 
 +Copyright (C) 2016 Free Software Foundation, Inc. 
 +License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> 
 +[...]
 </code> </code>
-  * Output should be like this:+If missing install with
 <code> <code>
-GNU MCU Eclipse 64-bits Open On-Chip Debugger 0.10.0+dev-00254-g2ec04e4e (2017-11-10-11:27)+apt-get install gdb 
 +</code> 
 + 
 +  * Latest GNU MCU OpenOCD binaries can be found [[https://gnu-mcu-eclipse.github.io/openocd/releases/|here]]. 
 +  * This leads e.g. to [[https://github.com/gnu-mcu-eclipse/openocd/releases/tag/v0.10.0-7-20180123/|these binary files]] 
 + 
 +Installation: 
 +<code> 
 +$ cd ${HOME}/opt 
 +$ tar xvf ~/Downloads/gnu-mcu-eclipse-openocd-0.10.0-7-20180123-1217-centos64.tgz 
 +$ chmod -R -w gnu-mcu-eclipse/openocd/0.10.0-7-20180123-1217 
 +</code> 
 + 
 +Check OpenOCD installation: 
 +<code> 
 +$ ${HOME}/opt/gnu-mcu-eclipse/openocd/0.10.0-7-20180123-1217/bin/openocd --version 
 +</code> 
 +Output should be something like this: 
 +<code> 
 +GNU MCU Eclipse 64-bits Open On-Chip Debugger 0.10.0+dev-00404-g20463c28 (2018-01-23-12:24)
 Licensed under GNU GPL v2 Licensed under GNU GPL v2
 For bug reports, read For bug reports, read
-http://openocd.org/doc/doxygen/bugs.html+ http://openocd.org/doc/doxygen/bugs.html
 </code> </code>
-\\+ 
 +Install UDEV rules for USB OpenOCD probes: 
 +<code> 
 +# cp ${HOME}/opt/gnu-mcu-eclipse/openocd/0.10.0-7-20180123-1217/contrib/60-openocd.rules /etc/udev/rules.d/ 
 +# udevadm control --reload-rules 
 +# usermod -aG plugdev $USER 
 +</code> 
 + 
 +Install OpenOCD Debugging plugin, see [[https://gnu-mcu-eclipse.github.io/openocd/install/|here]] 
 + 
 +Update OpenOCD path, see [[https://gnu-mcu-eclipse.github.io/openocd/install/|here]] 
 + 
 +{{ :en:uhsdr_dev:openocd.pdf |OpeOCD manual from sourceforge}} \\ 
 +[[https://community.particle.io/t/tutorial-using-eclipse-st-link-v2-openocd-to-debug/10042|eclipse & st-link/v2 tutorial]] 
 + 
 +In Virtualbox make sure the STM-link/V2 adapter is connected through to virtual machine (check machine settings->USB) 
 + 
 +In Eclipse hit green "Debug" button. 
 + 
 === GNU MCU Eclipse and CDT === === GNU MCU Eclipse and CDT ===
   * Install Eclipse and CDT   * Install Eclipse and CDT
Line 78: Line 110:
 $ tar xvf /home/gerd/Downloads/20180125-1917-gnumcueclipse-4.3.2-oxygen-2-linux.gtk.x86_64.tar.gz  $ tar xvf /home/gerd/Downloads/20180125-1917-gnumcueclipse-4.3.2-oxygen-2-linux.gtk.x86_64.tar.gz 
 </code> </code>
 +
 +Make the GNU Arm toolchain location known to Eclipse in Project->Properties->C/C++ Build->Environment->PATH. add the path to GCC here (in this example we would add /home/gerd/opt/gcc-arm-none-eabi-7-2017-q4-major/bin ).
  
 === Launch Eclipse to test installation === === Launch Eclipse to test installation ===
Line 84: Line 118:
 /home/gerd/opt/GnuMcuEclipse/eclipse/eclipse  /home/gerd/opt/GnuMcuEclipse/eclipse/eclipse 
 </code> </code>
- 
-(grg seems not necessary, check installed plugins. first try if those compile run debug) 
-=== Install GNU MCU Eclipse plug-ins === 
-  * See https://gnu-mcu-eclipse.github.io/plugins/install/ 
-  * In Eclipse: Help->Install new software, choose "work with GNU MCU Eclipse Plug-ins - http://gnu-mcu-eclipse.netlify.com/v4-neon-updates". Then select these packages: 
-    * GNU MCU C/C++ ARM Cross Compiler 
-    * GNU MCU C/C++ Documentation (Placeholder) 
-    * GNU MCU C/C++ OpenOCD Debugging 
-    * (GNU MCU C/C++ QEMU) ?? 
-    * GNU MCU C/C++ STM32Fx Project Templates 
-(/grg) 
  
 === Build Test Project to check all is ok === === Build Test Project to check all is ok ===
  • en/uhsdr_dev/toolchain.txt
  • Last modified: 06.02.2018 23:03
  • by df9ts_user