<?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>Sendchar error LPC2148</title><link>https://community.arm.com/developer/tools-software/tools/f/keil-forum/23153/sendchar-error-lpc2148</link><description> 
Hello, 

 
When I try to compile my program I get the following
error: 

 
&amp;#39;project.axf: Error L6218E: Undefined symbol sendchar (referred from retarget.o).&amp;#39;
 

 
I&amp;#39;ve tried to solve this error for quite a while now, but it
doesn&amp;#39;t work out. I&amp;#39;ve read</description><dc:language>en-US</dc:language><generator>Telligent Community 10</generator><item><title>RE: Sendchar error LPC2148</title><link>https://community.arm.com/thread/49262?ContentTypeID=1</link><pubDate>Tue, 15 Jan 2008 07:26:17 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:c6ba5d1c-d9a7-4f23-b972-c6ca519bd6dc</guid><dc:creator>Dani&amp;#195;&amp;#171;l Hoogendoorn</dc:creator><description>&lt;p&gt;&lt;p&gt;
Update:&lt;br /&gt;
Today we got the whole UART -&amp;gt; Terminal stuff working :)&lt;br /&gt;
We changed some things and with the help from a friend we got rid of
the errors.&lt;/p&gt;

&lt;p&gt;
Thanks for the feedback!&lt;/p&gt;

&lt;p&gt;
Kind regards,&lt;br /&gt;
Dani&amp;Atilde;&amp;laquo;l&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Sendchar error LPC2148</title><link>https://community.arm.com/thread/113575?ContentTypeID=1</link><pubDate>Mon, 14 Jan 2008 10:46:44 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:2ae4d63c-e8f4-40ad-863c-36de378721ee</guid><dc:creator>Dani&amp;#195;&amp;#171;l Hoogendoorn</dc:creator><description>&lt;p&gt;&lt;p&gt;
That&amp;#39;s true, but, just as I wrote, we&amp;#39;ve tried different codes, we
didn&amp;#39;t put them together :-)&lt;/p&gt;

&lt;p&gt;
And in my previous post I made a slight error.&lt;br /&gt;
It worked in the debug mode yesterday, then we continued editing the
code to make it working from the chip. And that&amp;#39;s where it went bad
and Keil started giving errors while compiling.&lt;br /&gt;
Well, today we&amp;#39;ve been busy trying to correct the code, but we didn&amp;#39;t
manage to do so, and that&amp;#39;s the reason I&amp;#39;m posting my problem on the
forum.&lt;/p&gt;

&lt;p&gt;
Again, you are right Andy, I&amp;#39;m a freshman.&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Sendchar error LPC2148</title><link>https://community.arm.com/thread/100143?ContentTypeID=1</link><pubDate>Mon, 14 Jan 2008 10:12:27 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:2c0d4b8d-ebd4-4ea5-b07b-add16ec52aae</guid><dc:creator>Andy Neil</dc:creator><description>&lt;p&gt;&lt;p&gt;
That&amp;#39;s what comes with wildly thrashing about and grabbing
whatever unrelated code you find next, instead of carefully reading
the message and thinking about what it&amp;#39;s telling you...&lt;/p&gt;

&lt;p&gt;
The first message, then, relates to the first piece of code - and
says that &lt;b&gt;sendchar&lt;/b&gt; is not defined.&lt;/p&gt;

&lt;p&gt;
The second piece of code contains no &lt;b&gt;main&lt;/b&gt; and,
unsurprisingly, gets an error saying that &lt;b&gt;main&lt;/b&gt; is not
defined!&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Sendchar error LPC2148</title><link>https://community.arm.com/thread/75902?ContentTypeID=1</link><pubDate>Mon, 14 Jan 2008 10:10:15 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:d8968a67-d871-4541-99a0-2af20ec1c588</guid><dc:creator>Dani&amp;#195;&amp;#171;l Hoogendoorn</dc:creator><description>&lt;p&gt;&lt;p&gt;
Thanks for the feedback.&lt;br /&gt;
Actually I&amp;#39;m very new indeed, but I&amp;#39;m trying my best to get this
working for my school project.&lt;/p&gt;

&lt;p&gt;
We&amp;#39;ve tried to define the sendchar function, but we simply didn&amp;#39;t
know how. Until now we only had to use delays and work with cases.
That went well, but this is different :-P&lt;/p&gt;

&lt;p&gt;
With help from a friend yesterday we got data echoed back, but
that only worked in the debug mode. So the program was fine, you&amp;#39;d
think. When we tried to connect the LPC2148 with a terminal, it
didn&amp;#39;t send anything back. So that was our poblem yesterday. But
today we were unable to get our program compiled, we obviously
changed something. We&amp;#39;ll work on it tomorrow and I hope to give you
some more details then.&lt;/p&gt;

&lt;p&gt;
Thank you for your time,&lt;br /&gt;
Kind regards.&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Sendchar error LPC2148</title><link>https://community.arm.com/thread/88804?ContentTypeID=1</link><pubDate>Mon, 14 Jan 2008 09:59:56 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:5d2781ff-6495-44dd-b0de-265350ca75d6</guid><dc:creator>ImPer Westermark</dc:creator><description>&lt;p&gt;&lt;p&gt;
I really do think this message has something with main() to do
:)&lt;/p&gt;

&lt;pre&gt;
schiet.axf: Error: L6218E: Undefined symbol main (referred from kernel.o).
&lt;/pre&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Sendchar error LPC2148</title><link>https://community.arm.com/thread/88808?ContentTypeID=1</link><pubDate>Mon, 14 Jan 2008 09:50:57 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:64ef40e3-9959-405f-99ec-e5b2d1505e30</guid><dc:creator>Andy Neil</dc:creator><description>&lt;p&gt;&lt;p&gt;
&lt;i&gt;&amp;quot;from your error message, I think that the problem is ...
because your main routine isn&amp;#39;t defined good.&amp;quot;&lt;/i&gt;&lt;/p&gt;

&lt;p&gt;
&lt;b&gt;No:&lt;/b&gt; the error message say that it is &lt;b&gt;sendchar&lt;/b&gt; that
is not defined at all!&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Sendchar error LPC2148</title><link>https://community.arm.com/thread/49259?ContentTypeID=1</link><pubDate>Mon, 14 Jan 2008 09:48:25 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:2f023803-b66a-4df7-9839-8ad9b7ccb6e6</guid><dc:creator>Andy Neil</dc:creator><description>&lt;p&gt;&lt;p&gt;
&lt;i&gt;&amp;quot;I&amp;#39;m new with the UART and I find it quite difficult to work
with.&amp;quot;&lt;/i&gt;&lt;/p&gt;

&lt;p&gt;
It seems that you are actually new to any sort of software
development, and this has nothing specifically to do with the
UART?&lt;/p&gt;

&lt;pre&gt;
extern int sendchar(int ch);
&lt;/pre&gt;

&lt;p&gt;
&lt;br /&gt;
Where is the definition of this &amp;quot;sendchar&amp;quot; function?&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Sendchar error LPC2148</title><link>https://community.arm.com/thread/49261?ContentTypeID=1</link><pubDate>Mon, 14 Jan 2008 08:05:18 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:dc8c154f-a639-4425-80cc-85ec940ced82</guid><dc:creator>Karel Vergauwe</dc:creator><description>&lt;p&gt;&lt;p&gt;
Hello,&lt;/p&gt;

&lt;p&gt;
from your error message, I think that the problem is not because
of the use of serial port, but because your main routine isn&amp;#39;t
defined good.&lt;/p&gt;

&lt;p&gt;
normally it should look like:&lt;/p&gt;

&lt;pre&gt;
/*----------------------------------------------------------------------------
 *        Main Function
 *---------------------------------------------------------------------------*/

int main (void) {
   /* Start with &amp;#39;init&amp;#39; task. */
   os_sys_init(init);
   while(1);
}
&lt;/pre&gt;

&lt;p&gt;
Here I use the RTX kernel, I start a proces to Init my device and
start the other processes.&lt;/p&gt;

&lt;p&gt;
All the rest is the same in my files (retarget, and
initialisation). You know you can use printf(&amp;quot;tekst&amp;quot;); now??&lt;br /&gt;
Does your code work without this code for serial communication???&lt;/p&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>