<?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>LPCXpresso IDEのトピックRe: Minimal Blinky in about 200 bytes</title>
    <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540444#M6986</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by akhilpo on Fri May 13 01:14:16 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;I just made these changes from that code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1.changed header file to LPC11xx.h&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2.changed memory mappings to corresponding memory address of LPC1114:&lt;/SPAN&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: &lt;/STRONG&gt;&lt;BR /&gt;#define STCTRL 0xE000E010&lt;BR /&gt;#define RELOAD 0xE000E014&lt;BR /&gt;#define FIO0DIR 0x50008000&lt;BR /&gt;#define FIO0PIN 0x50003FFC&lt;BR /&gt;#define LEDPIN (1&amp;lt;&amp;lt;7)&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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is my edited code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD bgcolor="#cacaca"&gt; &lt;PRE&gt;/*
===============================================================================
 Name&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : main.c
 Author&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :
 Version&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :
 Copyright&amp;nbsp;&amp;nbsp; : Copyright (C)
 Description : main definition
===============================================================================
*/

#ifdef __USE_CMSIS
#include "LPC11xx.h"
#endif

#include &amp;lt;cr_section_macros.h&amp;gt;
#include &amp;lt;NXP/crp.h&amp;gt;

// Variable to store CRP value in. Will be placed automatically
// by the linker when "Enable Code Read Protect" selected.
// See crp.h header for more information
//__CRP const unsigned int CRP_WORD = CRP_NO_CRP ;

#define STCTRL 0xE000E010
#define RELOAD 0xE000E014
#define FIO0DIR 0x50008000
#define FIO0PIN 0x50003FFC
#define LEDPIN (1&amp;lt;&amp;lt;7)

volatile unsigned int msTicks;

int main(void) {

&amp;nbsp;&amp;nbsp;&amp;nbsp; unsigned int *p = (unsigned int *)STCTRL;
&amp;nbsp;&amp;nbsp;&amp;nbsp; //STCTRL = 7&amp;nbsp; enable timer and interrupt
&amp;nbsp;&amp;nbsp;&amp;nbsp; *p = 7;
&amp;nbsp;&amp;nbsp;&amp;nbsp; p = (unsigned int *)RELOAD;
&amp;nbsp;&amp;nbsp;&amp;nbsp; //RELOAD = (FIRC / 100) - 1 = 40,000 - 1 = 39,999 = 0x9C3F
&amp;nbsp;&amp;nbsp;&amp;nbsp; // 10 mSec
&amp;nbsp;&amp;nbsp;&amp;nbsp; *p = 0x9C3F;

&amp;nbsp;&amp;nbsp;&amp;nbsp; p = (unsigned int *)FIO0DIR;
&amp;nbsp;&amp;nbsp;&amp;nbsp; *p = LEDPIN;

&amp;nbsp;&amp;nbsp;&amp;nbsp; msTicks = 0;
&amp;nbsp;&amp;nbsp;&amp;nbsp; // enable all interrupts
&amp;nbsp;&amp;nbsp;&amp;nbsp; __asm volatile ("cpsie i");

&amp;nbsp;&amp;nbsp;&amp;nbsp; // Enter an infinite loop
&amp;nbsp;&amp;nbsp;&amp;nbsp; while(1) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; return 0 ;
}

void SysTick_Handler(void)
{
&amp;nbsp;&amp;nbsp;&amp;nbsp; msTicks++;

&amp;nbsp;&amp;nbsp;&amp;nbsp; if(msTicks &amp;gt;= (50)) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; msTicks = 0;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; unsigned int *p = (unsigned int *)FIO0PIN;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if(*p &amp;amp; LEDPIN) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; p += 2;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; } else {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; p++;
&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; *p = LEDPIN;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
}
&lt;/PRE&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Jun 2016 21:54:49 GMT</pubDate>
    <dc:creator>lpcware</dc:creator>
    <dc:date>2016-06-15T21:54:49Z</dc:date>
    <item>
      <title>Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540372#M6914</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Wed Apr 20 17:15:35 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;In the following post CodeRedSupport had said this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: CodeRedSupport&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;The example blinky application uses additional libraries such as CMSIS to demonstrate their use. If you use the libraries, this will obviously increase the code size.&amp;nbsp; A minimal blinky can be done in about 200 bytes.&lt;BR /&gt; &lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://"&gt;http://knowledgebase.nxp.com/showpost.php?p=1212&amp;amp;postcount=2&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Without resorting to assembly has anybody done this or does anybody have any suggestions on how to do this?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Larry&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; [COLOR=darkorange]Newbies take note[/COLOR]:&amp;nbsp; This thread contains advanced programming techniques that are not really suitable for those just starting out with LPCXpresso.&amp;nbsp; I want to leave this thread open for more experienced users to add ideas.&amp;nbsp; If you try the programs in this thread and they don't work for you and want to ask why please open a new thread and refer to this one.&amp;nbsp; In other words, please don't ask in this thread.&amp;nbsp; Thank You.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540372#M6914</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:03Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540373#M6915</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by jharwood on Wed Apr 20 17:32:53 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Is it ok for LED to blink at 25Mhz? :D&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm down to 268 bytes&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:04 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540373#M6915</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:04Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540374#M6916</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Wed Apr 20 18:58:31 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: jharwood&lt;/STRONG&gt;&lt;BR /&gt;Is it ok for LED to blink at 25Mhz? :D&lt;BR /&gt; &lt;BR /&gt;I'm down to 268 bytes&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Sure, I can accelerate, slow, and travel through time.&amp;nbsp; I am The Doctor.:rolleyes:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Care to share that?&amp;nbsp; The best I have done is 2K bytes, but I'm still a noob at all this amazing ARM stuff.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I would still like to see a blinky normal people could visualize.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;EDIT:&amp;nbsp; Actually I would like to challenge the CodeRedSupport person that posted this to buck up and show me how.;)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks James.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Larry&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540374#M6916</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:05Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540375#M6917</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by jharwood on Wed Apr 20 19:52:03 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;To make it visualizable by normal people, I used the SysTick timer. Now it's a whopping 356 bytes :mad:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Anyway, this runs on a '1769 using the IRC @ 4Mhz. Oh, and there's just one asm line - to turn on the global interrupts :o&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540375#M6917</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:06Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540376#M6918</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Wed Apr 20 20:00:29 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: jharwood&lt;/STRONG&gt;&lt;BR /&gt;Oh, and there's just one asm line - to turn on the global interrupts :o&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;That's cheating.:) But only a little bit.&amp;nbsp; ~100 bytes seems like a lot for just adding a small handler.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I gather that the if (*p... stuff in the Systick_Handler was in main in the version without interrupts that produced 268 bytes.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Need to, thoroughly, study your build options and maybe read a little more about the GCC parameters to get a better grasp on how to obtain the numbers you did.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Nice routine though, especially the use of the pointer.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks again.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540376#M6918</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:06Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540377#M6919</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Thu Apr 21 10:32:30 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: larryvc&lt;/STRONG&gt;&lt;BR /&gt;Actually I would like to challenge the CodeRedSupport person that posted this to buck up and show me how.;)&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;CodeRedSupport?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540377#M6919</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:07Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540378#M6920</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by NXP_USA on Thu Apr 21 14:00:20 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;The USB_HID_ROM_TINY example for LPC1343 can also be used as a starting point for making truly minimal applications. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[U]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Be aware that it can be dangerous to place application code into the vector table, so make sure you know what you are doing. [/U]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It should be entirely possible to make a minimal Blinky entirely in C.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:08 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540378#M6920</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:08Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540379#M6921</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Thu Apr 21 21:18:46 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: larryvc&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;Nice routine though, especially the use of the pointer.&lt;BR /&gt; &lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;@jharwood,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I thought I had a good understanding of what the pointer manipulation in the ISR was doing.&amp;nbsp; Today I have confused myself after working it out on paper.:o&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Can you clear this up for me before I go further insane?:)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;@everyone,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm also working on understanding the code that NXP_USA has provided.&amp;nbsp; I just need to figure out the code to put into the while loop. It shouldn't take too long to implement.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; I have Joseph Yui's book "The definitive guide to the ARM Cortex-M3 Second Edition" out and I am reading it again for more details.&amp;nbsp; Most of the time I use an LPCXpresso1769 for experimentation and learning, but I do have 3 LPCXpresso1114s just waiting to be tried.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I thought this was going to be an easy one to figure out though it seems I have opened up a can of worms.&amp;nbsp; All in all I'm glad I started this thread as it has provided me with an opportunity to explore the depths and I have already learned so much more.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Larry&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:08 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540379#M6921</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:08Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540380#M6922</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by jharwood on Thu Apr 21 22:24:48 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi Larry&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Perhaps this will help:&lt;/SPAN&gt;&lt;BR /&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD bgcolor="#cacaca"&gt; &lt;PRE&gt;
int main(void) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; unsigned int *p = (unsigned int *)STCTRL;&amp;nbsp; // p is now set to the address of the STCTRL register
&amp;nbsp;&amp;nbsp;&amp;nbsp; //STCTRL = 7&amp;nbsp; enable timer and interrupt
&amp;nbsp;&amp;nbsp;&amp;nbsp; *p = 7;&amp;nbsp;&amp;nbsp; // store 7 into the STCRL by de-referencing p
&amp;nbsp;&amp;nbsp;&amp;nbsp; p = (unsigned int *)RELOAD;&amp;nbsp; // p is now set to the address of the RELOAD register
&amp;nbsp;&amp;nbsp;&amp;nbsp; //RELOAD = (FIRC / 100) - 1 = 40,000 - 1 = 39,999 = 0x9C3F
&amp;nbsp;&amp;nbsp;&amp;nbsp; // 10 mSec
&amp;nbsp;&amp;nbsp;&amp;nbsp; *p = 0x9C3F;&amp;nbsp; // store 0x9C3F into the RELOAD by de-referencing p

&amp;nbsp;&amp;nbsp;&amp;nbsp; p = (unsigned int *)FIO0DIR;&amp;nbsp; // p is now set to the address of the FIO0DIR register
&amp;nbsp;&amp;nbsp;&amp;nbsp; *p = LEDPIN;&amp;nbsp; // store (1&amp;lt;&amp;lt;22) into FIO0DIR by de-referencing p

&amp;nbsp;&amp;nbsp;&amp;nbsp; msTicks = 0;
&amp;nbsp;&amp;nbsp;&amp;nbsp; // enable all interrupts
&amp;nbsp;&amp;nbsp;&amp;nbsp; __asm volatile ("cpsie i");

&amp;nbsp;&amp;nbsp;&amp;nbsp; // Enter an infinite loop
&amp;nbsp;&amp;nbsp;&amp;nbsp; while(1) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; return 0 ;
}

void SysTick_Handler(void)
{
&amp;nbsp;&amp;nbsp;&amp;nbsp; msTicks++;

&amp;nbsp;&amp;nbsp;&amp;nbsp; if(msTicks &amp;gt;= (50)) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; msTicks = 0;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; unsigned int *p = (unsigned int *)FIO0PIN;&amp;nbsp; // p is now set to the address of the FIO0PIN register
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if(*p &amp;amp; LEDPIN) {&amp;nbsp; // de-reference p to obtain its value and mask it with (1&amp;lt;&amp;lt;22)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; p += 2;&amp;nbsp;&amp;nbsp; // move p up by two words (8 bytes) (since p is an unsigned int ptr), so it now points to the FIO0CLR register
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; } else {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; p++;&amp;nbsp;&amp;nbsp;&amp;nbsp; // move p up by one word (4 bytes) so it now points to the FIO0SET register
&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; *p = LEDPIN;&amp;nbsp; // store (1&amp;lt;&amp;lt;22) into which ever register was selected above by de-referencing p
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
}
&lt;/PRE&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;HTH &lt;SPAN class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;&lt;LI-EMOJI id="lia_slightly-smiling-face" title=":slightly_smiling_face:"&gt;&lt;/LI-EMOJI&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540380#M6922</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:09Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540381#M6923</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Thu Apr 21 22:48:07 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: jharwood&lt;/STRONG&gt;&lt;BR /&gt;HTH :)&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Immensely.&amp;nbsp; I'm sane again.&amp;nbsp; Like Zero once said "[B][COLOR=#ffb210]Pointers[/COLOR][/B] and structures, [B][COLOR=#ffb210]a[/COLOR][/B] [B][COLOR=#ffb210]never[/COLOR][/B] [B][COLOR=#ffb210]ending[/COLOR][/B] [B][COLOR=#ffb210]story[/COLOR][/B]....:)".&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;HAL: I'm feeling much better now Dave..&amp;nbsp; Daisy Daisy...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Larry&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540381#M6923</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:09Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540382#M6924</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by jharwood on Thu Apr 21 23:27:32 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: larryvc&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt; HAL: I'm feeling much better now Dave..&amp;nbsp; Daisy Daisy...&lt;BR /&gt; &lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm sure you already know this, but if not:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;HAL == I(-1) B(-1) M (-1)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;and&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;IBM == "I'm Bloody Mad"&amp;nbsp; :mad::)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540382#M6924</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:10Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540383#M6925</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Thu Apr 21 23:45:50 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;HAL yes. IBM, aren't we all a little bit.&amp;nbsp; We should get an opinion from an important mathematical place holder.:D&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540383#M6925</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:11Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540384#M6926</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Sat Apr 23 15:12:45 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;So far jharwood's implementation is still the most efficient.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I don't have enough knowledge yet to implement NXP_USAs suggestion but I'm working on it.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Anyone else up to the challenge?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I might have a spare board laying around for the individual that produces the smallest and most efficient working blinky.&amp;nbsp; It must be a perceptible blink to qualify.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540384#M6926</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:11Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540385#M6927</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by jharwood on Sat Apr 23 17:10:34 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Did some hacking^H^H^H^H^H^H^H code removal and ended up with this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;DIV class="j-rte-table"&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD bgcolor="#cacaca" style="border:1px solid black;background-color:#cacaca;"&gt; &lt;PRE&gt;
arm-none-eabi-size minblink.axf; arm-none-eabi-objcopy -O binary minblink.axf firmware.bin ; checksum -p LPC1769 -d firmware.bin;&amp;nbsp; cp firmware.bin c:/opt/tftp
&amp;nbsp;&amp;nbsp; text&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; data&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; bss&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dec&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; hex&amp;nbsp;&amp;nbsp;&amp;nbsp; filename
&amp;nbsp;&amp;nbsp;&amp;nbsp; 164&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 4&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 168&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; a8&amp;nbsp;&amp;nbsp;&amp;nbsp; minblink.axf
Created checksum 0xc67dffef in firmware.bin at offset 0x1c
&lt;/PRE&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/DIV&gt;&lt;SPAN&gt;- Took out all the data and bss section initialization stuff from both the c source, and the linker script.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- Combined all the exception fault handlers into one&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for the challenge Larry. I learned a lot &lt;SPAN class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;&lt;LI-EMOJI id="lia_slightly-smiling-face" title=":slightly_smiling_face:"&gt;&lt;/LI-EMOJI&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540385#M6927</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:12Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540386#M6928</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Sat Apr 23 20:18:25 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: jharwood&lt;/STRONG&gt;&lt;BR /&gt;Did some hacking^H^H^H^H^H^H^H code removal and ended up with this...&lt;BR /&gt;Thanks for the challenge Larry. I learned a lot :)&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;OK. I will allow one asm instruction, but if anyone can do this only in C great.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;You're welcome, and you are still in the lead James.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Had to sneak out of a birthday party to send this.&amp;nbsp; Be back later.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540386#M6928</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:12Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540387#M6929</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Sun Apr 24 01:09:36 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;jharwood,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I find the fact that you were able to get it down to 168 bytes, is extremely remarkable.:)&amp;nbsp; Using the reset ISR and omitting main is genius.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This shows that with the proper coding discipline we can cram a lot more into these devices than we previously thought and all while using C.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I'll let this challenge go on for another week.&amp;nbsp; I have my doubts that this can be beat.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Larry&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540387#M6929</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:13Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540388#M6930</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by jharwood on Sun Apr 24 09:11:34 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: larryvc&lt;/STRONG&gt;&lt;BR /&gt;....and all while using C.&lt;BR /&gt; &lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Technically, it's not a valid C runtime environment. The data section initialization has been removed, and the bss section has not been zeroed. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So while you could write &lt;/SPAN&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD bgcolor="#cacaca"&gt; &lt;PRE&gt;int foo[] = {1, 2, 3};&lt;/PRE&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;SPAN&gt; as a global variable, the results would not be what you expect. A global constant would be okay though.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You may notice that the very first half cycle (led off) after reset is of indeterminate length, but not more than 500 ms.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540388#M6930</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:14Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540389#M6931</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Sun Apr 24 10:09:04 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: jharwood&lt;/STRONG&gt;&lt;BR /&gt;Technically, it's not a valid C runtime environment. The data section initialization has been removed, and the bss section has not been zeroed.&lt;BR /&gt;&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Details.&amp;nbsp; It still blinks.:)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;So what do you think.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Should the parameters for the challenge be changed to require a valid C runtime environment?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Is one week pushing it for some of the others that might be interested in attempting this?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I haven't seen much other interest so far and I want this to be a fair challenge.&amp;nbsp; Should I start a new thread announcing a challenge and link to this thread?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;LPC1114 or LPC12xx for the winner.&amp;nbsp; I forgot which LPC12xx board is available.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Other ideas?:confused:&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540389#M6931</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:14Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540390#M6932</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by larryvc on Sun Apr 24 11:45:35 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Did I exceed the number of questions allowed on this weekend?:o&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Oh Oh.&amp;nbsp; That was another question.:)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540390#M6932</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:15Z</dc:date>
    </item>
    <item>
      <title>Re: Minimal Blinky in about 200 bytes</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540391#M6933</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by jharwood on Sun Apr 24 13:12:04 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: &lt;/STRONG&gt;&lt;BR /&gt;Should the parameters for the challenge be changed to require a valid C runtime environment?&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think so, yes. What has been proven so far is that the quotation you included in your first post is only possible if the validity of the C runtime environment is disregarded.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Tests show that it is possible to have a minimal program "doing something" (but not particularly useful) written in C, using only one assembler instruction to enable interrupts, in about 356 bytes.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You mentioned that you were stuck at around the 2k mark (which would be alarming when working with a device that had only 8k flash). I think that what you saw was caused by using the CMSIS library and a C standard library.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you need portability and maintainability of your application, you tend to use the standard libraries while keeping an eye on memory consumption. I find more often that RAM is more of an issue than flash. The SNMP mib tree is interesting as it is a complex data structure using flash as much as possible for the constant nodes and ram for the leaf and table row nodes.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm not really sure what would make a good challenge that would get enough interest and be simple and quick to accomplish.:(&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 21:54:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/Minimal-Blinky-in-about-200-bytes/m-p/540391#M6933</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T21:54:15Z</dc:date>
    </item>
  </channel>
</rss>

