Skip to content

Conversation

@szymon-czapracki
Copy link
Contributor

Added new BTP command BTP_GATT_EATT_CONNECT (opcode 0x1f) to trigger
EATT connections with configurable L2CAP channels.

Implemented handler eatt_conn() that:

  • Calls ble_eatt_connect() with the requested channel count and proper address

Updated supported_commands response to advertise the new capability.

Enables testing scenarios requiring explicit control over EATT establishment and channel management.

@github-actions github-actions bot added the size/S Small PR label Mar 28, 2025
@szymon-czapracki szymon-czapracki changed the title nimble/eatt: Add manual EATT connection control to BTP tester nimble/bttester: Add manual EATT connection control to BTP tester Apr 14, 2025
ble_gap_conn_find_handle_by_addr(&cp->address, &conn_handle);

rc = ble_eatt_connect(conn_handle, cp->num_channels);
if (rc == BLE_HS_EALREADY) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this check doesn't seem valid, I'd suggest something like

if (rc == 0 || rc == BLE_HS_EALREADY) {
    return BTP_STATUS_SUCCESS;
}

return BTP_STATUS_FAILED;

(or reverse logic if you prefer to have success as 'default' case)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Adds new BTP command `BTP_GATT_EATT_CONNECT` (opcode 0x1f) to trigger
  EATT connections with configurable L2CAP channels.

Implements handler `eatt_conn()` that:
  * Calls `ble_eatt_connect()` with the requested channel count
    and proper address

Enables testing scenarios requiring explicit control over EATT establishment
and channel management.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/S Small PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants