<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.arm.com/utility/feedstylesheets/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/"><channel><title>Resetting Code / Timer Interrupt</title><link>https://community.arm.com/developer/tools-software/tools/f/keil-forum/22511/resetting-code-timer-interrupt</link><description> 
Hey all. We are having a weird issue on an LPC2148 part. Code
here: 

 
Main source file: 

 
#include &amp;lt;LPC214X.h&amp;gt;
#include &amp;quot;event.h&amp;quot;
#include &amp;quot;timer.h&amp;quot;
#include &amp;quot;PJstate.h&amp;quot;
#include &amp;quot;led.h&amp;quot;
#include &amp;quot;buffer.h&amp;quot;
#include &amp;quot;pc.h&amp;quot;

EVENTGROUP pjEvent =</description><dc:language>en-US</dc:language><generator>Telligent Community 10</generator><item><title>RE: Resetting Code / Timer Interrupt</title><link>https://community.arm.com/thread/130203?ContentTypeID=1</link><pubDate>Thu, 20 Sep 2007 15:11:05 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:0e8a4518-c3fe-4ae0-801c-17752635b53d</guid><dc:creator>Ryan Tolonen</dc:creator><description>&lt;p&gt;&lt;p&gt;
Revenge of the uninitialized default handler. Remember to
initialize VICDefVectAddr. Time to read about handling spurious
interrupts.&lt;/p&gt;

&lt;p&gt;
Thanks to the people who read/responded!&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Resetting Code / Timer Interrupt</title><link>https://community.arm.com/thread/124100?ContentTypeID=1</link><pubDate>Thu, 20 Sep 2007 12:58:53 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:479ffb2e-eef0-4425-b2f9-97af12b37858</guid><dc:creator>ImPer Westermark</dc:creator><description>&lt;p&gt;&lt;p&gt;
Some compilers warns about a superfluous &amp;amp;. Some compilers
don&amp;#39;t.&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Resetting Code / Timer Interrupt</title><link>https://community.arm.com/thread/113231?ContentTypeID=1</link><pubDate>Thu, 20 Sep 2007 12:01:07 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:9b62346d-ca8d-41a3-a43a-697198d3cb67</guid><dc:creator>Ryan Tolonen</dc:creator><description>&lt;p&gt;&lt;p&gt;
Guess I&amp;#39;ve never asked myself how &amp;amp;function_name should
behave. I would have thought that an error should have been generated
but know otherwise now. Learn something new every day. I&amp;#39;ve always
simply used the function name.&lt;/p&gt;

&lt;p&gt;
None the less, main issue still remains. =) Any suggestions?&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Resetting Code / Timer Interrupt</title><link>https://community.arm.com/thread/99688?ContentTypeID=1</link><pubDate>Thu, 20 Sep 2007 11:43:08 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:ed02206b-c0e8-4204-8f53-14cccc8bec13</guid><dc:creator>HansBernhard Broeker</dc:creator><description>&lt;p&gt;&lt;p&gt;
&lt;i&gt;Somewhat bizarre actually.&lt;/i&gt;&lt;/p&gt;

&lt;p&gt;
Actually, not at all. That&amp;#39;s how functions have to behave, as per
the definition of the language.&lt;/p&gt;

&lt;p&gt;
&lt;i&gt;Seems like a compiler bug to me.&lt;/i&gt;&lt;/p&gt;

&lt;p&gt;
On the contrary. Any &lt;b&gt;other&lt;/b&gt; behaviour would constitute a
bug.&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Resetting Code / Timer Interrupt</title><link>https://community.arm.com/thread/75522?ContentTypeID=1</link><pubDate>Thu, 20 Sep 2007 11:27:47 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:9477d000-ac89-4672-b5c6-c15a12f3e72b</guid><dc:creator>Ryan Tolonen</dc:creator><description>&lt;p&gt;&lt;p&gt;
Unfortunately if you&amp;#39;re referring to the &amp;#39;&amp;amp;&amp;#39;, this is not the
issue.&lt;/p&gt;

&lt;p&gt;
Somewhat bizarre actually. Both&lt;/p&gt;

&lt;p&gt;
VICVectAddr0 = (unsigned long)IRQ_Timer;&lt;br /&gt;
and&lt;br /&gt;
VICVectAddr0 = (unsigned long)&amp;amp;IRQ_Timer;&lt;/p&gt;

&lt;p&gt;
Compile to the same thing believe it or not!&lt;/p&gt;

&lt;p&gt;
SUB R0,PC,#0x00000034&lt;br /&gt;
STR R0,[R1,#-0x0F00]&lt;/p&gt;

&lt;p&gt;
I had noticed that before but as I know the code is getting to the
timer handler had assumed it was correct despite it looking
otherwise. Seems like a compiler bug to me.&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Resetting Code / Timer Interrupt</title><link>https://community.arm.com/thread/48635?ContentTypeID=1</link><pubDate>Thu, 20 Sep 2007 10:52:26 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:57d2662a-7aa2-4e7b-adda-8dc5eab9b089</guid><dc:creator>Patrick Noonan</dc:creator><description>&lt;p&gt;&lt;pre&gt;
        VICVectAddr0 = (unsigned long)&amp;amp;IRQ_Timer;
&lt;/pre&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>