text:
How can I keep Android connected to a Raspberry Pi which doesn't provide Internet?
I use a PilotAware aircraft electronic conspicuity device from my Android device. This works fine on my tablet but has recently stopped working so well on phones - it repeatedly connects and disconnects.

PilotAware works like many other Raspberry Pi based devices in offering a WiFi AP but doesn't necessarily provide upstream Internet access. My phone/tablet connects to the AP to enable my SkDemon moving map app to connect a port providing location and traffic information.
This works as planned on my Samsung Galaxy Tab S6 Lite, but no longer works on my Google Pixel 4a 5G (Android 13) or my friend's Pixel 2 (Android 11). It used to work in the past. It simply won't stay connected to the AP being as there is no Internet connection:

My new Samsung Galaxy A54 seems to fare better as it asks what to do, but I have seen a similar dialog in the past on other devices.

Things I've tried, that don't fix it:

Disabled Battery > Adaptive preferences > Adaptive charging and Adaptive battery
Disabled Network & Internet > Adaptive connectivity
Disabled Mobile data (not really a fix, but worth trying)
Set a static IP

There must be more use cases where a non-Internet connected AP needs to be accessible from Android.

Based on a reddit post, you may want to try 1) Disable DHCP 2) Set DNS to 0.0.0.0 3) at which point you should get the "stay connected?" dialog.


text:
Galaxy XCover 6 Pro not connecting to computer via USB
I am currently having difficulties in connecting my Galaxy XCover 6 Pro to a computer.  When I plug it in, it charges for about 1-2 seconds, and then the charging stops.  The computer never registers a device being plugged in, and I do not get the prompt on the phone to switch from charging mode to file transfer mode.  I have tried multiple different cables, multiple different USB ports, and both Windows 10 and Windows 7 computers, and there is no difference in the experience.  The phone does charge fine, so long as the charging cable is plugged into a USB wall charger. The phone is running Android version 13.  Is this an issue other folks are having?  Searching for help on the internet does not show any similar problems for other folks, nor any applicable solutions.

When connected to an  USB charger, is the charging speed as expected? Based on your description a (partially) defect USB socket on the device may be the cause. It is a common problem that people put too much force on the USB plug while inserted in the phone (in all directions) which can lead to breaking the soldering points the USB socket is connected to the motherboard and then the USB connection is getting unstable (some times only power, or only data or often for both).

@Robert when connected to the wall wart it will charge without interruption.  It probably takes about 2 hours to go from empty to full, but I have turned rapid charging off in order to preserve the battery, so this time does not seem excessive.

The the pins that transfer power seem to work correctly, unfortunately this may be different for the data pins. The only way to be sure would be letting a repair center check the device.

Either your port is damaged or you have charge only cables.

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

sort: votes


text:
8-in on stuck in boot mode recovery in Chinese
8-in on tablet stuck in boot mode. It keeps going arrow up, down, up, down through recovery, fast boot, and normal boot. It won't stop unless I hold all three buttons down, then I can get it to the recovery page which is in Chinese.
I have factory reset it and rebooted it, but it still goes back to the boot mode. Tried all the buttons. Help

Welcome to the Q&A site Android Enthusiasts Stack Exchange. Based on current information, looks like the physical buttons are stuck, thus forcing the device to always boot into recovery due to the key combination. I think you have to bring your device to the repair shop and have it checked unless you want to try disassembling it yourself.

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
How do I restrict access to a Git folder on Android to only certain apps without a password check?
I want to secure a git folder on an Android device so that only specific apps do have access to its content of it. In the best case, there shouldn't even be a password check. I have sensitive data which should be easily accessible between my devices. Using git is the best option in my case, so switching to another option is not wished.
On my Huawei Nova 5T (non-rooted), there is no integrated option to encrypt the data or anything similar. I tried to use Shelter, but that seems not to do the job. Using X-plore file manager I've got a vault to store files, but I can't see the location on my phone so I couldn't use it for git + being asked for a key isn't as comfortable as I like to have it.

The Android storage system does not provide on option to share data with certain apps. Apps can have app private data only accessible by the app itself or a more or less public on the shared storage. The only way to keep the data private to an app but give other apps access would be implementing a content provider but that only works on a oer-fike basis and if I remember correctly not with random-access read/write but just read sequentially the whole file. But that is the programming level, I don't know what apps exists that make use of this meachnism.

So is there no way to store data at a shared storage which you can access by multiple devicec which is secured in anyway? Specifically I use i.e. Obsidian to store private data or my keepass vault. If I don't use something like git I would have to manage my passwords on 3 devices and so on. Maybe a SSD-card can help as an access-controll wall?

I prefer specialized apps. For passwords there are very good programs available. I prefer KeepassX compatible apps like "Keepass 2 Android". The key store file can be stored in any non-encrypted syn service like dropbox (directly in the app) if you use the Keepass feature to use a key file in addition to the password. If you keep the static keyfile private (no cloud only direct transfer via USB) this makes your keepass password wallet "unhackable" by guessing the password as also the file is necessary.


text:
Clock icon on a single WhatsApp chat message on both side
Today, I was talking with one of my friends on WhatsApp and suddenly a clock icon showed on some messages.
First, I assumed that there might be an internet issue, so I sent messages to other contacts on WhatsApp and they were delivered. But for half an hour, my friend's chat was still showing a clock sign, and the same issue was faced by my friend.
I faced this issue for the first time in my life. Why is that so?

Try to close the app in the background and open the app, by the time it processes the messages might have been sent from your side;
Otherwise, turn on and off flight mode.
Sometimes if there is a sufficient amount of reception and it is not sending or receiving any texts, then it is better to take some time to reset back to default mode.

Try logging out from all 'Linked Devices'. That worked for me.

Same issue here, although I've never faced such problems on Telegram.
This solves my problem:

Find Whatsapp here phone setting > application manager and Force Stop it.
From there tap the the storage button and clear cache (Not clear data!)
Start the app again


text:
Is there a way or app that allow me to configure my mobile hotspot as a real router?
I live in Cuba , and the easiest and cheapest way to have internet in home is sharing it from a mobile, now I'm trying to configure a Google home mini, but it doesn't work because AP isolation, so I need to figure out a way that allow me to configure the hotspot as a real router to disable AP isolation and modify other parameters. Thanks in advance.

Why not buy a router which has a SIM card slot? It is a one-time investment and it would save you from the hassle of figuring out if hotspot on Android can be configured like a router can be, and it would also avoid degradation of smartphone's battery life because of regular use of hotspot.

Thanks, but routers of any kind are really expensive here, and I have an old mobile for sharing internet. I know and understand that it's not the best option but it could be a solution until I can get a real real router.


text:
How to copy screen lock password from one device to another in Android11?
So I'm trying on copying the Android 11 screen lock password to another same device
our customer does not want to set the password one by one
and I find out a resolution:  copying files
However it only works in the scenario if the device password is not been set.
while copying the file below to the device without a password  after rebooting the device the screen lock will show up and the password is as expected**
Unfortunately, it will not work if the device's password has been set; the screen lock will still show up but the password was not as expected
What did I miss here? Does anyone know?
the code below what I am trying to do  is to copy
1.locksettings.db
an SQLite database containing the lock screen settings
2.copy /data/system_de/0/spblob/*
In order to unlock a real user, you need to know a synthetic password. However it's encrypted by the Keystore, so you need the real password to unlock the Keystore first
for example
.00000000000.handle: return value of gatekeeper first enroll by synthetic password derived password
handle.pwd: the second gatekeeper enroll by real password with a fake user ID (e.g. user_id + 10000).
handle.secdis: Actually a random number. Used to encrypt the synthetic password.
handle.spblob: encrypted synthetic password
3.
copy /data/misc/keystore/user_0/
keystore key. Used for encrypting synthetic passwords.
cp -rf /storage/self/primary/export/configuration/Settings/lock* /data/system/

chown system:system /data/system/locksettings.db
chmod 660 /data/system/locksettings.db

rm -rf /data/system_de/0/spblob
mkdir /data/system_de/0/spblob/
chown system:system /data/system_de/0/spblob
rm -rf /data/misc/keystore/user_0
mkdir /data/misc/keystore/user_0/
chown keystore:keystore /data/misc/keystore/user_0

cp -rf /storage/self/primary/export/configuration/data/spblob/* /data/system_de/0/spblob/

chown system:system /data/system_de/0/spblob/*
chmod 600 /data/system_de/0/spblob/*

cp -rf /storage/self/primary/export/configuration/data/keystore/* /data/misc/keystore/user_0/

chown keystore:keystore /data/misc/keystore/user_0/*
chmod 600 /data/misc/keystore/user_0/*

For additional question:
Yes those command above need to run under root acces ,however because it is a customize os so we make those command run under a system service and fix some sepolicy avc error so the customer do not have root acces for sure and we can run those command even under an unroot device

Is locksettings command not useful for you in this context? See https://android.stackexchange.com/a/194779/96277

@Firelord yes this solution is also been cosidered for us.  but we need to know the customers password first . We have  like thousands of  same device  on the customers hand it will be disaster if they forgot their password .  So the best solution for us is to try copying files between devices without knowing their password. Fortunately we have full access of our customize os so we are trying on this approach

Those files are only accessible with root permissions, so all the devices for the customer are rooted? I would really be surprised if you can change the lock screen PIN by copying files. There should be the Gatekeeper running in the ARM TrustZone which you can not copy as it should be device unique. Even if it works the first time you should test if it still works after changing the lock screen PIN.

@Robert Thanks for reply .For dev we have somesort of debug mode os and yes we have full access,but for customer they absolutely dont have the root access . However we can run those command under a system service and fix sepolicy avc error so we can copy those file even if we dont have the root access on customer os . and yes we have test some test program to test the stuff we are doing it work on if the device is not been set password and we believe we can accomplish even if the password if been set. we done this on Android 9 before and it works well for couple years not sure what they change


text:
Screens wakes up right after timeout for no apparent reason
There's a strange situation on my new phone where as soon as the screen turns off due to inactivity, it wakes up again by itself after a couple of seconds. (However, if I turn it off manually, it stays off.)
I noticed that this stops when I disable "Wake screen for notifications". However, there are no notifications coming in when this happens or even an active notification that can be dismissed but hasn't; the display just wakes up at a very regular, short interval after it goes to sleep.
Other similar problems I found mentioned on the Web don't seem relevant; e.g.,

it happens even if the device is not moving (but "Lift to check phone" is off just in case).
"Screen attention" is off

Question:
I would like to stop this from happening but still have the display wake up when an actual notification comes in. Any ideas / previous experience? If not, is there a way to find out exactly what's causing it to wake up?
Device details:

Pixel 6 Pro
Lineage 20-20230331-NIGHTLY-raven (Android 13)

UPDATE
I found what seem like the most relevant entries from logcat at the time of waking up: https://pastebin.com/yUCqFegF
Specifically, some of the entries have reason=WAKE_REASON_GESTURE, which seems to suggest (I couldn't find an explicit description/definition online) that a "gesture" is responsible for waking up the display.
However, the device is not moving and I'm not touching it or even near it when this happens. Also, it sounds to me that this is not really consistent with the fact that this behaviour stops when I disable "Wake screen for notifications".
From the UID (10204), it appears that com.android.systemui is the offending package:
$ adb shell pm list packages --uid 10204
package:com.android.systemui uid:10204

Here's a screenshot of the Gestures settings for reference:

Observe logcat output when screen wakes up after timeout.

@Firelod, what should I be looking for? I found some entries for DisplayPowerController, but not sure if they contain what I'm looking for (the cause).

Do you see a log entry from PowerManagerService such as PowerManagerService: waking up from Asleep?

@Firelord, yes, and it seems to suggest that it wakes up from a "gesture" detection, but not sure why (added details in revision 3 of the question).

The logcat mentioned the uid, perhaps How can I find app name by UID? could help? Otherwise, you might want to check the notification history just to be sure. Perhaps there's one app that is showing a notification very briefly, thus it wakes the device, but the notification is already gone by the time you notice it.

@AndrewT.: the package with that UID is com.android.systemui. I've enabled notification history, so I'll check again.

@Ratler it is likely that you are dealing with a bug in your ROM (it is a nightly release). It might be worthwhile to take this issue with your ROM maintainer so that they can look at your findings and possibly help you out.

I believe, and it's what happened to me also, that you will still receive some system or possibly Play Services (in my case) notifications, even if mute/DnD or lock screen is enabled if the "Show as popup" isn't toggled to on in the App > Notification Settings and if not marked to "Hide in screen lock", which will wake the device. Not a gesture per se, just from my user experience. Worth a try.


text:
How to open backup.ab
i got a backup.ab file with password. I'am looking for how to open it for 1 month but i still couldnt open it. I really need help can anyone tell me how can i open it please explain it with step-step

Why have you tagged your question twrp? backup.ab files are created by the command adb backup which works in regular OS, not in TWRP.

actually, TWRP can create backup.ab files. but the format is completely different. twab.sh can convert into .win

@alecxs A bad choice to use the same file extension as adb backup but using a different format. But are those backups also password encrypted?

@KaanAyhanoğulları Please edit your question and add more details how the backup had been created. It would also be helpful if you could open the backup.ab file in an edit and post the first may be 10 bytes of the file so that we can determine what type of backup it is.

@Robert whatever TWRP creates is wrapped into backup.ab, so I assume depending on TWRP settings encrypted backup might possible (untested)

I got this backup file with adb backup command

But at that time you executed adb backupTWRP was running right? That means it is not an Android backup but something else that only exists within TWRP. Check out this topic, it contains a lo of details what you can do with such a backup (unfortunately mostly manual modifications or scripts that only work under certain circumstances):  https://github.com/TeamWin/Team-Win-Recovery-Project/issues/898 Next time just do not use adb backup with TWRP.

I didnt know twrp was running. My phone is not rooted so maybe i wasnt using twrp but can you explain what is twrp i dont know what twrp exactly is

backup.ab files are usually created by the command adb backup. This answer is only for backup files that has been created by adb backup. It will not work for other backup types.
Extracting an Android adb Backup file is pretty simple. You just need Android Backup Extractor, a Java program that does everything for you.
Just download the latest abe.jar release. As it is Java based you also need a Java Runtime. Oracle Java is no longer free in all usage scenarios, therefore I recommend OpenJDK from Eclipse foundation. But any other Java 11 or 17 JRE or JDK is also fine (abe requires Java 11+).
To convert your Android Backup file backup.ab to a tar execute
java -jar abe.jar unpack backup.ab

It will create a file backup.tar which you can open using an ZIP tool of your choice (e.g. 7-Zip).

Hi i tried but i got this message : ''Unable to access jarfile abe.jar'' Is it because i put a password when i was backing up?

@KaanAyhanoğulları abe.jar is the program for reading the backup not the backup itself. Have you downloaded abe.jar as described in my answer? And then open up a command prompt or terminal how it is called in your os in the directory where you have downloaded abe.jar into and execute the command to run abe.jar with Java.

Yes i have downloaded abe.jar but when i try to open i get that error message : ''a java exception has occurred''

@KaanAyhanoğulları The downloaded abe.jar works fine. If it doesn't work on your system then something is wrong with your installed Java version or the backup file is defect or in a wrong format. BTW: You still have not answered by comment on TWRP tag.

@KaanAyhanoğulları Is the error similar to the one shown in this post? https://forum.xda-developers.com/t/how-to-extract-data-from-adb-twrp-ab-backup.3725347/ (the one with java.lang.IllegalArgumentException: Invalid Magic TWRPtwstreamheader)

No not the same error. Probably it is because my java is broken but i deleted it then download install last version . After i tried to open abe.jar but it give same error that says a java exception has occured


text:
Block calls for many time ranges in the 24 hours
I have Xiaomi Poco F3 running on Android 13, fully updated. I know my relative is aging fast in the last few months, so we normally call each other 4 to 7 times a day. TODAY: I visited her at 11:20. At 14:05, she had already called me three times. So, to put down a little stress on me, meanwhile letting her keep her phone, I thought about taking a selective blocking action on that number.
Says my phone refuses her calls:

from 00:00 to 08:30
from 09:45 to 12:30
from 13:30 to 16:30
from 17:10 to 18:45
from 23:00 to 00:00

While I may call her anytime, she will be able to reach me only on the usual timetable:

Coffee time 08:30 > 09:45
Meal time 16:30 > 17:00
Supper time 18:45 > 23:00

BUT NOT DURING WORKING HOURS AND NIGHT. Meanwhile, all the other calls are as per usual
I couldn't find any leads to a practical answer on the web. Only generic-non-useful-well-known.

Have you considered an automation app such as Tasker, MacroDroid or Automate? I know that Tasker and MacroDroid can easily reject call from a number. You can setup triggers and constraints as time between X and Y hours. Or setup two tasks where one activates call rejection when time is A,B,C hours and the other disables call rejection when time is D,E,F hours.

Welcome to Android Enthusiasts. While we sympathize with your relative's condition, I'm sorry that some of the info that is irrelevant to solving the issue here got trimmed because it may distract from the main question. Meanwhile, consider trying what Firelord suggested. Thanks for your understanding.

Thanks for the answer.
Information are added for context.      If was thinking somebodu else got the issue from Kids ( during working hours ) ... and The Boss ( while on hollidays )

I was thinking someone else got the issue from Kids ( during working hours ) ... and The Boss ( while on holiday)  ---> There is a manual way: on the contact > hamburger dots > "send to mailbox "/"unsend to mailbox" (provided you do not have a mailbox)  So The Caller will get the "Busy" response. Now I'll find a way to automatize and report back

@firelord
MacroDroid like the other Apps: (1) senses "a call" that you can generically "Block/unblock"--- I didn't find a way to sense "a specific caller" -(2) That Apps cannot interact with "Contact" App to insert or remove "send to mailbox" on a specific name ---->Results NONE - <that are the only to way I've found possible at the moment> Any other suggestions please ?.


text:
How to mount a folder/partition as USB device for a computer
I have one phone that upon plugged into a computer, shows up as an MTP device. The SD card and the internal storage are visible on the computer. I can also change it to only mount the SD card and then it unmounts the SD card from the phone and directly connects it like if it were to be an SD to USB adapter.
I want to be able to do this on another phone, but not with an SD card, I want to be able to use a part of the internal flash memory in the same manner so that I can connect the phone as if it were a USB stick and I also want to be able to connect it as an MTP device. It would be handy if I can do this with tmpfs too, so I can basically use the phone's available RAM as temporary high speed USB storage.
The reason I want to do this is because MTP is incredibly slow for loading the directories, file transfer is a bit faster but still a fraction of what USB 2.0 can achieve. I want to use the RAM so that the internal storage isn't affected and filled up for no reason since the phone doesn't have that much free storage. On the other phone, connecting it in SD card adapter mode causes windows to see it as an actual sd card so Windows doesn't open the storage in MTP mode which misses file properties and is super sluggish. Another reason for using RAM is that the internal storage can't be unmounted while Android is running on the phone so you wouldn't be able to use it as USB storage in anything other than MTP.
Are there any ways of doing this using busybox, or by modifying some system files?
I know this has to be possible but I don't know how it works with the SD card adapter mode on the ohter phone and I don't know how to replicate it for other storage media. The phone is rooted so I can do anything to the system I want. Preferrably on Android 4 and up. How can I accomplish such result?

Update

I was able to get UMS working on the phone thanks to Irfan's comment. I can change the drive that mounts by editing the "file" file.
To do this, first the command cat /proc/partitions.
Then you can write echo '/dev/block/vold/<major>:<minor>' -n> /sys/devices/virtual/android_usb/android0/f_mass_storage/lun/file
I am not done yet though, I need to know how to now how to forward the path in "file" to tmpfs. I can't find a device file for tmpfs like all the other partitions. Is there a vold partition for tmpfs, or can I maybe link to a folder in file? How can I put the path to tmpfs inside "file"?

I managed to get it working!
Thanks to Irfan's answer I knew exactly what to do!
Here are the steps:

Create a folder to mount a new RAM disk. I used /data/local/
and created a new folder. Then mounted a new RAM disk to it.
mkdir /data/local/temp
mount -t tmpfs tmpfs /data/local/temp

Next, creat a new disk image. You can choose the block size and the amount of blocks for any size you like. The total size of the file is bs * count. I chose a count of 200000 for a 90MB file on the RAM.
dd if=/dev/zero of=/data/local/temp/ram bs=512 count=200000

We now want to create a loopback device so we can mount the new file on the RAM disk as a virtual semi-device. First we want to know the major value for loopback devices.
ls -l /dev/block/loop0

We now know what major value the first loopback node has. In my case it showed 7, 0. We know we will have to use major value 7 for the new device node. We can now create a new node. For this we use the command "mknod". The -m parameter specifies the permissions. I already have files loop0-17. loop0 is used for the built in cdrom, and the rest are used for mounting .asec files.
mknod -m 0660 /dev/block/loop18 b 7 18

To mount the disk image on the RAM disk we have to use losetup.
losetup /dev/block/loop18 /data/local/temp/ram

We can check what backing file associated with each loop device by reading the backing_file with the cat command.
cat /sys/block/loop18/loop/backing_file

Now that the virtual device is ready we can format it. I will use mke2fs, but you can use other methods to format the device. Make2fs will format the drive EXT2. For Windows you should format FAT32, or you can use this amazing Ext3 filesystem driver. This adds native support for EXT to Windows and is very awesome.
mke2fs /dev/block/loop18

We can finally setup UMS (USB Mass Storage) so the computer can read the device directly. You can set lun, or lun1 depending on if you want multiple virtual usb devices.
cd /sys/class/android_usb/android0
echo /dev/block/loop18 > f_mass_storage/lun/file
echo mass_storage > functions
echo 1 > enable

That should be it, normally a USB device shows up on the computer now.
I tested the speed and it's a lot better than MTP, and it actually uses the full RAM speed, but it's limited by USB 2.0 speeds, unless your device supports USB 3.

While testing I noticed when enabling USB gadget mode and writing an incorrect path to "file", Windows breaks and suddenly can't read usb devices anymore. After this you can't reboot unless if you hold the power button down. This may be a bug in Windows, I'm not sure why it does this. Device manager also malfunctions after this.
Here is the source code of the mass storage driver on Google Source.
And finally here is the documentation on the configuration on kernel.org.


text:
redirect clients of your android hotspot to custom web page or send them a link notification
redirect clients of let's say my android hotspot to custom web page or send them a link notification without rooting if it is possible. The thing i want to accomplish is to be able to send a link the moment someone connects to my mobile wifi hotspot with no password and to get redirected to a url or get a notification.
The concept is to be able to send notification to multiple people cellphone to cellphones and only the sender is necessary to have the app. Can that be without rooting the phone?


text:
Porting Bluetooth dongle CSR to Android TV box
I have an Amlogic S905 TV box with no Bluetooth, only WiFi. I started porting the external Bluetooth adapter (CSR 4.0) driver to this box.
I found that the box kernel has inbuilt support for Bluetooth. I checked this using dmesg | grep -i bluetooth and it shows Bluetooth core ver 2.18
1|root@p383: # dmesg | grep -i bluetooth
dmesg | grep -i bluetooth
<6>[    0.977385@0] Bluetooth: Core ver 2.18
<6>[    0.985193@0] Bluetooth: HCI device and connection manager initialized
<6>[    0.991742@0] Bluetooth: HCI socket layer initialized
<6>[    0.996798@0] Bluetooth: L2CAP socket layer initialized
<6>[    1.002071@0] Bluetooth: SCO socket layer initialized
<6>[    1.558138@0] Bluetooth: HCI UART driver ver 2.2
<6>[    1.562707@0] Bluetooth: HCI H4 protocol initialized
<6>[    2.697881@0] Bluetooth: BlueSleep Mode Driver Ver 1.2
<6>[    3.928079@0] Bluetooth: RFCOMM TTY layer initialized
<6>[    3.933201@0] Bluetooth: RFCOMM socket layer initialized
<6>[    3.938501@0] Bluetooth: RFCOMM ver 1.11
<6>[    3.942343@0] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
<6>[    3.947854@0] Bluetooth: BNEP filters: protocol multicast
<6>[    3.953351@0] Bluetooth: BNEP socket layer initialized
<6>[    3.958471@0] Bluetooth: HIDP (Human Interface Emulation) ver 1.2
<6>[    3.964573@0] Bluetooth: HIDP socket layer initialized

Screenshot of terminal output
but there is no physical hardware present.
Also, there is a lack of required files like:

/system/app/bluetooth.apk,
/system/lib/hw/bluetooth.default.so,
/system/etc/bluetooth

Then I successfully compiled btusb.ko driver in Linux by downloading kernel source code and pasting in /system/lib, and driver btusb.ko is successfully installed now. The dongle detected in dmesg log as
#rfkill list
0: hci0: bluetooth
Soft blocked: no
Hard blocked: no

But I am unable to use it because Bluetooth functionality is not on.
I need help with how I paste the required files in the system folder to turn it on.


text:
How to play sounds at set times per day, like an alarm, but only once per time and with no need to interact?
I have tried Alarm Clock Xtreme which alleges to do this (play alarm, and dismiss automatically after 1s, which is the length of the sound) but it doesn't actually dismiss and just keeps looping. What other options do I have?
Use case: play one.m4a at 01:00, three.m4a at 03:00, etc. to twentythree.m4a at 23:00, every day. Each file is one second long and should be played exactly once, and preferably with no popups.

Isn't some automation tool like IFTTT sufficient for this?

Have you considered using an automation app for this? MacroDroid has an action called Play Sound where you can select your file. The Triggers can be time of day. You can setup wait and repeat actions as well.

MacroDroid appears to do the job. Thank you. :)


text:
Move apps to SD card at once
My LG phone's internal storage is full, the phone is NOT rooted.
I know I can move apps to SD card one by one: |cog icon| Apps | tap each app one by one and pray for the Move button to appear, but this is too time-consuming.
I recall I saw a place where all apps were listed and a checkbox was next to those apps that supported moving to SD card, so I could [X] check all boxes and tap one big Move button to move all those apps at once instead of guessing one by one which one can be moved. How do I do that?
After Googling around a lot,  I found this page, but I cannot find the menu it talks about and cannot find any Multi-select option. I also cannot find the Settings app they mention. In addition, their method seems to require the phone to be rooted. How can I do the same -- multi-select the apps and move them to the SD card all at once? (what would also help is a list of all apps on my phone that support moving to an SD card)


text:
Where are the locations where games store data?
I am trying to find the sprites for a game. They were not in the apk. I looked in /sdcard/Android/obb. But while there was a folder that matched the game, it was empty. I looked in /sdcard/Android/data but could not find any files that had images in them. I looked in /data/data/ and the same thing happened. My understanding is that the files have to be stored somewhere on the phone, right?

Welcome to Android Enthusiasts. The game data might be stored there, although file manager apps may not be able to list the content due to the Android restriction. Possibly related: Obb folder empty even though I can see inside data folder, Android 11: Can't see contents of "/sdcard/Android/data" even with root, and the canonical Where do Android apps store data?.

Note that games usually don't contain separate images, often they combine them in a few bigger file. The file structure of such files can be proprietary so searching for image files won't be successful even if you had permission to access all the mentioned paths.

I can see obb files for a different game in the obb directory, so I don't think restrictions is the reason why. Also, the game is made in Unity so I'll probably be able to extract the assets since there's a bunch of tools for that.

What game are you talking about? Some games hide their assets in other files. Does the game require wifi to launch or does it work offline? If it works offline, the files are inside the apk and you need to do some digging, try looking in the largest files first, assets are usually pretty large.

The game is called "Bonbon Cakery". It runs without wifi, but I don't know if that's because the files are stored in the APK or just because it downloaded the assets the first time I opened it, since it took a while to open the first time. I unzipped the apk and put all the files into Asset Ripper (for Unity) and it only showed me the icons and the start screen.


text:
Set up SOCKS5 proxy in OpenVPN on Android
I want to set up a SOCKS5 proxy in OpenVPN. For example, this proxy: 5.196.58.136:17471
I've read a few threads but couldn't fix it.
Can you please help me set up the SOCKS5 proxy on the OpenVPN Android app? How do I have to configure the .opvn file?


text:
PlayStore does not update APKMirror apps
I have an Android device where I have not assigned any Google account to it, just because I don't like/trust Google.
Since I cannot use the PlayStore to get apps without assigning an account (thanks for that Google...), I have downloaded some APKs from APKMirror.
Now, I see that the pre-installed Google apps get updated by the PlayStore, but the ones I have installed manually, after downloading them from APKMirror, don't. Despite the fact that I have read somewhere that this should work and that apps should be updating.
Is this some new Google way of forcing things down our throats?
Am I missing something?
What is the best way to not use a Google account and have apps update automatically?

Welcome to Android Enthusiasts. Looks like there's a similar question: Don't use Google and APKPure misbehaves - how do I update apps?. Does it help?

@AndrewT. Thanks a lot. That looks like what I was looking for. Hopefully, the solutions posted there still work... I don't know if Google realizes this, but this can be filed as a huge security issue to their platform, which they have created on purpose...


text:
Android in system recovery mode gives an error on Windows
I have an old phone and I want to see if I can use adb in recovery mode on the device to mess around with the system, but when plugging the phone in after booting into recovery mode Windows immediately gives an error "the last usb device you connected to this computer malfunctioned and windows does not recognize it". I tried unplugging, plugging back in, the cable is fine, the phone works when booted normally and adb works fine and the computer recognises it. It just doesn't work in recovery mode.
It may be an issue with the usb driver in the recovery image but I don't know enough about Android so I have no good idea. I'm not sure if they shipped a phone that can't connect in recovery mode from the factory, but that would be weird. I like the stock recovery since it lets you backup and restore the /data partition to sd card.
I noticed when plugging it into a different port it sometimes shows up in device manager with an exclamation mark. For some reason it sometimes gets recognised but it automatically uses the driver "unknown usb device (device descriptor request failed)" so I assume there is some missing recovery mode driver for Windows. What driver am I supposed to use and where do I find it? I think it's a MediaTek made custom bootloader but I'm not sure.
I can't boot into fastboot mode, choosing fastboot on startup just freezes the phone forever until I pull out the battery or let the battery drain for hours. I can't remember fastboot ever working and I would also like to get that working like it should.
I am now getting the error "unknown usb device (device descriptor request failed)" even when just plugging it in being already booted.

What are you trying to do? If stock recovery has adb at all, then it is limited to abd sideload.

Concerning booting into fastboot mode, when the device is powered on and connected over adb, run "adb reboot bootloader" to enter into fastboot mode (that will turn off the phone and enter into fastboot)
Run "fasboot devices" to verify that your devices is connected.
You can leave fasboot by entering "fastboot reboot".
If your device isn't connecting over adb whiles it is powered on, try checking that USB debugging is enabled in settings.
Sorry, I couldn't ask for clarifications. If adb works when your phone is booted, then you should stick with that.


text:
S21 Bluetooth interrupted by youtube links
In twitter, when scrolling thru tweets containing youtube links, bluetooth automatically attaches to the link ready to play it. This interrupts whatever was being listened to, even though I dont click the link to actually listen. Is there a way to prevent bluetooth anticipating my wanting to play the youtube in that way, so it doesn’t interrupt until I actually click the video link?

Solved! https://www.theverge.com/21422932/autoplay-videos-how-to-facebook-twitter-reddit-chrome-safari-edge-firefox

Welcome to Android Enthusiasts. Looks like you've found the solution by yourself, which is great! Consider posting it as a proper answer since self-answering is not only allowed, but even encouraged. Thanks!


text:
Delete photos from WhatsApp backup
I had recently painstakingly deleted lot of unwanted WhatsApp photos from my gallery to save storage space. But unfortunately WhatsApp has again restored all those photos (probably from backup). How do I say to WhatsApp that locally deleted photos should also be deleted in backup also?

Can I delete backup from Google Drive and rebackup from local storage? So that deleted images are permanently deleted.

If you delete the photos/videos you don't want. Then create a new chat backup, overwritting the old one that should fix it.
Might not resolve the longer term issue though.

What do you mean by 'might not resolve the longer term issue'?


text:
PNG Image Files Become Corrupt Shortly After Transferring From Computer
I am running Android 12 on a Galaxy A12 phone. Recently, out of the blue, image files that I transfer to my phone from my computer have been having the following problem:
At first, right after I transfer them, they are OK. I can view them in Gallery. When I'm done, I'll close that app. Later, I'll need to view them again, so I'll go back into gallery, but they will be corrupted. Gallery will just tell me "Unsupported Media" or some such nonsense and refuse to display them. I can transfer them over from the computer again, replacing the corrupted files, and they will work again for my first session of viewing them... and then they won't.
This never used to be a problem.
I am saving them to my external SD card. I have not tried saving them on the phone's internal storage, but that would not be feasible. My internal storage is tight, and I need to conserve it. The images happen to be PNG format images. That is what I use most commonly. I avoid JPEG due to it being a lossy format. But I CAN verify that this problem happens to GIFs as well.
I have tried using Gimp on my computer to open and resave the original images in the hopes that there was just something odd about the files, and Gimp would save them "properly". That actually worked for a few of them for a while, so I thought that that was the problem, but then even that stopped fixing them. Even my gimp-saved images started doing this.
I have tried installing and using several other gallery apps in the hopes that the default one was just stupid, but no luck. Nothing can view them once they spontaneously corrupt like this. I don't even know what causes them to go corrupt. Sometimes they will work for a few viewing sessions, quitting and restarting the Gallery and coming back to view them later a few times. Sometimes they will go bad after the first session. I can never predict when they will die.
Even more confusing, sometimes the thumbnail will become corrupt along with the image, causing the Gallery to display a blank icon both when listing images and viewing individual ones, and sometimes only the full image will get corrupted, so that I can see the thumbnail in lists, but not the full-screen image when I try to view it. It is completely unpredictable which images will do which.
I am at a complete loss here. Has anyone ever encountered this and/or does anyone know what is happening?
EDIT: I should also mention that any images saved before this started happening don't get corrupted. This only happens to images newly transferred after the problem started.

Welcome to Android Enthusiasts. I don't use an external SD card, so all of this is basically a guess, but could it be that the SD card might be encrypted? How did you set up the SD card; as portable storage or as internal/adopted storage?

What happens if you copy the corrupt image files back to the computer and compare them to their original source files? Are they still identical?

Samsung, external SD, photos? Ouch. My wife swears on Samsung. That combination ALWAYS turned out as you described: the Sammy phone breaking the SD card – on EACH of those devices (3 Galaxies meanwhile). Please check: does the same problem occur if you copy the photos to the internal card? I bet not. Which most likely means your Sammy ate your external card, as (to my experience) all Sammies do.

Just tried transferring back to the computer, and yeah. The file from the phone is wrecked. Both Gimp and Windows Photo Viewer are unable to open it, saying that the file is corrupt.
Next I'll try saving to the phone's internal storage...

As for how I set the card up, I have absolutely no idea. Portable storage? Internal adopted storage? What's the difference? All I did was shove it into the appropriate slot on the side of the phone for that purpose before starting the phone up.

Then there is a high chance that the SD-card is defect in any way. How old is the SD-card? If it is new it may be a fake card claiming to have more space as really flash chips are inside and writing to it overwrites existing data. If the card is old it may be simply be defect because of too many writes.

I don't remember how old it is exactly, but yeah. I guess it's at least kind of old. But I still don't want to risk yet another SD card on this phone if, as Izzy says, every one of his wife's Sammys have always broken their cards like this (and that I have now tried saving to internal storage and verifying that this is indeed the issue he describes). I think there's a much higher chance that it was the phone, not the card.

Furthermore, my Motorolla phones never had this problem with their cards. So I'm pretty sure the problem is Samsung. I switched on a whim to try something new. That was a bad idea. I liked Motorolla, and I should go back as soon as I can.

As @Izzy advised, I tried saving my pictures to the internal storage instead of the SD card. It seems he was right. The answer to my problem is simply that Samsung Phones have a major defect. In this case, eating/destroying my SD card.
At every turn, through one incident after another, I have been finding that experimentally switching from Motorola to Samsung when last I needed a new phone was the worst phone decision I ever made, and this incident has been the worst yet.
Never buy Samsung. Period. That is the answer/solution. And if you already have, your only solution is to discard it for something that actually works, instead of being actually LESS than not working--actually malicious.

I have used Samsung phones for 10+ years and I have used an SD card (the same one in fact) for at least 6 years.  And I replace my phone almost every 18 months. I have had no problems.  Perhaps you should be looking at the quality of your SD card !

No. Pretty sure it's the phone. See Izzy's comments on the original question. According to him, every one of his wife's Sammys have always broken their cards like this. I think there's a much higher chance that it was the phone, not the card.

Furthermore, my Motorolla phones never had this problem with their cards. So I'm pretty sure the problem is Samsung. I switched on a whim to try something new, not because there was anything wrong with Moto. That was a bad idea. I liked Motorolla, and I should go back as soon as I can.

Thats as much proof as my comment, which makes it null and void.  My wife also uses Samsung, and similarly, no SD card has ever been destroyed, ever.  ITs more likely to be the quality of the sdcard or some app you may have on the phone.  And I have 300+ apps, and it still works. !!!  As I change my phone, I take it out and plug into the new one.  I have swapped phones 4 times this year.

@Rohit Gupta My Sammy recently got destroyed since posting this question, and I had to buy a new phone. I switched back to Moto. It's cheaper, and better. It is already showing up my Sammy to have been relatively expensive garbage at every turn. I'll have to wait and see if it handles data transfer from computer to the card any better, but if it does, then consider the "More proof than your comment" acquired. I suspect it will, since the Motos I had previously to the Sammy did.


text:
Which folder contains the temperature sensor output for the CPU in /sys/devices/virtual/thermal?
/sys/devices/virtual/thermal/thermal_zone0/temp shows 37°C (37000 millicelcius) no matter what the actual temperature is. The device is Moto G32, Android 12, not rooted. Using cat on Termux to view the temperature.

Welcome to Android Enthusiasts. There is a similar question that may help: How do I get the temperature of my phone via ADB?. While the question mentioned ADB, the underlying command dumpsys thermalservice should be able to be called directly from Termux. Let us know if it helps. Otherwise, is there a requirement to get the value from that folder specifically?

While following the advice of Andrew make sure you give Termux the DUMP permission to access dumps from system services and then call dumpsys by its absolute path. Here's how: adb shell pm grant com.termux android.permission.dump; Then in your Termux environment, run /system/bin/dumpsys thermalservice

I'm currently away from my pc but I'll try this out and update


text:
Is Samsung's Facial Recognition secure on Galaxy A50?
Cheap Samsung phones have facial recognition functionality. The settings application states that if the "Faster recognition" option is enabled, "A video or image could be recognized as your face".
So, if I disable faster recognition my phone cannot be fooled by image/video? How can a simple camera decide whether it sees a real person or a photo/video?

Facial recognition in general is vulnerable to spoofing no matter what. It's all about how accurately a physical face can be constructed. Software based solutions make it more vulnerable because they don't have 3D data. An AI model can be trained to distinguish between a face in image/video and a real face. These things add little resistance against spoofing attacks but they don't make it impractical.


text:
Android boot password security
I recently purchased a security solution software for Android (Antivirus + additional security features). Before the installation, my phone started like this:

Android logo
Password
Phone manufacturer animation
SIM1 PIN, SIM2 PIN

After the installation, the order of the boot events has changed:

Android logo
Phone manufacturer animation
SIM1 PIN, SIM2 PIN
Password

Is this order more or less secure? What settings have been changed? Why does my phone ask password only after SIM PIN?

Android today uses File Based Encryption that doesn't require a password on boot. Its screen lock authetication is cryptographically tied to encryption. Password on boot used to be there when android was using Full Disk Encryption. Password at boot doesn't make it any more secure than what it already is with file based encryption.

@defalt - why don't you make that an answer?

@Rohit Gupta The difference between FBE & FDE has become too repetitive as an answer. It is now a common knowledge that FBE doesn't need password on boot.


text:
Android - getting current playing media/url from adb
How can we go about getting the current playing media (in this case hulu).  We would like to know the URL or the asset id via adb if possible.

You first need to find out which activity of the Hulu app accepts URLs. The you could construct a command-line using am start the activity name, the command -a android.intent.action.VIEW and the URL as -d argument. A bit similar to https://stackoverflow.com/a/58458736/150978 just additionally with the activity to be started.

Thanks we have the playing part working.  What we want to do is check which media is playing via ADB (or some other method?) via our scripts.

am start does not return anything so this way will not work. Does Hulu show a media notificvation (where you can pause/play the currently active media)? If it shows such a notification then you should try to read the notification.

Unfortunately I am not seeing a media notification when pausing as it's live TV in this case.


text:
YouTube : content is not available on this app
I have a very old tablet that I just use to cast YouTube and Netflix.
It stopped working yesterday, this appears on the screen where the video should be:
The following content is not available on this app
Watch on the latest version of YouTube

Tapping the second line brings me to the play store with no option to update the app.
Tablet is Android 5 and YT version is 16.4. I'm in Ireland (in case this is being rolled out at different dates globally).
Tried watching in Chrome but there appears to be no way to cast
Any way round this? Thanks.

The latest Youtube version 18.16 requires Android 8+. To continue to use YouTube without updating the app, on your mobile browser, go to m.youtube.com. https://support.google.com/youtube/answer/12318250

@Robert As I mentioned the web version does not allow me to cast, which is a deal breaker for me. Thanks for the link though, I see there are third party YT players, what would be a good one?

Looks like the latest version that supports Android 5.0 is 16.40.36. Not sure if it may help or not though.

UPDATE my YT app is working again. I did nothing to fix it, I guess YT saw a drop in revenue and allowed old apps access again.


text:
TWRP Unable to mount everytime I boot into TWRP recovery mode
After I installed TWRP and a Custom ROM everytime I boot into the Recovery Mode it says unable to mount storage or data and then I have to do the steps to fix it and then when i boot to system my files get removed
Steps I do when the TWRP can't mount:

I click the wipe menu
Then Advance Menu
and then I click the data and check it
And then I click the repair or change
I click change first since error 255 when I click the repair first
I changed it to HTX4
I reboot to recovery
I changed it back to f2fs again
And repair it
10 finished the mount problem is fixed

The problem is when I boot up and then reboot to recovery again the problem is back again and the data is erased

this is no "fix" to get "access" you're simply factory resetting device each time. booting into android will automatically re-encrypt the phone, and there is no way access encrypted data in TWRP. ask the TWRP maintainer for encryption support, use another custom ROM, another recovery, or simply disable encryption in ROM at all

How do I disable encryption in ROM?

with encryption disabler

Can you send the file for it

And also the custom ROM is android 13 can I still disable it

maybe if you add the necessary information in your question


text:
What URL does a homescreen shortcut contain?
I want to make shortcuts to OneNote notes on android in a certain folder (not app launcher folders, but folders visible in a file manager app). To do so I want to create a .url file containig the link to the note. Unfortunately, it is not possible to share notes with OneNote, thus I have no idea how the links look like.
I was given the idea to enable developer mode on my android device and then to check the logcat while tapping the Android home screen shortcut. This should reveal the full Intent which contains the link of the note. I tried to do so but I don't understand the android developer mode.
Is this a possible way to find out the link of a shortcut of the home screen? Can anyone who succeeds in this share a OneNote home screen shortcut link? I would like to know the link format so that I can make those shortcut link files by myself.

What I mean by "link format": For example, I figured out that simply adding ?si= at the end of a Spotify web link opens the app. Compare https://open.spotify.com/track/3Bp8X5z1jgq7HS0tCr0liJ which opens the song in browser to https://open.spotify.com/track/3Bp8X5z1jgq7HS0tCr0liJ?si= which opens the same song in the app. I hope there is a simple solution as this for OneNote: Once I know the differences in format I can easily make android shortcuts from web links.

I don't think you'd have success with OneNote's note shortcuts. They are dynamic app shortcuts. They are managed by system itself. The shortcut info is shared with the default launcher app which only knows shortcut id. Even with shortcut id, a user using ADB (am start) cannot do a thing. I tried it. Didn't work.

Here's what I tried: am start-activity -n com.microsoft.office.onenote/.ui.ONMSplashActivity -c com.android.launcher3.DEEP_SHORTCUT --es shortcut_id pageLocalId where pageLocalId differs for each shortcut. For a demo note it looked like this: am start-activity -n com.microsoft.office.onenote/.ui.ONMSplashActivity -c com.android.launcher3.DEEP_SHORTCUT --es 'shortcut_id' '{77A73696-E1EA-644B-9ECE-AEC247F25549}{1}'. Nevertheless, I didn't get anywhere with this.

@Firelord Is this here of some help in this situation: https://android.stackexchange.com/questions/231799/create-a-widget-shortcut-to-an-app-url/233199#233199 ?

No. The answer is not relevant. // You could ask at [so] "how to correctly launch an intent that has shortcut id of a dynamic shortcut".

Links formatted like `onenote:https://[linktonote] will open in the OneNote app if clicked. I was able to create a link and follow it both via clicking in a document and with a Task top open it (created with Tasker) linked to a home screen widget. I don't know how these would be selectable via a file manager app though. Unfortunately, you can't generate these links from within the Android app it seems, I had to right-click a note in the Desktop app and select "copy link to page," then get that to my phone.

@jlehenbauer This sounds amazing! Unfortunately, this is not the case for me.. I made another question about that issue. Maybe you can have a look? https://android.stackexchange.com/questions/251524/how-to-change-what-links-open-a-specific-app Thanks!


text:
In Android Go, how can I change the camera app?
In non-Go Android versions I can install camera apps (eg OpenCamera) and set as default camera app. Then, in my custom app I could select OpenCamera as the camera and take pictures from it.
I cannot found the way to do it in Android Go, i'm using a Nokia 2.3 with Android 11, the default camera app has no picture settings so I cannot lower the resolution, and so far I cannot set OpenCamera as my app camera then I'm stuck in high resolution photos but I need only minimal resolution for my app to use.
Any ideas?

It doesn't seem there is a "clear defaults" for the camera app as there used to be, but some people have had luck by disabling the stock camera app completely (Settings > Apps > Camera > Disable). This way, the next time something wants to access the camera, they'll be prompted to pick a default.


text:
How to open certain pages/ sections with OneNote app (not with browser) on android?
I want to have links that open certain OneNote notes. I was told in comments of a former question that we can achieve this like that:

Open OneNote on Windows, rightclick the note tab and choose "Copy Link of this note"
This gives two links, of of them beein like this: onenote:https://d.docs.live.net/...
Clicking on this link on an android device should open the same note page with the OneNote app

Unfortunately, this is not the case for me! Here is the screenshot of how a Desktop-generated OneNote-link looks on my android phone:

If I click on it the browser opens, not the app. In fact I am not too surprised because the beginging of the link, i.e. onenote:, is apperently not part of the link.
Further, I noticed that under Settings -> Apps -> Apps -> OneNote -> Opening standards only the following formats are listed under supported links: *.sharepoint-df.com, onenoteresume.page.link, *.sharepoint.de and *.sharepoint.com. So the suggested link format onenote:https://[linktonote] is not listed here. Can I somehow add it here? And: is the beginging onenote: important at all since it is not recognized as part of the link? I don't understand why the link does not open the app for me but does for others.

Yeah, the hard part is using this link through a service that will format it correctly. For instance, try pasting that link into a OneNote page itself and making that text it's hyperlink address. Then clicking it should take you to that other note.
A lot of services like Gmail, Messaging apps, etc. refuse to use anything preceeding "https://", invalidating the functionality of these links

@jlehenbauer What apps do you use that recognise the whole part being a link? Besides OneNote

It's hard to know what all works without trying each option individually. I was able to confirm that the "Browse URL" Task in Tasker will open these notes directly through the OneNote app.

I finally figured this out how to do this.. Step by step instruction how to create a .url file which opens OneNote app on android at the page you want.

Open OneNote app on windows, go to the section or page you want to have a .url for.
Rightclick on the tab opens menu, choose "Copy link for page"
Open some text app like Word and paste. You get two links, one stars with https://onedrive.live.com/... and the other with onenote:https://d.docs.live.net/.... Copy the onenote:https://d.docs.live.net/... link.
Create a new shortcut file by right-click in some folder or on desktop. In the first windows paste the link (including onenote:...), click next, then type in some name.
Clicking on this shortcut should open the correct note page/ section in OneNote app on Windows.
Share the file with your android device (if your email client forbids sharing .url files try uploading the file in a cloud).
Download the file from cloud to mobile phone (opening from cloud caused error for me).
Install the app Open Any URL.
Click on the downloaded .url file, choose to open with Open Any URL and it will directly open the linked page with the OneNote app!

If you use a cloud to fodler client like FolderSync, this approach helps you because you can access the same notes by opening the same .url file on windows and android.


text:
What should be whitelisted in a firewall to allow push-notifications?
I'm using a firewall (NoRoot) on (Samsung) Android (10) to try to harden it, but now, push-notifications aren't coming through. I'm trying to figure out which apps/services are responsible for that and what URLs/ports need to be whitelisted. I've seen several candidates that might be it:

System
A different System‽
System (Uninstalled)
Google Play services/Google Services Framework
AASAservice, Accessibility, … … …, Wallpapers, WlanTest (very long list)
Hiya Service

Most search results just mention this page which doesn't specify the app/service that requires the URLs and ports listed. Likewise, this answer (which is outdated since GCM is deprecated) also doesn't specify which service to whitelist. And this page outright recommends just allowing everything which defeats the whole point to a firewall.

I would like to add this answer as it contains a push related server https://android.stackexchange.com/a/233287/2241 But I fear the answer is outdated as I can not remember having seen mtalk server the last time I checked Google traffic using a proxy.

Related: https://firebase.google.com/docs/cloud-messaging/concept-options#messaging-ports-and-your-firewall

(I've been trying to do some tests to try to narrow it down, but without an easy and reliable way to induce notifications, it's been slow going. So far, it's looking like it might be the Google Play services, Google Services Framework app/service that needs to be whitelisted, though the catchall AAAServer…WlanTest service doesn't seem to want to shut up with its requests.  Also, I have Samsung Push Service whitelisted, but I can't imagine that's required for everything since not all Android is Samsung.


text:
Is call recording restricted based on GPS location, country you bought the phone from, the carrier, or something else?
A while back I was able to use call recording on my Android phone. These days, however, at best I can get only my side of any given conversation recorded, which is not enough for my needs (for example, recording a company doing something shady so I can report them).
I live in Canada, where it is legal to record your phone calls if at least one party is aware  of it. However, the feature is not available in my country for some reason. So I'm wondering, what decides whether those restrictions apply or not?
Is it due to my GPS location, in which case if I travel somewhere that supports call recording will I be able to record my calls? Or is it perhaps tied to the device itself, in which case I'd have to buy a phone from a location that supports this feature to be able to use it. Or perhaps is it tied to my carrier, in which case I'd have to somehow get one from abroad to be able to use it?
What decides whether a phone is able to record calls or not?

Regarding the country list, it's specifically about the Google Phone app. Thus, in this case, it's Google that decides the restriction. However, while I live in a country where Google Phone allows it, I've never seen such a feature on Nexus 4, Nexus 5, Pixel 3a (built-in Google Phone app). AFAIK, carriers in my country don't allow call recording.

@AndrewT. That list might be specific to Google Phone app, but it seems to apply to other apps as well. I think I tried 2-3 different phone apps that should have that feature but at best I could only record my own audio. So it would be nice to know where this restriction comes from...

If call recording in third party apps works (and how good) depends on the Android version.


text:
With magisk, how to bypass boot-time password input?
I have an phone with magisk and termux installed, and now functions as a mini server at home. Whenever I need to reboot the phone, I need to manually unlock the phone with GUI to get termux running, so I can not reboot when away from home.
Is there a way to let magisk decrypt the phone programmatically, with password written in some config/script file?

If you keep the phone at home then why not just remove the password?

@Firelord IIRC, FBE is always there with or without password, so even I removed the  password, android need manual swipe up at boot to get other non-core app running. See reference here: https://security.stackexchange.com/questions/266720/android-file-encryption-without-screen-lock

You can disable encryption from fstab. You then have to format the data.

Add a shell script that runs at start-up. It's just a matter of timing.
/data/adb/service.d/99unlock
#!/system/bin/sh
sleep 30
input keyevent KEYCODE_WAKEUP
sleep 5
input keyevent KEYCODE_SPACE
input text <SIM PIN>
input keyevent KEYCODE_SPACE
sleep 5
input keyevent KEYCODE_SPACE
input text <PASSWORD>

Make sure the script is executable:
chmod 0700 /data/adb/service.d/99unlock


text:
Gmail emails with images get stuck in outbox for 1-2 days
Android 11; Samsung Galaxy A20; Gmail app (fully updated):
When I send an email that has an image, the email gets stuck in the Gmail outbox folder (status = Queued) for a day or two before eventually being sent.
Details:

This issue started a couple of weeks ago. The Gmail app worked fine before then -- ever since I got the phone years ago. I'm not aware of any changes that were made to my phone/settings that might have caused this issue.
The issue happens no matter what the file size is -- not just for large photos. For example, a screenshot of a small area of the screen also has this issue.
The network type is a cell data plan, not Wi-Fi. Although switching to Wi-Fi doesn't solve the issue either.
I tried resetting the Gmail app by un-updating the app (can't uninstall the app), then re-updating the app. That had no effect. I also cleared the app cache and data.
The issue happens regardless of the email recipient.
I don't have this problem when sending emails that have no attachments.

Why are emails with attachments not being sent right away?

GMail app allows to use GMail as well as IMAP accounts from other mail servers. What mail account is your question about?

@Robert It’s a Gmail account. I.e. xxxx@gmail.com.

I don't have an answer as to why it's happening. But I did come up with a couple of workarounds:

Sometimes works: Refresh the outbox folder in Gmail by using the drag-down motion.

Always works: Send the email from the Gmail website in a browser instead of using the Gmail app.


text:
Reformat sdcard on every reboot in MIU13
I have an Android 12 with MIUI 13, Xiaomi Redmin Note 11 pro 5g.
sdcard works flawlessly, configured as an removable/external memory.
I reboot the phone, and it asks me if I want to use it as an internal or external memory (portable).
If I choose external, the only option I have is to format it and loose all my data.
This is a lot of overhead: copy old data, reformat it and copy again backup up data.
I already hat to do so when I upgraded from MIUI 12 to 13.
I don't desire to do this  every time I reboot the phone.
Any hints to avoid all this fuss?
I've checked with fsck that the partition has no problems.
Related info:

https://c.mi.com/uk/post/12553

UPDATE
Finally I've decided to:

backup all my data
format the sdcard with the phone
extract the sdcard
recopy all the data (a very lengthy process with a 128 Mb card)
reinsert in the phone

and now it offers me to format it again in order to use it.
 sudo fsck.exfat /dev/mmcblk0p1
[sudo] password for david:
exfatprogs version : 1.1.3
failed to get stream dentry. 0
failed to get name dentry. 0
failed to get stream dentry. 0
/dev/mmcblk0p1: checking stopped. directories 405, files 1562
/dev/mmcblk0p1: files corrupted 3, files fixed 0

So you want to use the sd-card as external. Have you tried to remove the card for a reboot? Have you tried to overwrite the first few MB of the card with zeros. You need a PC and an USB sd-card reader to do so (or a rooted phone).

Thanks.  What is the procedure for overwriting the MB?.  I have a PC and a sd card reader.

On Linux you can use dd command-line program. On Windows I would use HxD a simple free hex editor which is capable to open a whole disk, then select a block of a few MB and then overwrite it with zero.

I've installed by compiling https://github.com/exfatprogs/exfatprogs version 1.2.0, as it can repair the filesystem.
Then I run in a Linux PC with a card reader:
$ sudo /usr/local/sbin/fsck.exfat /dev/mmcblk0p1  -p
exfatprogs version : 1.2.0
...
ERROR: /Android/data/com.sygic.aura/files/maps: unknown entry type 0xc1 at 0000420 at 0x2c80420. Delete (y/N)? y
/dev/mmcblk0p1: clean. directories 414, files 3296
/dev/mmcblk0p1: files corrupted 0, files fixed 3

and now the phone accepts the sdcard.
I don't know why so many errors after recopying everything.
Maybe some Android app can do the same, and it will be more confortable to use, but probably it will need root access.

I tried with version 1.1.3. It failed. Version 1.2.1 worked.


text:
Get Android Emulator To Display/Render On A Dedicated Display
I have a phone sized external HDMI touch screen display.
Instead of the android emulator in a window on the desktop. I want to be able to display directly to that touch screen display.
A quick look through the emulator docs got me able to pass through the GPU directly to the android emulator but that still displays the "screen" of the emulated phone in a window on the desktop.
A Glance at qemu2 docs didn't reveal anything more.

Additional info/details about your PC's OS (Windows/Mac/Linux) (graphics system / GPU driver) setup and emulator commands you are using to display to the second screen may be helpful.


text:
How to install and run Tor with Snowflake client on Termux
Since the internet restrictions in Iran have become more severe as of October 2022, nowadays many Iranians are trying different methods to bypass censorship and connect to Telegram.
For example, using various proxies and VPNs. So I'd like to encourage them to use Tor - one of the most advanced and secure online anonymity tools. But some of those people seem to gripe that Tor doesn't work in Iran or that Tor's connection is extremely slow, humorously describing its speed as like a turtle with spinal cord injuries.
So I was wondering if there is a way to install and use Tor with Snowflake client on Termux, the Linux Terminal Emulator, which is probably a light-weight app and can therefore be used instead of the official Tor Browser and Orbot apps to provide faster performance.
After the installation, I also want to set a proxy in my Telegram so that all the Telegram's traffic will be relayed through the Tor Network. So could you help me do so?

I did a Google search and found this post on Ask Ubuntu site, which discussed how to install and use Tor with Snowflake bridge on Ubuntu 20.04 (NOT Termux). Based on what I learned from that post, I figured out a similar solution for Termux, which worked just fine after I tested it on two Android phones. However, after the installation of Tor and Snowflake on those phones, the Termux app took up a very large amount of the phone's storage space, which might be an issue of my approach. Below you can find instructions for installation and instructions for usage.
(Only for Android version 7 or higher)
Instructions to install
For the initial installation of Tor and Snowflake client on Termux, it is required that you have a separate VPN and keep it connected while performing Steps 1 through 4. After accomplishing Step 4, you no longer need that VPN, so you can disconnect it and/or even uninstall it from your device. Follow the instructions below:

First, download and install the latest version of Termux app from FDroid website. You do not need to download the F-Droid app (via the Download F-Droid link) to install Termux. You can download the Termux APK directly from the site by clicking the Download APK link at the bottom of each version section.
Open Termux and execute the following commands to install the packages required for Tor and Snowflake client.

pkg upgrade
pkg install tor golang git nano -y

Then execute the following command to download Snowflake source code.

git clone https://git.torproject.org/pluggable-transports/snowflake.git

Next, compile that source code by executing the below commands one-by-one.

cd snowflake/client
go get
go build
cd $HOME

Now it's time to configure Tor to use Snowflake bridge for connection. To do so, open the Tor's configuration file (known as torrc) in the Nano editor, by executing the following.

nano $PREFIX/etc/tor/torrc

Then in the Nano editor, scroll down to the end of the file, and append the three lines of code below.

UseBridges 1
ClientTransportPlugin snowflake exec /data/data/com.termux/files/home/snowflake/client/client
Bridge snowflake 192.0.2.3:80 2B280B23E1107BB62ABFC40DDCC8824814F80A72 fingerprint=2B280B23E1107BB62ABFC40DDCC8824814F80A72 url=https://snowflake-broker.torproject.net.global.prod.fastly.net/ front=cdn.sstatic.net ice=stun:stun.l.google.com:19302,stun:stun.altar.com.pl:3478,stun:stun.antisip.com:3478,stun:stun.bluesip.net:3478,stun:stun.dus.net:3478,stun:stun.epygi.com:3478,stun:stun.sonetel.com:3478,stun:stun.sonetel.net:3478,stun:stun.stunprotocol.org:3478,stun:stun.uls.co.za:3478,stun:stun.voipgate.com:3478,stun:stun.voys.nl:3478 utls-imitate=hellorandomizedalpn

Then you must save the changes you made to the file, by pressing CTRL+O. Then you will be asked to specify a file name; don't type anything and just press Enter, so that the file name will remain the current one (torrc).
Close the Nano editor by pressing CTRL+X.
Close Termux by pressing CTRL+D, and open Telegram app.
In Telegram, go to Proxy Settings, then add a SOCKS5 proxy with the following information:
Server: 127.0.0.1
Port: 9050
Username: admin
Password: admin

During the installation, if you haven't received any error messages so far, it means Tor installation on Termux has been successfully completed.
Instructions to use
After successful Tor installation, whenever desired, you can enable Tor and then easily connect to Telegram. To enable Tor, simply open Termux and execute tor. Then Tor will start establishing a connection to the Tor Network, and display some logs indicating the progress. So you must wait until the progress reaches 100%, i.e. you get the following message in the logs:
[NOTICE] Bootstrapped 100% (done): Done

Finally, you can open Telegram and let it connect through the Tor proxy.
Please note that after you finished using Telegram, it is highly recommended that you disable Tor and exit Termux, otherwise Termux would unnecessarily consume your battery power in the background.
Disabling Tor is really simple: just go to Termux and press CTRL+C; upon success, you'll get the following message.
Interrupt: exiting cleanly.

Next, exit Termux by pressing CTRL+D.


text:
How can I find deleted notes (even in recycle bin) in Xiaomi?
I deleted my Xiaomi notes in the cloud, but I saw my notes are deleted in the app too.
How can I find my notes? Maybe there are some folders. Should I root my phone to find them?

Comments have been moved to chat; please do not continue the discussion here.


text:
"Read phone status and identity" privacy issue
Multiple apps released in my country require the android.permission.READ_PHONE_STATE permission which means not only they get to know my phone number, they also get my IMEI. My second concern is that I have apps which are not even related to banking, financials or anything like that, which use this permission and that's just outrageous.
Is there any method in Android to prevent apps from doing that?
I'm a legitimate user, I have my own phone but I don't want to grant access to this data to companies which are leaking customer data left and right.
The only solution I can think of is having an Android VM on my PC, e.g. Android x86 and using these apps in it which is quite tiresome (and I've verified it works).
My phone is not rooted but if there are root related options, I'd like to hear them out.
Of course, there's Virtual Android made in China by God knows whom which is basically an entire Android 7.1 but I'm not ready to trust it yet.

On Android 10+ regular apps can no longer access IMEI.

As Firelord stated rooting fails the SafetyNet attestation; however, using Magisk has its own advantages ;) I'm on Android 10 with root and Xposed framework with all the banking apps working like a charm. SafetyNet is pretty easy to pass with Magisk. In fact, I use Pixelify GPhotos for unlimited google photos storage by faking it to be Pixel 5. I don't really need that but it's good to have it

Just a second thought.. the apps work fine even if you reject the permission which they don't necessarily utilize. In case you always allow all the permissions asked for. Like calculator asking for Phone permission

@Robert can you say more about this particular permission? Can apps still read my phone number? I have an old SIM card which includes it but strangely a newer one does not. Actually Android 11 already hides the phone number but only for apps "If your app targets Android 11": https://developer.android.com/about/versions/11/privacy/permissions

@44yu5h the apps I use ask for this permission specifically. Of course, I can unpack them, edit manifests, sign them again but I will have to do that for up to seven installed apps which is a chore.

Google enforces that new apps and app updates have a certain targetSDK. "app targets Android 11" means a minimum targetSDK value of 30. According to this all app updates that have been published after Nov. 1st 2021 have to target Android 11 or higher.

I've just run DevInfo https://play.google.com/store/apps/details?id=com.liuzh.deviceinfo on Android 11 and it happily reads my phone number. Darn. The app was last updated a week ago or so. IMEI is at least restricted.


text:
Prevent person-on-call from hearing YouTube audio playing on my device
I would like to know why can a person hear videos playing from my Android while on call with them? How can I prevent this?

Welcome to the Q&A site Android Enthusiasts Stack Exchange. Could you [edit] and clarify the situation: did you really play videos when on call? If yes, then the sound from your speaker might loop back to the microphone. One of the solutions is to use headphones/earphones. Otherwise, echo cancellation is another way, though I'm not sure if it's implemented on Android. Meanwhile, consider mentioning the device model and Android version too in case it's relevant.

Yes I was on a call with someone while playing a video on YouTube at the same time and they could hear what I was playing.

It seems there was an older question with a similar case: I'm on a WhatsApp call and the person can hear my audio from YouTube etc. Consider checking the answer and let us know the result.


text:
How to make Pixel 4 XL automatically turn on once power is connected?
I am trying to recycle my old Pixel 4xl into a screen for my 3D printer. Since it does not hold a charge anymore, I need it to be able to power on when it gets power from the printer. I tried following the instructions from this post, but none of the files listed in any of the answers exist on my device. I also tried running the command: fastboot oem off-mode-charge 0, but it is giving me an unknown OEM command error. I am using LineageOS 19 on the device.

I must've missed it when I first read the post, but the magisk solution worked!


text:
"Issue with your SD Card" when copying files from Linux to memory card directly
Every time I copy some music and photos from my Linux computer to my phone, my phone says the SD card is corrupted.
Here's more details:

I formatted SD card from my phone.
Ejected the SD card from phone.
Connected the card to PC running Linux with a card reader.
Copied files to the SD card's Music/ and Pictures/backgrounds/ directories with Nemo file manger (didn't delete anything that's put by the Android formatter).
Ejected SD card from PC.
Inserted SD card in phone.
Phone says to format the SD card with message: "Issue with Sandisk SD card" "Tap to fix".
Inserted the SD card again to PC and everything looks good on PC, no files seem to be corrupted.
To eliminate the possibility of a software-related issue, I performed a restart of the phone and started all over again from 1.

If I format SD card, everyone knows what happens, and then I repeat step 2 to 6 and it still continues to show same message. What could be the issue here?
This doesn't happen with data cable transfer or SSH transfer. But what's going wrong with SD card?
I see the files have owner of the PC, the files are readable by the default user, and no other attributes are set with chattr for example.
EDIT

This time I copied 5 music, and it's still corrupted.
Looks like copying or creating any file makes in incompatible.

EDIT 2
TL;DR: Issue fixed somehow
I was able to reproduce this issue multiple times, persisted across reboots, but somehow I was able to create an empty file which didn't corrupt the SD card, then I was able to copy all the Music, it worked as usual. I am not sure what happened there.

it's a windows file system, needs fsck_msdos all the time :)

This ^^^ and you should avoid that procedure. Keep the SD card in the phone and use USB to transfer the files.


text:
File does not be sent in KDE connect
I have galaxy J7 and lineageOS 17.1. When I send a file with KDE connect from my phone to another device (another phone or a laptop) I am successfull, but in reverse not. For example when I try to send a file with KDE connect from my laptop to my phone a notification appears saying "failed receiving file from ...".

Ensure that the phone KDE Connect app settings are set for this. Go to the phone's Settings, then to the settings for Apps, select KDE Connect, and then set "Storage Access For This App" to 'Allow'.
Ensure that, in the phone KDE Connect app, you click on the device (e.g., a laptop) you're connecting to -- and then set the 'Share and receive' settings for that device. Without this device-specific setting, the file transfer attempts may fail.


text:
Connection fails when receiving photos from Nintendo Switch
I am attempting to wirelessly send screenshots from my Nintendo Switch to my Asus Zenfone 8. However, when I try to scan the QR code to connect to my phone to my Switch I get a "Connection Failed" error. I tried manually connecting to my Switch in the wifi settings and navigating to "http://192.168.0.1/index.html", but the page was stuck on the loading screen in Firefox.
Why can't I transfer photos from my Switch to my Asus Zenfone 8?

You should first check your Wifi router, most routers deny Wifi-to-Wifi connections by default.

I think this option has the switch emulate a wifi hotspot jtself


text:
How to turn off incoming phone calls while I am on a zoom / whatsapp call?
Often I am on an important whatsapp or zoom video call meeting and it gets suddenly interrupted due to an incoming phone call. Looks like my data gets temporarily disconnected when an incoming call comes in.
Is there a way to turn off incoming phone calls temporarily?
I cannot turn off mobile data since I need it for the zoom / whatsapp call. Airline mode will also not work.
I tried the  do not disturb setting but not sure what that even does.
Any ideas?
If it matters, I am on OnePlus 9R


text:
Will some of my photos and files still remain in the memory if I do a factory reset?
Just wondering... If I sell my Android phone, is it possible for the new owner to use some data recovery software and recover some of the files?

No. except you have pre Lollipop device or manually disabled encryption


text:
How to give an app permission to see a subset of contacts
Some apps require access to my contacts list in order to function (e.g. WhatsApp). I am concerned about the privacy implications of giving permission to apps to see my entire contacts list, which may include private information that is not relevant to chat apps (e.g. birth dates, home addresses, personal notes, etc.). Is there a way to limit the contacts that an app can see? I only want to expose a subset of my contacts list to such apps.

What you want is not possible on stock devices.

@Robert Is it possible if I have superuser privileges on my phone?

ON a rooted phone this is possible but very complicated e.g. using [Ed]Xposed + XPrivacyLua. But both technologies are more or less EOL, and have many disadvantages so I would not recommend it.


text:
Can I still restore a crypt8 whatsapp backup from mid-2015 on Android in 2023?
I still have the same phone number. Is this local backup too old to restore?
Is there a limit on how old a backup I can restore on whatsapp?
On, https://faq.whatsapp.com/618575946635920/?cms_platform=android , it seems possible to restore older backups, however the example formats are crypt9+

What have you tried already?

Nothing. However I'd like to know before I try...


text:
Can serialNumber of hardware attestation certificate be used to uniquely identify a device?
When performing hardware attestation on Android, a new key-pair is created in the TEE, and the whole certificate chain is returned to the user, verifying that the key-pair was indeed created in the TEE.
Non-privileged apps on android can't force TEE to return Serial, MEID and IMEI in the key-pair certificate extension. At least, if they don't have READ_PHONE_STATE permission (but if they do, they can read it using android API anyway).
At least on Google Pixel and Samsung devices the chain consists of:

Generated key-pair certificate. It is unique for each key pair, that is, for each attestation request.
I suppose, device certificate. Unique for each device.
I suppose, manufacturer certificate. But on my devices (3 Samsung phones, the model of 2 of them is the same), it also was unique for each device.
One of four Google Root certificates

Unlike the key-pair certificate, the second certificate in the chain, I suppose, the certificate that is unique for each device, has a serial number. See here, same for my samsung devices.
I could not find any proof that this certificate and serial number is indeed unique for each device, or is it just a coincidence that on my devices that was the case.
So I want to ask here, is it true that the second certificate is unique for each device and can it be used to uniquely identify a device?
Unlike Android ID, that is unique for each application since Android 8 (API level 26), this serial number would be the same for all apps in the system, which makes it suitable for identification of the device without READ_PHONE_STATE permission.

If the certificate that may be is device unique are part of a certificate chain then device specific certificate would have to be generated while manufacturing the device because later this can not be done without the private key of the used CA certificate (which is not present on the device for sure). The effort for deploying device unique certificates in production in a secure way requires a lot of effort, I am not sure if this is done for every Android device. Thus I would assume certs are model specific not device specific.

You need two phones with the same hardware and Android version + patch level and then  compare their certificates if they are device unique or not.


text:
How to approach .local addresses in LAN from Android?
Using .local domains supported by mDNS or Avahi from devices in the same network as my device works flawlessly on macOS, Ubuntu and iOS.
I use it to make http(s) or SSH connection to a device inside the network.
But using a domain like e.g. macbook.local from Android does not work, while it does work from iOS or Ubuntu in the same network.
I have Termux which allows installing Avahi daemon which does allow approaching my Android device from the other devices by androidphone.local (name set in $PREFIX/etc/avahi/avahi-daemon.conf within Termux). But the other way around still does not work, even from within the Termux environment. I use Android 10 and on the other devices macOS 13, iOS 16 and Ubuntu 22.04.
What am I doing wrong ?

If I understand it correctly the approach uses local DNS server. Are you sure Android does make use of it and not an external DNS server? Check Android network settings if privacy DNS is active, if yes it uses external DNS.

That's the expected behavior. Android devices are discoverable to other devices on local network through mDNS but not the other way because Android's DNS resolution process doesn't use mDNS. More details in this answer.

@Robert mDNS is decentralized. It doesn't use a central DNS server. Every mDNS device is a server (and client) in itself.


text:
Locked out - Changing PIN via TWRP recovery when disk is already decrypted
I have a rather unusual scenario for which I need your help. I am running an OP9 Pro with Nameless ROM A13 and Microsoft Intune forced me to set a 8-digit PIN. After the last update however, Nameless started to automatically decrypt (FBE) after entering 4 digits after booting even though I need to enter 8 digits, which is probably a bug. When going into TWRP recovery, the decryption with the 8 digit code works just fine, so I backed up my data in case a reset is needed.
However I am wondering if there is any other way via ADB to change the PIN back from 8 to 4 digits. When in adb shell, it says
OnePlus9Pro:/ # locksettings clear -- old XXXXXXXX XXXX
/system/bin/sh: locksettings: inaccessible or not found
Maybe I'm missing something here. Would appreciate your help. Thanks
Edit: Would it be sensible to try to dirty flash another ROM without said "bug" over this?
Edit 2: This circumstance actually prevents me from using my phone, as it automatically tries to unlock after entering 4 digits (even though 8 are needed) and therefore fails to unlock. By decryption in TRWP I knew that the 8 digit PIN is still correct and in place.

it seems credentials aren't used, otherwise one of both would fail to decrypt

Sorry I may have not been clear enough, the regular PIN screen right after booting is preventing me to unlock/enter my phone because of said scenario. It automatically tries to unlock after entering 4 digits (but 8 are needed) and therefore displays "Wrong PIN". By decrypting via TRWP I just got reassured that the 8-digit PIN is still valid.


text:
Delayed notifications on Samsung Galaxy S21
On many apps on my Samsung Galaxy S21, notifications are significantly delayed. I have tried all suggestions but nothing seems to work.
These suggestions don't solve the problem:
How do I fix delayed notifications on Android - 1
How do I fix delayed notifications on Android - 2
How do I fix delayed notifications on Android - 3
I also tried not to close the apps but only use the Home button. But still, android sooner or later terminates the apps resulting in delayed push notifications.

You must have tinkered with the settings. Check battery optimisation


text:
Run init rc script after package manager have loaded
I'm writing an init service which make sure a package is installed and if not, it will install the apk.
The problem is, that currently I'm using a boot trigger with on boot but when I run pm install from there it doesn't seem to work. I've used a sleep command to wait for the package manager service to load but I would like to find a proper solution.
I've had three ideas which all seems to lead to me to a dead end:

wait for a prop to show up, but the package manager service doesn't create any.
wait for a file to show up, again no such file exist
set my service in a class but it seems to be relevant for the service itself and not the trigger or am I misunderstanding something?

My current service definition is like so:
on boot
    exec_background -- /vendor/bin/install.sh

Please share how you are starting the service (e.g. class_start, exec, ...) and the service definition. What property have you tried to trigger on sys.boot_completed or dev.bootcomplete?

You need to wait for the zygote (along with all of its services, which include PackageManager) to start. on boot is fired at very early stage. Use on property:ro.runtime.firstboot=* && property:init.svc.zygote=running && property:init.svc.bootanim=stopped && property:sys.boot_completed=1.

Sadly it didn't seem to work, pm install still failed

@yotamN failed with what error? Are the above properties set on your device?


text:
"FAILED (remote: 'size too large')" when flashing recovery image of Pixel Experience (Android 13) on Redmi 10
I'm trying to flash Pixel Experience (Android 13) on Redmi 10.
PS F:\android\Redmi 10\codice per il recupero del telefono\platform-tools> fastboot flash -S 4056M boot PixelExperience\recovery.img
Sending 'boot_a' (131072 KB)                       OKAY [  3.029s]
Writing 'boot_a'                                   FAILED (remote: 'size too large')
fastboot: error: Command failed

This is the error after starting the fastboot flash boot. I also tried -S which should crop the partition, but it doesn't work.
If you have any ideas to solve the problem, I gladly accept it.

That command fastboot flash boot <recovery_filename>.img don't look correct to me. A recovery image should not be flashed to a bootloader section.

@Robert apparently the official guide does mention boot.

Seems to be a workaround to compensate the missing recovery partition, so the the recovery is a recovery including bootloader? But as it is way larger it is not unexpected that it does not fit into the bootloader partition. May be there are devices and/or fastboot tools that ignore this and just flash it. or the manual is simply wrong (automatically generated).

As it is stated on the official guide   "NOTE: Outdated fastboot releases dropped legacy A/B support, so it might attempt to flash to boot__a / boot__b rather than boot_a / boot_b if you try to flash boot. In this case, you must update fastboot to a release newer than or equal to 31.0.2. Alternatively, you can manually specify which slot to flash to based on what slot fastboot failed to flash to. For example, if fastboot fails to flash to boot__a, you must flash to boot_a."

Note there are 2 underscores in boot__a and so on


text:
Motorola Moto G200 brick with error "No valid operating system"
I need help with Motorola Moto G200 whose bootloader stopped working after a bad overclock using the KonaBess app. I have tried to turn it on by myself, and I have even taken it to a technical service, but there is no case.
Attached is the error when turning on:

No valid operating system.

I tried RSI, CMD, and EPROM, and they all end with the same error message.
I am an amateur technician and I still do not specialize in these delicate issues, but I think I have burned the GPU or some internal interconnection of my smartphone. At the time of flashing the ROM, the vendor, boot.img, and bootloader.img fail in chain, and the superpacks are loaded correctly until the fifth, the sixth package or superpack does not load and dies there.

Sounds like the eMMC storage or the mainboard itself is bad... Attempting to repair this yourself is going to be almost impossible, and in most cases if a service center won't do a mainboard swap under warranty, it's likely not economically repairable.


text:
I cannot sync time with Microsoft Authentication app
I can not log in with 2FA from Microsoft Authenticator. Although the time is correct on my Android phone, when I use the authenticator app, I can not log in to my sites. It displays the wrong code. How to fix this?
I tried to set my phone date/time to automatic but the problem remains.
I googled and find on the search there is an option to sync time inside Microsoft Authenticator, but I can not find this option in the settings menu.

Do you live in a country with a recent timezone/DST change?

@AndrewT. yes this caused problems with other software as well

Ah... if that's the case, then I believe you have to set the time manually ignoring the automatic time, until your device receives the time zone data update (if applicable).

@AndrewT.I set time manually but I dont know how to use the link you provided. Can you write this as answer with steps ? I have Android 10

Microsoft removed that option from the Authenticator app with an update nearly 5 years ago. Using a local time should work without any issue. If your phone time is synced with the internet, the app will work correctly.

Microsoft Authenticator, wrong code issue, comes up if you have both 2FA and authenticator app enabled for an account.
You must delete all the accounts added to the app and re-add them to fix this.

Read this for more.

If they still don't work:

Check if you have an authenticator working on any other device, compare the time.
Try setting the time to the time zone you used to use earlier.
Or as always, clear cache, app data/reinstall, and reboot. Try again.

Thanks, tried all these methods but did not work. I tried now to use another app called authey and when I open the app it display message that time not synced but still work and I was able to login with 2FA. I have many accounts use Microsoft Authenticator , it is a big problem. When I set time to auto it display the wrong time and this also did not work.

Hmm.. that's oddly strange. Did you try removing and re-adding accounts? It worked for me the last time I had this issue. Also can you try logging in on any other device? There shouldn't be anything apart from these, make sure you are doing things correctly :)

yes I tried remove and add accounts . I tried now to use on another device but this device has Android 7 so it display this app can not be installed on this device


text:
Issue with Android Emulator Directional pad Buttons looks
In the extended controls of android emulator, i have an issue with messed up graphics of Directional Pad buttons.
Does someone know what might be the issue here. Also, i was wondering if new buttons with different Key event functionalities could be added to the Directional Pad.

Can you try using API 31 or 29?

I have to use API 33 for this project. Any idea how this issue could be fixed? Can i soemhow change these buttons in the android image or emulator files?

Looks like the icon/mask is slightly shifted, possibly due to not enough space. Have you tried resizing the window, particularly enlarging it?

As Andrew stated it might be a solution. Also try disabling the Google Assistant text box beside it (if there is an option to, there should be)