You are not logged in.
ello,
I use sdbus-c++ and IWD to work with WiFi.
I already can get in C++ list of WiFi networks and find my network.
If I use also in Terminal IWCTL - I can connect my 'station' (wifi adapter) to the WiFi PSK network with password (manual input by request) - so I receive the network as 'known' - with password stored.
Then in C++ I can (re)connect to the network with code like this:
#include <sdbus-c++/sdbus-c++.h>
..
auto connection = sdbus::createSystemBusConnection();
auto proxy = sdbus::createProxy(*connection, "net.connman.iwd", networkObjectPath); // networkObjectPath is my path
sdbus::Variant res_connect;
proxy->callMethod("Connect") /
.onInterface("net.connman.iwd.Network")
.storeResultsTo(res_connect);
But here I have next problem/question - how I can set password to WiFi network in C++? Using IWD and D-BUS (sdbus-c++ lib).
Last edited by user_24 (2024-11-01 22:12:22)
Offline