yashsingh1/xdaforums huggingface dataset:
[FYT Android Head Units] mastrv:
OK. So, i've checked the log again and it looks like two different things are being called or processes are used to call the app to handle a call. When try to start a call by saying "Call Mom & Dad", the Telecom server is firing this:

03-17 15:47:20.349 3651 3651 I Telecom : EmergencyInCallServiceConnection: Attempting to bind to InCall [ComponentInfo{com.google.android.dialer/com.android.incallui.InCallServiceImpl} supportsExternal? true supportsSelfMg?false], with Intent { act=android.telecom.InCallService cmp=com.google.android.dialer/com.android.incallui.InCallServiceImpl (has extras) }: PCR.oR@AEw

which I believe is the XDA Google Phone Dialer apk that I installed. So whatever apk that is supplied needs to implement an InCallService action. I found two projects on GitHub that should be able to be modified for this purpose:

https://github.com/arekolek/simple-phone

https://github.com/Abror96/CustomPhoneDialer

The first is a barebones dialer/phone in Kotlin and the second is a Java version of the first one. I figured first compile and install the app(s) and make sure the Telecom server will call it. After that, make a change so that it forwards the request to the Bluetooth app/dialer on the head units, such as GVC CallHandler.

I installed Android Studio and finally figured out how to make release versions of the apk that correspond to those two projects. However, when trying to install them, they won't install. Not sure why. Still working on it.
[FYT Android Head Units] mastrv:
This issue installing the app was related to signing the release apk. I made a debug version that installed successfully. Tried the app on my phone and it worked. Will try it on the head unit. If that works, I'll go about making the changes required to redirect the call to the Bluetooth app on the head unit.
[FYT Android Head Units] Kurosoul:
Can I get the link to your modded radio for the 9853i? I've trying to use access the 4pda but no success.

Thank you for your time 🙏
[FYT Android Head Units] mastrv:
Sure.

Are you in the GTA area as well? If not, I can let you know how to modify the apk so that you can specify other stations and images.

I'll post the apk a little later. One of the users on 4pda helped many users with the radio greatly...user tyukhta.
[FYT Android Head Units] mastrv:
Here it is...
[FYT Android Head Units] Kurosoul:
No I'm in the OC California area, yes I would appreciate if you can let me know how to modify the apk.

Thank you for the guidance.
[FYT Android Head Units] mastrv:
To modify the radio stations, open the apk with 7-zip. Do not add or remove files. Only update the existing files. Keep the file names the same. This will be the easiest way to add/modify stations.

Modify the radio_freqs.json file within the res/raw directory. You can add entries or modify existing entries. Use a text editor that uses Linux type formatting, such as Notepad++. Each entry is something like:

"freqName": "KLOS Rock Station",

"freqLogo": "CA50",

"freqNum": 9550,

"cityName": "Los Angeles",

"userRadios": []

freqName is the text displayed for the station.

freqLogo is the filename of the station image. For example, in the above, the image file would be named CA50.png

freqNum corresponds to the radio station frequency. When tuned to 95.5MHz FM, then this information is displayed.

cityName corresponds to the city name that must be specified so the station data is used. For example, when "Los Angeles" is specified for the radio station, all stations that have cityName of "Los Angeles" will be used. You specify your city by going into the radio settings by clicking on the little disk image on the bottom of the radio screen...2nd from the right.

Make sure you don't miss or add any quotes. If you do, the whole file may be ignored as it won't be valid JSON format. If you're curious about JSON, there are many examples and lots of info found by Google.

Only 18 (6 x 3) stations can be selected for display on the screen. You can choose to only have 18 entries of your choice or all of those in you area. When scanning for stations, all entries that match will display the logo you specify.

For station logos, replace existing files in the res/drawable-nodpi-v4 directory with the logo file(s) you provide. They should match the same format as those you replace. Some formats may not work. If the image has an issue or can't be found, a default image is displayed.
[FYT Android Head Units] Kurosoul:
I will try my best and this out, I appreciate the lesson 🙏
[FYT Android Head Units] mastrv:
Back to voice calling issue...

Good news. I have successfully modified, installed and tested changes to the CustomPhoneDialer so that I can now "Call Mom & Dad" from Google Assistant and the call is completed through a bluetooth connected phone.

I used some code from GVC CallHandler which finally worked properly.

I noticed something odd the first time I tried it. When I tried again, and from that point forward, it worked each time. This may be similar to some of the code in GVC CallHandler which stopped another Google process before proceeding.

A remaining issue is that the app is compiled in debug mode. Trying to figure out how to make a release version of the app. I'm also considering putting this up on the Google Play Store...not sure.

I'm going to be testing this more and post updates later.
[FYT Android Head Units] mastrv:
Still testing but I thought I'd post the debug version, if you'd like to try it. In other tests that I tried, it looks like it may have an issue, sometimes, where the call is not made and on the second attempt it works. Not sure if this happens all the times. I believe this was also something GVC CallHandler had code for.

One thing I'm definitely sure of, make sure you have an internet connection that is sufficient for Google Assistant to function.

The code that was added / changed is in the CallActivity class. The start method in this calass is called whenever a call is added. What this previously did was to invoke an activity to make the call...itself. I changed the method to the bluetooth activity, similar to GVC CallHandler as follows:

public static void start(Context context, Call call) {
/* Old code
Intent intent = new Intent(context, CallActivity.class)
.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
.setData(call.getDetails().getHandle());
context.startActivity(intent);
*/

try {
Intent intent = new Intent(callIntentCommand).setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intent.setClassName(bluetoothPackage, bluetoothApplication1);
intent.setData(Uri.parse("tel:" + call.getDetails().getHandle().getSchemeSpecificPart()));
if (!isCallable(context, intent)) {
intent = new Intent(callIntentCommand).setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intent.setClassName(bluetoothPackage, bluetoothApplication2);
intent.setData(Uri.parse("tel:" + call.getDetails().getHandle().getSchemeSpecificPart()));
}
if (isCallable(context, intent)) {
context.startActivity(intent);
} else {
Toast.makeText(context, R.string.app_notfound, Toast.LENGTH_LONG).show();
RuntimeException e = new RuntimeException("No BT App found!");
throw e;
}
} catch (Exception e) {
Toast.makeText(context, R.string.startapp_failed, Toast.LENGTH_LONG).show();
throw e;
}
}

private static boolean isCallable(final Context context, Intent intent) {
List<ResolveInfo> list = context.getPackageManager().queryIntentActivities(intent, PackageManager.MATCH_ALL);
return list.size() > 0;
}

Changes to variables and a few resources were also made.

I'll keep testing and post release app when available.

Note, unless the Telecom server is updated as discussed previously in this thread, this will not be called.

UPDATE: My Java skills are rusty. I had to make code changes to handle static / non-static calls. Not sure if I did it correctly. Any suggestions are welcom.
[FYT Android Head Units] mastrv:
GVC CallHandler does a few other things.

Maybe I should just change the code to call GVC CallHandler which then calls the Bluetooth app.

I think I found an updated version of the GVC CallHandler app that is more recent than the one in the Google Play Store. I think it was on 4PDA somewhere. It was updated to be more generic and not reference Joying, I believe. Not sure what other changes were made.
[FYT Android Head Units] mashrom:
Hello,

Google app is no more searching it hangs before showing the results for all types of searches. It hangs with ~80% progress bar without presenting the results. If I make a search through chrome ,it browses correctly till the end. I did clear data, update for Google App and even reverting to the orignal version by deleting all updates of Google App with no hope. Any help please?
[FYT Android Head Units] mastrv:
I changed the code to call GVC CallHandler and it seems to be working OK. I don't use the car too much these days. I'll post results after more testing. This is still the debug version. The latest version is attached. I've also attached the version of GVC CallHandler that I'm using...from 4PDA and it seems to be newer/changed from the market version.

If you're going to use it, you must have GVC CallHandler installed and both this app and GVC CallHandler should be given phone permissions. When you are first asked which dialer to use, select GVC CallHandler and make that the default "always".
[FYT Android Head Units] surfer63:
So the app-debug.apk is the Google Phone dialer modified by you?

And both apks need to be "normally" installed as any apk, or in /System or /oem?
[FYT Android Head Units] mastrv:
@surfer63, Yes. App-debug is the bare bones phone app modified by me. Both of these are installed normally. No root is required.

Also, you need to have the telecom server/app that has the proper intent-filter to handle the request from google assistant voice call. If you're not sure If you have the correct telecom, try the two apps first. If you get an error toast message that the app isn't installed, then run the script to replace the telecom apk with the one provided by bambapin. The script is in a previous post. It saves your old/existing one to the sd card before replacing it with the new one.
[FYT Android Head Units] mastrv:
This post recaps some of the work done to enable voice calling using Google Assistant (GA) through a Bluetooth attached phone on an sc9853i FYT compatible Android Head Unit (HU). I have a TEyes SPro 4/64 with CC2 firmware installed. This should work on other FYT compatible, including Joying units, but no guarantees. This includes required files and instructions/steps for those that may find this at some point in the future.

Attached is the software to enable GA voice calling:

Telecom script to update the Telecom server, if required. FYI, the Telecom server on my head unit was missing code to handle the voice call.

The updated simple phone app that is called by the GA when a voice call is made. The Telecom server calls this app when the voice call is made. This is a release version and not a debug version of the app.

GVC CallHandler I used. This app is called by the simple phone app. This app passes the details to the Bluetooth app to make the call.

Instructions:

Ensure you have up to date/latest Google Assistant, Google app and the Google Contacts app and they have appropriate or all Permissions given...from Play store if you don't already have them.

Install the attached GVC CallHandler and CustomGVCBluetoothPhoneHandler applications normally and give them permission to make calls. Root is not required. The GVC app is available from the Google Play Store. That may work, but the attached is a version that I tested with.

Try voice calling using Google Assistant...say "Call xxxxx" where xxxxx is any of your contacts from Google Contacts. i don't believe that Google Assistant uses contacts from the Bluetooth phone app on the HU. If prompted, set the GVC CallHandler as the default app to make calls. One of two things will happen:

It works and no messages or errors occur....the call will be made and you are finished! Note that there seems to be an issue where the first and/or second attempt don't work. Try the voice call a second or third time.

It doesn't work and a message similar to "App isn't installed." then you need to replace the Android Telecom server app that is currently installed on your head unit.

To replace the Telecom server, unzip the attached telecom_script.zip to a usb drive and insert into the HU. This should invoke the standard update process. The script includes the original TEyes Telecom server from my unit and the new one from another Joying unit, as described in a previous post. When it runs, it creates some information from your unit as well as copying the existing Telecom server on your head unit to the USB drive. If you need it or want to re-install it at some point, save it somewhere. You can also get it back from your own firmware.

If it didn't work previously and you replaced your Telecom server, try the voice call again.

That's it...it should have worked.

I'll be trying to figure out more info about the voice call not working on the initial attempt(s). I suspect I won't be able to determine the issue as I believe it occurs within the GVC app.

If you update to a different / newer firmware in the future, you will probably have to repeat this process.
[FYT Android Head Units] acain:
I have recently got a Joying UO138N4GSN 4GB/64GB SC9853i 1280x720 - 8 inch screen.

I was wanting to change the Density/DPI as I find the home/back buttons too small.

From what I've read it seems that I have to root the device in order to change the DPI.

I rooted and changed the DPI, however, Google Assistant doesn't answer with voice. (It shows audio volume 0) I understand this is due to the rooting?

I thought I would change back to the un-rooted boot image, which I seem to recall that worked with Assistant.

My question is - will my DPI setting be maintained or will it revert back to 160?

If it does revert, is it possible to add the density setting to the build.prop (fyt.prop) and use the method in start of the thread to change the DPI using the non-root method?

​
[FYT Android Head Units] surfer63:
Google Voice is indeed crippled when you root your unit.

DPI is a "persistent" setting which means it stays like that until you change or do a firmware flash of your unit.

If you only replace the boot image again, so only flash the boot image, the DPI setting will remain.

I did not try to add the DPI to the fyt.prop, but indeed you could create an alternative Allapp.pkg and only put an extended fyt.prop in there.

I did not test that yet.
[FYT Android Head Units] mastrv:
The way I changed the screen DPI was found here: https://beebom.com/how-change-dpi-android/

There's a section that talks about the app "DPI Changer". That's what I used to change my DPI without root.

The old app that's being used can be found at: https://m.apkpure.com/dpi-changer/com.zacharee1.dpichanger

You use adb to execute the command described to give the app permission to modify the settings.
[FYT Android Head Units] pajo985:
There is no need to root or to mess with adb to change DPI.

You only should install this app:

Hidden Settings For Android - Apps on Google Play

It can open practical settings which some phone vendors hide for user

play.google.com

With hidden settings you can change font size / display size like on any other Android device.
[FYT Android Head Units] mastrv:
@pajo985 Have you actually used this on an Android Head Unit, such as the one for this topic?

I was looking for the font size / display size in the default settings for the head unit, but it was not there. I'll check if I can see it in a "hidden" setting.
[FYT Android Head Units] PieterD82:
Hey all, very much new here and owner of a (European/Belgian/Dutch) Opel Astra J with an "unbranded" head unit. I'm reading a lot of very interesting info here and i'm building up the courage to make modifications to this unit. So far i figured out that it is FYT but some things are not adding up to what i'm reading here. I tinker a bit with APK's using programs like APK Editor Studio v1.4.0. My main (simple) goal is to try and change the blue background images from apps such as Radio and Equalizer and such. I'm not a fan of "blue"

I've seen people post their HWget_info files, so i will do the same. I would truly appreciate someone taking a look at that and give me the green light to go ahead and do the changes i intend to do.

Thank you.
[FYT Android Head Units] 2ndjobmoney:
I have one question.

Can syu.ms.apk effect touch screen sound?

I use sc9853i android head unit(not joying) and custom firmware made by another user using this product.

All sound is working(calling, music, media..) but touch screen sound and steering wheel button sound is not working.

I tried to change syu.ms.apk from another custom firmware working touch sound to now using custom firmware, and touch sound working but after reboot or factory reset, all sound(calling, music, media....all sound) not working.

My head unit, touch sound setting menu is on, but sound not working, and in my head unit, only amp switching on/off menu is exist, in factory setting, no amp select menu not exist.

Would you advice me to solve this situation?
[FYT Android Head Units] surfer63:
It is indeed a FYT sc9853i.

If it is only the background, you can unzip the apk (and I mean unzip, not decompile), for example 190043001_com.syu.radio.apk, and go into "res/drawable-nodpi-v4/" and change bk_radio.png, and then zip it again. (Where 43 in the name is the number of your vendor. 43 is Joying. For some nameless units it is 00 or 01)

For the other apps it is comparable, but sometimes it is a left image, right image and bottom image making the screen.
[FYT Android Head Units] surfer63:
You already mention it is a custom ROM. Probably one that does not function correclty.

Advice: flash the original firmware.
[FYT Android Head Units] PieterD82:
I went ahead and tried it. Following your instructions and guidelines. It worked like a charm, so thank you very much for sharing your knowledge.

I've investigated the device further. It is an unbranded one, claims to be android 10 but an app called "fake device tester" confirmed my suspicion, its an 8.1. The device has a couple of highly irritating limitations that might be undone doing the proper changed, so i'm looking into releasing those and if successful, share them obviously.

some of the irritating limitations are: it has a modified app called "touch assistant" You can find it on the app store, but what this device has, is not what the app store has. It has some irritating permissions that can be seen in its androidmanifest.xml. it wants permission for just about anything and you can't kill it. It refuses to share its permissions with other apps that want to be on top of apps. Torque would be a good example. In order to let Torque do its thing with the dashboard dials plugin, you'll need to disable the touch assistant and reboot the device. then things like Torque will work. But as soon as the device wakes up from deep sleep, it will have hogged the perms again and denied those of other apps. Highly irritating.

For some reason the media audio channel is limited to 87%. Apps like PowerAmp can not be set to max volume, when you do, about a second later it will adjust the volume lower again.

It does something to the canbus of my car (Opel Astra J) that i really dislike. My car is what Opel calls a "ECOFlex" meaning it has a start stop system. I actually like that, i did the maths and it does save me fuel. This device is capable of looking into, and changing car settings such as turning on and off the start stop system. By default the car will always have it on, and there is an "eco" button on the dach that lets you temp disable it, but when the car starts again, its on. For some reason this android device messes with that and always turns the start stop system off. I can go in to the car settings through this device and toggle the start stop system off and on, and then it will allow the car to do its eco thing, but around 2 days later, it will have disabled it again. Every now and then it turns it on again, but this is absolutely not the standard car behavior. I confirmed this by swapping back to the original car stereo for 2 weeks. The car always did its start stop thing. Highly irritating.

I basically don't want this thing to mess with my canbus at all, so i'm searching for a solution to not make it touch it at all and get rid of that bossy touch assistant. I've read in your instructions that i should change those version numbers in the PlatformConf.xml files, like i did with the radio app, but i'm thinking if i deliberately don't do that for this touch assistant, according to you the device would no longer see this app. In my mind that would effectively have disabled it...

Anyway, thanks again for sharing your knowledge. I saw in one of your apps you have a donation button, and if this info is still correct, i will be donating towards the work you do. thank you again.
[FYT Android Head Units] mastrv:
My experiences with the touch assistant were that once it was started, it could not be killed. Only a complete restart would remove it. That was acceptable as I usually did not start it and it did not start automatically. The only thing that I found useful in the touch assistant was the screen capture. However, I am able to do this now with Google Assistant. I wasn't aware of it requiring those permissions. If you really wanted, I guess you could remove it from the firmware the next time you flash one.

For your audio channel, I remember something similar where I would increase the volume and a short while later it would be reduced. I attributed that to the Canbus adapter. After removing the canbus adapter, this no longer happened.

You discuss the start/stop and the canbus interaction. Do you really need the canbus adapter? You may need it, though, for example, if it is used for climate control, your backup camera or other items. For my 2012 car, it was just before a lot of things were put on the canbus and so I didn't really need it. I was sent the adapter for my head unit. However, the one item that I was hoping it would handle, interacting with the original stereo amplifier, it did not do at all. So, I found another method to work with the amplifier and removed the canbus adapter completely. Working fine.
[FYT Android Head Units] surfer63:
The touch assistant is simply an app with its own settings. It normally autostarts on boot, but you can disable that from the settings to simply "do nothing".

Ther CAN bus controller is actually only necessary if your steering wheel buttons go via your CAN bus.

Sometimes you need to tweak your CAN bus settings in the CANbus app. If you buy a unit for an Opel Astra and the reseller sets it to Opel Insignia or some other model, it will not function entirely correct.

CAN bus is a standard, but every manufacturer extends it somehow. Sometimes they change it slightly between older and newer models. So maybe you should (first note the current settings and then) tweak the CAN bus model settings.
[FYT Android Head Units] mastrv:
The real problem with canbus is that it may have started as a standard but it's proprietary now. Ford and GM and Peugeot and Kia and Fiat don't use the same code and don't share or publish their info...to keep a competitive advantage I guess. A published standard would be too easy and these problems would not exist. That's why these modules were created. The several different canbus module manufacturers have varying levels of success and so not everything always works as it should.

As for the steering wheel buttons...if they do go through the canbus module then usually that means you cannot change their functions. However, others have removed the wires for the steering wheel buttons and connected them to the wires on the head unit directly.

In any case, you can try without the canbus module to see what you'd be missing or what stops and put it back later.