public string GetGapProfileStr(byte gapProfile)
{
string profile = string.Empty;
if (gapProfile == 0)
return "Gap Profile Role Bit Mask Is Not Set";
if ((gapProfile & 0x01) == 0x01)
profile += " Broadcaster ";
if ((gapProfile & 0x02) == 0x02)
profile += " Observer ";
if ((gapProfile & 0x04) == 0x04)
profile += " Peripheral ";
if ((gapProfile & 0x08) == 0x08)
profile += " Central ";
return profile;
}