Does wifi have sleep mode?

@DBMandrake, yeah i measured it when it wasnt connected. I thought Sam meant that the supply was problematic and didnt give enough juice in general. Yeah i know about the TP1/TP2, i thought about measuring the gpio pin but didnt want to risk it in the end.

@sam_nazarko, unfortunately i just lost my remote connection again, and i cant try the command…I’ll give it a try tomorrow morning…And yeah its a pi2.
-Thanks guys.

so far so good…its working fine. I upgraded my router firmware as well…(doubt thats the reason why its working fine now).
Should i measure the voltage on the 5v pin ?
Also something that i noticed when i rebooted the pi…was this:

Sep 03 15:10:33 osmc systemd[1]: Failed to start /etc/rc.local Compatibility.
Sep 03 15:10:33 osmc systemd[1]: Unit rc-local.service entered failed state.

here is the latest log with that message: http://paste.osmc.io/puzixaveme

and my rc.local file:

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
echo 0 | sudo tee /sys/devices/system/cpu*/cpufreq/ondemand/io_is_busy
sleep 20
iwconfig wlan0 power off

exit 0

Edit: I tried it again without the switch, and the problem is back…so this thing definitely fixes it. What does it do exactly ? I followed the code in github but didnt get it. Is is safe to just have it on ?

I measured the voltage on the pins, while the pi was on and i got 5.12volts. I even tried putting the wifi stick on an external usb3 hub (powered by its own power supply) and still the same thing.
This is software related…