<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.element14.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>Getting started with mbed.org and FRDM-KL25Z</title><link>https://community.element14.com/products/devtools/kinetiskl2freedomboard/w/documents/11160/getting-started-with-mbed-org-and-frdm-kl25z</link><description /><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>Getting started with mbed.org and FRDM-KL25Z</title><link>https://community.element14.com/products/devtools/kinetiskl2freedomboard/w/documents/11160/getting-started-with-mbed-org-and-frdm-kl25z</link><pubDate>Fri, 08 Oct 2021 05:31:40 GMT</pubDate><guid isPermaLink="false">93d5dcb4-84c2-446f-b2cb-99731719e767:ab6eaecc-2d1d-4755-a188-6e2051f9b830</guid><dc:creator>bprewit</dc:creator><comments>https://community.element14.com/products/devtools/kinetiskl2freedomboard/w/documents/11160/getting-started-with-mbed-org-and-frdm-kl25z#comments</comments><description>Current Revision posted to Documents by bprewit on 10/8/2021 5:31:40 AM&lt;br /&gt;
&lt;p style="margin:0;"&gt;I recently came across mbed.org, an online toolchain for ARM parts.&amp;nbsp; The first thing that I noticed was that they claimed to support the Freedom-KL25z, so I thought I would put that to the test.&lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt;The setup was not quite as effortless as I expected.&lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt;The first step was updating the bootloader by following this procedure:&lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ol&gt;&lt;li&gt;Update the bootloader firmware from a Windows system. &lt;em&gt; I attempted this from both Linux &amp;amp; Mac without success (this was the most frustrating part)&lt;/em&gt;&lt;ol&gt;&lt;li&gt;Dowload the firmware updates from PE Micro (&lt;a class="jive-link-external-small" href="http://www.pemicro.com/downloads/download_file.cfm?download_id=378" rel="nofollow ugc noopener" target="_blank"&gt;here&lt;/a&gt;) &lt;/li&gt;&lt;li&gt;Unpack the file Pemicro_OpenSDA_Debug_MSD_Update_Apps_2013_01_07.zip to a convenient location.&lt;/li&gt;&lt;li&gt;Follow the instructions contained in the BOOTUPDATEAPP_release_notes.txt file.&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt;Create an account on mbed.org&lt;/li&gt;&lt;li&gt;Install the mbed firmware by following &lt;a class="jive-link-external-small" href="https://mbed.org/handbook/mbed-FRDM-KL25Z-Getting-Started" rel="nofollow ugc noopener" target="_blank"&gt;this procedure&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt;Once all of that has been completed, you should have a USB disk titled &amp;quot;MBED&amp;quot; available; mount this disk as required for your operating system.&lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt; The rest is just plain fun.&amp;nbsp; Using the mbed compiler, The &amp;quot;HelloWorld&amp;quot; application that I created compiled and ran without any changes.&amp;nbsp; Compliing a program from the online compiler results in a downloaded &amp;quot;.bin&amp;quot; file, which is then copied to the USB drive.&amp;nbsp; Hit the reset button on the Freedom board and voila, your program is running!&lt;/p&gt;&lt;p style="margin:0;"&gt;&lt;span&gt;&lt;a href="https://community.element14.com/resized-image/__size/620x318/__key/communityserver-wikis-components-files/00-00-00-01-49/contentimage_5F00_22853.png"&gt;&lt;img alt="image" src="https://community-storage.element14.com/communityserver-components-secureimagefileviewer/communityserver/wikis/components/files/00/00/00/01/49/contentimage_22853.png-620x318.png?sv=2016-05-31&amp;amp;sr=b&amp;amp;sig=gRgA6xfFtrNH18QHAuYWJIPnoNF0RrQ4qSt6zdtsfxY%3D&amp;amp;se=2026-08-13T23%3A59%3A59Z&amp;amp;sp=r&amp;amp;_=Jf0LLpivnqynyi3/PtiJYg==" style="max-height: 318px;max-width: 620px;" /&gt;&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;&lt;p style="margin:0;"&gt;I tested both the default (gpio) demo and a serial demo.&amp;nbsp; Both compiled exactly as expected, downloaded without problems, and ran immediately.&lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt;If you want to do very much, you will probably want to replace the precompiled library with the source library.&amp;nbsp; I had to do this to find out what mbed was calling the pins.&amp;nbsp; The procedure is simple; delete the default &amp;quot;mded&amp;quot; lib and import the source libraries from &lt;span class="active_link"&gt;the mbed SDK (&lt;a class="jive-link-external-small" href="https://mbed.org/handbook/mbed-SDK" rel="nofollow ugc noopener" target="_blank"&gt;here&lt;/a&gt;). You will need to import both the mbed-src lib and the mbed-Freescale lib.&amp;nbsp; The pin names are (surprisingly) in the file &amp;quot;PinNames.h&amp;quot; under &amp;quot;mbed-Freescale/capi/KL25Z&amp;quot;,&lt;/span&gt;&lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt;All in all, I was impressed with the mbed tools; other than the confusion regarding the requirement for the bootloader upgrade to be performed from Windows, getting started with mbed.org was faster than downloading and installing native tools.&amp;nbsp; The library routines worked as expected and the documentation for both the library and compiler are both excellent.&amp;nbsp; In addition, I do not believe that mbed has any code-size restrictions.&amp;nbsp; There are provisions to export your project to several other&amp;nbsp; formats:&lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt;&lt;span&gt;&lt;a href="https://community.element14.com/resized-image/__size/464x256/__key/communityserver-wikis-components-files/00-00-00-01-49/contentimage_5F00_22854.png"&gt;&lt;img loading="lazy" alt="image" src="https://community-storage.element14.com/communityserver-components-secureimagefileviewer/communityserver/wikis/components/files/00/00/00/01/49/contentimage_22854.png-464x256.png?sv=2016-05-31&amp;amp;sr=b&amp;amp;sig=LWfaIc47EuF9LTGhs8r7Em7Qr5PAgWV6NNhDSA0VgF8%3D&amp;amp;se=2026-08-13T23%3A59%3A59Z&amp;amp;sp=r&amp;amp;_=lqzgJsfbTHpyYsJOUuJqTw==" style="max-height: 256px;max-width: 464px;" /&gt;&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt;I would say that this is a definite &amp;quot;win&amp;quot; .. &lt;/p&gt;&lt;p style="margin:0;padding:0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="margin:0;"&gt;&lt;span class="active_link"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;
</description></item></channel></rss>