How to Configuration Device as a Single Purpose Application Device? - android

I have seen this in action in places like hostels/hotels:
How can you lock/restrict/configure an android device to only use an application, while having the following or most of them?
After every boot open and lock to a specific application.
Restrict specific hardware buttons, if any. (power button or all)
Lock device to use specific applications.
Is there anything "out of the box" provided by the SDK when building your applications? And if there is something like that what is the API support for that and how low does it get, API level wise?
Do you configure your device in a specific way? Is ther a documented pipeline for that?
I would prefer something official from google rather than 3rd party applications that do that.

firet it will suport in or after android 5.0
second lock app on your device for that creaate activity for luncer startLockTask(){}

First of all Single Purpose application is supported after Android 5.0.
To lock the app on your device call a method startLockTask() in your onCreate of launcher activity.
For detailed decription see this doc.

Related

Can we create Kiosk apps in Android?

I am learning about Kiosk devices. I am going through the docs but stumbled across this thing.
As per docs-
Kiosk Apps are Chrome Apps that are designed to always run fullscreen using Single App Kiosk Mode on Chrome OS and do not allow the user to exit the app. They're great for a purpose-built Chrome device, such as a guest registration desk, a library catalog station, or a point-of-sale system in a store.
There is also a mention of Kiosk Mode
It is an Android kiosk app that replaces the default Home Screen or Launcher and restricts user to accessonly one application or a few allowed applications. ... It has become common to use off-the-shelf mobile devices to run business applications or self-service kiosks.
Though I am unable to understand as to how to develop a Kiosk app for Android.
Yes, you can build kiosk apps in android.
In addition to Morrison Chang's link in their comment I suggest you to read this article for more practical approach.
Note: This article has a point on making layer that catches user drag events and such. On newer Android versions(8.0) this no longer works.
You can create Kiosk application. From Lolipop 5.0 google is providing api for that.
https://developer.android.com/work/cosu
You can use Pinning or LockTask to achieve the Kiosk application feature.
Some like of sample git application
Git Link
Git Link2
You can make kiosk device by making your application owner of the device and then pinning the app on the device.
Please follow the below link it gives the detailed concept of making an application an owner device and then you can pin it using the code for pinning
https://medium.com/#ashubansal.ashishbansal/make-your-android-device-a-kiosk-device-so-that-no-one-can-open-anything-in-your-device-except-the-3bb42a0db8ea
If you are using a dedicated device for your kiosk app you can use the Android For Work APIs to have a single application or multi application kiosk.
Lock task mode API from the android allows you to lock the specific app to run on the device and always on the foreground. This will disable the Home button and Overview button as well making a true kiosk mode experience.
In order to use the API, you need to use the DevicePolicyManager and run your application as Device owner.
You can also refer here for details on how to create a Kiosk app
https://blog.esper.io/best-way-to-build-android-apps-in-kiosk-mode

Mobile Device Managed Single App Devices

I like to have single android app in our managed devices, we want only that app to be used on the device with necessary restriction, such that,
Single use - Device will have only one app, user can't use other apps, like browsing, youtube or anything,
the initial setting like notification sound, GPS always on, notification and ring sound maximum level can't be modified.
user can not power off the device.
this setting can only be changed by our servers.
i think i have 2 option,
1) Using samsung knox sdk on samsung devices,
Here's MDM proving feature of Samsung Knox Standard!
2) General Android way, Set up Single-Purpose Devices, COSU solution
Android Developer's site.
Wanted to know your's view on this, may be if you guys have done any of the two or any other ways, i could use some of the guidelines or a path.
Thanks for reading, and please comment if i was unable to articulate the subject or it needs editing.
You can use Google's new Android Management API, it seems to suit your needs.
It is a new cloud API that allows to manage Android devices from a server, without having to build an on-device agent (a device policy controller).
I have broad experience of using Samsung Kiosk Mode from Knox Standard SDK which is free and Pro-Kiosk mode from Knox Customization SDK (which has more functions but is not free).
So I can tell you for sure that all 4 points that you have mentioned can be achieved by using Knox Standard SDK.
Singe Purpose: https://seap.samsung.com/api-references/android-standard/reference/android/app/enterprise/kioskmode/KioskMode.html
LocationPolicy (you can turn on GPS and restrict changing): https://seap.samsung.com/api-references/android-standard/reference/android/app/enterprise/LocationPolicy.html
Yes. It is possible but I forgot the exact implementation.
Yes, as well.
Only downside of using this SDK is:
You are tied to Samsung (which I personally okay with, since Samsung has such market penetration and you could get service almost anywhere in the world and in enterprise world it is critical)
About Android native functionality: never tried it
Update March 7, 2019: Now I am playing around Device Owner, we use it for Kiosk mode, works well and works on android Device with Nougat and earlier.

Does Google Cast support screencasting from Android devices?

Does Google Cast support screencasting from Android devices? For example, could we implement it into our tablet app to broadcast our screen to a receiver device running on a bigscreen TV, for demonstrations and events?
This post mentions creating a mini-server on an iPhone to serve content from. Would it be possible to create a mini-server within our Android app that captures and broadcasts the screen?
Google Cast doesn't support screen casting. However, you could certainly create a tiny web-server (such as http://tjws.sourceforge.net/) which serves images you've created. (Remember to shut it down when the user turns off the screen -- to save power) You should even be able to use the Styled Receiver for that.
No, Google Cast only supports streaming to a Chromecast, from any Chromecast supported device.
Also the "app" must be chromecast capable, so you would have to do what the post suggests, create your own app that acts as the middle-man in-between your device and your chromecast-supported-TV.
Simple Alternative For Screen Sharing:
On the other hand, a faster solution (if all you need is share your screen) is to use Droid#Screen and mirror your computer's display to the bigger screen or use join.me so users seeing your screen can also see your Android device.

How to start screenshot service using a code in android 4.0

I want to know how to start screenshot service in android 4.0 using code. I know I can take screenshots using the power button. But I want to know how to do this using code.
This is not possible, except maybe by rooted device users. Apps cannot take screenshots of other apps, for obvious privacy and security reasons.

Android PRL update

Would it be possible to do this programatically? So far we are opening the dialer and dialing *228... but would prefer another method. Any ideas, or possible other directions?
From my research, the Android has classes to handle the upload of PRL using OTAUtils. However each phone manufacturer has different process to update the phone dependent on chipset.
You would have to service unlock phone and write the new PRL values.
There simply does not appear to be any general API to write PRL to phone.

Categories

Resources