June 27, 2012 By: Jimmy McGee
Building off the foundations of Linux knowledge begun by XDA TV Producer Jordan, XDA Elite Recognized Developer and XDA TV Producer AdamOutler teaches you more commands and tips to use Linux for Mobile Development. But first, AdamOutler introduces his latest music video and the XDA-Developers complaints line.
He begins the tutorial and covers several Linux commands including redirect, append, pipe, clear, echo, and cat. AdamOutler shows us how to define and use variables, escape characters, and edit datastreams. He wraps it up with a practical example of some of these commands using adb and modifying the build.prop on a Samsung Captivate.
April 30, 2012 By: Adam Outler
Everyone has experienced the desire to program at one point or another. However, there are generally four limiting factors: Time Constraints, Study Material, Mental Blocks, and Attention Span. So clear your schedule, clear your mind, and self-medicate your ADD with a nice cup of your favorite coffee because here’s the material you need to learn how to program.
The hardest part of learning to program is overcoming a mental block. First, there is no programming deity out there who grants code-literacy to anyone. Learning to code is the same as learning any language—there are nouns, verbs, and sentences that come together in a certain way in order to make sense to the computer. Once you’ve written down a complete thought, the program works properly.
Second, even Java experts with PhDs in computer science think of Java as having huge black-boxes with inputs and outputs. Just as with any language, the higher your expertise means the more obscure language structures you can use. Anyone can learn basic language structures though.
The third mental block is to get motivated and “Just do it.” The tools are free. The resources are available. Anyone who wants to write a program can do it and publish their work. So you need to just jump right into your IDE and start making something.
Tools: How to Build an Android App Part 1: Setting up Eclipse and the Android SDK – Setting up Eclipse and the Android SDK will give you the basic tools you need to get started making an Android app. As with any project, you should start by gathering up your tools and learning to use them first.
Skills: “The Java Tutorials” – The Java Tutorials is essentially an http E-Book that is laid out in the same format as many certifications and online courses. Many people have stated that they want to “Sit-down and learn Java.” The Java Tutorials are a great way to do precisely this. This is tailored to writing generic Java applications, and not specifically Android’s implementation of Java. Learning this material will give you a strong knowledge base for programming Java applications.
Materials: Android “Package Index” – The Android Package Index is a reference for all of the Packages, Classes, and APIs provided by Google. Once you learn how to program in Java, you need to learn about the individual building blocks of an application. Each of these packages function as the nouns and verbs in your writing. The documentation show the appropriate time and place to use these words as well as what you get out of them. This package index serves as your dictionary.
Architecture: “Android Design” – The Android Design page is a great launchpad for ideas in your Android application. This page is examples of what Google would like to see. Each page shows design implementations recommended by Google.
The Human Aspect: Our Android hacking forum is the perfect place to ask questions, get answers, and see the works of other developers.
So, we’ve covered all the basics needed to get started creating your own Android applications. There are almost infinite resources available on the Internet. Please share your favourite resources below.
Have you ever been in one of the numerous “Post Your Home Screen” threads here on XDA and wondered how someone accomplished that screen that just totally blows your mind? Or perhaps you were browsing mycolorscreen.com, admiring the artistic beauty presented there, and thought “I wonder how they did that?” Maybe you are just one of those people who likes to tinker with your phone and has crazy ideas about what your phone could do visually, but is afraid to ask/share for fear of someone posting a scumbag steve image to insult you. I may just have the thread for you, my friend—a safe haven, a place where you can inquire about how to do something without the backlash of flame-happy trolls.
That place is here, in a thread started by XDA Recognized Themer jeffsanace, which was created to encourage community development. This thread is an extension of another thread in the EVO 3D forum, which quickly turned into a crazy thread full of helpful people and information. Some really cool modifications have come out of this community effort, so Jeff took the lead, and gave it a new hope in the Android Software and Hacking forum. In the first post of the thread, you will find the “general rules” for the thread and links to more tutorials than you will know what to do with. You will also see links to some of the tools that you will need to get started. If that isn’t good enough, the thread itself is meant to be interactive, meaning that the crazy idea you had might lead to something great. Asking questions is encouraged, because without questions there are no answers. The only caveat is you need to be willing to learn. No one is going to do it for you, but they will gladly help you through the process and show you how to do it.
You will likely come in contact with some of the most helpful users here on XDA, but no one acts like they are better than anyone else. Everyone involved is there to learn and help one another. Having had the pleasure of working with the users involved, and I have learned more than I ever thought possible. If you are willing to participate, share your ideas, and ask your questions you will learn a ton. Check out the original thread to join in on the fun.
ADB this, ADB that, ADB to get such and such… If you are new to the world of Android, you are probably asking yourself “what in the world are these people talking about?” ADB or Android Debug Bridge is basically an interface or communication medium for the user to connect and issue commands to an Android device or emulator. It is a client – server type program that many devs have used to do all the wonderful things that can be done with the little green guy. Anything from sending or pushing files to the device, exploring the directory, and even root processes for most devices are based on certain ADB actions. Many users getting into Android are just getting their feet wet with the commands, but since the information on xda-developers is so vast and scattered, we decided to make a small guide, which will show beginners some of the basic commands and what they can do with them.
For starters, one needs a computer with an OS of their choice (Windows (most versions), Mac OSX, or Linux (several distros are capable of using this)), all the necessary Android drivers, and Android SDK, which can be freely downloaded from the Android Developers website. Alternatively, the thread linked at the end of the article also has direct links for all the required downloads.
After you are done with all the downloads, you have to follow the instructions found in here in order to install and run the SDK successfully. The instructions may seem long, but the whole process is a lot quicker if everything is done correctly.
Once you have everything installed and ready to go, you may want to move the contents of the ADB drivers and the SDK to the root of your drive for ease of access. To do this simply grab the folder with the drivers and drop it in the root of your hard drive. You do this because now you have to connect your device to the computer and it will ask you for the drivers, which now are conveniently located. Do this and wait until your computer has finished recognizing the device.
Since everything seems ready, you have to open command prompt and go to the folder that contains ADB, which is normally
C:\android-sdk-windows-1.1_r1\tools> <run your adb command here>
This should be the path as it belongs to the folder that you moved earlier to C:\. If you have a different path, modify it accordingly. Now, all the commands will look something like this:
adb <insert your command here>
That is pretty much it. For instance, if you wanted to push a file into your device, your command would be something like this:
adb push something.txt /sdcard/something.txt
This command basically tells adb to copy a file named “something.txt” to the root of your sdcard. If you are interested in finding out more commands for this, you can find them here, where you will find more in depth instructions on how to use other features as well.
Again, this was only a small introductory guide to ADB, and it was inspired by a more complete guide created by XDA member VanillaTbone. If you have questions, there are tons of information available throughout XDA as well as on Google.
You can find more information in this guide thread.
Want something in the Portal? Contact any News Writer.