yashsingh1/xdaforums huggingface dataset:
[Android Head-Units] TorstenH:
If you install via "click on apk file in a file explorer" Android will prevent an installation if the version number is smaller than the currently installed version. So I would give it a try.
[Android Head-Units] TorstenH:
Added modded MainUI version 1.51 to...

https://xdaforums.com/t/appswitcher...-devices-incl-autostart.4593865/post-88620949
[Android Head-Units] Vincent.Corleone:
Thanks for this amazing app!

I had my 7862 FYT HU configured with an app carrousel using seb21's modded syu but your app opens more possibilities.

I'm using 2 different SWC buttons, one for apps and one for PowerAmp shortcuts.

Since automate scripts are not supported, I've used your Flowstarter and created my own apk's for the shortcuts.

View attachment 5957785
[Android Head-Units] TorstenH:
It may be possible to create a modded MainUI for your 7862 unit which sends a broadcast on every key press.

Your apps and Automate could listen to the broadcasts.

Additionally the modded MainUI can start AppSwitcher Service after boot and sleep. AppSwitcher additionally allows to start the Automate service and an Automate flow.

But maybe your head unit has completely different systems apps. 😉
[Android Head-Units] Vincent.Corleone:
It's all working fine, thanks! Both AppSwitcher apps listens to their defined keycodes. Reboot or sleep is configured with autostart / no kill.

It's simply great being able to handle most of my use cases with 2 SWC buttons. Dankeschön!
[Android Head-Units] Arky21:
Thx Mate!
[Android Head-Units] Jafste:
I might be really dumb, i cant install any MainUI update, it always fails.

And doing from option 1, i can start the switch, but even when i changed to my button it does nothing.

Long press, short press nothing.

mine is a 825X
[Android Head-Units] TorstenH:
To help you I need further details.

Are you getting an error message when you click on the modded apk to install it?

Please install MainUiUpdater and share a picture of the About section with me.
[Android Head-Units] TorstenH:
Updated MainUiUpdater to version 0.14

Fix: Reboot wasn't performed with "reboot" button after update of MainUI.

https://xdaforums.com/t/appswitcher...-devices-incl-autostart.4593865/post-88620909
[Android Head-Units] dummptyhummpty:
This would be useful to me.
[Android Head-Units] TorstenH:
@dooger Thank you for the report regarding your installation experience.

I will try to improve MainUiUpdater and post your text here to help other users in case of install issues:

View attachment 5961843
[Android Head-Units] dummptyhummpty:
I may have run into this issue. I was somehow able to get my system in to a state where MainUi.apk wasn't actually installed. The built-in apps were missing and the physical buttons stopped working.
[Android Head-Units] TorstenH:
Added...

MainUI_8667_BMW_1.1​

Version 1.1 from 8667Q乐佳UI宝马v1920x720-国外_v22_20230221.zip

Xtrons firmware for BMW cars

Manufacturer: MTK

Product: XTRONS_IA

Device: spm8667p1_64

Board: spm8667p1_64

...to

https://xdaforums.com/t/appswitcher...-devices-incl-autostart.4593865/post-88620949

@dummptyhummpty thank you for providing the original apk and the firmware description and testing.
[Android Head-Units] t33t:
Finally got it working with mod. MainUI. Wow, this is really useful piece of software! Thank You :)!

Head unit Junsun V1 Pro 64G/4G

Car Peugeot 207
[Android Head-Units] ser_hero:
Wow, AppSwitcher has v3 with a new thread, missed it.
[Android Head-Units] LaitonSunny:
AppSwitcher is working with mod. MainUI_8667_1.1

TorstenH, you are doing a wonderful job, thank you!

Head unit: sadocom 8G, 128 ГБ

Car: Peugeot Partner b9
[Android Head-Units] Krouweeltje:
Hi ThorstenH,

Can you modify the mainUI for 825X_Pro version 90 as well?

I have a problem with wireless carletter as well. Where can I drop this problem?
[Android Head-Units] TorstenH:
v90 includes the same MainUI as v81: MainUI version 1.3

Regarding CarLetter it may be a good idea to wait for next firmware and continue to use AutoLink in meantime.
[Android Head-Units] Krouweeltje:
Okay, I did update the MainUI_825X_1.3 with the MainUiUpdater_0.21alpha.

installed AppSwitcher_3.1.apk, selected the navi and media app and log listener is disabled.

I started app switcher with the play buttun in the settings menu, but it didn't ask me for permissions.

Rebooted the system and now a few things doesn't work anymore:

- Side buttons of screen doesn't respond

- Car informant from settings menu opens for 100 ms and closed again

- FM/AM Radio doens't open

- Navi text is in chinese

- Sleep mode not active? Always start with android screen (long start) after turning ignition off and on

- app switcher doesnt start automaticly after reboot

I can install logcat later today if you need some logs.

Regarding AutoLink, do you mean the app from google playstore, or is there another version on the forum here?

Before I did all above, I checked the options for autolink in the 8878 menu/others and I had 3 options.

0 = CarBitLink

1 = Suud (or something like that)

2 = CarLetter
[Android Head-Units] TorstenH:
Please provide a photo of the MainUiUpdater "About" section and the log MainUiUpdater is showing.

Yes, please. Especially have a look on "fatal" messages.

Suding (option 2) is AutoLink which runs stable for Android Auto (wired and wireless) at least on my head unit.
[Android Head-Units] Krouweeltje:
The log:

View attachment 5968219

About:

View attachment 5968207

I will do this later today.

Thanks. I will try it when the setting->car informant menu work again
[Android Head-Units] TorstenH:
Thank you. That looks good. Just the second last message may be confusing which I will fix in next version. But let's see the logcat, first.
[Android Head-Units] Krouweeltje:
Here is the log. During the recording I opened the car informant menu and radio.

Logfile won't upload... Let's try something else
[Android Head-Units] TorstenH:
You can zip the log file before uploading it.
[Android Head-Units] TorstenH:
This makes MainUI crashing.

I will try to figure out what may be the problem...

[08-02 17:35:58.223 24456:24456 E/com.ts.MainUI]
Failed to register native method com.lgb.canmodule.CanJni.HondaWcGetAirTypeInfo(Lcom/lgb/canmodule/CanDataInfo$HondaWcAirType;)V in /system/priv-app/MainUI/MainUI.apk!classes2.dex

[08-02 17:35:58.224 24456:24456 E/[lgb]CanNative]
ERROR: native registration failed

[08-02 17:35:58.228 24456:24456 E/AndroidRuntime]
FATAL EXCEPTION: main
Process: com.ts.MainUI, PID: 24456
java.lang.UnsatisfiedLinkError: JNI_ERR returned from JNI_OnLoad in "/system/lib/libcan59.so"
at java.lang.Runtime.loadLibrary0(Runtime.java:1016)
at java.lang.System.loadLibrary(System.java:1669)
at com.lgb.canmodule.CanJni.<clinit>(CanJni.java:1070)
at com.lgb.canmodule.CanJni.CanStart(Native Method)
at com.ts.can.CanFunc.CanInit(CanFunc.java:1324)
at com.ts.main.common.MainUI.WmInint(MainUI.java:6025)
at com.ts.main.common.MainUI.DealTask(MainUI.java:1599)
at com.ts.MainUI.MainService$MainRunnable.run(MainService.java:22)
at android.os.Handler.handleCallback(Handler.java:873)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:6737)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:994)
[Android Head-Units] Krouweeltje:
Aaha I see. I haven't setup the right can mode before I did the update. I drive a skoda octavia 2, so my can should be VAG.
[Android Head-Units] TorstenH:
Could you please upload the first (oldest) backup of MainUI you can find in folder

/storage/emulated/0/MainUIUpdater

or

/sdcard/MainUIUpdater
[Android Head-Units] Krouweeltje:
Here it is.

Can I use the mainUiUpdater to set this version back, or do you want me to stay on this one for testing and providing data?
[Android Head-Units] TorstenH:
You can raname this backup to MainUI.apk and flash it from Download folder with MainUiUpdater.

I will provide a new modded MainUI asap. Looks like the Chinese modified MainUI without adjusting the version number.

I will please you to retry as soon as modded MainUI is ready.

Thank your for your support!
[Android Head-Units] TorstenH:
Here you can find an updated version of MainUiUpdater:

https://xdaforums.com/t/appswitcher...-devices-incl-autostart.4593865/post-88620909

And here the modded v90 MainUI:

https://xdaforums.com/t/appswitcher...-devices-incl-autostart.4593865/post-88620949

Please let me know if it works, now.
[Android Head-Units] Krouweeltje:
Wow thats fast. I will try this right away.
[Android Head-Units] TorstenH:
Great! In case of errors please provide a logcat. Smali code editing is an ugly job because assembly code is hard to read.
[Android Head-Units] Krouweeltje:
So far, so good.

Tested AppSwitcher after sleep mode and after reboot.

All works fine!

I want my radar app to start automaticly after sleep and reboot. Do I have to add this to AppSwitcher or do I have to connect Automate with AppSwitcher?

Got this one on right now. It asked me for a activation key. I searched alieexpress and found 2 keys, but the wireless option key isn't available to buy. Any suggestion?
[Android Head-Units] TorstenH:
I would suggest to use Automate because AppSwitcher can start the last used media app but it makes no sense to set a radar app as media app.

I bought the AutoLink key before the wireless option was available. I don't think you need a different key for wireless usage.

Have you already tried CarLetter? Would be interesting for me if it runs well.
[Android Head-Units] DizXDA83:
Hi there. Would like to ask if theres plans for a MainUI_8227L_1.1 update maybe with other theme? I have it installed and i like it best over original one
[Android Head-Units] Krouweeltje:
I tried. wired is working, but wireless is still not working. It does show the bluetooth connection and my phone tells me that android auto is started, but nothing happen in the carletter app.

I havent tried it to update CarLetter with the mainUiUpdater (0.22Alpha), because the option for carletter update has been removed.
[Android Head-Units] TorstenH:
It should be possible to install a CarLetter update by clicking on the apk of the newer version. At least this way it should survive until next reboot.

I removed the CarLetter update option temporarily because an installation on a system without pre-installed CarLetter is complex and many system files need to be added or modified to make it work. I will continue on this if I see the huge benefit by using CarLetter instead if AutoLink.
[Android Head-Units] TorstenH:
If you can provide a newer version of MainUI for 8227L feel free to share it here for modding.

Intention in this thread is to enhance MainUI only to make it work with AppSwitcher.

I don't want to replace resources inside MainUI or even create new graphics because that needs to be redone as soon as a new version is available and that would be too time consuming.
[Android Head-Units] Krouweeltje:
Well, lets try AutoLink first
[Android Head-Units] suphion:
Hi I tried and failed to succesfully use the app, I may be missing something here, please advise.

I used the option2, changed my main app (MTK8667)

Now the Mode button does not do anything, which is expected.

I disabled log listener from app settings.

Do I need to install AppSwitcher Starter

What should I assign to my desired button, GPS button? I f so, in my settings, what app do I want this button do?

I want only, poweramp autolink and radio to switch, what should my settings be like?
[Android Head-Units] TorstenH:
True, because we don't want the default behavior in parallel to AppSwitcher.

Option 2 doesn't need AppSwitcherStarter.

As described here

https://xdaforums.com/t/appswitcher...-devices-incl-autostart.4593865/post-88620899

Please select the navigation and media apps relevant for you:

View attachment 5969535

And start AppSwitcher for the very first time manually:

View attachment 5969537
[Android Head-Units] suphion:
Wow, thanks for very prompt answer.

I have already selected my desired apps, rebooted and started app switch manually.

However, the button still does nothing.

My device is with CAN, and I can change the actions for the buttons from SWC menu.

What should I assing to my desired button, GPS or Mode?

And If I assign GPS, the button turns the iGO on and OFF only.

But I can change which app I can select as GPS app, so do I need to select Appswitcher from Android settings.
[Android Head-Units] TorstenH:
Is the AppSwitcher status bar icon and the notification visible after manual start?

Usually it's not possible to change the SWC action if a CAN box is in place. As least on none of the Junsun devices I know.

But if it's really possible you need to select mode, please.
[Android Head-Units] suphion:
Hi again.

Finally succeded.

But with a hybrid way.

I did do the MainUI Mod as in Option 1 (MTK 8667 v1.51)

View attachment 5969709

Disabled Log Listener.

Assigned the key to GPS

View attachment 5969713

Installed AppSwitcher Starter

Selected AppSwitcher Starter as my Navi app

View attachment 5969715

And Voila, it work as I desire.

My Device:

It is not JUNSUN but a similar Chinese one with MTK8667 Model: Alps FF_866X

View attachment 5969717

View attachment 5969719

Thanks for a great program.
[Android Head-Units] TorstenH:
For me this looks like your SWC is not connected via CAN box even one is in place for other functionalities.

It would be interesting to see the Android log to get an idea why the mode button can't be used. Let me know if you're willing to support this investigation.

Please note: It is not required to install the modded MainUI in case AppSwitcherStarter gets used.
[Android Head-Units] suphion:
May be.

The CAN works with reverse camera for example, and reads Air condition info (It is 2degree off and some settings are not exact, but still)

But you may be right about SWC, I don't know if it is CAN or some other connection else.

But a question though, how come it works if the log listener is turned OFF with Option 1

Of course I can try to help you.

I don't have root though if it is needed.

Just let me know what I need to do.

Thanks
[Android Head-Units] TorstenH:
Please install Logcat reader

Logcat Reader - Apps on Google Play

View your device's logs

play.google.com

and grant Read logs permission. You can do this with the latest version of MainUiUpdater (v 0.23alpha).

If the app is in place and you can see log entries press the SWC button and search for "original key".

Please share a photo if you could find a match.
[Android Head-Units] TorstenH:
Key (in this case 810) gets translated to 9810 for AppSwitcher:

View attachment 5970403

In case CAN box mode button is used, key 10 will be translated to 9010.

After boot/sleep AppSwitcher gets started (message "start AppSwitcher") and the AppSwitcher icon will appear on status bar after successful start:

View attachment 5970405
[Android Head-Units] TorstenH:
Dear AppSwitcher users,

I figured out how to control day / night mode of AutoLink:

View attachment 5970459

AppSwitcher already handles sunset and sunrise data so it would be possible to automatically switch to night mode.

Let me know if you're interested in such a feature and if you are willing to support me by doing some tests.
[Android Head-Units] elalvaro19:
It is an interesting function, I can't get automatic mode with autolink, I could try this function since I use autolink
[Android Head-Units] Jetblack31:
Hi,

I'm using autolik with CarPlay. Just for information, CarPlay has settings for day/night and dark modes.

Jetblack
[Android Head-Units] TorstenH:
My phone has an Android Auto setting to let the car control day/night.

At least on my MTK825X unit the head unit is not triggering AutoLink to request night mode.
[Android Head-Units] TorstenH:
Great! I'll get in touch with you as soon as developer test is completed.
[Android Head-Units] TorstenH:
Extended dimming feature of AppSwitcher 3.2 which controls the day/night mode of AutoLink.

View attachment 5972515

View attachment 5972521 don't show overlay, AutoLink in day mode

View attachment 5972517 show overlay, AutoLink in night mode

View attachment 5972519 controlled by sunrise 🌅 and sunset 🌇

Let me know if it works on your device and if you like this feature.
[Android Head-Units] Jetblack31:
Hi Torsten,

Thank you for the new great feature.

I use Autolink with CarPlay. I did some tests yesterday. When car lights are on, Autolink/Carplay go in night mode, and apps in CarPlay go in dark mode.

I'll do a test tonight with Appswitcher 3.1 to see if CarPlay automatically switches day/night with current time.

Jetblack
[Android Head-Units] TorstenH:
Should be fixed with version 3.2.1 which sends the command multiple times as soon as AutoLink gets detected as foreground app.
[Android Head-Units] TorstenH:
This may depend on the model (8667, 825X, ...), installed firmware version, phone OS (Android Auto vs. CarPlay) and if the phone is connected by wire or wireless.

Let me know if the new feature influences the dark/night experience negatively, we may need a switch to turn it off.
[Android Head-Units] Crane2106:
Hi everyone.

Thank you TorstenH for your incredible work.

I've send a message to the seller because Carletter doesn't work on m'y head unit and he sends me the firmware version : 8259P_军灿UI02v1280x720-国外_v94_20230729.zip

Will appswitcher still work if I install this update ?
[Android Head-Units] PrinceLc:
Can you share the v94 firmware with us thanks
[Android Head-Units] TorstenH:
Maybe we need a new modded MainUI. Please share the link to the firmware so I have a chance to check that.
[Android Head-Units] Crane2106:
Here is the link to the firmware : https://drive.google.com/file/d/1Vl2Ek89JFEYKqAgMRaMh9sqYS3cKbuwQ/view?usp=sharing
[Android Head-Units] TorstenH:
Modded MainUI from and for v94 can be found here:

https://xdaforums.com/t/appswitcher...-devices-incl-autostart.4593865/post-88620949

@Crane2106 FYI
[Android Head-Units] PrinceLc:
It is still on Android 9 with v94 firmware ? You can check with Fake Android Test app on PlayStore
[Android Head-Units] M_4axx:
View attachment 5973397

can you identify my? device spm8667p1_64 can i use this MainUI?

MainUI_8667_1.51 (please unzip!)​

Version 1.51 from 8667Q军灿UI02-国外-1280x720_v34_20230703.zip
[Android Head-Units] TorstenH:
I would simply try to install it as update by clicking on the apk - not with MainUiUpdater in a first step.

This would allow to remove the update from MainUI via Settings --> Apps --> MainUI
[Android Head-Units] M_4axx:
hmm... And this will not cause the device to reboot cyclically? or its just ask me use a old UI ?
[Android Head-Units] elalvaro19:
I have installed the latest version but that menu does not appear above, the clock appears, I think my version of android is not compatible with automatic night mode. The screen dims when the car lights (canbus) are turned on, I don't know if you could capture this canbus option and that it also works when the car lights are turned on
[Android Head-Units] TorstenH:
You need to touch outside of the app icons (e.g. on the header) of the AppSwitcher dialog to let the buttons appear.
[Android Head-Units] TorstenH:
No risk, no fun. 😊

As I've written in the manual replacing MainUI can be risky and you should be familar flashing a firmware.

On the other side you would be the first who needs to reinstall because of the MainUI installation.
[Android Head-Units] TorstenH:
View attachment 5973481

Tap on the AppSwitcher dialog header to interrupt the countdown and show equalizer, dimming and settings button:

View attachment 5973477

Equalizer button appearance can be disabled in settings.
[Android Head-Units] TorstenH:
View attachment 5973725

Start AppSwitcher the very first time manually by clicking on the icon on top of the settings screen:

View attachment 5973723

This is required to allow AppSwitcher to ask for required permissions and so to automatically start after boot and sleep.
[Android Head-Units] elalvaro19:
thanks!, currently working
[Android Head-Units] TorstenH:
View attachment 5975959

If you can't find the media app you want to add to AppSwitcher, you should check the activities of MainUI. MainUI contains standard apps like Radio, AUX input, Bluetooth and more.

Expand the activities by clicking on the arrow button:

View attachment 5975961

(just a screenshot of a video)

Please note that the description of MainUI can be "Bluetooth" and even the descriptions of the activities may be misleading so also keep an eye on the technical names.

You can tap on an entry to test it.

Tipp: An activity can also represent a specific screen of you app. E.g. directly open the player main screen or the Playlist.
[Android Head-Units] suphion:
Hi,

Sorry for replying late, I have been out of city for a while.

I have figured out what was causing my issue.

FCC Launcher has also settings for mode button, probably/apparently it was messing up with app switcher.

I changed those settings, and now it finally works just excatly like you described, (Modded Main option)

However, I have a minor bug that I wanted to point out.

When a program is selected at appSwitcher, if I unisntall the app, it still shows at app sort screen, and the number of selected apps are also showing one more than the actual number of current selected apps.

I.E. I uninstalled poweramp, but forgot to remove it from APPSwitcher beforehand.

Now I have only two apps selected (Music&Radio) but it shows 3 apps are selected. Also, the Sort settings still list the uninstalled app.

It is no big deal, but still wanted to tell.
[Android Head-Units] TorstenH:
Thank you for telling us the root cause of the issue.

Thank you for reporting the bug. The workaround would be to re-install the app, remove it from AppSwitcher selection and uninstall it.
[Android Head-Units] TorstenH:
This bug is fixed with new AppSwitcher version 3.2.2:

Please note: If you uninstall a selected app while AppSwitcher service is running, AppSwitcher will still offer this app. To remove it from the list, open AppSwitcher settings menu "Apps and Activities" (no further taps required) or reboot your device.
[Android Head-Units] mitko9922:
I have 8667 with update 1280x720_v34_20230703 and I have CANBUS, so I chose option 2 to work remap buttons with canbus. I installed MainUI with apk by downloading MainUI_8667_1.51.zip, extract and install it, then installed AppSwitcher_3.2.2.apk and enabled permissions and started the service, however after restart the system doesn't start by itself, when I open AppSwitcher it says "Failed to bind AndroidIDE" and when I click on the icon it says it started the service and only then it appears in the status bar as started but nothing works, the steering wheel buttons work as they do, no media starts and it doesn't seem to work. What could be the problem?

P.S. How can I check if the MainUI has actually been replaced, because I have suspicions that although it installs without error it has not been replaced?
[Android Head-Units] TorstenH:
I've sent you an alternative MainUI via a private message. Please try to install and let me know if it stays sticky and survives reboots.

This issue is fixed with AppSwitcher version 3.2.3. Thank you for reporting.
[Android Head-Units] TorstenH:
Updated MainUI_8667_1.51 to make an update by install via "click on apk file" sticky.

Additionally it includes a change which allows the start of AppSwitcher and the navigation app (if auto navi is enabled in factory settings).

@mitko9922 Thank you for your testing effort to make AppSwitcher better.
[Android Head-Units] mitko9922:
And I thank you for your time and great support. This app has become an integral convenience, works without notice and is an indispensable addition to the system software of my 8667 navigation!
[Android Head-Units] Crane2106:
Hello, sorry for the delay, I only found time to apply the update this weekend. Here's a picture of the app, it looks like the Android version is still 9.
[Android Head-Units] PrinceLc:
I know but thanks