Dual-Sim, choose SIM for bluetooth HFP connection
Is there anyway on a dual sim device, e.g. JollaC, to choose which SIM will be used over a bluetooth hands free connection, e.g. car?
We have moved to a new Sailfish OS Forum. Please start new discussions there.
Is there anyway on a dual sim device, e.g. JollaC, to choose which SIM will be used over a bluetooth hands free connection, e.g. car?
I came accross this:
https://talk.sonymobile.com/t5/Xperia-M4-Aqua/Xperia-M4-Dual-auto-SIM-selection-for-hands-free-calls/td-p/1008473
which suggests that Sony/Android has or had a similar problem - but at least you can choose. Any other experience?
An option in SFOS to select which SIM to use for HFP would be best, or just connect to SIM 1 always.
My VW seems to connect randomly to SIM 1 or 2 - at least I can't see a pattern. It should NOT use the one with the best signal - my main SIM (3UK) has the worst signal.
BTW - although this question is 'answered' the underlying feature request is not.
I use Sailfish X with bluez5. If you have bluez4 it might be different issue but if first is the case, perhaps look into bluetoothctl (if you are familiar with command line tools) there is more flexibility.
I don't have this same problem (single sim here), but I looked a lot into the HFT stuff and sometimes it helps to delete the .pulse or .config/pulse directory and reboot, so that it may recreate properly.
I then would tell pulse audio which is the source to connect to - I did it for A2DP, but should be similar for HFT. It looks like PA is picking whatever source available. It sounds like you have bluez5
good luck
deloptes ( 2018-05-25 01:09:04 +0200 )editThanks. I'm very familiar with BT CLI tools (unfortunately - having struggled to get A2DP working on a BananaPi!). There's more to it than fiddling with pulseaudio, though. The sound might go through PA but the operator/signal/contacts obviously don't. But maybe it's possible to disable HFP on SIM 2. BT and pairing applies to the whole phone, though, not each SIM AFAIK.
Ideally the UI should be in the car, when you connect - or perhaps pair; it should ask which SIM to use. I wondered if anyone has a car that does that?
DaveRo ( 2018-05-25 09:41:56 +0200 )editStill not clear what bluez version you have. If it is bluez5 the HFT is in ofono. So those 3 must play together. It looks like ofono is offering HFT for second sim, because perhaps 2nd sim is discovered later.
Try disable/enable sim1 and see if it gets connected.
I don't know exactly how it works - you need to look into the code to get it right or track the behavior and ask for bug resolution.
I had to always do following on my PC to be able to get A2DP working from phone to pc
pactl list short
pactl load-module module-loopback source=bluez_source.xx_xx_xx_xx_xx_xx.a2dp_source sink=alsa_output.pci-0000_00_1b.0.analog-stereo
regards
deloptes ( 2018-05-25 19:39:53 +0200 )editWorkaround here:
https://together.jolla.com/question/191410/jollac-un-changelog-22118/
BT will connect to first-activated SIM. Require a PIN on SIM2 only, which should ensure that PIN1 connects first.
With the help of my auto-enter-pin script, you can automate the activation of SIMs in the order you wish at boot. This means you can use DaveRo's workaround while keeping a pin lock on SIM 1.
slowcyclist ( 2018-12-01 22:13:49 +0200 )editThis workround does not, in fact, work - or not reliably, or not any more on my Jolla C 3.0.1.11 Yesterday the car connected to SIM2 despite SIM1 having been activated first. On the previous occasion I had connected SIM2 to the car by disabling SIM1. Maybe it 'remembered' that.
DaveRo ( 2019-02-12 09:56:28 +0200 )editThe connection will be don with the last activaed SIM. So after reboot the activation sequence is SIM1 then SIM2 and SIM2 will be connected via BT. If SIM1 is temporarily disabled, it's the last activated SIM after and will be connected via BT.
(reliable) workaround: disable and reactivate the preferred SIM before connecting to car, also to have the connected SIM displayed correctly. Otherwise the car display will switch to connected SIM with next call. It's a fiddling - even in 3.2.1 ...
fortify ( 2020-01-21 10:53:21 +0200 )editMy car always uses SIM 1 as main SIM. But there is no way to select. you only can deactivate the SIM you dont want to use for the connection process. In that case SIM 2 is the main card for this ride.
For the first time ever the car connected to SIM2 - they're set to 'always ask' and people always ring me on SIM1. I think this might have been because I'd last used SIM2, which was unusual - I sent a service message.
I had to stop the car, deactivate SIM2, reconnect to the car, and reactivate SIM1.
An option - which SIM to pair - would be useful.
How do other phones do this?
DaveRo ( 2017-10-17 14:34:13 +0200 )editIn my case (SFOS 3.0.3.9, VW Golf 7) it seems, that the car uses the SIM which connected first with the network and therefore is used by hfp/bluetooth. I have the impression, that this 'first connected SIM priority' consist until the next reboot of the phone.
So my modification of the workaround is to disable the unwanted SIM, boot up the phone and activate the unwanted SIM only after the preferred SIM has connection to the network.
If I recall correctly HFP is registered to bluetooth via ofono - so disable the sim and restart ofono should be enough. I'm not sure how you can easily restart ofono though - I was thinking there were an option under utilities, but just checked and there is none.
deloptes ( 2019-06-17 22:48:27 +0200 )editThis thread is public, all members of Together.Jolla.Com can read this page.
Asked: 2017-10-08 10:58:24 +0200
Seen: 2,289 times
Last updated: Jun 17 '19
PBAP bluetooth profile support is requested [released]
[Feature-request] Automatic call answer when connected to (BT) handsfree/headset
Bug: Tones don't come through headset
Media player trough carkit (handsfree)not working
My Jolla does not recognise any micro sd card. What I can do? [answered]
Add skype integration to sailfish os
Add DBus interface to stock music player [released]
[How-To] WPA-802.1X (enterprise), eduroam +[Others] GUI wifi support needed + workaround [released]