<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: gdb debugging on Kinetis with Segger gdb server on Linux in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/gdb-debugging-on-Kinetis-with-Segger-gdb-server-on-Linux/m-p/248617#M6840</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Hello ,&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; I am Manish .I have been working on open-source Embedded technologies on Linux platform since 2 years.Now&amp;nbsp; I have just started to learn about free scale freedom board .But I'm not able to flash (Load) same code take from this community using OpenSDA. Fllowing thing I have done successfully&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;1.I have installed Drivers of OpenSDA and verified for ttyACM0 port .&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;2.Went through Boot-loader mode of OpenSDA and found&amp;nbsp; "/media/BOOTLOADER" directory on Linux platform .&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;3.Compiled sample code given on this community and tried to copy main.srec to&amp;nbsp; "/media/BOOTLOADER"&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp; But expected output not got.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;so please guide me&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;1.How &lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;&lt;STRONG&gt;to flash code freedom board (&lt;A href="http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=FRDM-KL25Z"&gt;FRDM KL25Z&lt;/A&gt;) .&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;2.How &lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;&lt;STRONG&gt;to set&amp;nbsp; Debug Environment ?&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;3.Is any utilities for flashing and Debugging available..?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Regards&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Manish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 15 May 2014 05:21:31 GMT</pubDate>
    <dc:creator>manish2789</dc:creator>
    <dc:date>2014-05-15T05:21:31Z</dc:date>
    <item>
      <title>gdb debugging on Kinetis with Segger gdb server on Linux</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/gdb-debugging-on-Kinetis-with-Segger-gdb-server-on-Linux/m-p/248616#M6839</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;Hi,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;I'm a Kinetis guy with most of my embedded experience with CodeWarrior or IAR IDEs on Windows.&amp;nbsp; However, I just started to work with free GNU tools on a Linux host for compiling, &amp;amp; debugging code for Kinetis MCUs.&amp;nbsp; With gcc and gdb client from ARM, and gdb server and J-Link pod from Segger, you can compile, flash, and debug Kinetis devices with just command line operations. For me, it’s a different and very powerful model to work in.&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;If you are interested in Kinetis development using gdb and Segger's &lt;A href="http://www.segger.com/jlink-gdb-server.html"&gt;gdb server&lt;/A&gt; and &lt;A href="http://www.segger.com/debug-probes.html"&gt;j-link&lt;/A&gt;, here are steps I used to get started.&amp;nbsp; This does not cover makefiles and compiling with gcc.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;I'm using Ubuntu 12.04 running in VirtualBox.&amp;nbsp; I have a J-Link connected to a &lt;A href="http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=FRDM-KL25Z"&gt;FRDM-KL25Z&lt;/A&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;1. Install gcc (comes with gdb for ARM) maintained by ARM&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;(Details at &lt;A href="https://launchpad.net/gcc-arm-embedded"&gt;https://launchpad.net/gcc-arm-embedded&lt;/A&gt; ) &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;&lt;SPAN style="color: black;"&gt;mac@mac-VirtualBox:/$ &lt;/SPAN&gt;sudo add-apt-repository ppa:terry.guo/gcc-arm-embedded&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;&lt;SPAN style="color: black;"&gt;mac@mac-VirtualBox:/$&lt;/SPAN&gt;sudo apt-get update&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;&lt;SPAN style="color: black;"&gt;mac@mac-VirtualBox:/$&lt;/SPAN&gt;sudo apt-get install gcc-arm-none-eabi&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;2. Install Segger J-Link software and documentation pack for Linux (DEB Installer 32-bit version)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt; &lt;A href="http://www.segger.com/jlink-software.html"&gt;http://www.segger.com/jlink-software.html&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;3. Start GDB Server&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;mac@mac-VirtualBox:/$ JLinkGDBServer -device MKL25Z128xxx4 -if SWD -speed 1000 -endian little &amp;amp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;For the FRDM-KL25Z, select MKL25Z128xxx4 as the device.&amp;nbsp; See list of all Segger supported devices &lt;A href="http://www.segger.com/jlink_supported_devices.html"&gt;here&lt;/A&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;&lt;A href="http://www.freescale.com/webapp/sps/site/taxonomy.jsp?code=KINETIS_L_SERIES"&gt;Kinetis L-series&lt;/A&gt; devices use SWD for debugging, so that is selected as the interface.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;4. Start GDB client (command line):&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;mac@mac-VirtualBox:/$ arm-none-eabi-gdb&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;5. Connect to GDB Server &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;(gdb) target remote localhost: 2331&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;There are many references to gdb commands online. &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-top: 2.4pt; margin-bottom: 2.4pt;"&gt;&lt;/P&gt;&lt;P style="margin-top: 2.4pt; margin-bottom: 2.4pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;6. flash target&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;(gdb) load myapp.elf&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;7. Set symbols for debugger&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;(gdb) file myapp.elf&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;8. Use target specific commands.&amp;nbsp; Here are some examples.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;(gdb) monitor reset&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;(gdb) monitor go&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;(gdb) monitor halt&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; color: black; font-family: arial, helvetica, sans-serif;"&gt;(gdb) dump srec memory file 0x0000 0x1000&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;For target specific commands the gdb client can pass commands to the gdb server by adding “monitor” in front on the gdb server command.&amp;nbsp; This is shown above.&amp;nbsp; See Segger gdb server documentation for list of gdb server commands.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;See other great posts and blogs on related topics.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/message/348225#348225"&gt;https://community.freescale.com/message/348225#348225&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;&lt;A href="http://mcuoneclipse.com/2013/07/20/dyi-free-toolchain-for-kinetis-part-1-gnu-arm-build-tools/"&gt;&lt;SPAN style="color: #6a737b; background-color: white;"&gt;DIY Free Toolchain for Kinetis: Part 1 – GNU ARM Build Tools | MCU on Eclipse&lt;/SPAN&gt;&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: arial, helvetica, sans-serif;"&gt;Good luck!&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Dec 2013 17:04:36 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/gdb-debugging-on-Kinetis-with-Segger-gdb-server-on-Linux/m-p/248616#M6839</guid>
      <dc:creator>macl</dc:creator>
      <dc:date>2013-12-06T17:04:36Z</dc:date>
    </item>
    <item>
      <title>Re: gdb debugging on Kinetis with Segger gdb server on Linux</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/gdb-debugging-on-Kinetis-with-Segger-gdb-server-on-Linux/m-p/248617#M6840</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Hello ,&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; I am Manish .I have been working on open-source Embedded technologies on Linux platform since 2 years.Now&amp;nbsp; I have just started to learn about free scale freedom board .But I'm not able to flash (Load) same code take from this community using OpenSDA. Fllowing thing I have done successfully&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;1.I have installed Drivers of OpenSDA and verified for ttyACM0 port .&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;2.Went through Boot-loader mode of OpenSDA and found&amp;nbsp; "/media/BOOTLOADER" directory on Linux platform .&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;3.Compiled sample code given on this community and tried to copy main.srec to&amp;nbsp; "/media/BOOTLOADER"&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp; But expected output not got.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;so please guide me&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;1.How &lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;&lt;STRONG&gt;to flash code freedom board (&lt;A href="http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=FRDM-KL25Z"&gt;FRDM KL25Z&lt;/A&gt;) .&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;2.How &lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;&lt;STRONG&gt;to set&amp;nbsp; Debug Environment ?&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;3.Is any utilities for flashing and Debugging available..?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Regards&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Manish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2014 05:21:31 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/gdb-debugging-on-Kinetis-with-Segger-gdb-server-on-Linux/m-p/248617#M6840</guid>
      <dc:creator>manish2789</dc:creator>
      <dc:date>2014-05-15T05:21:31Z</dc:date>
    </item>
  </channel>
</rss>

