1.Create a New Project

  • Open AndeSight
  • Select File > New > Project > Expand Andes Project by clicking the “+” icon, and select C project and press Next > input the project name in the next dialog and then click Finish

create_a_new_project.jpg





2.Editing

This step for the project is to create a C source code file and edit it, but AndeSight provides a pre-prepared example for you to add in the new project.

  • Select the project name and click the File > Import…
  • Select the File System and click Next

import.jpg

  • Click Browse and navigate the directory structure to <AndeSight-installed-path>\demo\hello, and then click OK
  • In the left window of the Import dialog, click the hello folder. The files inside the hello folder will be shown in the right window
  • Check the checkbox of the hello.c, and then click Finish.







3.Build

Select the project Hello you just created, right click to invoke the Build Project command. Builder will call Andes’ backend toolchains to create the make file and compile, link and at last generate the executable file. The compiler and linker have several options which could be configured by right-clicking the project selecting Properties.
build.jpg







4.Start GDBAgent and VEP

Before running your program/software, you need to set up the backend environment. For your convenience, Andes provides you GDBAgent to complete this task.

  • From Windows Start Menu Programs > Andestech > AndeSight > Cygwin, GDBAgent is started in Cygwin prompt by

%> GDBAgent –v none

  • Start Virtual Evaluation Platform (VEP) by selecting Advance > Start VEP from menu bar or clicking Start VEP icon vep.jpg from toolbar. The following VEP Manager shows the control GUI of VEP.

vepcontrol.jpg

  • Drag the general.vep file from Project Explore and drop to the space next to Select VEP Config

  • Press Start Simulator
  • AndeSight IDE will pass the vep file to VEP through GDBAgent. The SoC configured in the vep file will be run as the simulation target.







5.Target Setting

To run and debug the program, you need to specify the target before executing the program by the following steps:

  • Select Run > Debug… from menu bar, a Debug dialog is popup to let you set the VEP configuration, including the simulator of AndeScore and models of peripheral IPs. Select Cross Platform Application and press New button. A demo configuration will be created under Cross Platform Application.

debug.jpg

  • :?:Click the third tab Target on the right pane and click Auto Select button for selecting a VEP. You can select evaluation board VEP-1, VEP-2, or VEP SID-Simulator-1 from the Select Target dialog. Select SID-Simulator-1 for VEP and click OK to finish.

target.jpg

  • The Debug configuration dialog will be appearing and then click Debug button to run the selected project on the target.A dialog will pop up to confirm if you want the perspective to be switched as following picture. Click Yes, then AndeSight will automatically switch to Debug Perspective.

confirm.jpg







6.Debugging

  • The program will stop at the main() entry and a pointer locates at the line after main(). There are two views presenting different information of the source code. The execution could step in different formats, either in higher level C source code or lower level assembler, depending on your debugging needs. In the Debug view, icons at the tool bar are Run , Pause , Step into , Step over , and Terminate etc. The root of the content is the application, and the Cross Platform Debugger below the root indicates the target you specify in Target management section.







7.Profiling

  • To start the profiling, please switch the perspective from Debugger to Profiler first.

profiler.jpg

  • As you can see, project explore will be on your left hand side. Right click the project that was being debugged, and then select Profile As > Profile….
  • Profiling dialog will show and inherit the settings you just set in the debugging dialog, click Profile.
  • Trigger the Enable Source Profiling icon p.jpg to start the profiling.
  • Click Resume resume.jpg to run the program till finished, and then click p.jpg icon again to terminate profiling.
  • Now refresh the project explore, you will find prof.out generated in the profile folder.
  • Double click prof.out or click pp.jpg to show profiling results. In order to present detailed and clear profiling, we provide three views, which are timeline, call, and flat view.
 
andes/andes/development_steps.txt · Last modified: 2010/05/22 09:20 (external edit)
 
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki