Skip to main content
luis
Associate II
August 25, 2014
Question

Using templates with IAR

  • August 25, 2014
  • 4 replies
  • 1134 views
Posted on August 25, 2014 at 03:29

Hi everyone,

So i have started to use STM32 MCUs.

I used before Tiva MCUs with IAR and now i'm trying it with the ST.

I realy find hard to configure a project to work with the HAL drivers. You need always do so much each time you create a project. So i wanted to use the templates and just change the main.

Problem is everytime i copy it, it just doesn't find any of the files associated like HAL drivers.

Am i doing anytigh rong?

#project-templates-in-workbench
    This topic has been closed for replies.

    4 replies

    Andrew Neil
    Super User
    August 25, 2014
    Posted on August 25, 2014 at 12:08

    everytime i copy it, it just doesn't find any of the files associated like HAL drivers.

    Correct: It doesn't just find them - you have to tell it where they are!

    Obviously, if you copy a project without that information, then the copy is also not going to have that information!

    Look-up the documentation for includes paths, library paths, etc...
    A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.
    luis
    luisAuthor
    Associate II
    September 1, 2014
    Posted on September 01, 2014 at 17:27

    So what is the point of a template if i have to set it up every option, include, file if i copy it?

    I always take like 10-20min to set up at project and most of the times it doesn't work the includes even though i included the entire Cube.

    Montassar BEN ROMDHANE_O
    Visitor II
    September 1, 2014
    Posted on September 01, 2014 at 17:45

    Hi afonso.luis.001,

    I don't really have enough insight into what specifically you are doing, and how. Could you provide a little more information about the STM32Cube package you are using ?  

    Please note that you must copy the ''Templates'' folder at the directory hierarchy level.

    With regards.

    David Brooks
    Associate III
    August 6, 2015
    Posted on August 06, 2015 at 17:42

    I think I have the same question as Luis. I want to use Cube to configure my hardware. However, when the project is opened in IAR Workbench, I want that project to be pre-configured from a template with C-STAT and C-RUN settings, compiler and linker settings, etc. In fact, even if I don't use Cube, I still want to create a new project from a template.