This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Difference between programming stellaris with IAR and CCS

Hi,

I have the Stellaris Launchpad (LM4F120H5QR) board. I don't have the CCS software. Instead, I have the IAR embedded workbench installed. Since the workshop files uses code composer studio, I followed those examples in IAR. But it complains about the SysCtl function even after including all the needed header files.

However, when I use ROM_SysCtl, It works fine. My question is, what is the difference?

I understand that the driverlib is burned into the controller ROM, and we are calling the function/specifying that it can be found in the ROM by specifying as ROM_ before the function (correct me if I am wrong). My question is,

1. How can CCS compile with out the ROM_ prefix while IAR cannot?

and

2. Are the "Stellaris Launchpad" inputs 5v tolerant as given in the workshop workbook?

 

Thanks.

  • Hi,

    Even with CCS, without the ROM_ prefix the compiler will generate error. Declaring the #include file is not enough - it provides only the declaration of the function(s) (it's shape, to allow the compiler to generate proper calls to that function), while to operate you need the definition of the function (i.e the body = it's content), which is only in the *.c file. ROM_ calls provides direct links to "the body" (direct is by means of some tables...). Calling without prefix means calling the function from driverlib folder, so you need to compile/make the library before it's use...

    Yes, (only) the inputs are 5V tolerant... 

    Petrei

  • Hi,

    Thanks for clearing my doubt, but I cannot understand the final part of the answer. Do you mean that, when we compile the driverlib library, and use the function, we need not include the ROM_ prefix?

     

    And what is the significance of the "only" in the second answer?

    Thanks

     

  • Hi,

    Always you can have two kind of driver libraries: one is embedded in special ROM area on chip; the other one can be compiled and loaded in flash, same space with the application. So you can use either ROM_xxx function, either xxxx function from the library and which will reside in flash (on old LM3S StellarisWare that was the case).

    The "only" is to highlight only inputs, some people extend that also to output, which is not the case.

    Petrei 

  • Hi Petrei,

    Thanks for your valuable answers.

     

    Bye