Making this call, without waiting for the reply, always fails:
dbus-send --system --dest=org.bluez /org/bluez/hci0 org.freedesktop.DBus.Properties.Set string:org.bluez.Adapter1 string:Discoverable variant:boolean:false ; dbus-send --system --dest=org.bluez /org/bluez/hci0 org.freedesktop.DBus.Properties.Set string:org.bluez.Adapter1 string:DiscoverableTimeout variant:uint32:0
The same call with the --print-reply argument to dbus-send will however work. I think bluez might be ignoring the calls if the caller is going to disappear.
I monitored the state of "Discoverable" and "DiscoverableTimeout" using bluetoothctl, after setting Discoverable to on.
Making this call, without waiting for the reply, always fails: .DBus.Propertie s.Set string: org.bluez. Adapter1 string:Discoverable variant: boolean: false ; dbus-send --system --dest=org.bluez /org/bluez/hci0 org.freedesktop .DBus.Propertie s.Set string: org.bluez. Adapter1 string: DiscoverableTim eout variant:uint32:0
dbus-send --system --dest=org.bluez /org/bluez/hci0 org.freedesktop
The same call with the --print-reply argument to dbus-send will however work. I think bluez might be ignoring the calls if the caller is going to disappear.
I monitored the state of "Discoverable" and "DiscoverableTi meout" using bluetoothctl, after setting Discoverable to on.