Skip to content

Commit

Permalink
Change advertised struct size (#20543)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jakub authored Jul 11, 2022
1 parent d98568f commit 19f2d7d
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/platform/Tizen/BLEManagerImpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,6 @@ static constexpr unsigned kNewConnectionScanTimeoutMs = 10000;
/* Tizen Default Connect Timeout */
constexpr System::Clock::Timeout kConnectTimeoutMs = System::Clock::Seconds16(10);

const int BtpServiceDataLenMax =
7; // OpCode(1) + Discriminator(2) + VendorId(2) + ProductId(2), 5.2.3.8.6. Advertising Data, CHIP Specification

static void __AdapterStateChangedCb(int result, bt_adapter_state_e adapterState, void * userData)
{
ChipLogProgress(DeviceLayer, "Adapter State Changed: %s", adapterState == BT_ADAPTER_ENABLED ? "Enabled" : "Disabled");
Expand Down Expand Up @@ -584,9 +581,9 @@ int BLEManagerImpl::RegisterGATTServer()

int BLEManagerImpl::StartAdvertising()
{
int ret = BT_ERROR_NONE;
CHIP_ERROR err = CHIP_NO_ERROR;
char service_data[BtpServiceDataLenMax] = {
int ret = BT_ERROR_NONE;
CHIP_ERROR err = CHIP_NO_ERROR;
char service_data[sizeof(ChipBLEDeviceIdentificationInfo)] = {
0x0,
}; // need to fill advertising data. 5.2.3.8.6. Advertising Data, CHIP Specification
ChipBLEDeviceIdentificationInfo deviceIdInfo = {
Expand Down

0 comments on commit 19f2d7d

Please sign in to comment.