crankshaft icon indicating copy to clipboard operation
crankshaft copied to clipboard

suggestion for android auto wifi

Open Grawa opened this issue 5 years ago • 6 comments

First af all, i've noticed that android auto wifi in lastest releases has been improved a lot, so thank you!

This is just a suggestion: It's possible to add an option in settings to Autostart AA when Crankshaft is connected to a Wi-Fi device instead just updating the icon in main screen with the blue AA logo?

thank you in advance.

Grawa avatar Feb 01 '19 18:02 Grawa

Yes general it's possible and no big deal :) I didn't include it until now to first be sure the wifi handling is not causing problems before enabling auto connect stuff... I think it will step in next time...

hawkeyexp avatar Feb 02 '19 09:02 hawkeyexp

Ok, perfect! thank you (:

Grawa avatar Feb 02 '19 10:02 Grawa

Additional information:(may be useful for other users)

i'm keeping the android auto developer server always on (obv.until you reboot the phone) hiding the notification...

using an app called "Carspot" the wifi hotspot will be activated/deactivated automatically when the phone connects to the car audio bluetooth

So, will be perfect if crankshaft will start automatically android auto when connected to the phone :D

Grawa avatar Feb 05 '19 11:02 Grawa

Is crankshaft auto operaing android auto now?

I am trying to set up crankshaft over wireless using my phones access point. following FrankLaverne's instructions here but I do not get a visible wifi button to use to define my phones head unit server. https://www.reddit.com/r/crankshaft/comments/99py4c/wireless_connection/

Just wondering if the wifi button is no longer necessary and I have a connection error.

I can open as a separate issue with phone details and debug log if this is a connection error.

Thank you.

johnmorio avatar Feb 24 '19 16:02 johnmorio

I would love this feature too. I have my phone set up with tasker to switch to the hotspot when it detects crankshaft's bluetooth. Can you send us a little python script to launch openauto when crank shaft detects auto over wifi

haywirephoenix avatar Mar 28 '19 08:03 haywirephoenix

You could do this a different way. Set CranckShaft to create a Wifi Hotspot and set the TCP socket to listen on port 5288 (or any other port if you want), however if you set CranckShaft to create a hostpot which is called HUR and the password is set to AndroidAutoConnect and you set Crankshaft to listen on port 5288 you can use my WiFi Launcher app on the phone to automatically join the hotspot and start AA in projection mode (without the need of the Headunit Server running in Android Auto). It will only work if the phone runs Android 9 and above.

So instead of connecting to a socket I set it to listening mode (this is Java, headunit reloaded):

 SSLEngine engine = sslEngineBuilder.Builder(getBaseContext());
                            ServerSocket serverSocket = new ServerSocket(5288);
                            Log.d("HU","Listening for incoming connection");
                            transportSocket=  serverSocket.accept();

You can download the WiFi Launcher app from: https://play.google.com/store/apps/details?id=com.borconi.emil.wifilauncherforhur

borconi avatar Mar 03 '20 20:03 borconi