This is a simple script written in Python for Android devices. I'm just learning Python but I hope this simple demonstration will inspire others to learn how to program. This has some XML mixed in with it.
This website will give more information on running Python with Android:
http://code.google.com/p/android-scripting/
Here is the link for the script:
http://db.tt/xbZwabUk
Here are some screenshots of the program in action but remember the screen brightness was turned all the way to 100% (or 255) by the script. The shot showing the console was initially a mistake I came across by typing a wrong value for the color but I liked it so it stayed. Now I'm working on a calculator program.
What did you use to compile the script
Into an app?
Sent from my SGH-T999 using xda premium
Ninosmaxima said:
What did you use to compile the script
Into an app?
Sent from my SGH-T999 using xda premium
Click to expand...
Click to collapse
After installing the app you have sl4a/scripts folder on sdcard.
Sorry let me rephrase...
OK so I make websites and I occasionally script.
How did you turn that script into an app, from a txt file to apk. is there a guide you followed?
Sent from my SGH-T999 using xda premium
I haven't converted this script yet for an .apk file. There is an easy way to convert it but it would require the user to install the Python 4 Android app in addition to the .apk of the script. There is also a way to compile the interpreter and script in one .apk for easy distribution.
This site will provide more info and Google also has a wealth of knowledge
http://code.google.com/p/android-scripting/wiki/SharingScripts#Scripts_as_APKs
Related
Sorry if this information is available already.. BUT is there a way to convert a .py to a .apk from the android phone or from the computer I'm sure there is but I don't know how and yes...I've checked on google
Sent from my Nexus One using XDA App
How do you mean converting .py to .apk? An .apk file is just a zip compressed archive with a certain file structure containing the compiled sources and your raw resources.
I'm quite certain that there is no way to just convert a Python script to a functional Android application.
If you instead meant that you are looking for an interpreter which interprets Python for example then yes there is a library called Bean shell.
okay thank you I was looking for a way to convert it but I guess it's okay is there a way to treat it as a market app.. where if I gave them a link with a barcode image that they can download it like a regular apk and perhaps give the option to install sl4a.. And how do you increase text size of the interpreter?
Sent from my Nexus One using XDA App
I found out how to convert it... It's in the sl4a wiki pages and requires eclipse, quite a bit of steps but it's possible
Sent from my Nexus One using XDA App
Legend28469 said:
I found out how to convert it... It's in the sl4a wiki pages and requires eclipse, quite a bit of steps but it's possible
Sent from my Nexus One using XDA App
Click to expand...
Click to collapse
Just wanted to add the link for the wiki as it's quite disorganized
https://code.google.com/p/android-scripting/wiki/SharingScripts#Scripts_as_APKs
so would this work with a project file made up using tkinter? ive got a script i want to build into an app but cant get kivy to work because of an issue with pygame and tkinter works fine
RandomKing's Android Kitchen
IMPORTANT NOTICES:
First and foremost, I will not be providing intricate and detailed directions with this.
This will remove almost any need to ever have to enter command-line code by simplifying everything into simple menus and performing the code for you!
I only take partial claim to this, as I've only written the over-arching interface and the smali/baksmali interface.
This is provided primarily for personal modifications. Please do not make a few minor changes to an existing rom and call it your own.
WHAT IS PROVIDED:
Quite simply, this is a menu-based interface coupled with nearly all of the .jars, packages, and files necessary for android development. Using this you can decompile/compile .apks and the vast assortment of features associated with this as well as baksmali/smali .dex files and even sign your .zips! This is the interface I currently personally use to streamline my edits combined into an easy installer. This will create a shortcut in your start menu, as well as provide an uninstaller. I'm always looking to streamline more!
Decompile framework-res.apk and systemui.apk for theming purposes!
Rebuild framework.jar to include the latest mod that your favorite rom just doesn't have!
Etc!
WHAT ELSE IS NEEDED:
Java [For functionality]
Gimp [For png and .9.png editing]
Winmerge [For easily identifying file changes]
Notepad++ [For smali and xml edits]
7zip Archiver [For creating/managing .zips]
A general knowledge of everything mentioned!
INCLUDED FEATURES:
Apk Manager 5.0.2 by raziel23x
-Zipalign
-Apk Tool
-More
Dex Manager 1.0.0 by RandomKing
-Smali
-Baksmali
AutoSigner by Stericson
DOWNLOADS:
>>Android Kitchen 1.0.4<<
>>Alternate Download<<
(Rename from '.bin' to '.msi'.)
CHANGELOG:
Version 1.0.4
-Removed rogue classes file (reduced install size)
-Fixed shortcut
Version 1.0.3
-Redesigned AutoSigner menu in line with overall menu
-New versions should install over old versions
-Version number shown in cmd header
-New splash screen
Version 1.0.2
-Added shortcut to kitchen folder for easier file management
Version 1.0.1
-Fixed issue with APK Manager not including requisite folders
KNOWN ISSUES:
-When using my Dex manager to Smali/Baksmali, it may say "File Not Found" and appear to work anyway. It will work anyway. All this indicates is that prior to performing its function it is removing a preexisting directory or classes.dex to avoid overwrite issues and that none currently exists.
-Sometimes baksmali will not properly perform, but running it again usually solves that.
I post this in 'General' under the assumption that most users in the 'Development' forum can do all of this and more without my help.
ScreenShots
Went down with my old site. PPCGeeks gave me no warning. Nice of them, right? Good thing I moved almost everything beforehand.
Nice work
Sent from my SPH-D700 using XDA App
Sweet! Well done! Thanks for sharing.
marcusant said:
Nice work
Sent from my SPH-D700 using XDA App
Click to expand...
Click to collapse
codest3r said:
Sweet! Well done! Thanks for sharing.
Click to expand...
Click to collapse
I figure, some people are daunted by command lines. Plus it can be tiresome. But even more so, some that want to try their hand at developing (the only way to learn it!) don't know where or what tools to find. I made this some time ago, and have been adjusting it ever since to my liking.
XDA is for sharing, right?
Awesome
sent from my cm7 touchwiz 4.5-ed epic
what do i do with the .bin file?
So can I compile 9.pngs with this instead of Eclipse? I couldn't get the Android plug-in to work on Eclipse...thanks.
Thanks, RandomKing, I've been thinking of creating some CMD line scripts. You just saved me the trouble!
Wow this is awesome! Thank you for all your hard work!
Sent from my ADR6300 using Tapatalk
kennyglass123 said:
So can I compile 9.pngs with this instead of Eclipse? I couldn't get the Android plug-in to work on Eclipse...thanks.
Click to expand...
Click to collapse
Yup, this is how I've been doing it for a while now.
AmericanJedi001 said:
Thanks, RandomKing, I've been thinking of creating some CMD line scripts. You just saved me the trouble!
Click to expand...
Click to collapse
The developers of ApkTool, and subsequently Apk Manager are the ones that gave me the idea... why not one cmd interface to rule all of my programming needs?
imtoomuch said:
Wow this is awesome! Thank you for all your hard work!
Sent from my ADR6300 using Tapatalk
Click to expand...
Click to collapse
No problem, I figured I'd finally made it as user-friendly as possible. I had a lot of trouble keeping all the necessary codes memorized, and smali edits to framework.jars was my biggest annoyance!
jpond83 said:
what do i do with the .bin file?
Click to expand...
Click to collapse
Change it from .bin to .msi. I'm not sure why it uploaded like that, I may put it in a zip.
that worked, thanks for sharing this, this is great
Hey guys I know I have posted some other similar programs, but hopefully this will raise the bar on how people use Android Debug Bridge.
So To start off, this program will not root any phone, but can easily break a phone if used improperly.
Secondly, If you need to ask what a button in the program THEN DO NOT USE IT!
I will only answer questions if they involve drivers or programming bugs, NOT for something like "What is Sync?" because If you do not know, then you do not need to know now.
SEE LINKS BELOW FOR MORE RECENT UPDATES!
This program has some built in ADB functions:
Rebooting- Recovery/Bootloader/Fastboot.
Sync from a folder (If you don't know or have to ask do not use!)
Use logcat
Start up a shell instance (With root if possible.)
Remount (Needs root also)
Flash(Recovery/Boot.img)
Root SOME devices(Using Bin4ry Script Credit to him)
Auto Download Root script
adb shell built in now
cmd shell built in
automatic updates
push files
install apks
get misc system information
Download ODIN for Samsung devices
Detect HTC device correctly for once lol
Application Manager
ADB Learning Center (Under Construction but not beta)
4.0-4.3 Backup Manager (Using adb backup NOT Nandroid)
0Nandroid intergration
Build.PROP veiwer (Soon to be editor too!)
Free device ram and kill background process
MORE TO COME!
___________________________________________________________________
Also a BIG thing for this program is the ability to install ADB and Fastboot into Windows as a command in Command Prompt.
This would allow one to use adb as a normal command from CMD.
E.G "C:\Users\Lab\>adb shell"
Instead of having to CD to C:\android\and all that.
Download the program: Version 5.0.2.26:New Download link[/COLOR]
As far as the newest huge feature in ADBGUI goes, the Application Manager is to be considered Pre-beta and should be used with extreme caution.
Requirements for the Application Manager:
> You need root
> It only works with 3rd Party (Downloaded from google play or other source)
> It does not work with all devices and has some major bugs.
Come on guys give some feed back!
Well enjoy!
Have questions or maybe want to report an issue?
Check out my Discussions Forum here otherwise you can post here at XDA Forums
About ClickOnce:
The core principle of ClickOnce is to ease the deployment of Windows applications. In addition, ClickOnce aims to solve three other problems with conventional deployment models: the difficulty in updating a deployed application, the impact of an application on the user's computer, and the need for administrator permissions to install applications.
ClickOnce-deployed applications are considered 'low impact', in that they are installed per-user, not per-machine. No administrator privileges are required to install one of these applications. Each ClickOnce application is isolated from the other. This means one ClickOnce application is not able to 'break' another. ClickOnce employs Code Access Security (CAS) to ensure that system functions cannot be called by a ClickOnce application from the web, ensuring the security of data and the client system in general.
Some other thinks about ClickOnce:
My ClickOnce application is personally signed, so windows will tell you the publisher is "Unknown" but that is OK. It will install just fine.
[UPDATE Nov. 21st 2013]
Hey guys!!
Just wanted to share some news for all you linux users!
I will be starting a linux conversion for ADBGUI to be fully compatible with Ubuntu/Debian/Arch Linux Distros!
Details: Click Here!
Looks great! Will try as quickly as possible.
Sent from my U20i using xda app-developers app
Is this ADB GUI project open source?
I think this is a really cool idea. Might also help get more users into ADB and willing to learn what things do. (sometimes it's scary when thinking of command line)
Shifted from the bottom of the rabbit hole
thronnos said:
Is this ADB GUI project open source?
I think this is a really cool idea. Might also help get more users into ADB and willing to learn what things do. (sometimes it's scary when thinking of command line)
Shifted from the bottom of the rabbit hole
Click to expand...
Click to collapse
I will be posting the source on github but it is written in VB.NET. I am also happy to answer questions about the source code.
Required program for the source is
visual studio 2012.
Sent from my SCH-R530U using xda premium
Just updated to version 2
Read about it at urgero.org/node/5
Sent from my SCH-R530U using xda premium
Hey guys!!
Just fixed a bug in ADBGUI about a file not found.
Download Fix
Can also be found Here
Fixed bug with version 2.1:
Would still try to download, even if you selected no.
and added Android Device Discovery
currently working on adding an option to browse sd card and to get device information and battery levels.
Tonight around 11pm central time I will be uploading the source code for this project.
Sent from my SCH-R530U using xda premium
UPDATE:
Check out the new updates at http://urgero.org/node/5!!
Added rooting scripts!!
With downloader (No need to hunt down the scripts!!)
Just updated to 2.4!
added:
Automatic updates!!
Over 400 dpwnloads and no one has anything to comment about?
Sent from my SCH-R530U using xda premium
sandix said:
Over 400 dpwnloads and no one has anything to comment about?
Sent from my SCH-R530U using xda premium
Click to expand...
Click to collapse
Sorry, bro, I thought the same after releasing my first few works... Sadly, that how it seems to be.
To the tool: I think its awesome, haven't had any problems so far. Don't give up!
Sent from my U20i using xda app-developers app
Thank you!
Does anyone have any feature requests?
Sent from my SCH-R530U using xda premium
Just Updated to V2.6:
Added F-Droid for all you Open Source fans!
Also fixed a bug where applications would not install correctly for some devices(Still does not fix all of them)
Download: http://urgero.org/node/5
If you already have 2.4 or higher, just launch the program as administrator and it will prompt you to update, otherwise download 2.4 aat the link above to upgrade to 2.6!
sandix said:
Thank you!
Does anyone have any feature requests?
Sent from my SCH-R530U using xda premium
Click to expand...
Click to collapse
Can you add a file manager to see from your tool all the folders and modify them and files
Inviato dal mio GT-I9070 con Tapatalk 2
I am currently in the process of doing so yes.
Sent from my SCH-R530U using xda premium
Does not work on mine. Dont know why.
it says: "is not valid s Win32."
Please help.
i have winxp 32 bit.
Make sure you run as administrator and that all the files are extracted from the archive. Also make sure they are all in the same folder.
If you could post a screenshot that would be great help
Sent from my SCH-R530U using xda premium
mr_itou said:
Does not work on mine. Dont know why.
it says: "is not valid s Win32."
Please help.
i have winxp 32 bit.
Click to expand...
Click to collapse
I for got to add:
You NEED .NET Framework 4.5, download from microsoft here
Hey guys, i need help porting apps from one android device to another like apps from LG Optimus 2x to LG optimus one or porting stock apps to cyanogenmod or porting xperia, samsung apps to non xperia(or non samsung) devices. I dont intend to make it for commercial use like posting on playstore. I just want it include on roms and make it such a way that other devs can include it on their roms. I have basic C++ knowledge and Im learning java on my own!
Normally you can just compile the app and add it to your work with the right copyright notice as long as your device/ROM is the minimum API level which is required.
How can i compile a app from source, which is already compiled like stock keyboard for xperia making it work on non xepria or LG optimus 2X Launcher for LG optimus one!
Edit: I'm new at this!
Sent from my LG-P690 using xda app-developers app
ayazm.140895 said:
How can i compile a app from source, which is already compiled like stock keyboard for xperia making it work on non xepria or LG optimus 2X Launcher for LG optimus one!
Edit: I'm new at this!
Sent from my LG-P690 using xda app-developers app
Click to expand...
Click to collapse
So have you got the sources? If you do, select File -> Import -> Existing Android code into workspace in Eclipse.
If you have already got a compiled app why don't you use that one?
If you mean resizing the images, rename the compiled apk to a .zip file. Then you can browse the content. Afterwards rename it to .apk.
nikwen said:
So have you got the sources? If you do, select File -> Import -> Existing Android code into workspace in Eclipse.
If you have already got a compiled app why don't you use that one?
If you mean resizing the images, rename the compiled apk to a .zip file. Then you can browse the content. Afterwards rename it to .apk.
Click to expand...
Click to collapse
I have got no sources. It's a stock application. I have to make it work on other device by resizing the images and make them work on other devices (may be low end device of same company or different company!)
Sent from my LG-P690 using xda app-developers app
ayazm.140895 said:
I have got no sources. It's a stock application. I have to make it work on other device by resizing the images and make them work on other devices (may be low end device of same company or different company!)
Sent from my LG-P690 using xda app-developers app
Click to expand...
Click to collapse
Ok. Try what I described:
If you mean resizing the images, rename the compiled apk to a .zip file. Then you can browse the content. Afterwards rename it to .apk.
Click to expand...
Click to collapse
I know I should modify the apk but what files like xperia has some file which checks the device for xperia device. What are the dimensions for mdpi device. What are the files should I modify in a keyboard to make it work on other device!
Sent from my LG-P690 using xda app-developers app
I'm a beginner in AndroidModding, and the ways that I have found so far are boring (as well as my ability to describe my project).
Basically, I'm developing a visual tool to facilitate mods creation. I know there are already some, but I intend to make a better base for beginners as I don't make crap.
I'll leave out some screen shots and when I make the program more stable I'll upload a first test version.
I wish everyone who has any idea about what I can add in the project manifest and suggest the same. At the end I will give credit to all who help me improve things.
And also, if you guys think this is will be useless please tell me this too
[Change log]
14/10/13
Working features:
-Create and manage Devices and ROMs
--Auto framework change 90% complete
-Create multiple projects of same APK
-Import an APK via dialog box to avoid mistake at folder arrange
-Decompile, Build, Auto META-INF PATCH, Recompile and ZipAlign just at one click for each function.
-Shortcut to working folders
-Debug output
-Set zipalign compression option
Features i'm working on:
-Auto change framework for different devices
-Auto mod scripting
-Translation features
-Pull/Push files via ADB
Features that I already tought about:
-Multi-Framework capability: Switch between frameworks to mod apps of different Roms and devices without complication.
-Project creation: Create a new independent mod with just one click without losing your previous project.
-Auto patch: Select a Mod in a list, choose your preferences and watch while program do the hard work for you.
-Create a auto patch youself: If you are already experient and want automate your mods, you can create a list of actions to auto apply into an apk.
-Create a Zip file to install in recovery mod
-Default stuff to ApkTool like decompile, build, recompile, blabla
[add 06/10/13 18:30]
-Adb pull/push: send or get files from your phone by adb connection
-Smali code autopatch support
ps: I don't know speak english as well, so, sorry about any mistake
This is good and seems fun
will wait for a test release
Will it be Open Source ?
Then we could improve your work by submitting patches
Pixelvernichter said:
Will it be Open Source ?
Then we could improve your work by submitting patches
Click to expand...
Click to collapse
Its a good idea, I'll think aboit it
Sent from my GT-I9100 using xda app-developers app
Also, if you need an tester for your tool I have time and i would do it
That tool will be great for a nope like me thanks
Sent from my GT-I9100 using xda app-developers app
shfddi being
:good:
i'll help to test if u want to..
Live log would be good. To watch as phone boots into an inevitable bootloop when trying something new. Saves running log separately and lets you view as it happens. With filtering would be good. Adbmagic did something similar but you cant copy or search the log.
Sent from my GT-I9305 using Tapatalk 4
Solved!Does anyone know if a xml like instead when inner value is empty interferes something or just make file bigger? I mean to Android, because I know their same thing.
Also, who wants help me making me an logo? I was thinking about an android with Merlin's costume, but I don't have the skills to reproduce this
Goldieking said:
Live log would be good. To watch as phone boots into an inevitable bootloop when trying something new. Saves running log separately and lets you view as it happens. With filtering would be good. Adbmagic did something similar but you cant copy or search the log.
Sent from my GT-I9305 using Tapatalk 4
Click to expand...
Click to collapse
That's a good idea, i'll try implement that, thanks
Sent from my GT-I9100 using xda app-developers app
SkyaTura said:
Does anyone know if a xml like instead when inner value is empty interferes something or just make file bigger? I mean to Android, because I know their same thing.
Also, who wants help me making me an logo? I was thinking about an android with Merlin's costume, but I don't have the skills to reproduce this
That's a good idea, i'll try implement that, thanks
Sent from my GT-I9100 using xda app-developers app
Click to expand...
Click to collapse
Bump !
Logo in progress
( Android with Merlin Costum. lol xD )
New changes at thread!!!
I pretend to release a beta version this week yet
Pixelvernichter said:
Bump !
Logo in progress
( Android with Merlin Costum. lol xD )
Click to expand...
Click to collapse
Can we see a preview of our MerlinDroid?
(i would be annoying if i ask an icon version?)