This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Advertise multiple vendor UUIDs

Hello!

I hope this question has not been asked before - at least I can't find it. I do have an application with two vender specific services (128bit UUID's) and I want to advertise both of them.

First: I know how to advertise two standard services (16bit UUIDs):

ble_uuid_t m_adv_uuids[] = 
{
    {BLE_UUID_SERVICE_ONE, BLE_UUID_TYPE_BLE},
    {BLE_UUID_SERVICE_TWO, BLE_UUID_TYPE_BLE}
};

image description

Second: I know how to advertise one vendor Service (128bit UUID):

ble_uuid_t m_adv_uuids[] = 
{
    {BLE_UUID_SERVICE_ONE, BLE_UUID_TYPE_VENDOR_BEGIN}
};

image description

But when I want to add a sencond vendor UUID to "Second", I end up in errors. Mixing BLE and VENDOR_BEGIN is possible, but than I only have one 128bit UUID and the others are 16bit.

PS: Adding UUIDs is done the folowing way:

ble_advdata_t srdata;
memset(&srdata, 0, sizeof(srdata));

srdata.uuids_complete.uuid_cnt = sizeof(m_adv_uuids) / sizeof(m_adv_uuids[0]);
srdata.uuids_complete.p_uuids = m_adv_uuids;

Thanks, Johann

Parents
  • What software are you using to receive the advertisements, is it some existing software e.g. an iOS app or something you are writing yourself

    If its just a normal iBeacon scanner, then the iBeacon protocol just allows for one UUID and this is all the App will look for

    It sounds like what you really want to do is alternate between sending 2 different vendor UUID's or perhaps send one the send the other, but I'm not sure you can send both at once and still have a valid iBeacon data packet

Reply
  • What software are you using to receive the advertisements, is it some existing software e.g. an iOS app or something you are writing yourself

    If its just a normal iBeacon scanner, then the iBeacon protocol just allows for one UUID and this is all the App will look for

    It sounds like what you really want to do is alternate between sending 2 different vendor UUID's or perhaps send one the send the other, but I'm not sure you can send both at once and still have a valid iBeacon data packet

Children
No Data
Related