Personal tools

Log in

Changes

From IGEP - ISEE Wiki

Jump to: navigation, search

How to develop with Eclipse IDE under IGEP Technology

5,979 bytes added, 09:52, 31 December 2013
m
Requirements
'''under construcion'''
 
= Overview =
There are some requisites to follow this guide:
*[httphttps://www.isee.biz/componentsupport/zoodownloads/item/igep-virtual-machine-sdk-yocto IGEP SDK VM]: follow the [http://isee.biz/component/zoo/item/igep-sdk-software-user-manual IGEP&nbsp;SDK&nbsp;SOFTWARE&nbsp;USER&nbsp;MANUAL] (chapter 2.3 "Setting up and running the VM") or install [[How to install Eclipse IDE|Eclipse IDE]]<br> in your host computer *[httphttps://www.isee.biz/products/igep-processor-boards IGEP Processor Board] *MicroSD Card (optional: If you want to upgrade your IGEP board has Poky Firmware) = Pre-installed software on *[http://labs.isee.biz/images/c/ca/Eclipse_examples.tar.bz2 Eclipse Examples] (with IGEP Processors Boards =&nbsp;SDK VM is not necessary, there are included)
''(from [[= Pre-installed software on IGEP Processors Boards]])'' =
''(from [[Pre-installed software on IGEP Processors Boards]])'' {{#lst:Pre-installed software on IGEP Processors Processor Boards}}
= Using Eclipse IDE =
== Open program ==''(from [[How to install Eclipse IDE]])'' {{#lst:How to install Eclipse IDE|shortoverview}}
== Create and Build projects ==
 
You can create two types of projects on Yocto Eclipse IDE Plug-in: Autotools-based, or Makefile-based. The IGEP SDK Virtual Machine provides already some examples that can be used as a template for your project. The examples are:
 
*'''C_example''', autotools-based “Hello World” program written in C.
*'''Cairo_example''', generates a png file named hello.png.
*'''Cpp_example''', autotools-based “Hello World” program written in C++
*'''Dbus_example''', sends "Hello Wolrd!" using D-Bus message system.
*'''Glib_example''', simple “Hello World" written using Glib library.
*'''Gstreamer_example''', ogg audio player using Gstreamer.
*'''Gtk_example''', Hello World in GTK.
*'''C_example_without_autotools''', makefile-base “Hello World” program written in C.
 
=== Import examples ===
 
'''NOTE:''' These steps are not necessary if you use IGEP SDK VM, examples are included by default
 
*[http://labs.isee.biz/images/c/ca/Eclipse_examples.tar.bz2 Download] examples
*Located your downloaded file, in my case is inside /home/Downloads:
<pre>jdoe@ubuntu ~ $ cd Downloads/</pre>
*Extract binaries:<br>
<pre>jdoe@ubuntu ~/Downloads tar jxf Eclipse_examples.tar.bz2 -C ~/ </pre>
*Go to File menu -&gt; Import...
*Select General -&gt;Existing projects into workspace<br>
*Locate examples and finish the assistant
 
{| cellspacing="1" cellpadding="1" width="200" border="1"
|-
| [[Image:Eclipse import1.PNG|331px]]
| [[Image:Eclipse import2.PNG|331px]]
|-
| [[Image:Eclipse import3.PNG|331px]]
| [[Image:Eclipse import4.PNG|331px]]
|}
 
'''<sup>Click to enlarge image</sup>'''
=== Build an autotools-based project ===
 
To create your own project based on a Yocto template and then display the source code, follow these steps:
 
*Select File menu-&gt; New -&gt; Project.
*Double click C/C++.
*Double click C Project or C++ Project to create the project.
*Expand Yocto ADT Project.
*Select a template
*Select Hello World ANSI C Autotools Project or Hello World C++
*Autotools Project. This is an Autotools-based project based on a Yocto Project template.
*Put a name in the Project name: field. Do not use hyphens as part of the name.
*Click Next.
*Add information in the Author and Copyright notice fields.
*Be sure the License field is correct.
*Click Finish.
*If the "open perspective" prompt appears, click "Yes" so that you in the C/C++ perspective.
*The left-hand navigation pane shows your project. You can display your source by double clicking the project's source file.
 
{| cellspacing="1" cellpadding="1" width="200" border="1"
|-
| [[Image:Eclipse newproject1.png|250px]]
| [[Image:Eclipse newproject2.png|250px]]
| [[Image:Eclipse newproject3.png|250px]]
|-
| [[Image:Eclipse newproject4.png|250px]]
| [[Image:Eclipse newproject5.png|250px]]
| [[Image:Eclipse newproject6.png|250px]]
|}
 
'''<sup>Click to enlarge image</sup>'''
 
== Set up a connection between IGEP and Host computer ==
 
In IGEP SDK VM is configured by default in Eclipse IDE 192.168.5.1 IP adress for IGEP. If you want use another IP address you should do a new connection configuration.
 
''(from [[How to install Eclipse IDE]])'' {{#lst:How to install Eclipse IDE|setup_connection}}
== Run programs remotely ==
 
Once you have compiled your program, use the following steps to run programs remotely:
 
*Select Run menu-&gt; Run Configurations...
*In the left area, expand C/C++Remote Application.
*Locate your project and select it to bring up a new tabbed view in the Run Configurations Dialog.
*Enter the absolute path into which you want to deploy the application. Use the Remote Absolute File Path for C/C++Application: field. For example, enter /usr/bin/&lt;program name&gt;.
*Select Remote Connection
*If field is empty search your C/C++ Application
*Use other option as you want like program arguments or commands to execute before application run
*Finally run your program
 
{| cellspacing="1" cellpadding="1" width="200" border="1"
|-
| [[Image:Eclipse run1.png|331px]]
| [[Image:Eclipse run2.png|331px]]
|-
| [[Image:Eclipse run3.png|331px]]
| [[Image:Eclipse run4.png|331px]]
|}
 
'''<sup>Click to enlarge image</sup>'''
== Debug programs remotely ==
 
Once your program can run in your IGEP device you debug your application. Follow these steps to debug the application.
 
*Select Run menu-&gt; Debug Configurations...
*In the left area, expand C/C++Remote Application.
*Locate your project and select it to bring up a new tabbed view in the Debug Configurations Dialog.
*Enter the absolute path into which you want to deploy the application. Use the Remote Absolute File Path for C/C++Application: field. For example, enter /usr/bin/&lt;program name&gt;.
*Select Remote Connection
*If field is empty search your C/C++ Application
*Use other option as you want like program arguments or commands to execute before application run.
*Click Debug
*Accept the debug perspective if it’s not the default perspective.
 
{| cellspacing="1" cellpadding="1" width="200" border="1"
|-
| [[Image:Eclipse debug1.png|250px]]
| [[Image:Eclipse debug2.png|250px]]
| [[Image:Eclipse debug3.png|250px]]
|-
| [[Image:Eclipse debug4.png|250px]]
| [[Image:Eclipse debug5.png|250px]]
| [[Image:Eclipse debug6.png|250px]]
|-
| [[Image:Eclipse debug7.png|250px]]
| [[Image:Eclipse debug8.png|250px]]
| [[Image:Eclipse debug9.png|250px]]
|}
 
'''<sup>Click to enlarge image</sup>'''
= Other uses =
== Explore IGEP filesystem remotely == You can manage your IGEP files using Remote System Explorer:  *Launch a remote terminal *Import/Export files *Rename files and folders *Copy, Paste, Delete, Cut ... *etc. {| cellspacing="1" cellpadding="1" width="200" border="1"|-| [[Image:Eclipse remoteIGEP1.png|331px]] | [[Image:Eclipse remoteIGEP2.png|331px]]|-| [[Image:Eclipse remoteIGEP3.png|331px]] | [[Image:Eclipse remoteIGEP4.png|331px]]|} '''<sup>Click to enlarge image</sup>'''
4,199
edits