mirror of
https://gitlab.com/eql/lqml.git
synced 2025-12-06 02:30:38 -08:00
example 'meshtastic': fix for BLE mode
This commit is contained in:
parent
804aec5e90
commit
fdf1db11f9
2 changed files with 5 additions and 4 deletions
|
|
@ -16,12 +16,13 @@ const UID BLE_ME::uuid_fromNum = UID(STR("{ed9da18c-a800-4f66-a670-aa7547e3445
|
|||
|
||||
#ifdef Q_OS_ANDROID
|
||||
BLE_ME::BLE_ME(QtAndroidService* service, Connection* _con) : BLE(uuid_service), emitter(service), con(_con) {
|
||||
// forward signals defined in class BLE
|
||||
connect(this, &BLE::deviceDiscovered, service, &QtAndroidService::deviceDiscovered);
|
||||
connect(this, &BLE::bleError, service, &QtAndroidService::bleError);
|
||||
#else
|
||||
BLE_ME::BLE_ME(Connection* _con) : BLE(uuid_service), emitter(_con), con(_con) {
|
||||
#endif
|
||||
// forward signals defined in class BLE
|
||||
connect(this, &BLE::deviceDiscovered, [&](const QString& name) { emitter->deviceDiscovered(name); });
|
||||
connect(this, &BLE::bleError, [&]() { emitter->bleError(); });
|
||||
|
||||
connect(this, &BLE::mainServiceReady, this, &BLE_ME::ini);
|
||||
connect(this, &BLE::deviceDisconnecting, this, &BLE_ME::disconnecting);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue