So I'm trying to compile x893's example code on v0.0.12 IDE and I keep getting this error:
In function 'void setup()':
error: invalid conversion from 'const char*' to 'const signed char*'
It is coming from the Task Handle "LEDx" 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?
<br />
#include <MapleFreeRTOS.h></p>
<p>int ledPin = 22; // LED connected to digital pin 13</p>
<p>static void vLEDFlashTask( void *pvParameters ) {<br />
for(;;) {<br />
vTaskDelay( 2000 );<br />
digitalWrite( ledPin, HIGH );<br />
vTaskDelay( 200 );<br />
digitalWrite( ledPin, LOW );<br />
}<br />
}</p>
<p>// The setup() method runs once, when the sketch starts<br />
void setup() {<br />
// initialize the digital pin as an output:<br />
pinMode(ledPin, OUTPUT);</p>
<p> xTaskCreate(<br />
vLEDFlashTask,<br />
"LEDx",<br />
configMINIMAL_STACK_SIZE,<br />
NULL,<br />
tskIDLE_PRIORITY + 2,<br />
NULL<br />
);<br />
vTaskStartScheduler();<br />
}</p>
<p>void loop()<br />
{<br />
// Insert background code here<br />
}<br />