Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
CodeVision AVR 1.25.7, user manual.pdf
Скачиваний:
236
Добавлен:
12.08.2013
Размер:
1.22 Mб
Скачать

CodeVisionAVR

2.2.5 Obtaining an Executable Program

Obtaining an executable program requires the following steps:

1.Compiling the Project’s C source files, using the CodeVisionAVR C Compiler, and obtaining an assembler source file

2.Assembling the assembler source file, using the Atmel AVR assembler AVRASM32.

Compiling, executes step 1.

Making, executes step 1 and 2.

For large projects Compiling make take a considerable amount of time.

In this case it is advisable to first Check the Project for Syntax Errors, which is much faster as no files are created during this process.

2.2.5.1 Checking the Project for Syntax Errors

To check all the Project’s files for syntax errors you must use the Project|Check Syntax menu command or press the Check Syntax button of the toolbar.

The checking process can be stopped using the Project|Stop Compilation menu command or by pressing the Stop Compilation button on the toolbar.

Eventual compilation errors and/or warnings will be listed in the Message window located under the Editor window, or in the Navigator window.

By double clicking on the error or warning message, the line with the problem will be highlighted. The size of the Message window can be modified using the horizontal slider bar placed between it and the Editor window.

© 1998-2007 HP InfoTech S.R.L.

Page 38

CodeVisionAVR

2.2.5.2 Compiling the Project

To compile the Project you must use the Project|Compile File menu command, press the F9 key or press the Compile button of the toolbar. The CodeVisionAVR C Compiler will be executed, producing an assembler source file with the .asm extension. This file can be examined and modified by opening it with the Editor.

The compilation process can be stopped using the Project|Stop Compilation menu command or by pressing the Stop Compilation button on the toolbar.

After the compilation is complete, an Information window will open showing the compilation results.

© 1998-2007 HP InfoTech S.R.L.

Page 39

CodeVisionAVR

Eventual compilation errors and/or warnings will be listed in the Message window located under the Editor window, or in the Navigator window.

By double clicking on the error or warning message, the line with the problem will be highlighted. The size of the Message window can be modified using the horizontal slider bar placed between it and the Editor window.

© 1998-2007 HP InfoTech S.R.L.

Page 40

CodeVisionAVR

2.2.5.3 Making the Project

To make the Project you must use the Project|Make menu command, press the Shift+F9 keys or press the Make button of the toolbar. The CodeVisionAVR C Compiler will be executed, producing an assembler source file with the .asm extension.

The compilation process can be stopped using the Project|Stop Compilation menu command or by pressing the Stop Compilation button on the toolbar.

Eventual compilation errors and/or warnings will be listed in the Message window located under the Editor window, or in the Navigator window.

By double clicking on the error or warning message, the line with the problem will be highlighted.

If no errors were encountered, then the Atmel AVR assembler AVRASM32 will be executed, obtaining the output file type specified in Project|Configure|C Compiler|Code Generation.

© 1998-2007 HP InfoTech S.R.L.

Page 41

CodeVisionAVR

After the make process is completed, an Information window will open showing the compilation results.

Pressing the Compiler tab will display compilation results.

© 1998-2007 HP InfoTech S.R.L.

Page 42

CodeVisionAVR

Pressing the Assembler tab will display assembly results.

© 1998-2007 HP InfoTech S.R.L.

Page 43

CodeVisionAVR

Pressing the Programmer tab will display the Chip Programming Counter, which shows how many times was the AVR chip programmed so far.

Pressing the Set Counter button will open the Set Programming Counter window:

This dialog window allows setting the new Chip Programming Counter value.

© 1998-2007 HP InfoTech S.R.L.

Page 44