cancel
Showing results for 
Search instead for 
Did you mean: 

application template auto generated code problem

Gzini.6
Associate II

I've a problem with the generation of the code for the application template. Following the steps, i've generate a blank code, but there's a weird problem, maybe something about linker.

In fact looking in Middlewares/ST/AI/AI/src/network.c there are a lot of syntax errors, like if the variables defined in "network.h" wouldn't be considered, even with #include "network.h".

besides, calling a function that is defined in network.h, like ai_network_create for example, i get this error "Undefined reference to ai_network_create".

With validation template i haven't any problems, i can load the network and validate it both from pc that on the board.

here the blank project:

https://drive.google.com/open?id=1uMNyChclq7Rt7NMQVxcdyMxSpfZNgoHN

here some errors in network.c

0690X000008aHpfQAE.png

1 ACCEPTED SOLUTION

Accepted Solutions
Gzini.6
Associate II

i've solved

the problem was in the code generation spec

i had to select True studio as IDE, uncheck Generate under root and select copy only the necessary library files.

in this way i was able to load and run an application template on my board without linker problems.

instead for validation template generate under root must remain selected.

View solution in original post

2 REPLIES 2
fauvarque.daniel
ST Employee

In the project properties can you verify that the include paths have been generated properly.

You should have something like

../Inc

../Middlewares/ST/AI/AI/include

../Middlewares/ST/AI/AI/data

then the regular HAL and CMSIS includes

Regards


In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Gzini.6
Associate II

i've solved

the problem was in the code generation spec

i had to select True studio as IDE, uncheck Generate under root and select copy only the necessary library files.

in this way i was able to load and run an application template on my board without linker problems.

instead for validation template generate under root must remain selected.