Solved [bash/python] know if wifi is connected
-
Is there anyway to know if wifi is connected?
I need to run a script once wifi is connected for the first time, doing it on the startup it seems that it doesn't work because wifi is not connected yet -
@minze better detect that there a connection at all no ? all people don't use wifi ?
you'll have to use a custom script launched after the emulationstation script I suppose, look into/etc/init.d
-
What I wanted to test was if it was connection it didn't matter if it was through wifi or ethernet, I have found an script that I will post here if it works.
-
@minze just ping your gateway, or check if ifconfig returns anything other than loopback