Serial Port Profile
Topics | Functions | Structs, Records, Enums | Types

The Bluetooth SPP API supports client and server functionality for one-to-one connections.


The built-in Bluetooth Serial Port Profile (SPP) supports one-to-one connections. The API enables you to connect two Bluetooth devices and the exchange data between them. When acting as a client, it can:

  • Scan for Bluetooth devices and connects to a designated server device.
  • Send and receive data to and from the connected server device.

When acting as a server, it can:

  • Accept/reject SPP clients - Send/receive data from a client

The API only support one-to-one connections.

A server uses this function in order to accept a connection when it is notified by the VM_BT_SPP_EVENT_AUTHORIZE event. 
Creates an SPP instance. 
This function destroys a SPP resource. 
Connects to a server. 
Disconnects an already opened SPP connection. 
Get the Bluetooth address with the connection ID. 
Gets the bt_spp minimum buffer, returns the minimum size for tx and rx buffer in vm_bt_spp_connect() It is recommended to malloc tx/rx buffer for SPP data transmission, the size is determined by the device. 
Opens bt_spp and returns the resource handle if it is successful. 
Read data over an established connection. 
The server uses this function to reject when it is notified by the VM_BT_SPP_EVENT_AUTHORIZE event. PARAMETERS. connection_id : Connection ID. 
Set the security level for the handle. 
Sets an SPP resource name. 
Writes data over an established connection. 
Structs, Records, Enums
Struct, Record, Enum 
bt_spp srv for app event enum 
spp srv for app event structure 
bt_spp return error type 
bt_spp security level 
bt SPP connection id 
Callback function of bt_spp. 
bt_spp open handle 
Created with a commercial version of Doc-O-Matic. In order to make this message disappear you need to register this software. If you have problems registering this software please contact us at