about sdp server

21 views
Skip to first unread message

Arthur Evstifeev

unread,
Aug 23, 2010, 4:38:32 AM8/23/10
to btstack-dev
Good day. I have some questions about sdp service records. As i say in
issue (wrong issue:) ) after registering records i have done some
tests with sdp_record_matches_service_search_pattern and it returning
me that service found, but when i trying SERVICE_SEARCH_REQUEST i`m
not getting 1 of the services... Maybe this is the result of the wrong
records, then why both sdp_record_matches_service_search_pattern
telling me that services found?

i have tried 3 ways of the service records creating:
1. de_add_number(service, DE_UINT, DE_SIZE_16,
SDP_ServiceClassIDList);
de_add_number(service, DE_UUID, DE_SIZE_16, 0x112d);
de_add_number(service, DE_UUID, DE_SIZE_16, 0x1204);
2. // 0x0001
uint8_t *serviceClassIDList = de_push_sequence(service);
de_add_number(serviceClassIDList, DE_UINT, DE_SIZE_16, 0x0001);
uint8_t *serviceClasses = de_push_sequence(serviceClassIDList);
de_add_number(serviceClasses, DE_UUID, DE_SIZE_16, 0x112d);
de_add_number(serviceClasses, DE_UUID, DE_SIZE_16, 0x1204);
de_pop_sequence(serviceClassIDList, serviceClasses);
de_pop_sequence(service, serviceClassIDList);
3. seq2 = de_push_sequence(service);
de_add_number(seq2, DE_UINT, DE_SIZE_16, SDP_ServiceClassIDList);
de_add_number(seq2, DE_UUID, DE_SIZE_16, 0x111f);
de_add_number(seq2, DE_UUID, DE_SIZE_16, 0x1203);
de_pop_sequence(service, seq2);

And another question.. A didn`t saw in function
sdp_handle_service_attribute_request code that is returning requested
attributes by SERVICE_ATTRIBUTE_REQUEST it returning only bytes count,
i also see this in log files...

Thank you!

Matthias Ringwald

unread,
Aug 23, 2010, 7:45:05 AM8/23/10
to btstack-dev, Arthur Evstifeev
Hi Arthur

you only tried 3 different versions of encoding SDP attributes - but none of them is correct :)

the attribute ID is stored as a DE_UINT, the attribute values can be a single value or a data element sequence.

Try:

de_add_number(service, DE_UINT, DE_SIZE_16, SDP_ServiceClassIDList);
attribute = de_push_sequence(service);
{


de_add_number(service, DE_UUID, DE_SIZE_16, 0x112d);
de_add_number(service, DE_UUID, DE_SIZE_16, 0x1204);
}

de_pop_sequence(service, attribute);

> then why both sdp_record_matches_service_search_pattern
> telling me that services found?

that's because it's the specified behaviour. The service search pattern matches ANY UUID in the record, independent of any semantics.


> A didn`t saw in function
> sdp_handle_service_attribute_request code that is returning requested
> attributes by SERVICE_ATTRIBUTE_REQUEST it returning only bytes count,

that might be related to the incorrect record. Please try again with a correctly formatted one.

In general, the SDP implementation should be 100% for correct records, but it's not helping/verifying yours at the moment.

Best
Matthias

> --
> You received this message because you are subscribed to the Google Groups "btstack-dev" group.
> To post to this group, send email to btsta...@googlegroups.com.
> To unsubscribe from this group, send email to btstack-dev...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/btstack-dev?hl=en.
>

Arthur Evstifeev

unread,
Aug 23, 2010, 2:02:09 PM8/23/10
to btstack-dev
Thank you very much for very useful example. Now everything is
perfect!

On 23 авг, 15:45, Matthias Ringwald <matthias.ringw...@gmail.com>
wrote:

Arthur Evstifeev

unread,
Aug 30, 2010, 4:00:20 PM8/30/10
to btstack-dev, Arthur Evstifeev
Thank you again for the help, btstack was very useful for me, may be
this video will be interesting for you :) http://www.youtube.com/watch?v=_lz9ictQKNU

Matthias Ringwald

unread,
Aug 31, 2010, 5:04:29 AM8/31/10
to btsta...@googlegroups.com, Arthur Evstifeev
Hi Arthur,

thanks for the YouTube link, but can you tell us a bit more?

The SDP record said you're implementing Remote SIM Access Protocol with BTstack. I even made a wiki page as people started to ask for that: http://code.google.com/p/btstack/wiki/RemoteSimAccessProtocol

Does it run on the iPhone? How does one talk to the SIM card there - is this done using AT commands?
What's your plans for your project (open source it, free closed, or commerical)?

Best
Matthias

Arthur Evstifeev

unread,
Aug 31, 2010, 5:37:50 AM8/31/10
to btstack-dev
Good day!

On 31 авг, 13:04, Matthias Ringwald <matthias.ringw...@gmail.com>
wrote:
> Hi Arthur,
>
> thanks for the YouTube link, but can you tell us a bit more?
>
> The SDP record said you're implementing Remote SIM Access Protocol with BTstack. I even made a wiki page as people started to ask for that:http://code.google.com/p/btstack/wiki/RemoteSimAccessProtocol

yes i have implemented rSAP on iphone. In video i tried to watch that
but i understand it not so good )) in the beginning of the video i
have called from iphone to nokia telephone to watch the phone number
of the iphone. Then i turned on the fly mode in the iphone and from
the terminal started application (gui version will be soon). Then i
connected from nokia 616 car kit to the iphone (no codes because of
the link key) and then i called from nokia 616 to the iphone and i
tried to watch that there is no sim in nokia 616 and the phone number
identical to the iphone number. :)

>
> Does it run on the iPhone? How does one talk to the SIM card there - is this done using AT commands?
> What's your plans for your project (open source it, free closed, or commerical)?
I`m made this app for some company and i don`t really know their plans
about this app for now, but hope to know them soon :)

>
> Best
> Matthias
>
> On 30.08.2010, at 22:00, Arthur Evstifeev wrote:
>
>
>
> > Thank you again for the help, btstack was very useful for me, may be
> > this video will be interesting for you :)http://www.youtube.com/watch?v=_lz9ictQKNU
Reply all
Reply to author
Forward
0 new messages