Skip to content

zlberto/BluetoothServer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Bluetooth Server

#include <iostream>
#include BluetoothServer.h"

int main() {
    // Create a BluetoothServer instance with your desired device alias
    BluetoothServer server;
	server.registerAgent();
	server.setAlias("MyIoTDeviceTreatmo");
	server.powerOnAdapter();
	server.makeDiscoverable();
	server.makePairable();
	server.startAdvertising();
	

	// Initialize the GLib main loop
    GMainLoop* loop = g_main_loop_new(NULL, FALSE);

	// Start the main loop
    g_main_loop_run(loop);

    // Cleanup the main loop when the application exits
    g_main_loop_unref(loop);

    return 0;
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages