Re: Battery level of energy

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Grigory,
On Wed, Jan 23, 2019 at 6:22 PM Grigory Fateyev <gfborn@xxxxxxxxx> wrote:
>
> Hello!
>
> I have a bluetooth headset Sony MDR-XB650BT.
>
> # hcitool info 00:18:09:C5:44:1E
> Requesting information ...
> BD Address:  00:18:09:C5:44:1E
> OUI Company: CRESYN (00-18-09)
> Device Name: MDR-XB650BT
> LMP Version: 4.0 (0x6) LMP Subversion: 0x2576
> Manufacturer: Cambridge Silicon Radio (10)
> Features page 0: 0xff 0xff 0x8f 0xfe 0x9b 0xff 0x59 0x87
> <3-slot packets> <5-slot packets> <encryption> <slot offset>
> <timing accuracy> <role switch> <hold mode> <sniff mode>
> <park state> <RSSI> <channel quality> <SCO link> <HV2 packets>
> <HV3 packets> <u-law log> <A-law log> <CVSD> <paging scheme>
> <power control> <transparent SCO> <broadcast encrypt>
> <EDR ACL 2 Mbps> <EDR ACL 3 Mbps> <enhanced iscan>
> <interlaced iscan> <interlaced pscan> <inquiry with RSSI>
> <extended SCO> <EV4 packets> <EV5 packets> <AFH cap. slave>
> <AFH class. slave> <3-slot EDR ACL> <5-slot EDR ACL>
> <sniff subrating> <pause encryption> <AFH cap. master>
> <AFH class. master> <EDR eSCO 2 Mbps> <EDR eSCO 3 Mbps>
> <3-slot EDR eSCO> <extended inquiry> <simple pairing>
> <encapsulated PDU> <non-flush flag> <LSTO> <inquiry TX power>
> <EPC> <extended features>
> Features page 1: 0x01 0x00 0x00 0x00 0x00 0x00 0x00 0x00
>
> I'd like to get the energy level at least in shell. In which direction
> I should look for? How to know if my device has GATT support? If it
> connected with Android smartphone, where Android version is < 6.0, it
> has an icon with level in percents. I want to get the same on my linux
> machine.

bluetoothd should be able to detect if there is a battery service,
well at least if you are connect over LE, note that in past there
exists ways to fetch the battery level of AVRCP and HFP via AT
commands, so perhaps Android is using one of those, btw you should be
able to see what bluetoothd has discover with:

bluetoothctl> info <bdaddr>

> Thank you!
>
> --
> Grigory



-- 
Luiz Augusto von Dentz



[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux