Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Kura » Kura Target Platform Error(Missing constraint Import-Package: Javax.microedition.io)
Kura Target Platform Error [message #1699282] Tue, 23 June 2015 08:46 Go to next message
Srinivas channakeshava is currently offline Srinivas channakeshavaFriend
Messages: 15
Registered: November 2014
Junior Member
When I create an example using the javax.micrioedition.io(ex:-serial communication) build fails throwing the java.lang.exception.
I found that this(java.lang.exception) was caused on importing this (javax.micrioedition.io) in the manifest.
Later I found some issue in the target platform which I have attached .
Missing constraints : Import-package; javax.microedition.io;version="0.0.0"
for kura.api and kura.core.comm

Please do help me in resolving the issue.

Regards,
Srinivas
Re: Kura Target Platform Error [message #1699386 is a reply to message #1699282] Tue, 23 June 2015 21:49 Go to previous messageGo to next message
David Woodard is currently offline David WoodardFriend
Messages: 420
Registered: July 2014
Senior Member
Hello Srinivas,

Did you follow this example [1] when creating your serial bundle? If not, I would encourage you to do so. Importing javax.microedition.io is a little tricky as it is provided by an Equinox bundle. One possible error is that you need to add "additional.bundles = org.eclipse.equinox.io" to your build.properties file.

I can't tell much by the screenshot you provided. A couple of things to check:

1. Did you open target-defnition/kura-equinox_3.8.1.target and click "Set as Target Platform"?
2. When importing Kura, did you import the "target-platform"? If so, you should delete it from your workspace. The only thing that you should import to your Eclipse workspace is under kura/kura, not kura/target-platform.

[1] http://eclipse.github.io/kura/doc/serial-example.html

Thanks,
--Dave
Re: Kura Target Platform Error [message #1699397 is a reply to message #1699386] Wed, 24 June 2015 04:21 Go to previous messageGo to next message
Srinivas channakeshava is currently offline Srinivas channakeshavaFriend
Messages: 15
Registered: November 2014
Junior Member
hello David,
1) I have followed the examples on kura and even worked on with external jars with kura in the intial releases for gpio and serialComm etc.

2) Currently I have integrated XMPP on the kura and that part is working fine and now I wanted to integrate to a project similar to Green House where reading sensor data via serial comm and tried to use the inbuilt library where am experience this issue.

3) I am using eclipse on windows ,Is it causing any issue?

4)Target platform I have imported the workspace as shown in the Hello world example.

Regards,
Srinivas

Re: Kura Target Platform Error [message #1699493 is a reply to message #1699397] Wed, 24 June 2015 15:00 Go to previous messageGo to next message
David Woodard is currently offline David WoodardFriend
Messages: 420
Registered: July 2014
Senior Member
Hello Srinivas,

WIndows should be okay. We don't regularly test or develop on Windows, but I will try to find a machine and test that today.

To be clear, there is no target-platform project in the Hello World example, there is a target-definition. In your workspace you should not see any of these projects:

target-platform
org.eclipse.soda.dk.comm
javax.usb.api
etc

You do want to see the target-definition project. This contains the *.target file used to setup your workspace.

Thanks,
--Dave
Re: Kura Target Platform Error [message #1699707 is a reply to message #1699493] Fri, 26 June 2015 04:15 Go to previous messageGo to next message
Srinivas channakeshava is currently offline Srinivas channakeshavaFriend
Messages: 15
Registered: November 2014
Junior Member
Yup, sorry it is target-defnition.
Import the target-definition . Set as target platform.
But facing issue in using JDK.io and javax.microedition.io , not able to build the project.
Missing constraints : Import-package; javax.microedition.io;version="0.0.0"
Java.lang.exception Sad

Regards,
Srinivas
Re: Kura Target Platform Error [message #1700058 is a reply to message #1699707] Mon, 29 June 2015 21:37 Go to previous messageGo to next message
David Woodard is currently offline David WoodardFriend
Messages: 420
Registered: July 2014
Senior Member
Hello,

Can you provide as much of the below information has possible:

1. A screenshot showing all projects in your workspace. They can be collapsed, I just want to see the project names.
2. The manifest file for the bundle you are trying to create.
3. All of the errors from your Eclipse workspace.
4. You mentioned you are not able to build. Is this a Maven build? If so, please provide the output of the maven build.

Thanks,
--Dave
Re: Kura Target Platform Error [message #1700078 is a reply to message #1700058] Tue, 30 June 2015 04:26 Go to previous messageGo to next message
Srinivas channakeshava is currently offline Srinivas channakeshavaFriend
Messages: 15
Registered: November 2014
Junior Member
Hi david,
Please do find the attached screenshots you requested.

regards,
srinivas

  • Attachment: 1.png
    (Size: 273.03KB, Downloaded 337 times)
  • Attachment: 2.png
    (Size: 191.57KB, Downloaded 380 times)
  • Attachment: 3.png
    (Size: 226.96KB, Downloaded 404 times)
  • Attachment: 4.png
    (Size: 189.29KB, Downloaded 303 times)
Re: Kura Target Platform Error [message #1700217 is a reply to message #1700078] Tue, 30 June 2015 21:43 Go to previous messageGo to next message
David Woodard is currently offline David WoodardFriend
Messages: 420
Registered: July 2014
Senior Member
Hello,

Thanks for the information.

1. Please make the import of javax.microedition.io optional:
javax.microedition.io;resolution:=optional

2. The jdk.dio error is a bug related to Windows. I will get that added as an item to fix for the next release.
3. For exporting, are you using "Quick Build" or "Export"? I would recommend Export for this case. When exporting, please make to check "Use class files compiled in the workspace" as described here [1].

[1] http://eclipse.github.io/kura/doc/serial-example.html#_Export_the_Bundle

--Dave
Re: Kura Target Platform Error [message #1700233 is a reply to message #1700217] Wed, 01 July 2015 05:19 Go to previous messageGo to next message
Srinivas channakeshava is currently offline Srinivas channakeshavaFriend
Messages: 15
Registered: November 2014
Junior Member
Hi David,
Even on UBUNTU I am facing same javax.microedition.io issue.

I had even tried making "resolution:optional".
If I make "resolution:optional" the build fails with error this log.

Regards,
Srinivas
  • Attachment: @dot.log
    (Size: 2.13KB, Downloaded 132 times)
Re: Kura Target Platform Error [message #1700318 is a reply to message #1700233] Wed, 01 July 2015 18:44 Go to previous messageGo to next message
David Woodard is currently offline David WoodardFriend
Messages: 420
Registered: July 2014
Senior Member
Hello,

That error is almost always caused by not selecting "Use class files compiled in the workspace". I have verified test bundles on OS X, Linux, and a Windows 7 VM. Please make sure:

1. Your build.properties files has:
additional.bundles = org.eclipse.equinox.io


2. When exporting:
Right Click project and select "Export"
Select "Deployable plug-ins and fragments", click "Next>"
Choose output directory for the bundle
Select "Options" tab and check "Use class files compiled in the workspace"
Click "Finish"

If this does not work, you will need to post the source code somewhere that I can view it.

--Dave
Re: Kura Target Platform Error [message #1700391 is a reply to message #1700318] Thu, 02 July 2015 11:20 Go to previous message
Srinivas channakeshava is currently offline Srinivas channakeshavaFriend
Messages: 15
Registered: November 2014
Junior Member
Hi David,
Thanks Exporting as deployable plugin worked , and I have attached the linux javax.microedition.io error screenshot.
I tried to use I2C and UART using JDK.IO where i am getting "jdk.dio.DeviceNotFoundException: Cannot get serial port name" Then i found out it's w.r.t permissions and I don't know where to find the **jdk.dio.properties** file.
Could you please let me know where i can find it.

regards,
Srinivas
Previous Topic:XMPP client to and Logging module to Kura
Next Topic:Export Plug-in throws Nullpointer Exception
Goto Forum:
  


Current Time: Sat Apr 20 14:46:01 GMT 2024

Powered by FUDForum. Page generated in 0.05058 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top