Zigbee communication in depth
e. Go to the extra-libs folder and select the following files:
rxtx-2.2.jar
n
slf4j-api- x.y.z .jar
n
slf4j-nop- x.y.z .jar
n
f. Select Run in the left tree of the Properties dialog.
g. In the VM Options field, add the following option:
-Djava.library.path=<path_where_the_XBee_Java_Library_is_unzipped>\extra-
libs\native\Windows\win32
where:
<path_where_the_XBee_Java_Library_is_unzipped> is the absolute path of the
n
directory where you unzipped the XBee Java Library file (XBJL_X.Y.Z.zip)
Windows\win32 is the directory that matches your operating system and the Java
n
Virtual Machine installed (32 or 64 bits). If you don't know which Java Virtual Machine is
installed in your computer, open a terminal or command prompt and execute:
java -version
h. Click OK.
Step 6: Add the source code to the project
Follow these steps to add the source to the project.
1. Download and unzip the
2. Add the Java source file with Eclipse or NetBeans.
Option 1: Eclipse
a. Copy the files inside the zip file.
b. In the Package Explorer view, src folder inside the project and right-click.
c. From the context menu, select Paste.
d. Double-click each copied file to open in the editor.
e. A line at the top of the pasted files is underlined in red. Click on that line; a pop-up appears.
Select the first option (Move 'MainApp.java' to package '...') to resolve the error.
or
Option 2: NetBeans
a. Copy the files inside the zip file.
b. In the Projects view, select the Source Packages folder inside the project and right-click.
c. From the context menu, select Paste.
d. Double-click each copied file to open in the editor.
e. A line at the top of the pasted files is underlined in red. Click on that line; a pop-up appears.
Select the first option (Move class to correct folder) to resolve the error.
Step 7: Set the port name and launch the application
For this step, set the port name and launch the application.
XBee® Zigbee® Mesh Kit
ExplicitDataSample-src.zip
Examples: explicit data and ZDO
file.
173
Need help?
Do you have a question about the XBee Zigbee Mesh Kit and is the answer not in the manual?