<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>LeafLabs Garden &#187; Topic: FreeRTOS xTaskCreate() compile error</title>
		<link>http://forums.leaflabs.com/topic.php?id=1117</link>
		<description>A place to share, learn, and grow...</description>
		<language>en-US</language>
		<pubDate>Fri, 22 Jan 2016 00:18:54 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.2</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://forums.leaflabs.com/search.php</link>
		</textInput>
		<atom:link href="http://forums.leaflabs.com/rss.php?topic=1117" rel="self" type="application/rss+xml" />

		<item>
			<title>kaipyroami on "FreeRTOS xTaskCreate() compile error"</title>
			<link>http://forums.leaflabs.com/topic.php?id=1117#post-6945</link>
			<pubDate>Sat, 22 Oct 2011 09:58:06 +0000</pubDate>
			<dc:creator>kaipyroami</dc:creator>
			<guid isPermaLink="false">6945@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;Thank you Richard!&#60;br /&#62;
It worked!&#60;/p&#62;
&#60;p&#62;&#60;code&#62;&#60;br /&#62;
xTaskCreate(&#60;br /&#62;
        vLEDFlashTask,&#60;br /&#62;
        (const signed char *) &#34;LEDx&#34;,&#60;br /&#62;
        configMINIMAL_STACK_SIZE,&#60;br /&#62;
        NULL,&#60;br /&#62;
        tskIDLE_PRIORITY + 2,&#60;br /&#62;
        NULL&#60;br /&#62;
        );&#60;br /&#62;
&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;FYI the IDE is a Precessing/Arduino Clone so it is very limited.&#60;br /&#62;
&#60;a href=&#34;http://leaflabs.com/docs/ide.html&#34; rel=&#34;nofollow&#34;&#62;http://leaflabs.com/docs/ide.html&#60;/a&#62;&#60;br /&#62;
I would probably have to use a makefile to change settings like that if the compiler even allows it.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>FreeRTOS.org on "FreeRTOS xTaskCreate() compile error"</title>
			<link>http://forums.leaflabs.com/topic.php?id=1117#post-6944</link>
			<pubDate>Sat, 22 Oct 2011 06:11:15 +0000</pubDate>
			<dc:creator>FreeRTOS.org</dc:creator>
			<guid isPermaLink="false">6944@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;I don't know exactly what this forum is, what hardware you are using, or which compiler you are using, but the error you report should (if using standard development tool chains) generate a warning, not an error.  It comes from the fact that the FreeRTOS coding standard does not allow unqualified plain char types, only explicit signed char or unsigned char types.  &#60;/p&#62;
&#60;p&#62;In this case, the parameter to xTaskCreate() is expecting a const signed char *, but it seems your compiler is such that unqualified char types default to being unsigned.  To fix that, either change the compiler options (most embedded compilers will allow unqualified chars to default to either signed or unsigned), or simply cast the parameter to the correct type, so instead of writing&#60;/p&#62;
&#60;p&#62;&#34;LEDx&#34;&#60;/p&#62;
&#60;p&#62;by itself, write&#60;/p&#62;
&#60;p&#62;(const signed char *) &#34;LEDx&#34;&#60;/p&#62;
&#60;p&#62;this uses standard C syntax, and you might even be able to leave the const off if you really want to, and the warning level of the compiler is set to not be too pedantic.&#60;/p&#62;
&#60;p&#62;Regards,&#60;br /&#62;
Richard.&#60;br /&#62;
&#60;a href=&#34;http://www.FreeRTOS.org&#34; rel=&#34;nofollow&#34;&#62;http://www.FreeRTOS.org&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>kaipyroami on "FreeRTOS xTaskCreate() compile error"</title>
			<link>http://forums.leaflabs.com/topic.php?id=1117#post-6939</link>
			<pubDate>Fri, 21 Oct 2011 12:41:16 +0000</pubDate>
			<dc:creator>kaipyroami</dc:creator>
			<guid isPermaLink="false">6939@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;I was not using the command line tool chain I will attempt it tonight. Thank you!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>poslathian on "FreeRTOS xTaskCreate() compile error"</title>
			<link>http://forums.leaflabs.com/topic.php?id=1117#post-6929</link>
			<pubDate>Thu, 20 Oct 2011 22:45:15 +0000</pubDate>
			<dc:creator>poslathian</dc:creator>
			<guid isPermaLink="false">6929@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;oops - FreeRTOS cant be used from within the IDE. You will need to use the command line toolchain. Ostensibly, you should be able to get it working from the IDE but to my knowledge this has not been done. &#60;/p&#62;
&#60;p&#62;If you are using the command line toolchain, you can find a freertos example in libmaple/examples
&#60;/p&#62;</description>
		</item>
		<item>
			<title>kaipyroami on "FreeRTOS xTaskCreate() compile error"</title>
			<link>http://forums.leaflabs.com/topic.php?id=1117#post-6872</link>
			<pubDate>Fri, 14 Oct 2011 21:03:26 +0000</pubDate>
			<dc:creator>kaipyroami</dc:creator>
			<guid isPermaLink="false">6872@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;For reference:&#60;/p&#62;
&#60;p&#62;&#60;code&#62;&#60;br /&#62;
portBASE_TYPE xTaskCreate( pdTASK_CODE pvTaskCode,&#60;br /&#62;
   const signed char * const pcName,&#60;br /&#62;
   unsigned short usStackDepth,&#60;br /&#62;
   void *pvParameters,&#60;br /&#62;
   unsigned portBASE_TYPE uxPriority,&#60;br /&#62;
   xTaskHandle *pvCreatedTask&#60;br /&#62;
   );&#60;br /&#62;
&#60;/code&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>kaipyroami on "FreeRTOS xTaskCreate() compile error"</title>
			<link>http://forums.leaflabs.com/topic.php?id=1117#post-6871</link>
			<pubDate>Fri, 14 Oct 2011 20:54:45 +0000</pubDate>
			<dc:creator>kaipyroami</dc:creator>
			<guid isPermaLink="false">6871@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;So I'm trying to compile x893's example code on v0.0.12 IDE and I keep getting this error:&#60;br /&#62;
&#60;code&#62;&#60;br /&#62;
 In function 'void setup()':&#60;br /&#62;
error: invalid conversion from 'const char*' to 'const signed char*'&#60;br /&#62;
&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;It is coming from the Task Handle &#34;LEDx&#34; name. When it is set to NULL everything will compile fine. Is there any reason that the function xTaskCreate() needs a const signed char instead of a const char? (other than the fact that that is how the OS is written) Or does anyone see any other solutions?&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;br /&#38;gt;
#include &#38;lt;MapleFreeRTOS.h&#38;gt;&#38;lt;/p&#38;gt;
&#38;lt;p&#38;gt;int ledPin =  22;    // LED connected to digital pin 13&#38;lt;/p&#38;gt;
&#38;lt;p&#38;gt;static void vLEDFlashTask( void *pvParameters ) {&#38;lt;br /&#38;gt;
    for(;;) {&#38;lt;br /&#38;gt;
        vTaskDelay( 2000 );&#38;lt;br /&#38;gt;
        digitalWrite( ledPin, HIGH );&#38;lt;br /&#38;gt;
        vTaskDelay( 200 );&#38;lt;br /&#38;gt;
        digitalWrite( ledPin, LOW );&#38;lt;br /&#38;gt;
    }&#38;lt;br /&#38;gt;
}&#38;lt;/p&#38;gt;
&#38;lt;p&#38;gt;// The setup() method runs once, when the sketch starts&#38;lt;br /&#38;gt;
void setup()   {&#38;lt;br /&#38;gt;
  // initialize the digital pin as an output:&#38;lt;br /&#38;gt;
    pinMode(ledPin, OUTPUT);&#38;lt;/p&#38;gt;
&#38;lt;p&#38;gt;    xTaskCreate(&#38;lt;br /&#38;gt;
        vLEDFlashTask,&#38;lt;br /&#38;gt;
        &#38;quot;LEDx&#38;quot;,&#38;lt;br /&#38;gt;
        configMINIMAL_STACK_SIZE,&#38;lt;br /&#38;gt;
        NULL,&#38;lt;br /&#38;gt;
        tskIDLE_PRIORITY + 2,&#38;lt;br /&#38;gt;
        NULL&#38;lt;br /&#38;gt;
        );&#38;lt;br /&#38;gt;
    vTaskStartScheduler();&#38;lt;br /&#38;gt;
}&#38;lt;/p&#38;gt;
&#38;lt;p&#38;gt;void loop()&#38;lt;br /&#38;gt;
{&#38;lt;br /&#38;gt;
    // Insert background code here&#38;lt;br /&#38;gt;
}&#38;lt;br /&#38;gt;&#60;/code&#62;&#60;/pre&#62;</description>
		</item>

	</channel>
</rss>
