Hi,
I created a "clean" RMS Project where I want to execute the JavaScript APIs and NOT Ruby APIs, where I have modified the build.yml to include extensions "rho-javascript" and also enable "gps" in features. Furthermore, I setup the app.js with the dependant js-libs (jquery, json, angularjs, ionic, rho-libs) - and in the order I saw in a Rho documentation (I can try to find the page telling which order to load js-files, if needed). Nevertheless, I get errors when I try to obtain some of the Rho GeoLocation methods (e.g is_known(), longitude() and latitude()).
The main errors I get are:
"The file /app/RhoJavaScriptApi/command_handler was not found" and "JSON Parse Error"
I have attached a screenshot of the rholog.txt. Furthermore, I have also added a screenshot of the source code of how we are trying to invoke the Rho GeoLocation APIs.
We are using RMS v.5.3.2 and have also included the pre-APIs (you can see in the log which order they are loaded).
Can anybody say why we do not receive the floats or why the call-back for the set_notification only is triggered once (but with no params - seems undefined).
Thanks,
Rubathas
2 Replies
Here is a simple geolocation app, that I used for another customer issue.
Hi Rubas,
A few suggestions:
1) Debugging on WinMo is kind of a pain with using log files. I would suggest you either use Weinre and do remote inspection. Or use the inspector.cab that we have for Enterprise browse (make sure to compile Rho in debug mode). EB instructions: Enterprise Browser 1.3 (go to Using Remote Debug Inspector section)
2) Try using the API outside of your Angular/Ionic to ensure the syntax is correct (I would recommend you use embedded function as call back instead of calling a function name)
Rho.GeoLocation.set_notification( function(cbobj){ console.log(cbobj)}, "", 10)
Also try changing interval to something besides 0.