cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with RVDEBUG - Compile project (include, source,...)

gpoirier9
Associate II
Posted on June 14, 2006 at 08:08

Problem with RVDEBUG - Compile project (include, source,...)

5 REPLIES 5
gpoirier9
Associate II
Posted on June 05, 2006 at 08:27

Hi,

I work on RVDEBUG with RealView Ice and the eval-board STR710 (MB393B).

I tried to compile a project which is placed in a directory ''Project''. I have 2 sub directories :

-> the first ''include'' which contains all files .h (71x_lib.h, 71x_map.h,gpio.h,...)

-> the second ''source'' which contains all files .c and .s except main.c

My file main.c is placed in the main directory with the scatter file (.scf).

In my main.c file, I use predefined functions of the ''STR71x_library''. The main file begin with : #include

I created new project standart, I specified the sources files (main.c & all files in the ''sources'' sub directory).

Then, in the project setting, I customized the project :

-> I selected the scatter file (scf)

-> I edited the entry point and marked ''Reset_Handler''

-> I selected the directory ''.include'' in the COMPILE=Arm group & preprocessor

Then, I save and quit the project properties.

But when i try to ''Rebuild all'' my project, i have some errors and warnings saying that there are ''unknown identifiers'' (i.e : he don't know GPIO0 or functions of the STR71x_Library)

--------------

I have been able to create the project for the Example1 & 2 of the AN1774, and it works well but files are not the same and these examples don't use current files of the STR71x_Library, and now, I would like to use STR71X_Library (files .h and .c) in my projects with all theirs functions.

I think that problems comes from the project properties or settings when I create new project.

Thank you for your help !

[ This message was edited by: GP on 05-06-2006 11:59 ]

gpoirier9
Associate II
Posted on June 05, 2006 at 08:58

I have tested something else :

I have done a main.c file without instructions and then with just a simple instruction like this (GPIO0->PC0=0xFFFF;) :

#include ''71x_lib.h''

int main(void){}

I have done the same thing before with 2 sub-directories (include, source). In both cases, I have same errors.

When i ''Rebuild All'', I have following errors :

c:\progra~1\arm\rvct\programs\2.1\526\st\win_32~1\armlink --entry Reset_Handler --scatter 'd:\users\G-POIRIER\Documentation CAN _ STR710\Software Developement\Copie de Application_archi de base d'un projet\scat.scf Debug\main.o Debug\71x_it.o Debug\71x_lib.o Debug\adc12.o Debug\apb.o Debug\bspi.o Debug\can.o Debug\eic.o Debug\emi.o Debug\flash.o Debug\gpio.o Debug\i2c.o Debug\pcu.o Debug\rccu.o Debug\retarget.o Debug\rtc.o Debug\tim.o Debug\uart.o Debug\wdg.o Debug\xti.o Debug\71x_init.o Debug\71x_vect.o -o Debug\Testing.axf

Fatal error: L6002U: Could not open file CAN.

Finished: 0 information, 0 warning, 0 error and 1 fatal error messages.

make: Error code 129, while making 'Debug\Testing.axf'

*** Command exited with error or warning: 255

gpoirier9
Associate II
Posted on June 05, 2006 at 12:35

I have found my problems !

Some files where not at the right place in the directory or sub directory, and I have done some errors in the project properties. In the file ''71x_conf.h'', I only uncomment the GPIO, but in the project properties all sources files were include, so the building doesnt works !

It was just a few problems with the organisation of directory and sub-directory and their setup.

ewitt
Associate II
Posted on June 14, 2006 at 07:30

I have the same problem. Could you post your project settings and the directory structure?

cheers,

Erwin

gpoirier9
Associate II
Posted on June 14, 2006 at 08:08

First of all, you can download AN1774 on ST website if you don't have this. it's a good help in order to create a project. You must follow exactly the same steps than in AN1774.

Before you create a project, you must to do a directory structure where you choose organisation of your files. I have decided to do a main directory project, a sub directory ''include'' with all *.h files, and an other sub directory ''source'' for *.c files and *.s files. In the main directory, i have only the scatter file (*.scf), main.c and 71x_it.c files.

Then, you can create your project. You need just follow step of AN1774, but you must keep in mind to uncomment only peripherals that you use in your main.c (71x_conf.h) : if you are using only GPIO, you must uncomment only GPIO peripherals in the 71x_conf.h. If you forget to uncomment peripherals that you are using in you main.c, then ''Compilation errors''.

When you have done this, you must modify ''Project Settings''. You must include all *.c files than you want use (always main.c, retarget.c, 71x_it.c, 71x_init.s,71x_vect.s,71x_lib.c and if you use GPIO for example, you must include also gpio.c).

Then, in the window Project properties, in Compile=arm, on the ''include setting'', you select your repertory include. Then in Build, you type ''Reset_Handler'' on entry setting and you select your scatter file. Save and Close. Rebuild all.

And, I hope it works !!