I split the hexadecimal into several bytes and populated an array with the values:
Code: Select all
uint8_t ManufacturerData[3];
ManufacturerData[0] = 0x01;
ManufacturerData[1] = 0x08;
ManufacturerData[2] = 0x03;
advertisingData[0] = 0x00;
advertisingData[1] = 0x0A;
advertisingData[2] = 0x00;
advertisingData[3] = 0x04;
advertisingData[4] = 0x00;
advertisingData[5] = 0x01;
advertisingData[6] = 0x00;
advertisingData[7] = 0x02;
advertisingData[8] = 0x0A;
advertisingData[9] = 0x06;
advertisingData[10] = 0x00;
advertisingData[11] = 0x01;
Code: Select all
.set_scan_rsp = false;
.include_name = true;
.include_txpower = true;
.min_interval = 0x0006;
.max_interval = 0x0010;
.appearance = 0x00;
.manufacturer_len = sizeof(uint8_t) * 4;
.p_manufacturer_data = disneyManufacturerData;
.service_data_len = 12 * sizeof(uint8_t);
.p_service_data = advertisingData;
.service_uuid_len = 0;
.p_service_uuid = NULL;
.flag = (ESP_BLE_ADV_FLAG_GEN_DISC | ESP_BLE_ADV_FLAG_BREDR_NOT_SPT);