linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Claudio Takahasi <cktakahasi@gmail.com>
To: bluez-devel@lists.sourceforge.net
Subject: [Bluez-devel] hcid and bluetoothd
Date: Wed, 14 Sep 2005 10:48:56 -0300	[thread overview]
Message-ID: <e1effdeb050914064849913a76@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 2679 bytes --]

Hi Marcel,

You said in an old e-mail that hcid is your playground for D-Bus services. 
Probably, hcid D-Bus should be the starting point for bluetoothd.

I would like to align your ideas to avoid future reworks.

D-Bus provides 4 types of messages:
1. Method call
2. Method reply
3. Signals
4. Error
Currently, only signals are sent. The following signals are sent as result 
of the hci commands:
- InquiryStart
- InquiryResult
- InquiryComplete
- RemoteName
path: /org/bluez/DevAgent
interface: org.bluez.DevAgent

The topics that I want discuss are:
1. hcid signals
In my opinion it is not necessary send signals to notity inquiry 
start/complete. Only signals for news devices are enough. 
Another aspect is, inquiry result can contain repeated devices. This 
approach could cause D-Bus app client overhead(inconsistency), by other hand 
if periodic inquiry is active repeated signals must be sent because more 
than one client can be filtering these signals and they can start at 
different time. :)

2. hcid and bluetoothd object path
What is the object path that you want use?
I suggested in an old email use a hierarchical paths. bluetoothd can be the 
main object path provided at /org/bluez/bluetoothd, hci D-Bus services could 
be provided at /org/bluez/bluetoothd/hci

3. D-Bus services
hci D-BUS services is the next step, I am going to starting coding ASAP. 
Regarding inquiry requests, what kind of implementation do you prefer, send 
method reply message or send only signals(like the current)?
If you use signals, all D-Bus client capturing D-Bus hci signals are able to 
see the new devices found. Using a method reply only the peer (requestor) 
will receive. Using a method reply approach, we can implement device class 
filters and avoid repeated devices. We have the same problem for remote 
name, disconnect, authentication/security, info, role switch and display 
connections.

4. bluetoothd
There are shared codes like(pand/bnep.c, pand/sdp.c, hidd/sdp.c, ...) that 
we need be aware.
It is NOT clear for me how hcid and bluetoothd should work. hcid must be 
running all the time, but the hci D-Bus service will be running only if the 
system has a D-Bus system daemon running. Therefore, who should register the 
hci object path? IMHO, bluetoothd should centralize all D-Bus services. It 
will not be easy separate the "normal" code from the "D-Bus code". Maybe 
your "new interface" that your are defining can solve this problem.

5. new interface
You said that a new interface for kernel and the userspace communication is 
being defined. What is the current status?


Regards,
Claudio.

[-- Attachment #2: Type: text/html, Size: 2853 bytes --]

             reply	other threads:[~2005-09-14 13:48 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-14 13:48 Claudio Takahasi [this message]
2005-09-15  9:08 ` [Bluez-devel] hcid and bluetoothd Marcel Holtmann
2005-09-15 14:04   ` Claudio Takahasi
2005-09-15 14:23     ` Marcel Holtmann

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=e1effdeb050914064849913a76@mail.gmail.com \
    --to=cktakahasi@gmail.com \
    --cc=bluez-devel@lists.sourceforge.net \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).