From: David Frey <dpfrey@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: bluetoothctl "advertise on" fails
Date: Tue, 28 May 2019 13:54:55 -0700 [thread overview]
Message-ID: <ae0ac0fb-faae-edaa-7205-9ef9d6b03edd@gmail.com> (raw)
Hi,
I have an embedded system running Yocto Linux and a desktop using Arch
Linux. Bluez is 5.50 in both cases. I'm using the same Cypress CYW20719
Bluetooth chipset connected via a UART. On the embedded system, running
"advertise on" in bluetoothctl fails with the error message:
"Failed to register advertisement: org.bluez.Error.NotPermitted"
I dug into the source code a bit and I suspect that the error is being
produced in register_advertisement() from advertising.c:
https://git.kernel.org/pub/scm/bluetooth/bluez.git/tree/src/advertising.c?h=5.50#n1135
On my Linux PC, running "advertise on" is successful.
The error message in the code is "Maximum advertisements reached", so I
decided to pursue that. I ran the command "dbus-send --system
--print-reply --type=method_call --dest=org.bluez /
org.freedesktop.DBus.ObjectManager.GetManagedObjects" on both the
embedded system and the PC.
This is the snippet from the embedded system that I think is pertinent:
dict entry(
string "org.bluez.LEAdvertisingManager1"
array [
dict entry(
string "ActiveInstances"
variant byte 0
)
dict entry(
string "SupportedInstances"
variant byte 0
)
dict entry(
string "SupportedIncludes"
variant array [
string "local-name"
]
)
]
)
And the corresponding snippet from the PC:
dict entry(
string "org.bluez.LEAdvertisingManager1"
array [
dict entry(
string "ActiveInstances"
variant byte 0
)
dict entry(
string "SupportedInstances"
variant byte 5
)
dict entry(
string "SupportedIncludes"
variant array [
string "tx-power"
string "appearance"
string "local-name"
]
)
]
)
I'm not sure what "SupportedIncludes" really means, but I immediately
noticed that the value for "SupportedInstances" on the embedded system
is 0 while the on the PC it's 5.
Why are these values different? Please let me know if there is any
other information that would be useful.
Thanks,
David
reply other threads:[~2019-05-28 20:54 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ae0ac0fb-faae-edaa-7205-9ef9d6b03edd@gmail.com \
--to=dpfrey@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.