We have upgraded the community system as part of the upgrade a password reset is required for all users before login in.

Scan for Wi-Fi networks from within a C program?



  • Hi Omega Kids!

    I'm writing a C++ program, for the Omega, that needs to scan for Wi-Fi networks. I understand that I could do this by making a system call (from C) to

    ubus call onion wifi-scan '{"device":"ra0"}'

    and then parsing the JSON-formatted output.

    Is there a more direct way to do this? For example, a C library call that my executable can call directly?

    Or has somebody already written such a library as a wrapper around the ubus system call, above?

    Just trying to do things as simply as possible here. Thanks!

    Tim



  • Hi Tim.

    This makes sense. You'd like to be a ubus client. A google search turned up this example:

    https://github.com/txomon/ubus/blob/master/examples/client.c

    Chris


Log in to reply
 

Looks like your connection to Community was lost, please wait while we try to reconnect.