Wednesday, April 11, 2018

System Point of View to Understand the new features of Android P (9.0)


Introduction :

-Treble plan.
-System.
-Framework.
-Runtime.
-Security.


Treble Plan :

1. Treble Level.
2. System Properties.
3. VINTF (Vendor Interface).
4. VNDK & System SDK.

System :

1. Storage performance improvement.
2. Kernel breifing
3. LMKD
4. F2FS (Flash Friendly File System).
5. Perforamnce improvements 


Framework :

1. AMS
2. PMS
3. WMS
4. upgrade
5. Machine Learning (Neural N/w API)
6. Location optimizations/improvements


Runtime :

1. ART & Libcore
2. Soong Compiler for build
3. Private API

Security.


Highlights of Android P (9.0).


1. Android P enforce Treble to provide a good support the major upgrades of Android.
2. Adopting a new build system, using SOONG compile, replace Android.mk with Android.bp.
3. Limitation of private API normalized the Ecosystem of Android.
4. Optimization of framework services such as AMS,PMS,WMS locks.
5. Introduction the AI technology to enhance the background management and to improve system battery life.
6. Storage performance improvements.

Features (9.0):

1. Inline photos and smart replies on notification revamp.
2. Notch Support and preview with Visulize notch sizes(Display cutout).
3. Multi Camera API
4. Screenshot Editor (called Markup).
5. Lockdown
6. Chrome like feature flags.
7. Neural Networks(API 1.1)  for Machine learning.
8. Quick Settings, Nice rounded icon looks.
9. Settings has colored icons.
10.Side to side animation.
11.Low Power mode (Reduce/Battery power saver mode).
12.Indoor Positioning with Wi-Fi RTT.
13.Background apps.
14.HDR(High Dynamic Range) VP9 Profile2 built-in support.
15.Data cost Sensitivity in Job Scheduler.
16. Autofill framework improvements.

& much more....


Explanation of above : To be continued...


Sunday, July 1, 2012

Android 4.1 for Developers - JellyBeans Now Availble

Welcome to Android 4.1, Jelly Bean!




Android 4.1 is the fastest and smoothest version of Android yet. We’ve made improvements throughout the platform and added great new features for users and developers. This document provides a glimpse of what's new for developers.



See the Android 4.1 APIs document for a detailed look at the new developer APIs,



Find out more about the Jelly Bean features for users at http://www.android.com/

Friday, May 18, 2012

Android Multi-Core Enable/Disable

Actually support for Hot Plug-gable CPU's added by Config file.

Config Option is below:


CONFIG_HOTPLUG_CPU=y
or # CONFIG_HOTPLUG_CPU is not set

If your device has root permission, you can execute below commands for the above.

adb shell stop mpdecision

adb shell "echo 1 > /sys/devices/system/cpu/cpu1/online"
or
adb shell  ->
# stop mpdecision
# echo 1 > /sys/devices/system/cpu/cpu1/online

Friday, May 4, 2012

Google Play Store Now Offers Carrier Billing For Books, Music, Movies and Apps

There are many ways to pay on Google Play. Some carriers offer direct billing that lets you charge your Google Play purchases directly to your monthly phone bill.

This week we expanded this service to include all types of digital content on Google Play. In the U.S., T-Mobile customers can now purchase apps, music, movies and books by charging them directly to their mobile bill. In Japan, DoCoMo, KDDI and Softbank customers can also enjoy the convenience of paying for movies, apps and games on their mobile bills, too. And coming soon, Sprint will offer expanded direct billing options so you can pay for more digital content for your Android device.

Check out the full list of carriers that offer direct billing at http://goo.gl/rQ5Ps.

 or those of you who enjoyed carrier billing when it came to apps on the Android Market, guess what?  Google is now offering direct carrier billing on the Play Store for everything else as well.  Now, you can consolidate your music, books, movies and apps onto one bill if your carrier is on the list above (sorry Verizon users).  We’re pretty thankful that Google is offering this as for some, it’s extremely convenient.  So, from here on out, when you purchase something, your device will now prompt you as to what method of payment you prefer.  If you’re not into consolidating and the whole convenience thing, just opt out.  What’s your preference?  Feel free to drop a comment or two below.

Monday, April 16, 2012

5 reasons why mobile is the best platform to know your customers.

What are your customers thinking?


Marketing as a means of just selling is long past gone. Today’s marketer wants to understand his customer first before selling anything. Today’s marketer wants to provide the right solution for the right customer. There is a constant handshake happening between a marketer and his customers. Data plays a big part in this handshake.

Market Research plays a great role in marketing. In simple terms, traditional market research has been about collecting and analyzing data to help companies understand their customers and to make right decisions. In big corporations market research is conducted as a separate activity. Companies do market research all the time. You as a consumer is constantly given offers to fill down surveys to help companies fine tune their businesses.

The Web acted (acting) as a great platform for companies to efficiently combine marketing and market research. Many successful companies used this platform intelligently to know about their customers and grow their business. One clear example is Amazon. Here is a good article which talks about Jeff Bezos’ “data-driven customer focus”.

Now it is the age of mobile. Mobile is further going to bring down the divide between marketing and market research. Or to put it another way – mobile is opening up opportunities for companies to combine their marketing and market research efforts, know their customers and grow their businesses. Here are 5 reasons why mobile is the best platform to know your customers:

1. “Its my device” – Almost 50% of US adult population carries a smart phone. And unlike PCs, smartphones are not shared (except for when you allow your kids to play Temple Run !!!). So, you get direct access to the customer you want to reach.

2. “I carry it everywhere i go” – We may even forget carrying our wallet when we go out, but we feel at loss when we are without our mobile devices. Read “Everywhere” as “location”. Location allows marketers not only reach the customers they want, but the customers they want at the right places. If a marketing campaign needs to reach users just around Boston area. It is very much possible at a fraction of the cost.

3. “I do most of my stuff using my phone” – From replying to emails to killing sneaky pigs to comparing prices (and of course answering phone calls), we do almost all transactions on our mobile device. Many analyst firms have quoted big numbers on mCommerce growth. And with lot of (mobile) activity comes lot of data.

4. “I am less distracted” – This is counter intuitive. There has been a barrage of articles that talk about how information overload and proliferation of devices make us distracted. I view this differently when it comes to mobile. According to Flurry, average session time on a mobile application is 4.2 mins (as compared to web session time of just under 1 minute). As a mobile user, when i am inside an app, i want to give full attention to that app. Even if i have to click on some links as part of the application, i expect to go back to the application when i am done with the link. For those few minutes, i as a user, is tied to the device.

5. Small is beautiful – Though the form factor of mobile devices looks limiting, they are also, in a way, act in favor of a marketer. Due to the limited space, messages from many brands can not be cluttered on one screen. A screen at any given slice of time is dedicated to one brand. Though this looks simple, it is very powerful in increase the brand awareness of a brand.

From Neemware.org

Thursday, February 16, 2012

Linux Find Out Virtual Memory PAGESIZE

How do I check the size of PAGESIZE under Linux?

Most modern operating systems have their main memory divided into pages. It allows better utilization of memory. A page is a fixed length block of main memory, that is contiguous in both physical memory addressing and virtual memory addressing. Kernel swap and allocates memory using pages

To display size of a page in bytes, enter:

$ getconf PAGESIZE

OR

$ getconf PAGE_SIZE

Output:

4096

Monday, January 2, 2012

Disable Linux Kernel Version Magic problem while loading the module

Linux kernel will refuse to load kernel module, if the linux version magic is not match.

goto kernel/module.c file in kernel folder.

check for 'check_modinfo' function .

comment return -ENOEXEC this line in below function for same_magic() check.

static int check_modinfo(struct module *mod, struct load_info *info)
{
const char *modmagic = get_modinfo(info, "vermagic");
int err;

/* This is allowed: modprobe --force will invalidate it. */
if (!modmagic) {
err = try_to_force_load(mod, "bad vermagic");
if (err)
return err;
} else if (!same_magic(modmagic, vermagic, info->index.vers)) {
printk(KERN_ERR "%s: version magic '%s' should be '%s'\n",
mod->name, modmagic, vermagic);
return -ENOEXEC; }

if (get_modinfo(info, "staging")) {
add_taint_module(mod, TAINT_CRAP);
printk(KERN_WARNING "%s: module is from the staging directory,"
" the quality is unknown, you have been warned.\n",
mod->name);
}

/* Set up license info based on the info section */
set_license(mod, get_modinfo(info, "license"));

return 0;
}

Sunday, January 1, 2012

Service lifecycle in Android Application

A service can be used in two ways:
1)It can be started and allowed to run until someone stops it or it stops itself. In this mode, it's started by calling Context.startService() and stopped by calling Context.stopService(). It can stop itself by calling Service.stopSelf() or Service.stopSelfResult(). Only one stopService() call is needed to stop the service, no matter how many times startService() was called.
2)It can be operated programmatically using an interface that it defines and exports. Clients establish a connection to the Service object and use that connection to call into the service. The connection is established by calling Context.bindService(), and is closed by calling Context.unbindService(). Multiple clients can bind to the same service. If the service has not already been launched, bindService() can optionally launch it.
The two modes are not entirely separate. You can bind to a service that was started with startService(). For example, a background music service could be started by calling startService() with an Intent object that identifies the music to play. Only later, possibly when the user wants to exercise some control over the player or get information about the current song, would an activity establish a connection to the service by calling bindService(). In cases like this, stopService() will not actually stop the service until the last binding is closed.

Like an activity, a service has lifecycle methods that you can implement to monitor changes in its state. But they are fewer than the activity methods — only three — and they are public, not protected:
void onCreate()
void onStart(Intent intent)
void onDestroy()
By implementing these methods, you can monitor two nested loops of the service's lifecycle:
1)The entire lifetime of a service happens between the time onCreate() is called and the time onDestroy() returns. Like an activity, a service does its initial setup in onCreate(), and releases all remaining resources in onDestroy(). For example, a music playback service could create the thread where the music will be played in onCreate(), and then stop the thread in onDestroy().
2)The active lifetime of a service begins with a call to onStart(). This method is handed the Intent object that was passed to startService(). The music service would open the Intent to discover which music to play, and begin the playback.
There's no equivalent callback for when the service stops — no onStop() method.
The onCreate() and onDestroy() methods are called for all services, whether they're started by Context.startService() or Context.bindService(). However, onStart() is called only for services started by startService().

If a service permits others to bind to it, there are additional callback methods for it to implement:
IBinder onBind(Intent intent)
boolean onUnbind(Intent intent)
void onRebind(Intent intent)
The onBind() callback is passed the Intent object that was passed to bindService and onUnbind() is handed the intent that was passed to unbindService(). If the service permits the binding, onBind() returns the communications channel that clients use to interact with the service. The onUnbind() method can ask for onRebind() to be called if a new client connects to the service.

The following diagram illustrates the callback methods for a service. Although, it separates services that are created via startService from those created by bindService(), keep in mind that any service, no matter how it's started, can potentially allow clients to bind to it, so any service may receive onBind() and onUnbind() calls.

Tuesday, December 27, 2011

Check Available Sensor's on your device & Verify it's behaviour on Android platform.

1. enter adb shell

2. execute command "getevent"

o/p shows like this :

add device 1: /dev/input/event8
name: "qt602240_ts_input"
could not get driver version for /dev/input/mouse0, Not a typewriter
add device 2: /dev/input/event7
name: "melfas-touchkey"
add device 3: /dev/input/event6
name: "light_sensor"
add device 4: /dev/input/event5
name: "proximity_sensor"
add device 5: /dev/input/event4
name: "aries-keypad"
add device 6: /dev/input/event3
name: "orientation_sensor"
add device 7: /dev/input/event0
name: "accelerometer_sensor"
could not get driver version for /dev/input/mice, Not a typewriter
add device 8: /dev/input/event2
name: "raw_magnetic_sensor"
add device 9: /dev/input/event1
name: "magnetic_sensor"

3. example if you want to verify the proximity sensor execute below command.

echo 1 > /sys/class/input/input5/enable //for proximity sensor

4. sense the particular sensor and verify behaviour the output w.r.t sensor you enabled for shell.

Wednesday, June 29, 2011

List of Top 10 web browsers

Top Ten Blrowser List .....
Internet Explorer: There is no doubt that it is one of the most popular web browsers available and in use. There are several reasons of its popularity. The stronger two are - till date its free availability with windows operating system (most favored by the users) and its safe browsing promptings.



Mozilla Firefox: As an internet user, all of us know that Firefox is highly popular for its speed, so many plug-ins, built-in spell checkers and so many other features. Day by day it is also getting renovated also. Every new vision is coming out with several good plug-ins and other features.



Google Chrome: The search giant Google, has given the internet community one of the best gift – Chrome. The browser is a light weight, new interface and fast loading features. The most favored feature is its private browsing – “incognito window”. And day by day its extensions and tools are getting it highly popular.



Opera: This browser is in several ways highly popular for its attractive look and “turbo” speed. This browser is very much in use for it mobile version. The fast space and slick feature in mobile phones, this browser is gaining back its lost fame.



Apple Safari: It is fact that there is less number of Mac Ox users. But though the browser was built especially for the Mac machines, now for innovative web kits, Html 5 support and availability in other computer formats (ipod & other smart phones) the browser is getting highly popular among users.



SeaMonkey: It is an all in-one latest browser developed by Mozilla foundation. It has several exciting features included – integrated email, newsgroup, html editor, IRC chat, web development tools and etc. A simple user has to like it as he or she can use several mails in tabs. At the same time developers like it for its rendering of CSS in html editor with dynamic images and table resizing. Even JavaScript debugger and DOM inspector is include in it. The browser is compatible with windows, Linux and Mac OX operating systems.



Flock: It is one of the browsers targeted towards social networking lovers. It has the feature of letting its users informed of the social networking updates. It has several features of Firefox (even powered by Firefox) and the users like to use it for this very reason only.



Maxthon: It is favorite for its powerful tabbed user interface. With all its basic browsing functionality, the tabs are strong enough to stop crashes against the running of multiple pages at a time. Its Isolator Technology creates a walls type of system that prevents tabs being frozen for the bad web pages.



PhaseOut: It is a web browser for outer “starship navigation” panel with all the latest privacy protection shields. It comes with several “Pop-up Blocker” and “CleanUp tools” with extended options, skin database and swapping interface layout, it is gaining popularity to the internet users.



Avant: This browser is one of the ultra-fast web browsers. It has a user-friendly interface that brings efficient browsing experience with reliability. Apart from its simple common features of browsing, Avant has strong detection of malware, mouse gesture support, multi processing. Slowly it is getting popularity.



list of top 10 web browsers. However, you can find out several portals providing several unique lists. the most important point is the usage of the users – you. Try Yourself and judge the usability of the browsers.

Thursday, January 13, 2011

Bluetooth 4.0 is expected to hit markets dis year

The Bluetooth Special Interest Group (SIG) said on Wednesday that version 4.0 of the wireless specification may be incorporated into devices by the end of the year. The new spec will bring Bluetooth to a whole new set of gadgets including watches, pedometers, and all other low-power devices that run on coin-cell batteries.

This is a huge step considering that Bluetooth only resided in devices that used triple-A or larger capacity batteries. Michael Foley, executive director of the Bluetooth SIG, said that 4.0 combines both the high-speed data transfer capabilities provided by Bluetooth 3.0 with the new ability to transmit small bursts of data over short ranges.

The IGD News Service reports that Bluetooth 4.0 won't offer users a major improvement in actual battery life-- only a nominal improvement at best. Foley provided an example, saying that Bluetooth 4.0 radios will see the same battery drain as Bluetooth 3.0 radios when used to sync headphones to music players, or to connect smartphones to laptops.


Charles Golvin, principal analyst at Forrester Research, said that Bluetooth 4.0 will be better than the competition because it can be deployed across a wide variety of devices, giving the tech a head start over the other technologies. Unfortunately, the data transfer rate hasn't improved: Bluetooth still shoots data from device to device at a maximum rate of 24Mb/s (BT 3.0 + HS).

http://www.tomshardware.com/news/Blu...sfer,9812.html

Thursday, January 6, 2011

How to build Android application package (.apk) Manually.

he good thing about building manually your apk is that you don’t have to name your resources directory to res, you can name it anything you want.

You can find ant scripts in: \platforms\android-1.5\templates\android-rules.xml

Step 1: Generate Resource java code and packaged Resources
aapt package -f -M ${manifest.file} -F ${packaged.resource.file} -I ${path.to.android-jar.library} -S ${android-resource-directory} [-m -J ${folder.to.output.the.R.java}]

Step 2: Compile java source codes + R.java
use javac

Step 3: Convert classes to Dalvik bytecodes
use dx.bat
dx.bat –dex –output=${output.dex.file} ${compiled.classes.directory} ${jar files..}

Step 4: Create unsigned APK
use apkbuilder

apkbuilder ${output.apk.file} -u -z ${packagedresource.file} -f ${dex.file}

or

apkbuilder ${output.apk.file} -u -z ${packagedresource.file} -f ${dex.file} -rf ${source.dir} -rj ${libraries.dir}

-rf = resources required for compiled source files?
-rj = resources required for jar files

Step 6: Generate a key
use keytool

Step 7: Sign APK
use jarsigner

jarsigner -keystore ${keystore} -storepass ${keystore.password} -keypass ${keypass} -signedjar ${signed.apkfile} ${unsigned.apkfile} ${keyalias}

Step 8: Publish
use adb
adb -d install -r ${signed.apk}

Inspecting your APK file:

aapt list -v latest.apk