Pali Rohár wrote:

> Yes, HFP 1.7 has support for reporting battery level via HF indicators,
> so via AT+BIEV= command.
> 
>> Looks like that not all devices support one and the same method to report
>> battery level. (I can imagine that not many support H[S|F]P).
> 
> But you are right that not all devices support HFP 1.7 and important is
> that HF indicator for battery level is optional and even HFP 1.7
> compliant device does not have to support it.
> 
> And also more HFP pre-1.7 devices reports battery level via own custom
> vendor AT commands. E.g. via apple command AT+IPHONEACCEV=1,1, or via
> csr command AT+CSRBATT=
> 
> All 3 ways I implemented in my Perl prototype.
> 

I was not specific to HFP or HSP. In fact HFP is more into automotive and is
not equal to HSP, but I bet you know this. I also did not read HFP specs to
go into detail.

I meant many devices that run on battery do not have HFP - but you are very
specific to audio devices that run on battery

>> Anyway - seems to be interesting topic
>>
https://stackoverflow.com/questions/49078659/check-battery-level-of-connected-bluetooth-device-on-linux
>> https://www.bluetooth.com/specifications/gatt/
> 
> This is GATT profile, which is independent of HFP profile and therefore
> is out of scope of HFP implementation.
> 
>> I am more interested in more robust H[S|F]P implementation, though it
>> looks like it depends widely on the manufacturer.
> 
> Yes, manufactures uses own custom AT commands, but I know only above 3
> ways how devices report battery level via HFP.
> 
> Prototype with documentation and API specification I put into
> repository: https://github.com/pali/hsphfpd-prototype

I am more interested in HFP working with my car :) which it stopped doing
since Sailfish X became the phone of choice (was N9 before) ... but I guess
it will be solved when I sell it next year :)
With newer cars it worked well, but in the background the ofono and pulse
parts are a bit odd.


_______________________________________________
SailfishOS.org Devel mailing list
To unsubscribe, please send a mail to devel-unsubscr...@lists.sailfishos.org

Reply via email to