<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Programming nRF51822 using SWD</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/3386/programming-nrf51822-using-swd</link><description>We are using nRF51822 in our custom board.
We just remain two pin ------ SCLK and SWDIO
Can we programming by STLink ?
what&amp;#39;s the step?
1.using nrfgo studio to programming SoftDevice
2.using keil to download?
thanks!</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 17 Feb 2020 10:30:37 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/3386/programming-nrf51822-using-swd" /><item><title>RE: Programming nRF51822 using SWD</title><link>https://devzone.nordicsemi.com/thread/234605?ContentTypeID=1</link><pubDate>Mon, 17 Feb 2020 10:30:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3956c915-ba3c-4653-ac53-dd3aa70bffee</guid><dc:creator>mr.project</dc:creator><description>&lt;p&gt;I am able to flash the BLE SDK on nrf51 Soc in Linux environment using openocd by below command.&lt;/p&gt;
&lt;p&gt;openocd -c &amp;quot;set WORKAREASIZE 0;&amp;quot; -f /usr/share/openocd/scripts/interface/ftdi/SWD_FT.cfg -f /usr/share/openocd/scripts/target/nrf51.cfg -c &amp;quot;init; reset halt; program &amp;lt;&amp;lt;path of your file&amp;gt;&amp;gt; 0X0 verify; shutdown;&amp;quot;&lt;/p&gt;
&lt;p&gt;Now I am looking to flash BLE application on different flash address but not sure how to proceed with openocd. Anyone have idea regarding the same.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Programming nRF51822 using SWD</title><link>https://devzone.nordicsemi.com/thread/12297?ContentTypeID=1</link><pubDate>Fri, 24 Jul 2015 09:56:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6fffca84-48e8-44ad-948b-2e013a46db9d</guid><dc:creator>Nguyen Hoan Hoang</dc:creator><description>&lt;p&gt;You can use &lt;a href="http://embeddedsoftdev.blogspot.ca/p/idap-link.html"&gt;IDAP-Link&lt;/a&gt; with a simple command to flash all 3 parts without needing mergehex.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;IDAPnRFProg s110_nrf51_8.0.0_softdevice.hex Blinky_ble.hex dfu_nrf51.hex
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;It also works with OpenOCD, Keil, Crossworks, etc.  Full CMSIS-DAP with Drag &amp;amp; Drop feature&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Programming nRF51822 using SWD</title><link>https://devzone.nordicsemi.com/thread/12298?ContentTypeID=1</link><pubDate>Fri, 24 Jul 2015 06:54:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:467b9809-7991-4d6b-acf7-22cf0a6588eb</guid><dc:creator>Christopher</dc:creator><description>&lt;p&gt;I use Eclipse with GCC, GDB and OpenOCD to program the &lt;code&gt;nrf51&lt;/code&gt; using the ST-Link/V2.&lt;/p&gt;
&lt;p&gt;To flash the SoftDevice using OpenOCD and any compatible Jtag (tested with ST-Link/V2), you can do:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;$ openocd -f interface/stlink-v2.cfg -c &amp;quot;transport select hla_swd; set WORKAREASIZE 0x4000;&amp;quot; -f target/nrf51.cfg -c &amp;quot;init ; reset halt ; nrf51 mass_erase ; sleep 500 ; flash write_image .bin 0x0 ; verify_image .bin 0x0 ; mww 0x4001e504 1 ; mww 0x10001000 $(STARTADDRESS) ; mww 0x4001e504 0 ; shutdown&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The application start address depends on the SoftDevice you use. The address value is given in the SoftDevice release notes (&lt;code&gt;0x16000&lt;/code&gt; for s110 v. 7.3.0 for instance). Do not forget to change your linker script with this offset value.&lt;/p&gt;
&lt;p&gt;Have a look at &lt;a href="https://github.com/sprhawk/nrf51822-macosx-build-scripts/blob/master/Makefile.OpenOCD"&gt;this Makefile&lt;/a&gt; to see other targets to program your application or to erase the flash.&lt;/p&gt;
&lt;p&gt;Regards,
Christopher&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Programming nRF51822 using SWD</title><link>https://devzone.nordicsemi.com/thread/12296?ContentTypeID=1</link><pubDate>Thu, 16 Oct 2014 00:58:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:db254ef8-d767-45a3-929b-4ea8cb146316</guid><dc:creator>Steven_wang</dc:creator><description>&lt;p&gt;I use jlink at last .&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Programming nRF51822 using SWD</title><link>https://devzone.nordicsemi.com/thread/12295?ContentTypeID=1</link><pubDate>Sun, 10 Aug 2014 13:03:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5fdb3aee-e5fe-4c47-b2bd-c2e02a9eb777</guid><dc:creator>EUA</dc:creator><description>&lt;p&gt;I can program via OpenOCD trunk. Also could program softdevice by hand using by downloading binary to correct addresses.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt; openocd -f interface/stlink-v2.cfg   -f target/nrf51_stlink.tcl -c &amp;quot;program &amp;lt;path_of_the_bin&amp;gt; &amp;lt;address&amp;gt;&amp;quot;
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>