tests: bluetooth: tester: add page number to response

PTS requires IUT to send requests with page number with
0xFF or the highest supported page number in order to
retrieve all the composition data pages from the lower
tester.

This commit add the page number to the response, thus
the upper tester can follow the last page number and
send the next page request until page 0 is requested.

Signed-off-by: Alperen Şener <alperen.sener@nordicsemi.no>
This commit is contained in:
Alperen Şener 2023-10-12 16:27:47 +02:00 committed by Carles Cufí
parent 098b5bd05b
commit 2972341388

View file

@ -2033,8 +2033,9 @@ static uint8_t composition_data_get(const void *cmd, uint16_t cmd_len,
return BTP_STATUS_FAILED;
}
memcpy(rp->data, comp->data, comp->len);
*rsp_len = comp->len;
rp->data[0] = page;
memcpy(rp->data + 1, comp->data, comp->len);
*rsp_len = comp->len + 1;
return BTP_STATUS_SUCCESS;
}