In this tutorial, I would like to show you how to integrate Netbeans with your Intel Edison device. First, you must know the Java Runtime location, for your reference you may find in /usr/lib/jvm/java-8-openjdk/jre/.
Now, lets start:
1.
Create new project in your NetBeans
2.
Select categories java and project java
application
3.
For test connection, just type helloWorld in the
project name the most famous starter for learning programming and select your
project location.
4.
Once you complete step 3, then press “Finish”.
Now, start fill up your code by adding “System.out.println(“Hello World!!!)” as
it seen in the picture below
6.
To make it run on your remote machine you need
to configure your project properties, by right click mouse (for right hand
person) on your project name as seen in the picture below
7.
In dialog project properties, select categories
-> Run and press “New…” button. Create New Configuration dialog box will pop
up, then type your configuration name, to end it press “OK” button.
8.
Next, press “Manage Platforms…” button. When you
inside this dialog box, press “Add Platform…” button.
9.
Select platform type “Remote Java Standard
Edition” then press “Next” button.
10.
Type your Platform Name, Host, Username and
Password. Make sure you already configure your SSH using “configure_edison” command
in your device. Then type your Remote JRE Path ->
/usr/lib/jvm/java-8-openjdk/jre/ by default your Working Directory on your
remote machine is in /home/root/NetBeansProjects/ as seen below.
11.
Once, your press “Finish” button, Netbeans will
validate your configuration.
12.
Now, select “Runtime Platform” as seen in the
picture below and press “OK” button to complete.
13.
Now, try to run again. You will see, Netbeans
will run your application on remote machine as seen below
To see this application actually running on your machine,
you can check your working directory on your machine as you write it on step 10
“Working Dir” as you can see below
Now, you can start develop your application on Intel Edison
with Netbeans.
Have fun
No comments:
Post a Comment