Linux bluetooth development
 help / color / mirror / Atom feed
From: Xavier Garreau <x.garreau@prim-time.fr>
To: bluez-users@lists.sourceforge.net
Subject: Re: [Bluez-users] adding a sdp service with a 128bit uuid
Date: Tue, 08 Mar 2005 14:39:15 +0100	[thread overview]
Message-ID: <422DAB03.1010402@prim-time.fr> (raw)
In-Reply-To: <20050308123527.49819.qmail@web60910.mail.yahoo.com>

>     3. actually this is more a c then a bluez question, but i'd
>     appreciate if
>     someone could tell it nevertheless:
>     # sdp_uuid32_create(uuid_t *uuid, uint32_t data);
>     # sdp_uuid128_create(uuid_t *uuid, const void *data);
>     the second function takes the uuid as "const void *data". What is the
>     appropriate way to give a uuid like 2c3ef0c843674369b1dfb7315e76332a to
>     that function?
>     I asked google and he (she?) told me this:
>     http://www.xgarreau.org/aide/devel/bluetooth/timeserver.c
>     but it seems a little big for me...

Whaou, nice, i love google :)

Actually i wrote this sample for a presentation in a university. It's 
not production quality code.

But to give data as void* you can do something like this:

unsigned char uuid_data[16] = {0x2c, 0x3e, 0xf0, 0xc8, 0x43, 0x67, 0x43, 
0x69, 0xb1, 0xdf, 0xb7, 0x31, 0x5e, 0x76, 0x33, 0x2a};
...
sdp_uuid128_create (&uuid, (void*)uuid_data);

Actually, in the code you mentionned i used the create_base_uuid 
function from a bluez source ... But i don't remember from what file it 
was ...

Regards,
Xavier


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Bluez-users mailing list
Bluez-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-users

  parent reply	other threads:[~2005-03-08 13:39 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-03-08 12:35 [Bluez-users] adding a sdp service with a 128bit uuid Ka Kin Cheung
2005-03-08 13:03 ` Marco Trudel
2005-03-08 13:39 ` Xavier Garreau [this message]
  -- strict thread matches above, loose matches on Subject: below --
2005-03-05  1:50 Marco Trudel
2005-03-05 11:21 ` Marcel Holtmann
2005-03-05 13:24   ` Marco Trudel
2005-03-05 13:38     ` Marcel Holtmann
2005-03-06  8:11       ` Taneli Vähäkangas
2005-03-06 11:19         ` 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=422DAB03.1010402@prim-time.fr \
    --to=x.garreau@prim-time.fr \
    --cc=bluez-users@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