Endpoint (endpoint)#

This class provides a command for closing Bluetooth connections.

Commands#

endpoint_close#

Deprecated. Use new command le_connection_close to close Bluetooth connections.

This command can be used to close a Bluetooth connection. The parameter is a connection handle which is reported in event le_connection_opened.

Command#

Byte

Type

Name

Description

0

0x20

hilen

Message type: Command

1

0x01

lolen

Minimum payload length

2

0x0b

class

Message class:Endpoint

3

0x02

method

Message ID

4

uint8

endpoint

The connection handle

Response#

Byte

Type

Name

Description

0

0x20

hilen

Message type: Response

1

0x03

lolen

Minimum payload length

2

0x0b

class

Message class:Endpoint

3

0x02

method

Message ID

4-5

uint16

result

Result code:

  • 0: success

  • Non-zero: an error occurred

For other values refer to the Error codes

6

uint8

endpoint

The connection handle that was closed

API#

/* Function */
struct gecko_msg_endpoint_close_rsp_t *gecko_cmd_endpoint_close(uint8 endpoint);

/* Response id */
gecko_rsp_endpoint_close_id

/* Response structure */
struct gecko_msg_endpoint_close_rsp_t
{
  uint16 result,
  uint8 endpoint
}

Events generated#

Event

Description

le_connection_closed