I will start a project ( not commercial, just for learning ) but I would like to choose to work with the right tools as I would if I were doing it for a company.
First of all small description of what I will need.
It would be a server-client(s) application.
For the server:
- GUI for Windows
- ORM
- Database without installation (sqlite ???)
- GUI builder (RAD Tool)
- Ability to create easily REST Services
Clients would be android devices
- GUI for android mobile
Clients would connect to the server and get some initial settings and then start to
send information to the server.
Server should be able to display properly the information collected from the clients and
edit them if needed.
Open source technologies are mandatatory.
First I am thinking to use sqlite ( I should not make any installation except the programm). Any alternatives here?
For the server maybe python with a gui library and sql alchemy. What about Camelot?
And for the clients (android) java. I think there are no other options here.
Can you make some comments on the above choices?
Maybe you can suggest something different which will make the development faster...
And for the clients (android) java. I think there are no other options here.
I'm no expert in the area, but below are some possible alternatilves for you:
C#: Mono for Droid (with MonoDevelop?)
http://monodevelop.com/Download/Mono_For_Android
https://stackoverflow.com/questions/tagged/monodroid?sort=votes
JavaScript: Titanium Appcelerator
https://wiki.appcelerator.org/display/guides/Home
https://stackoverflow.com/questions/tagged/appcelerator?sort=votes
Python: Kivy
http://kivy.org/docs/guide/quickstart.html#quickstart
https://stackoverflow.com/questions/tagged/android+python?sort=votes
For negative opinions on using such rapid-development frameworks, see, eg.
Appcelerator vs Android SDK
Of course such problems are not particular to the above frameworks... We couldn't rename a file atomically on Windows until the arrival of JDK7 which finally allows us to use MoveFileEx() (cf. Reliable File.renameTo() alternative on Windows? ). But you should always be careful on how to find an escape hatch :-)
As you have asserted: client is java only.
On server:
GUI for Windows : WPF
ORM - Database without installation : SQLCE 4.0 - Maybe use codefirst
GUI builder (RAD Tool) : Visual Studio lets you do that for WPF apps
Ability to create easily REST Services : Use WCF
hope that helps
Related
I am new to android programming and I wanted to create an application(vocabulary enhancer/words reminder which I already have for windows ) which pops up at certain time intervals to remind the words I saved earlier.
I thought android programming would be like programming windows which uses visual studio 6 or the latest.
I created a simple hello world program but it involved too many XML and other file references and inclusions.
Is there a way to create applications for android like win32 SDK using which we can create applications for windows. Like createwindows and other straight forward methods instead of having something like mfc or the one android programming uses ?
I have no idea what's "too many XML", other than a great name for a band.
If you're serious in your question, then I suggest you begin here: Comparisons of the Android framework's structure to the MFC/Win32's structure? and work your way forward.
Otherwise, I suggest you do form that band.
There is no equivalent to the Win32 API for Android. The closest you will get would be to talk to the (native) Linux OS. But that will only work if your device is rooted.
And that is the point. Something like the Win32 API would allow an Android app to do things that can interfere with other apps ... and compromise the security of the user's device.
I am learning python and i don't know that it will be helpful to me if i want to make android apps.I have read somewhere that python can make android app.But I want to ask you that is it a good option or we should always use andriod studio to make android apps because that is developed particularly for creating android apps.
I'm a core developer of Kivy, which has been mentioned in some of the other answers. I think it's the main option you have for making python apps for android, and it has both advantages and disadvantages.
The main technical disadvantages are (both in my opinion and I think the main problems I see people raise):
Startup speed: if the app isn't already running it takes a short time to spin up the python interpreter, up to a few seconds on older devices (or much longer if you code some things badly but that's avoidable), during which time a loading screen is displayed.
Lack of native look and feel: Kivy is its own opengl-based graphical framework, so it doesn't look like default android apps (it's customisable but still very hard to perfectly emulate something like that)
APK size: Because you have to package the python interpreter, the minimum apk size is about 7MB.
Ther are other potential disadvantages, such as the standard non-java problem of having to catch up the android api when it changes, but I consider these more minor issues, e.g. in this case since you can actually call much of the java api directly from python with pyjnius. I have a blog post about this. Another problem is that kivy's community is small compared to that of the java app community, though it's also quite active.
For some people, one or more of these are immediate or eventual barriers to using Kivy. For others they don't matter or are outweighed by the advantages, and for these reasons there are people using Kivy commercially on Android (and iOS). Personally I'm most interested in the wide space between 'I wrote a simple script' and 'I made a big polished android app', because I think it should be easier than it currently is to bundle simple things as simple apps, but that's just my own reason for using kivy.
If the question is,can i run python programs on android then by all means yes.
But if the intent is to create a mobile app usibg python then please look at kivy which is yet to support python 3.
But outside the love of python ,its best to stick to android studio for native android apps.
Chaquopy (https://chaquo.com/chaquopy/) is an option for Python on Android. It is a plugin for Android Studio so could include the best of both worlds - using the Android Studio interface and Gradle, with code in Python.
From the Chaquopy page:
With the Python API , you can write an app partly or entirely in Python. The complete Android API and user interface toolkit are directly at your disposal.
A in-depth review of Chaquopy is at http://blog.codelv.com/2018/02/a-look-at-chaquopy-python-sdk-for.html
The creator of Chaquopy also commented on that review with this:
I think there's room for many different approaches to Python on Android. Chaquopy focuses on giving complete access to all the features of the standard Android API and build tools. (For example, the XML layout file you mentioned was generated using Android Studio's WYSIWYG editor: it didn't have to be written by hand.) But if you want something more Pythonic, or portable to other platforms, then enaml-native or Kivy is the way to go.
CAVEAT: I have not (yet) tested this personally, so I cannot verify how well it works. It is rather complicated.
Additional: It appears to require a license key to run for more than 5 min and requires payment. If you decide to develop open source, there is an open source license which "will always be free of charge."
try kivy https://github.com/kivy/python-for-android
It can be used to create android apps.
Android doesn't come with a Python interpreter. So if you want to distribute an application written in Python, you will have to bundle a Python interpreter along with it. In other words, even a "Hello World!" app will be huge.
So yes, it's possible. But not recommended.
Yes you can using
1- Kivy library
2- install Ubuntu on a versatile machine
3- run buildozer to transfer your main.py file into APK file
I need to develop a portable application mainly for Windows 8.1 and iPad, but could be expanded for Android, WP and iOS later.
The application consists of calling web services to display data in grids and it contains CRUD operation, and it may save some local data for offline mode then synchronizes later when connectivity is up.
I'm torn between too many solutions, I need your advise for better solution.
1- Solution 1: Go Native for each OS (VS for Windows 8.1 [RT and pro] and xCode for iPad): this solution requires code duplication, logic and UI.
2- HTML5 with WebView app: I think this is a weak solution especially that we have local storage, checking for connectivity and calling ws ...
3- Using Xamarin: I think Xamarin does not support WinRT or Windows 8.1 to share logic code between iPad and Windows 8.1
4- Using Xamarin.Forms: Building the UI is tough and also it does not support Windows 8.1.
From your perspective, what is the best solution? please advices if you have any other proof of concept.
Many Thanks.
Most of the html/hibrid frameworks like Cordova (cordova.apache.org), Ionic (http://ionicframework.com/), etc, uses a native WebView on Android. Until Kitkat the performance of WebView is not production-ready and if you've a list with a lot of elements, the scroll experience is really bad.
If you want to do a simple proof of concept, prototype or whatever, I think that html frameworks are a good alternative. But if you are going to put your bussiness on top of one of this framworks, I would not recommend.
There is an alternative to embed a Chrome using Cordova & crosswalk (https://crosswalk-project.org/documentation/cordova.html) but you will end with an APK ~40Mb for a simple hello world.
Just my 2 cents. I don't see a point in using libraries that are unsupported across the platforms you plan to release and support on. Personally, I'd code natively for each platform. While this takes a lot of work, if you have to ask for direction on which path you want to take your application, then this type of project sounds more like a "you reap what you sow" application. Also, you'll be able to directly support each problem without having to wait for patches, but there are 2 sides to that coin as well. Your opportunity cost is missing future features the library will provide, if it's worth it to you.
If you aim at quality, going native is the only way... You can reduce the amount of work like Google is doing: writing the business logic and unit tests in Java, then converting it to ObjC with J2ObjC and to Javascript with GWT.
In your case, being that Java is a dumbed-down version of C#, you can easily find tools to convert to the latter, finding yourself with native business logic for every platform! That should account for 50%-70% of the codebase...
I think going with HTML5 with webapp view is better option.
Using Cordova (Phonegap) most of the native features are easily achievable in HTML webapp.
PhoneGap Platform Guide
Alot of other plugins are available for the advances features like BLE, NFC.
Calling webservice is really not an issue in HTML5.
Simple ajax is enough, however now a days many advanced frameworks are available which makes your work easy. One of the best among them is Angular JS(maintained by Google ).
Angular JS
For database you can access native database of the target OS or SQLite db of the mobile device.
You can check this link
Storage options
So developing a webapp can be a more efficient solution in your case. It can be best way for you as per my view point. However, you can do some R & D and can find the appropriate for you.
I am working on a project which can sync SQLite on Android app with MySQL on server. At first, my approach is:
-Create a periodic sync service to sync to MySQL via Restful API
-Sync algorithm: http://havrl.blogspot.ie/2013/08/synchronization-algorithm-for.html
-Using Retrofit lib: REST client for Android app.
But I am new to Android and I find it quite difficult to implement this approach. I found another solution: SQLite-sync Synchronization Framework - http://wiki.sqlite-sync.com/projects/sqlite-sync-com-synchronization-tool
This framework is based on Sencha Touch but my project is a native app.
-1: Is there any approaches to use this framework on my project smoothly with the existed SQLite database?
-2: If not, I have to develop sync module from scratch. Is my first approach OK ?
In additional, I have an OCR function on my project which recognize 7-segment number on 7 segment LCD panel using OpenCV. It recognizes well in virtual environment (black-white PC screen) but in actual environment (blood glucose monitor), it doesn't, because of contrast ratio, I thought. So, how can I improve quality of OpenCV 7-segment number recognition ? (contrast,etc) I have no idea of what to do.
you can go by the Sync algorithm you have mentioned in the link - http://havrl.blogspot.ie/2013/08/synchronization-algorithm-for.html
Use Rest APIs within Android sync adapter concept. Highly recommended as it has lot many advantages. Lot of plumbing code can be avoided
I have an iOS app in the Apple App Store. For the next big update I'm thinking about also creating an Android version of my app. In order to save development time, I got the idea to do the business logic and database access in C++ in order to use this layer on both platforms and only do the UI stuff using the API of the corresponding platform ( i.e. Objective-C/Cocoa touch for iOS and Java/Android SDK for Android).
What do you think of this approach from the Android point of view? Is it possible to access SQLite databases using C++ under Android?
Thanks & Regards,
Thomas
Keep in mind that you will need to use the NDK to run C++ code. Also, it is possible to compile SQLite with the NDK but that will take some work and possibly even some porting.
You will also have to write the wrappers in Java which is some additional work as well, albeit Android provides helpers for that.
And Marshalling between the native code and the app is not the most efficient process.
There are no SQLLite APIs (at least list time I looked) exposed in NDK but you should be able to take SQLLite as source package and include it into your application. If all your DB logic going to be in C++, you do not have to worry about interop with Java APIs.