|
ELEC-C7222
Libraries for ELEC C7222 Course Work
|
BLE example showing a minimal custom service with READ + WRITE characteristics. More...
#include <cassert>#include <cstdint>#include <cstdio>#include <vector>#include "../common/gap_event_handler.hpp"#include "../common/characteristic_event_handler.hpp"#include "advertisement_data.hpp"#include "attribute_server.hpp"#include "ble.hpp"#include "characteristic.hpp"#include "freertos_task.hpp"#include "gap.hpp"#include "platform.hpp"#include "app_profile.h"
Functions | |
| int | main () |
| Program entry point for the custom service RW example. | |
BLE example showing a minimal custom service with READ + WRITE characteristics.
This example demonstrates how to implement a custom service using:
.gatt profile (compiled into app_profile.h)AttributeServer to locate services/characteristics by UUIDCharacteristic::EventHandler to react to reads and writesService UUID: 0xFFE0
1) Connect to "c7222-rw-demo" 2) Read "PublicValue" -> returns the current value 3) Write any bytes to "WriteValue" 4) Read "PublicValue" again -> it becomes whatever you wrote
| int main | ( | void | ) |
Program entry point for the custom service RW example.
Creates the BLE task and starts the FreeRTOS scheduler.
