Create an Access Point with a Linux laptop

May find that you have a cable connection but no wifi or because absent or because security policies outside personnel may not access it. But now it is customary to have a handheld or smartphone that once connected to a WiFi network express the best of their performances. How so?

You can turn a laptop into a Linux access point via a simple script:

#Creazione di un access point
wlanconfig ath0 destroy
wlanconfig ath0 create wlandev wifi0 wlanmode ap
iwconfig ath0 essid MIOAP channel 2 key 0123-4567-89
ifconfig ath0 up 192.111.1.1 netmask 255.255.255.0
echo “1″ > /proc/sys/net/ipv4/ip_forward
iptables -t nat -A POSTROUTING -j MASQUERADE
sleep 10
#FINE

Obviously, you can customize the 'essid, channel and password.
Obviously I have not set a dhcp, then you need to configure your handheld ad hoc, so to be allocated directly to the 'ip, dns etc ... etc ...

Posted under EeePC , Technology

This post WAS written by admin on November 26, 2008

Tags: , , , ,

Other Post

15 Comments so far

  1. Lawrence November 26, 2008 12:53 pm

    Hello, I work with an EeePC or Acer Aspire One?

    You could create a bridge between the wifi network and the eth?

    Thanks for the info

  2. admin November 26, 2008 1:03 pm

    I do run the script sull'eeepc but seeing the features of the Acer, I assume there are just problems, the script is a sequence of standard commands :-)
    What does this script is just a machine to create "bridge" where you connect with a PDA via WiFi to your PC and a routing on the Ethernet. An AP stark!

  3. Lawrence November 26, 2008 3:45 pm

    Beautiful! I was just thinking about eeePC Dreambox + + HD + USB connection with mobile phone via USB

    Sorry if I take this opportunity ... that has brought the wifi network as configured on your eeepc?

  4. Lawrence November 26, 2008 3:47 pm

    Also, could you tell me how fast PCs communicate in a wireless network?

    Thanks!

  5. admin November 26, 2008 3:54 pm

    The wifi network has the maximum theoretical speed 54Mbit / s, if the connection is good and you are the only connected ... If you want to access the net there are tons of info.
    eeepc with an iphone and I was connected to a 20 meters ... without anything in between, an open space.

  6. Lawrence November 26, 2008 4:31 pm

    Thanks for the info!

  7. paul November 26, 2008 7:41 pm

    but how do you specify the key (WPA or WEP or other)? thanks

  8. admin November 28, 2008 5:36 pm

    As it has done the script is the wep key ...
    Honestly, I never bothered to use a wpa, at least not for an AP luck ...

  9. matteo January 1, 2009 4:35 pm

    hello i have a probem, I can not start your scrpt, I've probably done something wrong because I said
    wlanconfig: ioctl: No such device
    wlanconfig: ioctl: No such device
    Error for wireless request "Set ESSID" (8B1A):
    September failed on device ath0; No such device.
    ath0: ERROR reading interface flags: No device
    SIOCSIFADDR: No device
    ath0: ERROR reading interface flags: No device
    SIOCSIFNETMASK: No device
    you help me? (I have a eeepc 900 with eeebuntu installed)

  10. admin January 7, 2009 11:59 am

    What should I give you the command iwconfig restiuisce
    Why 'I think you're ussando of different drivers from my ...

  11. Alberto January 15, 2009 9:32 pm

    Hello!
    through the script!
    a question: if I wanted to activate the dhcp so that those who connect to the internet via my PC does not have to set the ip static commands should I add?

    thanks!

  12. admin January 19, 2009 10:35 am

    The operation is not as easy because you should install and configure the DHCP server!
    My script is simply an aid "flying" in cases Cusi need a wifi connection :)
    To what do you want, I suggest a little 'reading on dhcp server :)

  13. Home Loan January 30, 2009 1:46 am

    Lovely. Great site.

  14. hacku September 20, 2009 9:30 pm

    oO unbelievable I found exactly what you want! a script that was running on eeepc with linux to create an access point in order to connect my phone xD
    I was not clear, however, the settings you said ... so now I try the script and let you know

  15. maaaatteo July 23, 2010 9:31 pm

    > I should provide what you restiuisce command iwconfig
    > Why 'I think you're ussando of different drivers from my ...

    that you do not have madwifi, I guess .. : /

Leave a Comment

Name (required)

Email (required)

Website

Comments