Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp2053943ybb; Sat, 21 Mar 2020 11:41:00 -0700 (PDT) X-Google-Smtp-Source: ADFU+vv7Bq+DW1nR81qfdH8glXUfGQB+qeVLnTcM2H1X9um0Exv78ijc6HPQZqBjiMCXWkpvW/+t X-Received: by 2002:a54:478d:: with SMTP id o13mr11706198oic.166.1584816059850; Sat, 21 Mar 2020 11:40:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584816059; cv=none; d=google.com; s=arc-20160816; b=q3UIruxghzDj7TSDxgca/UpHrZkS2XCCcf8JKvsdvsCkhwbtcLHauMLFpvsUCq8GRk B40PRwTjQJXLS5XRFRZ3dCn+v2J4NyDFPc/AVi/KqhVIs+fC9YE9/bjYSEWcVlc673a/ 7PYLko3bEp3Ducwi/WSkHIjFN6nTv/gf5epYU0OBCW9Tqe8e0k/kQ44KpCyKGFtLIBu3 38VVDFy9FaJlLW36qfIE8ez4pZhpLtZu2ZK8NVTopqZrQ0TUpTfuA3xo7CjLUWx7zzCi P/h4fe3U8N6sp6hUrTwZkDb+2GpUbh2UPza5KOwksHV9nrh1rdylvsSIyznMEBysQ4Kx ONXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=GfOZeqjqnk/DxOF0n2BpDoMhtlujkViZfTpdaqMdXao=; b=RVn0U6z6tpd8dkr6pVi6fKZmZyXanovbV0AAiHLMDirgohJZVW/fgkpSgJOMVX7yE9 OF6T33ZY1MyaJchtu6qYtyLXc355/JqcRynnwAebg1xFhNfOP5iLRNEWzjRyzIZFk8ku tgFJegpazzfbl7ooAv8bHMedDwOAnbeAbdHBxc/y6R9VajU3w0qL5u54nL0DT5kJfgFG PUIxRvWaPbptHX00WRR7ukFdvaLd4x+HULjanHy4imsdTN8POAZIX8B29tXV/6xAl1yM 5Ip7jo96ZBZ1gatSo19tthmYO89IZD/Y5N46p1bkhHKXrn5gtsMg/8PVg0v5mdkx5Vua bliQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=GnutG9b7; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f207si5045381oib.65.2020.03.21.11.40.25; Sat, 21 Mar 2020 11:40:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=GnutG9b7; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727028AbgCUSkS (ORCPT + 99 others); Sat, 21 Mar 2020 14:40:18 -0400 Received: from mail-wm1-f68.google.com ([209.85.128.68]:32964 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727015AbgCUSkS (ORCPT ); Sat, 21 Mar 2020 14:40:18 -0400 Received: by mail-wm1-f68.google.com with SMTP id r7so9863404wmg.0 for ; Sat, 21 Mar 2020 11:40:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=GfOZeqjqnk/DxOF0n2BpDoMhtlujkViZfTpdaqMdXao=; b=GnutG9b7/euBkrBNVlKbdybfzPrJRXxam7QZvnvCnN0wjY+D10JFBzMQ98eCz8nR/R rHz4kD16qeci4GcWNCAn0FoAT5Og2wS9B5Hn4UkdN9FD5sG7oxTnvG+POLTzx7zt79wh vs8l1ILHLjIb6tllQuC7ceiyjQM+bbK3w9g+peUhKZxkE4jZ7dSbfDDtqHkCAinZ6+yp rPwKA3KLpthrLIFl6fxjvyLKEv+KNYKYomycYLpYo6LN8q4mb34BCTvlJwLTmqkGlxVN lIVwnq72RHXV/Jq5fIIWbVG06vF62bgl98MWEENH8n9FuVK8MILCvYw3jH7Hp3GcFdmX gH+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=GfOZeqjqnk/DxOF0n2BpDoMhtlujkViZfTpdaqMdXao=; b=hs105Y5lMSWwpf2ItG51+I48yZqoSiWY2amdkdY/hW2UTquH39wvUx00q2qFsLCa3D qt7DkXqdSPfgAA6OZHMqy7GDSgPorf7PxWGcFn4pWYi1DDwirZZ6u9l6IPxKv2l4W1vd UsMtC3z0/GS3aEG549OqaOrLcJO0oBoFqxB3DtVzllBMpZSLtBzpyt7MzvxQjng3WN3o ETfhivE1x0GIeyc045KsxPx8ShHL8SB8dGoH00ukfYiBzZX5XdQhEeuttr0bGZvIQbbR Kp3c67lVdwKMgNBYIOG29hiCzWD7F4BjR2YwkEd6pexUuIbxyfVqcg7uyY5ofetGPbY5 AEeg== X-Gm-Message-State: ANhLgQ2fJ6twPlcac3+n6ed1xrwG/1o57Ay/8EO1+Bo6mF+PpQAqIfZP hIRUDUdJf0oK1iJl2Z/qlvw= X-Received: by 2002:a1c:f60d:: with SMTP id w13mr18037679wmc.171.1584816017231; Sat, 21 Mar 2020 11:40:17 -0700 (PDT) Received: from pali ([2a02:2b88:2:1::5cc6:2f]) by smtp.gmail.com with ESMTPSA id o16sm14920253wrs.44.2020.03.21.11.40.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Mar 2020 11:40:16 -0700 (PDT) Date: Sat, 21 Mar 2020 19:40:15 +0100 From: Pali =?utf-8?B?Um9ow6Fy?= To: Luiz Augusto von Dentz Cc: "linux-bluetooth@vger.kernel.org" , David Heidelberg Subject: Re: bluez: Export SDP "Remote audio volume control" item for HSP profile Message-ID: <20200321184015.mtmb7zfk3jqcf6ya@pali> References: <20191212172944.hgt6se2qz2hpsbo2@pali> <20191212230314.g5gt6rxkphzpwucd@pali> <20200209130243.u4kpbj3cwhbdqa56@pali> <20200320130159.cm2shncjg5qo6xgh@pali> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: NeoMutt/20180716 Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org On Friday 20 March 2020 10:48:02 Luiz Augusto von Dentz wrote: > Hi Pali, > > On Fri, Mar 20, 2020 at 6:02 AM Pali Rohár wrote: > > > > On Sunday 09 February 2020 14:02:43 Pali Rohár wrote: > > > On Friday 13 December 2019 00:03:14 Pali Rohár wrote: > > > > On Thursday 12 December 2019 21:42:27 Luiz Augusto von Dentz wrote: > > > > > Hi Pali, > > > > > > > > > > On Thu, Dec 12, 2019 at 7:31 PM Pali Rohár wrote: > > > > > > > > > > > > Hello! > > > > > > > > > > > > According to HSP 1.2 specification, section 4.7 Remote Audio Volume > > > > > > Control, Support for remote audio volume control is optional, so an > > > > > > implementation may support none, either, or both of the controls for > > > > > > microphone volume and speaker volume. > > > > > > > > > > > > According to HSP 1.2 specification, section 5.3 SDP Interoperability > > > > > > Requirements, bluetooth device with HSP profile announce via SDP "Remote > > > > > > audio volume control" field information if device itself supports volume > > > > > > control. > > > > > > > > > > > > But currently I did not found any way how to access "Remote audio volume > > > > > > control" SDP field in (pulseaudio) application as bluez does not export > > > > > > it. > > > > > > > > > > > > Can you please export this field? E.g. for HFP profile all optional > > > > > > features from SDP are passed to NewConnection() DBus method via > > > > > > fd_properties dictionary under Features key. Could you export that > > > > > > "Remote audio volume control" bit for HSP profile in Features key? > > > > > > > > > > > > And in same way, this needs to be handled also in RegisterProfile() DBus > > > > > > method. > > > > > > > > > > Do you have a use case in mind? > > > > > > > > Yes, checking in pulseaudio if remote side announce that supports remote > > > > volume control or not. And based on this switch to software volume > > > > level. > > > > > > Hello Luiz! Is it is possible to export this field? > > > > Hello, I have not got any answer to my question. > > > > So may I ask again how to retrieve SDP attribute 0x0302 "Remote audio > > volume control" for a remote bluetooth headset with HSP profile? > > > > It is really important as this attribute says if remote bluetooth > > headset supports volume control or not. In case it does not support, we > > need to switch to software volume control on host side. > > > > There is open pulseaudio bug that on some headsets it is not possible to > > control volume level and therefore pulseaudio needs to switch to > > software volume control. > > > > But without checking this SDP attribute 0x0302 this is not possible. > > Not sure when I will have time to work on this one, btw can't you > actually detect this via some AT command, or the headset simple don't > respond to the AT command for volume control? Hello Luiz! I'm planing to add some "workaround" by detecting what happen when VGS or VGM commands are sent. But this is just a workaround and I would like to know how would proper solution would like. Does it mean that currently it is really not possible to retrieve SDP attributes of remote device? And we need to wait until bluez daemon exports it via DBus API (fd_properties dictionary under Features key)? -- Pali Rohár pali.rohar@gmail.com