Skip to main content
Visitor II
March 16, 2018
Question

Which libraries should I add to the project?

  • March 16, 2018
  • 1 reply
  • 776 views
Posted on March 16, 2018 at 20:36

Hello.

I'm trying to get started with stm8s series with IAR compiler that I'm not very good at.

So for the first project just trying to on and off a single LED to see if everything is ok or not.

I used Keil before this in ARM MCUs, that at first I the compiler asked me if I want to add the startup file or not.

So every time I pushed the yes button and everything was ok.

But IAR does not do this.

So I wanted to know what libraries should I add to the project?

I have to mention that I'm just using the registers and not any standard libraries.

The MCU I'm working with is an STM8S105k4t6.

    This topic has been closed for replies.

    1 reply

    Visitor II
    March 16, 2018
    Posted on March 16, 2018 at 21:19

    '

    So I wanted to know what libraries should I add to the project?'

    only add the ones that you need.

    Visitor II
    March 16, 2018
    Posted on March 16, 2018 at 21:59

    The problem is that I don't know which libraries are necessary and which are not.

    I just know that iostm8s.h is important because it has the register descriptions.

    I just wanted to know which are the necessity that without them the MCU will not work appropriately.

    Graduate II
    March 16, 2018
    Posted on March 16, 2018 at 22:26

    Include files are not inherently libraries.

    The compiler will not get closure if defines are missing.

    The linker will not get closure if the source and libraries do not provide code for all the functions which call each other.