Bash 构造dbus发送查询以停止GObject主循环

Bash 构造dbus发送查询以停止GObject主循环,bash,bluetooth,dbus,Bash,Bluetooth,Dbus,我在这里找到了如何通过dbus send停止MainLoop的示例 ,但我很难弄清楚使用哪些变量来阻止raspberry上的bluez simple agent 示例查询设置如下: dbus-send --session --type=signal --dest=com.example.StopLoop /com/example/StopLoop com.example.StopLoop.Stop 有了这些信息: OPATH = "/com/example/StopLoop" IFACE =

我在这里找到了如何通过dbus send停止MainLoop的示例 ,但我很难弄清楚使用哪些变量来阻止raspberry上的bluez simple agent

示例查询设置如下:

dbus-send --session --type=signal --dest=com.example.StopLoop /com/example/StopLoop com.example.StopLoop.Stop
有了这些信息:

OPATH = "/com/example/StopLoop"
IFACE = "com.example.StopLoop"
BUS_NAME = "com.example.StopLoop"
如果我有此信息:

BUS_NAME = 'org.bluez'
AGENT_INTERFACE = 'org.bluez.Agent1'
AGENT_PATH = "/test/autoagent"
我应该如何设置查询? 这一条给出:

dbus-send --session --type=signal  --print-reply --dest=org.bluez.Agent1 /test/autoagent org.bluez.Agent1.Stop
给我一个错误

Error org.freedesktop.DBus.Error.ServiceUnknown: The name org.bluez was not provided by any .service files