04-25-2012 12:30 PM
First off, the IDE can find my Playbook just fine, but it cannot find the simulator. I have tried different combinations of starting the simulator and IDE (in terms of order) as well as restarting my computer.
In the debug configurations target auto discovery does not find the simulator. I have tried manually entering the IP and development IP from the simulator as well but the IDE still cannot find it.
Solved! Go to Solution.
04-26-2012 05:14 PM
Do you have any firewall or VPN software running that could be blocking communication between the BlackBerry NDK and simulator?
04-26-2012 09:00 PM - edited 04-26-2012 09:10 PM
Hi, I do not have any VPN or firewall (or antivirus) software installed. Windows firewall is diabled. This is because I just recently in fact reinstalled Windows on this machine.
At any rate, I have solved my problem. I executed the blackberry-deploy script from the command line and discovered that Java was not in the PATH variable, so I added it. Now I was able to get blackberry-deploy to install the app from the command line successfully in the simulator. The IDE was still unable to auto-discover the device, but by creating the debug configuration with the target IP the IP in the simulator, I clicked through the error messages stating that it could not connect, hit the apply and OK buttons, and then in the project view lo and behold the error icon next to the simulator disappeared and I was able to debug happily from the IDE from there!
Thanks for your post, "blocking communication" made me wonder if the IDE was having trouble communicating with blackberry-deploy.
LESSON LEARNED: Make sure Java is in your PATH variable!
You know it is confusing to me how it was able to deploy to the device just fine, because I imagine that uses the same blackberry-deploy. Maybe it called a path/to/java instead of just "java" when deploying to the device, or maybe I'm going insane, or maybe the IDE just needs a gentle touch and randomly felt like working (and so maybe having Java in the PATH variable was not really the fix to this problem; I cannot say for sure)
04-30-2012 02:14 PM
Thanks for your followup message. I'm going to send this to our development team to improve on this type of configuration issue.
04-30-2012 02:33 PM
What OS are you using?
04-30-2012 03:55 PM - edited 04-30-2012 03:56 PM
I am using Windows 7 64 bit (Home Premium), and installed the 32 bit Java 7 update 3 JDK which didn't appear to automatically set the PATH variables.
Again I can't say for sure that this was necessarily an issue with Java being in the PATH; I just happened to notice a correlation with updating Java to be in my PATH and the IDE being able to connect to the simulator. Even so, it still cannot autodetect the simulator. Both simulator and NDK are for OS 2.0.1.
04-30-2012 04:13 PM
Thanks for the info. There are dependancies on Java, but in most cases it should make use of the JRE packaged with the NDK. I'll dig into this a bit further and see how we can make this easier in the future.
05-02-2012 10:38 AM - edited 05-02-2012 10:55 AM
Could you clearify what the exact path is you set? I have the Java folder, but in it is jre6 and in there is lib and bin, what is the path you added?
EDIT: Actually my problem was I wasn't building correctly, I needed to build for Simulator-Debug not default. ha silly mistake.