What is difference between Android and Android Rom? - android

I am new to AOSP anybody tell me what is difference between Android & Android Rom
I have found when i am googled but I did not understand the exact difference
Android is the open-source operating system used for smartphones.
Android ROM is the Android operating system. It is composed of a Linux kernel and various add-ons to achieve specific functionality.

As far as I know:
ROM
Literally it stands for Read Only Memory. When people talking about ROM it`s referring to the phone's internal memory. The memory where your firmware/apps are stored. When people say, falshing a new ROM, it means they are flashing a new version of the firmware onto their phone.
Android
In this case they are referring to the OS or to the product of Google.
Brace your self, Obvious link coming:
https://en.wikipedia.org/wiki/Android_(operating_system)

ROM is in fact "Read Only Memory." But for your purposes that has nothing to do with the use case here. Early on with some hardware the operating system was stored on a specific chip, a ROM chip. What you flashed onto that chip is called "the ROM image." It had to be written with special purpose hardware, or it had to be written to in a special boot sequence (like with a DOS bootdisk).
With Android, we distribute images which usually overwrite a file system without formatting it or partitioning it. That's more of a sloppy and crappy install and it's likely to go away at some point in time when someone clever does it the same way a desktop runs. So an "Android ROM" is usually just like a zip archive that gets unzipped to /. That's a bad way to upgrade a computer, but it's how it's done for now. It's also more acceptable to do it in such a bad way because on phones upgrades are done so seldom. You may get an OTA upgrade once a month, or every other month. And, you likely upgrade your phone fewer than 10 times.

Related

How to modifiy the system apps running on my phone

I want to modify the system apps running on my specific phone. I am stumped about some important steps on how to do that - see my questions further below.
N.B.: I am not interested in deploying these modifications to other phones. Instead I want to play with the original code and improve it. Hence "create your own system app" is no sufficient answer.
Background
I am just starting to get into Android development (have sufficient Java knowledge, though). There are plenty of great tutorials out there (e.g. here and here) but they all seem to cover user application development. I'm more interested in getting (a little) "closer to the metal". Unfortunately I am unable to find good sources teaching how to do that.
Example
As an example let's say I want to modify how the built-in brightness control works (e.g. changing the minimum) or want to add features to the call screen (e.g. "Send SMS instead" when the line is busy).
Specific Questions
I obviously need these things to get started...
Sources
The sources for (parts of?) the OS running on my phone. This is the part that confuses me the most. Can I just download the official sources or is it likely that my vendor made modifications?
In my specific scenario (I use a Fairphone), could those modifications be contained in any of these sources:
some core apps deployed by the vendor
the image binaries (some way down the page)
sources for the Linux kernel and some other libraries
Tools
I really hope to stay in Java-land. But either case I need a development (I hope to use Android Studio or Eclipse ADT) and a debugging environment (I hope the Android Virtual Devices suffice).
Is it a valid assumption that I can use those tools for system apps or are they usually implemented in C?
Process
Assuming I can download the official sources and get started with, e.g. Android Studio. As opposed to developing a user app, do I have to do anything special to emulate the modified system app on AVD?
I'm asking because I assume that AVD already runs an unmodified version of that very app.
I am just starting to get into Android development (have sufficient Java knowledge, though). ... I'm more interested in getting (a little) "closer to the metal".
You can of course follow your own bliss, but you may find it pretty frustrating to learn Android development by hacking on the OS itself. You'll find yourself doing a lot of OS debugging and working with harder-to-use tools than normal.
Example
As an example let's say I want to modify how the built-in brightness control works (e.g. changing the minimum)
I realize this is just an example, but this could be a tough one, because there are a lot of things that contribute to brightness control -- there's the app with the UI that sets it, but that talks to the framework and ultimately the driver for the hardware that actually deals with brightness curves for the display, in coordination with the ambient light sensor.
or want to add features to the call screen (e.g. "Send SMS instead" when the line is busy).
There's a dialer app, but implementing a feature like that will be...difficult, provided it's even feasible. I don't know offhand whether that sort of call state is available to the API.
Specific Questions
I obviously need these things to get started...
Sources
The sources for (parts of?) the OS running on my phone. This is the part that confuses me the most. Can I just download the official sources or is it likely that my vendor made modifications?
If you're replacing system apps, you'll need to run an OS signed with debug keys; you don't have access to the signing keys for the installed system apps on a retail build of the OS that would enable you to replace them. That will mean either getting a debug-keys installation or building it yourself from source, and flashing it to your phone. I would most strongly discourage you from using your daily phone for this sort of work -- you don't want it to be bricked when you need to receive an important call.
If you're not running a Nexus phone, then yes, your vendor has made modifications. The system apps are probably modified, and you almost certainly won't have access to the closed source of those apps. Also, there will be closed-source device drivers that are essential to the operation of the OS that you won't have access to. If you're trying to get AOSP Android up and running on such a device, as an individual hacker it's at best very, very difficult. If you're willing to use something like CyanogenMod, you could look to see if (and to what extent) they support your hardware.
If you are running a Nexus phone, then it's a goal of the AOSP project to try to have the OS bootable on select Nexus devices, though you won't necessarily enjoy the fullest functionality of the retail OS build, depending on the state of drivers -- even Nexus phones can have closed-source drivers and bits that make life more, um, exciting for building with AOSP.
In my specific scenario (I use a Fairphone), could those modifications be contained in any of these sources:
some core apps deployed by the vendor
Almost certainly
the image binaries (some way down the page)
Not sure what you mean by that
sources for the Linux kernel and some other libraries
It's unlikely there are significant modifications to the kernel itself, though vendors sometimes do...interesting...things with system configuration. I already mentioned device drivers. Vendors also have custom implementations/modifications of some framework APIs.
Tools
Vendor-specific tools are rare.
I really hope to stay in Java-land. But either case I need a development (I hope to use Android Studio or Eclipse ADT) and a debugging environment (I hope the Android Virtual Devices suffice).
Much of what you want to do can probably be implemented in Java, though it depends on how close you're getting to the hardware which can be difficult to know.
Is it a valid assumption that I can use those tools for system apps or are they usually implemented in C?
The "system apps" are implemented in Java, but again, you sort of have to know where the dividing line is.
Process
Assuming I can download the official sources and get started with, e.g. Android Studio. As opposed to developing a user app, do I have to do anything special to emulate the modified system app on AVD?
That's actually different, because you're dealing with an emulator system image instead of a phone image. The emulator system images are completely open source, and you can build them from AOSP.
I'm asking because I assume that AVD already runs an unmodified version of that very app.
That's correct.
To come back to my initial point, if you read between the lines of what I'm saying, I won't tell you it's impossible, but the difficulty ranges from freakin' tough on the easy end to spend-years-of-your-life on the hard end. If you really want to proceed, your best bet may be to buy the phone that's best supported by CyanogenMod and work that angle; there's a more active developer community there to help you. I know you're more excited about trying to customize the OS than you are in making a user-space app, but you'll experience less frustration with the latter than the former.

Writing a custom Android OS

I hope this is the right place to ask this.
I would like to work on an Android build with a completely custom OS. I was inspired by this project that ported Inferno to Android.
I would like to do this legally (obeying all terms of service and what-not) if possible, and I have no problem with disclosing my source code to a carrier.
Do any of you have experience with this? What are the considerations for getting a custom build to work with a carrier?
Since I am building on Android, I probably won't have to worry about cell/3g/4g hardware drivers, and I would like to buy a phone from the carrier anyway just to make sure it will be supportable.
I'm one of the creators of the Inferno project you mentioned. Anyway, making a completely custom OS for an Android phone will be difficult; a lot of the hardware will be undocumented or only drivable by Linux binary blobs. What we did (and what Boeing has also done recently for a commercial project) is strip away all the Java from an Android system, leaving a basic Linux upon which you can build your own custom interface. This lets you use all the hardware (since the drivers are in Linux), but everything that the end users see will be your stuff. There are a variety of ways to go from there. Inferno implements a virtual machine, so we can abstract the Linux stuff into our own Inferno-style world.
I don't think there should be any problems with the carriers. We started with a Cyanogenmod ROM and hacked on that; custom ROMs are just fine! I never had any problems, even when I was swapping my little pay-as-you-go SIM card among several phones running Gingerbread, ICS, and Inferno.
Head over to the AOSP source, and clone it. Strip out what you don't need in your branch and begin the kernel patching! You'll need to modify the kernel in portions to make it compatible (fairly) with the device you're on. The Android kernel is in fact a very close cousin of the Linux Kernel, and in Linux 3.3, they've begun merging the two. After this is done, write your interfacing mechanisms (be it a display, web interface, etc) and you can test it out on your platform.

Is it possible to run R from a tablet using Honeycomb (Android 3.0)?

I have a Xoom tablet and it would be great if I could run statistical analysis using R on it. As far as I know it is not possible to use R on iPad due to license problems (GPl x iTunes etc.) and a lack of compiler for Fortran in the Apple tablet.
But what about tablets using android? Arguably, the GPL issue is not a problem, so any help here on how to use R on my tablet?
I used Linux Installer from http://android.galoula.com/en/LinuxInstall/ (my Dezire Z was rooted beforehand), installed stable debian and R! on this Linux install. I`m not a Linux-geek and total time for installation (first time loop file size was insufficient, and I repeated the whole process) wass less than hour however.
(source: gyazo.com)
At some point, smartphones and tablets will have browsers capable enough to run RStudio in its server mode via the browser. Currently, the latter demands too much in terms of newer GWT, Javascricpt, ... magic that it remains limited to (recent enough) desktop browsers; see here for a bit more on this.
You can always ssh out though. Connectbot is a capable ssh client for Android, and of course free. No graphs though.
The Android SDK offers developers the facility to program in Java, ... not C or Fortran, which are the languages in which R is written. Although some have said that hacking the Android tablets voids their warranty and prevents upgrades, Motorola only requires that the device be relocked before doing upgrades. For this question I think it still boils down to "if you have to ask the question, then you cannot do it".
EDIT: But somebody else will probably try it.
(I haven't found gcc for the Android.)

Porting Android on various other mobiles

I am new to the development as well as the prg world. I want to learn android and want to make applications for it. So one possible way is to buy a new android phone to test it live and not on emulator. But I have two spare phones, Nokia N70 and Motorola MotoRokr E6. So I was willing to port the OS on those machines. As a result I wanted to know is that possible then what all do i need for that considering both Software and Hardware Aspects.
ThankYou in Advance...
Its possible however I would strongly recommend against it.
While android is open source and nominally can be run on any system you choose, in reality you would have to start worrying about keyboard incompatibility, drivers for any integrated peripherals your phone has, lacking buttons that are standard to all android phones etc.
Getting android running well on one of these phones would be a large project in its own right. I certainly wouldn't recommend testing your android apps on it as a first port of call as the problems you uncover are as likely to be with your android port as with your app.
Neither phone has anywhere near sufficient memory.
You need 96-128 mb, preferably more like 256 mb of ram.
Something that was already linux-based would be simplest as you would start by adding the android kernel modifications. Alternatively, something that is a winmo cousin to a vendor's existing android phone and has basically comparable hardware so you can hopefully recycle drivers or leverage an existing porting effort.
But if you need to aquire a phone anyway, get one that already runs android.

Build android system from source

I've recently purchased Samsung Galaxy Android phone after using Openmoko phone for 2 years.
One of the reasons for choosing Android was is that it's open sourced.
I don't want to depend on phone maker to provide updates for my phone. I'd like to do it myself.
Right now I'm in research stage if it's worth the time or not. So here are the questions:
I found some tutorials for building ROM images from source. They tell that Android build script will ask for make of the phone before building kernel. Does it mean that all the phone specific stuff is handled by the script or I will have to do some voodoo before I can flash it onto my phone?
Drivers. How are they handled? Are they included in the source as binaries and added automatically (question 1) or will I have to dissect old firmware to get them and put in my build? I realize that would mean some problems with module/kernel versions compatibility.
Is there is something I'm not aware of that would prevent me from building my custom firmware or make it very time-consuming?
I'm not afraid of installing SDK's and toolchains, after all I'm an Openmoko owner.
It's gonna be a little more complicated than that.
On any consumer Android phones I've seen, the user doesn't have root access to the OS. So step one, would be finding an exploit to get root.
Even after you get root, all consumer Android phones "lock" the bootloader to prevent unauthorized OS images from being booted.
The Android OpenSource project only contains device drivers for a small number of phones (Google dev phones, possibly the Nexus One?). For other phones, the drivers are proprietary binaries that the manufacturer loads on the phone. They generally aren't available separately.
Even with all of those obstacles, some enterprising smart guys have managed to create custom "ROM's" that blend the OpenSource release with drivers ripped OEM install on the phone, etc. CyanogenMod is one of the best known and is available for several different Android devices, but unfortunately the Samsung Galaxy does not currently appear to be one of the device supported by Cyanogen.
I found an old link here to a guide to getting root on the Galaxy and loading a custom ROM on it, but unfortunately the ROM they link to doesn't seem to be actively maintained anymore. It might be worth doing some more exhaustive google searches to see if you can find anyone doing active development on the Galaxy.

Categories

Resources