I am basically using this https://github.com/googlesamples/android-vision with a few changes and it works perfectly on my android device.
Anyway, I would like to use it inside PhoneGap. The idea is to build the rest of the application in javascript/html/css and when pressed a specific button, start the android app.
Can this be done by someone who has never created a plugin before?
I would be grateful for any hint or tutorial on how to do it.
Of course it depends of your dev skills but I created myself my first plugin two months ago without being a Phonegap/Cordova expert, I'm a Java developer since 15 years but the most important thing is your motivation.
You first have to develop your basic Cordova app:
https://cordova.apache.org/docs/en/latest/guide/cli/index.html
Then your ressource to create a plugin will be here: https://cordova.apache.org/docs/en/latest/guide/hybrid/plugins/index.html
You will have to create one or few Java files as an adapter between your web app and your Jar code.
I found that the documentation was not enough for my case but I googled and used some dev blog articles and found some StackOverflow questions to help me.
Good luck!
Related
I'm working on a school project this semester and I want to try to program a Phantom 3 Standard to do some simple flight paths. Prior to acquiring the Phantom 3, I was playing around with Parrot's 2.0 AR Drone. I was able to write up a couple files using javascript and Node.js in order to help me program the drone for autonomous flight. I would like to do something similar with the Phantom 3, but it seems a lot more complex than just downloading something like Node.js (You have to sign up to be a developer on DJI's website and I don't think the SDK is easy enough for me to understand).
Does anyone have any recommendations on how to do this? Like I said, it would be optimal if programming the Phantom 3 could be as easy as it was to program the AR 2.0, which would be downloading something like node.js and running some scipts. Thank you!
You can choose to program for iOS or Android. Your mobile device will plug into the RC, and will be able to control the UAV as long as the RC controller is in autonomous mode. I will talk about the Android code, as I haven't used the iOS SDK, but I assume it's similar.
Creating a developer account is simple. You just put your information in on their website. The form only takes a minute to fill out. This data will be used in your manifest file. When your app starts for the first time, it will connect to DJI servers to verify your account.
The Android project has a sample application, which can get you started. You can download DJI's sample, and be up and running in 30 minutes (provided you know how to make Android apps).
In my own opinion, the DJI SDKs are EXTREMELY buggy. I have been using the Android SDK for over a year, and have briefly used their onboard SDK. Their code is sloppy, documentation incomplete, and support is non-existent. So, if you end up using DJI's SDK, you can be up and running in a short period of time, but expect that the only help you'll get is on stackoverflow.
The most simple way to start with DJI SDK is to use DJI UI Library.
https://github.com/dji-sdk/Mobile-UILibrary-Android
https://github.com/dji-sdk/Mobile-UILibrary-iOS
It is a suite of ready to use UI components. You just drop those UI elements into your Android or iOS application and they should work with DJI products.
Glhf
I am trying to start an android activity from my phonegap javascript file. I have seen a few post from years ago when DroidGap was still utilized. Does anyone know how to do this with the current updated version of phoneGap? Please do not point me to any posts that refer to the old version of PhoneGap.
What you probably want is a native plugin.
You can call your native code from within your JavaScript and then stat your activity as usual.
Documentation for plugins (for android) is located here.
I've been building Android apps for a few years now, and I've arrived to this working setup:
Intellij Idea IDE write/debug
Genymotion "Emulator"
Physical Device (only when needed)
Git
Ant (probably should move to Gradle) Release/Debug builds
And now I'm looking to form an equally productive environment for Javascript (Phonegap, etc), for Android/iOS/Win8Phone.
I want to avoid the "nice-text-editor-only" solution (I believe a full IDE is superior in productivity terms).
Any suggestions?
Try Brackets editor http://brackets.io/. It's a nice editor to code the web. Phonegap plugins also available for this editor. Just take a look at this editor. Make sure to download the version of Brackets with Phonegap Plugin compatibility.
For the Cordova/Phonegap app I developed, I used cloud9. In my workflow, I would first get things working in my browser, then occasionally do builds with Adobe's Phonegap Build service to work out the kinks on my mobile devices.
The nice thing about c9 is you'll have a public URL for the website you're developing so you can preview it in your device's browser, which is typically closer to the environment you'll get with Phonegap.
The weinre debugging tool, although slow if you're running it through http://debug.phonegap.com/, can really help track down problems when debugging on mobile devices.
This is a bit of an open-ended question, since I am just starting out on the project.
Problem: I have clients who cannot install web-browsers on their machines, and are stuck with IE6. The app we are selling them is a web-based app using a lot of javascript and jquery.
Solution: Implement a windows application that has a web-browser control based on webkit (since the regular webbrowser control is not going to support javascript and jquery), which loads the app.
I started doing research, and I found 2 controls:
https://code.google.com/p/open-webkit-sharp/
and
http://webkitdotnet.sourceforge.net/
I started off with the second one, and tried the sample app they built, only to discover that the version of webkit they used is really old and doesn't run our app right.
So my current solution is to compile webkit myself and include the newer version in the control and see how that works out.
Since this is a time-sensitive issue I thought I'd also ask for the experience of StackOverflow at the same time I am going down my route, to see if there is a simpler solution, or if there are any libraries or pre-built controls I could use that I missed in my search?
Thank you for any help!
Will it be possible to use the Google Analytics JavaScript library (https://developers.google.com/analytics/devguides/collection/gajs/) for the Windows Metro JavaScript based application to trace views accessed by user?
In general, if a JavaScript library you want to use is on a CDN or a server external to your app, the answer is no, as Windows apps written with HTML/JavaScript cannot load external JavaScript libraries...if you try, a security exception will occur.
Many libraries will work fine if you copy the JS file into your project and run it locally. For example, jQuery works just fine this way. I have not tried the Google Analytics library, so you might just want to test it out and see if it will work with a local copy.
Something else to consider, however, is that unlike a web site, a Windows app written in HTML/JavaScript may occasionally be offline, in which case, a library written with the assumption of network connectivity would likely not work. So in this particular case, you might not get the data that you're hoping for.
Hope that helps.
we tried http://w8ga.codeplex.com/ (w8ga) to work with GA in our win8 js app.
Currently W8GA seems doesn't support html/js. Also I have no idea why developer didn't mension it( it's supports only c#/xaml metro app )
So, we found another way to do it; Look for cobra Tab 's answer at the bottom of this page: http://social.msdn.microsoft.com/Forums/en-US/winappswithhtml5/thread/f81ebbb9-d711-40f1-8a82-9aed44e2d8fe/
And finally, we are waiting Adobe's Omniture sdk:
http://microsite.omniture.com/t2/help/en_US/sc/appmeasurement/winrt/index.html#Developer_Quick_Start
Hope these answers helps...
We're using the free version of markedup in our applications with great success. In addition to simple page views it shows you some app specific numbers like number of installs, exception details, etc.
I'd recommend using the Google Analytics SDK for Windows 8 and Windows Phone. It is built as a WinRT component and therefore supports both JS & Xaml Win8 apps.
Full disclosure: I am the author of this SDK; I built it for my own app and decided to open source it. There are other frameworks out there but AFAIK, none of them support the new GA universal analytics protocol so they only work with older GA properties and don't support all the cool new features GA recently added just for apps.