madwimax & ap mode

Well, it took me a while to figure out what was wrong and why the heck my atheros laptop wifi won’t go to AP mode.
Looks like the ath5k driver that is in stock ubuntu 10.04 cannot do any AP mode, so you’ll have to grab ath_pci one. However, the snapshots didn’t work at all and I had to compile the svn version.
It looks like regular modbrobe -r ath5k && modprobe ath_pci DOESN’T work: Youll get 0 scan results/devices won;t see the ap created. You have to either blacklist ath5k, OR
modprobe -r ath5k
suspend the laptop
resume the laptop
modprobe ath_pci

Windows fans can do a reboot.
Well, nevertheless, I got it working and finally share a small script that does all the mode-switching between client mode and ap mode.

if [ $WW == "ap" ]; then
ifconfig ath0 down
wlanconfig ath0 destroy
killall knetworkmanager
/etc/init.d/network-manager stop
wlanconfig ath0 create wlandev wifi0 wlanmode ap
#wlanconfig ath0 destroy
#wlanconfig ath0 create wlandev wifi0 wlanmode ap
#wlanconfig ath1 create wlandev wifi0 wlanmode sta nosbeacon
hostapd -B /etc/hostapd/anomalia.conf&
sleep 1
ifconfig ath0
/etc/init.d/dhcp3-server start
exit 0
if [ "$WW" == "sta" ]; then
killall hostapd
ifconfig ath0 down
wlanconfig ath0 destroy
wlanconfig ath0 create wlandev wifi0 wlanmode sta nosbeacon
sleep 1
/etc/init.d/network-manager start
su necromant -c knetworkmanager&
/etc/init.d/dhcp3-server stop
sleep 1
exit 0

./ ap kills the network-manager & knetworkmanager
(Gnome users need to kill nm-applet)
./ sta brings back the sta mode.
Quite quick and dirty – but it does the job

Q&D air conditioner (2.5 hrs to make one!)

It’s damn hot in Russia now. no… Well, it’s HOT AS HELL HERE.
This weekend sitting in my country house with no air conditioner there, I got finally just a bit too sick of it. Besides the heat the smoke from those damned fires is always around. (see photos under the cut)
Freaking smoke!

Anyways, I got tired of my brain throttling 4 out 5 clock cycles due to overheat, I decided it’s time for some hacking =). So I loaded some water into the fridge and while it was slowly turning to ice…

The setup is simple. I got two buckets. The smaller one I used as the water tank. I later added ice to the water. the bigger – as the main chamber. The pump (some old junk I found lying around) pumps the water up, and inside the big bucket it is sprinkled into small particles. I cooler fan I ripped of an old PC power supply pushes the air through this watery chamber. The resulting air is cool, and the smell of smoke&ash is finally gone. It took this baby about 10 minutes to clean the air in my room so that my brain began to function normally. Besides it cooled the air from 34 (Celsius) to about 30, till I ran out of ice.
I guess, that if this heat goes on I will have to make something more powerful. It’s far better, than sitting in the basement all day… And more fun than buying a ready to use solution.
Here goes the video of the rig.

P.S. This is not the worst case of smoke you might see here. Back in the city it is a real ‘gasenvagen’ and even a real air conditioner doesn’t help.