<?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>C code class info</title><link>https://community.arm.com/developer/tools-software/tools/f/keil-forum/14354/c-code-class-info</link><description> I am trying to use app note 138 with one exception, I want to relocate C code, not assembly .... 
 
I believe my source file name &amp;quot;sram_x.c&amp;quot; defines the section name as SRAM_X, my problem is defining the class name. Anyone know how to do this? 
 
Jeff</description><dc:language>en-US</dc:language><generator>Telligent Community 10</generator><item><title>RE: C code class info</title><link>https://community.arm.com/thread/53864?ContentTypeID=1</link><pubDate>Thu, 24 Jan 2002 22:11:19 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:c76ebdb8-09bb-4729-b78d-fe982606c2d6</guid><dc:creator>Jeff Eigner</dc:creator><description>&lt;p&gt;My source looked like this&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;reg161.h&amp;gt;               /* special function register C161    		*/&lt;br /&gt;
#include &amp;lt;srom.h&amp;gt;                 /* allows code relocation to SRAM    		*/&lt;br /&gt;
#include &amp;lt;intrins.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#pragma LARGE&lt;br /&gt;
#pragma RENAMECLASS(FCODE=SRAM_CODE)&lt;br /&gt;
&lt;br /&gt;
void wait (void)  {                   /* wait function */&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void sram_code(void) {&lt;br /&gt;
unsigned int i;&lt;br /&gt;
	while (1) {&lt;br /&gt;
		for (i=0;i&amp;lt;=0x40000;i++) {&lt;br /&gt;
			wait();&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
I remember seeing the error you posted and as I recall the port was not present on the C161, so I commented it out. Hope that helps.&lt;br /&gt;
&lt;br /&gt;
Jeff&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: C code class info</title><link>https://community.arm.com/thread/37850?ContentTypeID=1</link><pubDate>Thu, 24 Jan 2002 14:24:23 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:5fe7ca04-a512-4af8-9024-79dbf4bb3952</guid><dc:creator>Douglas  Hewett</dc:creator><description>&lt;p&gt;Have you solved this yet?&lt;br /&gt;
&lt;br /&gt;
My first step was to try to re-build the example flash.uv2 but I get compiler errors with respect to:&lt;br /&gt;
=== paste begin ===&lt;br /&gt;
compiling Srom.c...&lt;br /&gt;
C:\KEIL\C166\INC\REG167.H(370): error C155: &amp;#39;DP8&amp;#39;: invalid base address&lt;br /&gt;
C:\KEIL\C166\INC\REG167.H(381): error C155: &amp;#39;P8&amp;#39;: invalid base address&lt;br /&gt;
C:\KEIL\C166\INC\REG167.H(386): error C155: &amp;#39;ODP8&amp;#39;: invalid base address&lt;br /&gt;
assembling Pflash.a66...&lt;br /&gt;
Target not created&lt;br /&gt;
=== paste end ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: C code class info</title><link>https://community.arm.com/thread/37851?ContentTypeID=1</link><pubDate>Wed, 05 Sep 2001 10:45:27 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:405fa0de-f12b-4f87-a1ed-013cbb8558a0</guid><dc:creator>Jeff Eigner</dc:creator><description>&lt;p&gt;Ok, I found the answer in technical support (yet to be verified)&lt;br /&gt;
&lt;br /&gt;
check out:&lt;br /&gt;
&lt;a href="http://www.keil.com/support/docs/942.htm"&gt;http://www.keil.com/support/docs/942.htm&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Jeff&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>