I have a Python script that I just about have perfected.
I had hoped to turn it into Java easily without having to know too much Java, my goal is to make this easily run on Android or iOS.
It is essentially a farming robot for a game I play with a bunch of friends. It is mainly working with Http requests but I know very little Java and I'm having a hard time even getting started. I see how to make a request but dont know enough about Java to decode a JSON return.
Any advice? I had thought about compiling with Jython but I'm not sure that will help me either. Im trying to keep this very simple and not use the Android python scripting which is a pain to setup. I did really want to walk every person through the setup on their phones.
Some information links
Some information about JSON in java here
Some information about http request here
Related
I was thinking about different ways to convert my android app to ios app without learning and writing code in obj C from scratch. So I thought about converting it to c# and using xarmarin, create the ios version of it.
I just wanted to know what's the best tool to convert java to c#. I know there is an old post but it's 10 years old, i was just wondering if there is an easy way to do that?
I think it will be difficult. Especially for all UI specific code. There are some solutions to convert some part of your code such as model, controller or business logic.
You can use Sharpen to convert Java to C#. But, it will be difficult to use it for UI part. And even, if you achieve this, you will obtain a Xamarin application that targets Android only.
Of course, it will be easier to port your application to iOS but you will have to rewrite all UI code.
You can still try Xamarin, by porting your non UI code and creating a Xamarin Forms application (it means new UI code to develop) which can then be deployed on iOS and Android.
I want to develop an app to track people's Whatsapp last seen and other stuff, and found out that there are APIs out there to deal with it, but the thing is they are writen in python and are normally run in Linux I think
I have Java and Android knowledge but not python, and wonder if there's a way to develop the most of the app in Java and get the info I want via calls using these python APIs, but without having to install a python interpreter or similar on the device, so the final user just has to download and run the Android app as he would do with any other
I want to know if it would be very hard for someone inexperienced as me (this is the 2nd and final year of my developing grade), for it's what I have in mind for the final project, thx in advance
Instead of running it as one app, what about running the python script as separate from the original script? I believe it would bee possible, as android is in fact a UNIX based OS. Any readers could give their input on this idea an if it would work.
I am trying to port an Android application to BlackBerry 10 and make it look naitive. I have written all the QML for the app but I cannot seem to get the code to work. Do I need to translate the Java into C++ and if I do, do I have to do it manually or would an automatic one do?
Also my application has many different classes which I am not sure how to integrate with the BlackBerry layout.
I am trying to port the open source messenger Telegram, if that's any use. http://telegram.org/source/
Assuming you want to do a proper port and know C++ and Java, a full rewrite would be best. You can probably copy a lot of code from the Java source, but there's no way an automated converter or direct copy would ever work in C++.
Most of the processes in BlackBerry are the same as in Android, all you'd really need to do is rewrite all the UI code and handlers to fit the BlackBerry Native SDK
I have an app in mind that will run various python scrpits.
But I have a problem running python scripts from my java code. I tried to use QPython, but I will have to start new intent to run my python code. That's not a problem but I have to close QPython intent manually to receive console output back to my app. That's not go. Also I looked at sl4a and its fork android scripting but I didn't find any examples of how can I do such a thing from my JAVA code. Thanks.
Try https://chaquo.com/chaquopy/
It does exactly what you need but their licensing process is very unfriendly.
I have the same issue and I'm still unable to find another solution, although because of the licensing, I'm not going to use it.
As an idea I'm thinking of making a service completely in python using kivy and all the rest in java, but I can't yet find an example.
There is a sampleproject which shows how to execute python scripts on your android devices.
https://github.com/qpython-android/AndroidApp-with-qpython-API
I'm trying to build a sound toy for Android, and I'm the most familiar with Processing for the visual side, which has been ported for Android. I want to use Puredata for sound, because at the moment it seems like the best option for dsp on Android. I've been told on the Processing forums that the best way to communicate with Processing through Puredata is to use TCP or UDP messages. I have no idea how to do this, because I am creating the .apk in the Processing environment and I don't see how I can launch the Puredata patch through Processing. Would this only be possible in pure Java? Or would I somehow have to launch a separate Puredata app at the same time. And are there any good resources for learning how to send TCP/UDP messages? Any help would be appreciated, and I can clarify if it makes it easier.
EDIT: It seems as if OSC uses the TCP protocol, so I'm not really sure why I can't use OSC. The only part I'm confused about is how to package the Processing sketch and the Puredata patch into one APK.
Thanks
I don't know the specifics of android platform development, but you would need to be able to run one app from within the other. This stack overflow question shows you how to do that. Once you have done that, you will be able to send commands over osc to you pd instance.
Another option would be using libpd. According to one of the devs, they are working on packing it up as a processing lib. If you wrote your visual code in c, then you would be able to link down to this libpd for your audio processing.