maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   Getting the id of currently connected WIFI from Python (https://talk.maemo.org/showthread.php?t=73658)

MasterZap 2011-06-01 09:04

Getting the id of currently connected WIFI from Python
 
Hi, I must be blind...

I've found no way to (from python code) know the id of what WIFI network I'm currently connected to. I've found some samples using conic (and dbus) to list the available access points or those in range... but I only want to know which one I'm actually connected to. This seems somewhat elusive, and all my google-fu has failed me :(

Help me, "Obi-Wan-TMO, you're my only hope?" :)

/Z

jstokes 2011-06-01 09:17

Re: Getting the id of currently connected WIFI from Python
 
https://vcs.maemo.org/svn/pymaemo/pa...atic_events.py could be what you're after maybe

MasterZap 2011-06-01 09:28

Re: Getting the id of currently connected WIFI from Python
 
Pretty much - thanks. I found something very similar to this independently (naturally 30 seconds after posting the above question, as always, sigh) but I was missing the "automatic-connection-events" which was key for this to be usable in my case.

However I'm a bit surprised there isn't a more "procedural" way to get this, than this event driven stuff. To me, testing the current state of something is different from waiting for events for changes.

But hey, this seems to work - thanks!

/Z


All times are GMT. The time now is 04:58.

vBulletin® Version 3.8.8