Yes, i have no warnings during compilation. To compile i use sparc-rtems-gcc.<br><br>I can print from all the tasks except function calls that are declared in the library functions. I even manualy created a test function in the library just to print something and then exit(0) afterwards but still no luck. But it is strange since i get no warnings or errors during compilation. This is the output of the application, where "Load X" are successfully loaded threads.<br>
<br>Load 1--<br><br>Load 2--<br><br>Load 3<br><br>Load 3<br>Load 4<br>Load 5<br>Start GNC on wrapper<br><br>    ¬ÖUf<br>    ¬ÖUf<br>Program exited normally.<br><br>I don't see why it doesn't work, it is just a printf(), same as in all other tasks.<br>
<br><br>Best,<br>JM<br><br><div class="gmail_quote">On Wed, Jun 16, 2010 at 4:56 PM, Joel Sherrill <span dir="ltr"><<a href="mailto:joel.sherrill@oarcorp.com">joel.sherrill@oarcorp.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im">On 06/16/2010 10:52 AM, João Rasta wrote:<br>
</div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Hi,<br>
<br><div class="im">
No, autocode requires the real-time workbench only, it is quite straightforward to generate the code.<br>
<br>
I didn't fully understood your question. Anyway, i have tried to compile the application with gcc and runs fine on linux so it should run on rtems with the apropriate modifications. However, when i printf("test\n") within the library finction, it returns strange characters, which doesn't happen in the function that calls the library function..<br>

</div></blockquote>
Is it including stdio.h?  I have seen some targets where if you don't the variable<br>
arguments stuff gets confused.<br>
<br>
Is the generated code warning free?<div class="im"><br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
I suspect of a compilation flag/option i may be missing on the library. Do you have any idea?<br>
<br>
</blockquote></div>
As long as it is compiled the same as the rest of the app, it should be ok.<div class="im"><br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Also, i don't need any rtems primitives/configurations on the library functions right? I'm assuimng It is enough to have the rtems configuration on the "main" file.<br>
<br>
</blockquote></div>
Right.<br>
<br>
Can you print from other tasks?<br>
<br>
--joel<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
Best,<br>
JM<div><div></div><div class="h5"><br>
<br>
<br>
<br>
On Wed, Jun 16, 2010 at 4:42 PM, Joel Sherrill <<a href="mailto:joel.sherrill@oarcorp.com" target="_blank">joel.sherrill@oarcorp.com</a> <mailto:<a href="mailto:joel.sherrill@oarcorp.com" target="_blank">joel.sherrill@oarcorp.com</a>>> wrote:<br>

<br>
    On 06/16/2010 10:38 AM, João Rasta wrote:<br>
<br>
        Hi,<br>
<br>
        I'm having trouble running an rtems application that uses code<br>
        generated from matlab using autocode. It all goes well until a<br>
        function of this library is called: printfs return awkward<br>
        characters and then the application crashes.<br>
<br>
    I have seen references to this before.  Is this hard to do?  Are<br>
    there instructions?<br>
    Standard glue code, etc.<br>
<br>
        1) Is there any obvious reason to why printfs of the autocode<br>
        generated functions are not working properly? They are<br>
        compiled with sparc-rtems-gcc, as the main code.<br>
<br>
        2) Are there any special flags needed to be passed to the<br>
        compiler in order to link other libraries? Or some rtems<br>
        configuration..<br>
<br>
    Is there any chance it is printing floating point numbers from a<br>
    non-FP task?<br>
<br>
<br>
        Best,<br>
        JM<br>
<br>
<br>
<br>
    --     Joel Sherrill, Ph.D.             Director of Research&  Development<br>
    joel.sherrill@OARcorp.com        On-Line Applications Research<br>
    Ask me about RTEMS: a free RTOS  Huntsville AL 35805<br>
      Support Available             (256) 722-9985<br>
<br>
<br>
<br>
</div></div></blockquote><div><div></div><div class="h5">
<br>
<br>
-- <br>
Joel Sherrill, Ph.D.             Director of Research&  Development<br>
joel.sherrill@OARcorp.com        On-Line Applications Research<br>
Ask me about RTEMS: a free RTOS  Huntsville AL 35805<br>
   Support Available             (256) 722-9985<br>
<br>
<br>
</div></div></blockquote></div><br>