AppSwitcher - smart SWC launcher (for Junsun and similar devices) incl. autostart

Search This thread

Jetblack31

Senior Member
Sep 10, 2022
90
19
@Jetblack31
Thanks for the advice and sorry for the delayed answer. I've checked the log. So this is the situation. I've attached at screenshot of the control switch for the headunit. The SRC key is mapped as key 10, the Key that opens the Info Monitor (the button on the end of the upper switch with the two arrows) isn't mapped to anything according to the log. It just doesn't show up. I've tried to map the App to key 10, however it doesn't work. App Switcher doesn't respond and on pressing the button it's still switches between Radio, Bluetooth and Maps. Is there anyway to get the headunit to ignore the SRC input? Or to get the App to work?

Thanks in advance
Hi,

What I found to get the headunit to ignore the SRC input is to modify the Menu Icon (8878) as in the picture. After that, I configure AppSwitcher like in the second picture. Note that I use Key 10 and Key 11 in my case.

Best

IMG_7672.jpg


IMG_7673.jpg
 
  • Like
Reactions: DarkTWH

DarkTWH

Member
Sep 25, 2021
18
3
POCO X4 Pro
Thanks @Jetblack31,
That tip for the SRC Key worked perfectly. However even after trying to set the press log entry (any of those 3 to == 10) Appswitcher still doesn't respond. In which of those 3 options do I need to set it? If tried all of them individually and the last two in combination, but that doesn't fix it either.
Thanks in advance
 

Jetblack31

Senior Member
Sep 10, 2022
90
19
Thanks @Jetblack31,
That tip for the SRC Key worked perfectly. However even after trying to set the press log entry (any of those 3 to == 10) Appswitcher still doesn't respond. In which of those 3 options do I need to set it? If tried all of them individually and the last two in combination, but that doesn't fix it either.
Thanks in advance
Hi,

Did you grand AppSwitcher with the READ_LOGS permission ?
Did you set AppSwitcherStarter as your preferred NAVI application in the HU system?
 

DarkTWH

Member
Sep 25, 2021
18
3
POCO X4 Pro
Hi,

Did you grand AppSwitcher with the READ_LOGS permission ?
Did you set AppSwitcherStarter as your preferred NAVI application in the HU system?
Yes to both. Still no change. However if I leave the first box empty and then try to close the app via the back key on the unit itself. The menu opens and I can flip through it using the back button left of the touchscreen. But no response to the SRC button
 

Jetblack31

Senior Member
Sep 10, 2022
90
19
Yes to both. Still no change. However if I leave the first box empty and then try to close the app via the back key on the unit itself. The menu opens and I can flip through it using the back button left of the touchscreen. But no response to the SRC button
Which first box? the first box in the Menu Icon option ?
 

DarkTWH

Member
Sep 25, 2021
18
3
POCO X4 Pro
Yeah, my answer was not verry percise. When I leave the box "On Button Press Log Entry" empty and then press the back key on the side of the screen the AppSwitcher Menu appears, and I can see the apps I set in the Settings. Do I need to set more than one key @Jetblack31? because in your case you set short to 11 and long to 10.


Edit: It finally works. After having to use the reset button on the unit due to another issue, I had to reapply all Settings (My Unit tends to forget certain settings after some time) and with Short button press set to 10 and the other two to 9999 it now works flawless
@Jetblack31 Thanks for the help, much appreciated
 
Last edited:

Jetblack31

Senior Member
Sep 10, 2022
90
19
From my experience, you can set only the "short press" and it works.
Have you allowed AppSwitcher to be front of other apps ? See one of my previous post.
Jetblack
 

elalvaro19

Senior Member
Sep 18, 2018
52
1
Hi, I'm new to the thread. I have installed the application, I have a car with canbus. I have managed to get the appshitcher menu to come out but the swc button continues to do the original function. That is to say, it does both functions, when I press swc it does the original function but the appswitcher is opened. Any idea how to override the main function?. My unit is junsun v1 (8227L)
 

Jetblack31

Senior Member
Sep 10, 2022
90
19
Hi, I'm new to the thread. I have installed the application, I have a car with canbus. I have managed to get the appshitcher menu to come out but the swc button continues to do the original function. That is to say, it does both functions, when I press swc it does the original function but the appswitcher is opened. Any idea how to override the main function?. My unit is junsun v1 (8227L)
Hi,
Welcome !
Have you modified the Menu Icon as described here above?
Jetblack
 

elalvaro19

Senior Member
Sep 18, 2018
52
1
Hi,
Welcome !
Have you modified the Menu Icon as described here above?
Jetblack
No, I have not done that, because I understand that if I do that, the apps that I remove from that menu will not appear in the main menu, is that right? Another point is that in the app selection I don't get the native radio app. My launcher is agama car launcher
 

DarkTWH

Member
Sep 25, 2021
18
3
POCO X4 Pro
If I am informed correctly you can install laucher APKS for a different lauchner here in the fourm. It should work with that. At least it works with mine that way (But I use Car Launcher Pro).

 

elalvaro19

Senior Member
Sep 18, 2018
52
1
tested like this if it works, but the apps of the link do not work for me it is installed but it does not do the function for example the fm radio one opens but it does not search for any station. I imagine it will be because of the chip, mine is the 8227L
 

elalvaro19

Senior Member
Sep 18, 2018
52
1
I have tried to search for the apk by the root of the system but I can't find it. I imagine a breakdown of an apk that contains everything would be done. It seems that this pack only works for v1 pro
 

Ukiews

Member
Nov 25, 2022
10
0
I’m running the app on a Teyes CC3 with a canbus converter for my Honda CRV swc. I’m trying to figure out witch key code is assigned internally to the “source” button on the steering wheel. Using Logcat Reader and filtering by “MainUI”, nothing shows up for any of the buttons in the log. Might I need a different filter to find these button presses?
 

Jetblack31

Senior Member
Sep 10, 2022
90
19
I’m running the app on a Teyes CC3 with a canbus converter for my Honda CRV swc. I’m trying to figure out witch key code is assigned internally to the “source” button on the steering wheel. Using Logcat Reader and filtering by “MainUI”, nothing shows up for any of the buttons in the log. Might I need a different filter to find these button presses?
Hi,

did you grant Logical with READ LOGS permissions ?
 

TorstenH

Senior Member
Feb 20, 2021
1,208
314
t.me
Realme GT 2 Pro
What is Logical? Do you mean Logcat? I did grant Logcat permissions upon first launch. The CC3 HU is rooted. The logs are beings generated, but when apply the filter "MainUI" under Tag, and then press swc buttons, the log screen remains blank.
Here is a demo:
In don't think that Teyes devices using the same main application as Junsun devices. In this case it doesn't make sense to filter for MainUI.
 

Top Liked Posts

  • 1
    Added version 2.6.14alpha which is the most stable version so far.

    Thanks to @Jetblack31 for his testing engagement

    Even the version is not final, I removed all previous versions on first post because they may lead to a bootloop on 8667 devices.

    As always: please provide your feedback. Not only but also in case of issues. Friendy user feedback is my motivation to continue this project...
  • 1
    How i can set a filter in logcat to get only a log of pressed buttons on my steering wheel?
    You could restrict the logs via the filter function inside the ... menu.
    IMG_20230118_135240_499.jpg

    After that you can filter on the main screen for keywords come into your mind. E.g. key, button,...

    Are you using a can box?
    1
    Hi Torsten,

    before I was with version 2.1.
    Ok, so I'll log the "fatal" messages and keep you informed.
    Thank you very much,
    Bernard
    1
    Hello thanks for the apk I will try on my Junsun 8259
    1
    What I just don´t understand is. With the PX3, 5, 6 it is also possible to change and assign the buttons, even a long press. Why doesn't that work with ours!?
    Because in the Junsun you just can remap the button if you don't use canbus and SWC is connected as resistance matrix to the head unit directly. The translation of can bus signal is hard coded.
    1
    Hi Torsten,

    before I was with version 2.1.
    Ok, so I'll log the "fatal" messages and keep you informed.
    Thank you very much,
    Bernard
    Bernard, I attached version 2.6.2alpha to first post. It will check if required permissions are granted and can try to authorize itself during service start (first option in settings). I hope this will simplify installation procedure for you.
  • 5
    AppSwitcher - SWC (Steering Wheel Control) app launcher.

    ic_launcher_adaptive_fore.png

    Stay focused on the street and don't touch the head units display to switch between apps.



    Please note: This app is developed and tested only on Junsun V1 Pro with MTK8257/MTK8259 AND 8667 CPU. You can test on other devices at your own risk if you are familiar with firmware flashing.


    UI:
    LMC_20230104_161458_lmc_8.4.jpg

    Video of 1st alpha version:


    Covered features:
    - allow to select an app to start without the need to jump from app to app.
    - one button press to switch between last used navigation app and last used media app.
    - support usage of multiple navigation apps.
    - works with pre-installed apps like Radio and apps added by the user.
    - start the last used media app automatically.
    - long button press to cancel (if dialog is shown) or to jump to home screen.
    - reactivate accessibility service of Automate and start initial Automate Flow
    - enable/disable DuraSpeed
    - change system property to make Android status bar visible (work as on other Android devices)
    - automatic screen dimming based on sunset / sunrise information
    - Supports Mtk8257 and 8667 devices. Thank you @Jetblack31 for your testing engagement on 8667.

    Open:
    - May not work on devices with canbus.

    Testers are welcome! I need YOUR help to make it work on head units connected to canbus.

    Please install both apps because 'AppSwitcher Starter' is just used to start the App Switcher Service. Find installation instruction in 3rd post.

    FAQ

    https://forum.xda-developers.com/t/...sun-and-similar-devices.4435555/post-86825555
    2
    Didn't see this mentioned; if someone has problems setting this up on Junsun V1 Pro w/ canbus, I had to give AppSwitcher permission to "READ_LOGS" with ADB. Now works great!
    2
    @demolite @Apk07

    Started to implement that static list feature. Because I have to change a lot of classes I hope you will provide your test feedback.

    IMG_20220816_154012.jpgIMG_20220816_153937.jpg
    2
    FAQ

    Why is the starter a separate apk?

    Junsun head units check if the navigation app package is already in foreground. If that's the case home screen gets displayed. If we set 'AppSwitcher' as navigation app it would not stay in foreground. Here the relevant coding of MainUI:
    IMG_20220429_164055.jpg

    Why is my screen flickering while I switch trought the list of apps with the steering wheel button?
    The head unit starts the navigation app via the activity com.ts.main.navi.NaviMainActivity which is part of MainUI (package com.ts.MainUI). It will become the foreground activity for a short amount of time, invisible because a transparent theme is used. Unfortunately the screen is flickering during this procedure.
    You can enable the setting "disable navi start activity" in 'AppSwitcher' to avoid this. Please note the activity will be only disabled as long as the dialog of 'AppSwitcher' is active.

    What is DuraSpeed?
    DuraSpeed is a proprietary tool from MediaTek restricting and closing(!) background apps and services to free memory and so to make it available for starting apps.
    AppSwitcher can set the properties to turn DuraSpeed off in case you're struggling with closed services / apps and want to give back control to Android.


    AppSwitcher dialog isn't shown
    On some head units you have to provide permissions manually. According to my experience on a Junsun V1 pro (with MTK8259/MTK8257 CPU) the authorizations granted automatically.
    1. Check if AppSwitcher has permission to appear on top of other apps. You can provide the authorization in "application settings".

    2. On some head units AppSwitcher doesn't get authorization to read the Android log. In this case you have to grant authorization via ADB:
    Code:
     adb shell pm grant com.thf.AppSwitcher android.permission.READ_LOGS

    How display dimming works
    Screen dimming is realized by "painting" a semi-transparent overlay on top of the screen because we don't have the possibility to access display brightness on system level.
    Some apps don't like to get overlayed and so Google PlayStore shows a warning message. AppSwitcher is pausing the overlay if Google PlayStore is the app in foreground.
    If you're using an app which doesn't work well whiles it's overlayed, let me know.
    2
    Added version 1.4.
    Only minor changes but the UI bug was too painful for my eyes. (-: