The Galileo is a great single board computer. However one thing that makes the board even more attractive is the simple support for WiFi. This blog outlines the steps necessary to get Galileo with WiFi working.
According to post in the Intel forum Galileo will work with the Intel Centrino N135 and N6205. However after reading the great post from Sergy I could not resist the temptation and got a Intel® Centrino® Advanced-N 6235 card from a local computer store. I then also had to get a pair of antennas and the half mPCI card extender.
Here are a few things you need before you start:
- A computer with the Arduino IDE for Galileo installed
- A network router with a DHCP server running
- An Ethernet cable to connect the Galileo board to your network
- An empty SD card or USB thumb drive
As my WiFi card is not supported out of the box I had to add the driver and firmware support. Here are the steps to do this:
(Note: instead of booting from a microSD card, you can also use a USB thumb drive and a USB-to-microUSB OTG-adapter cable). This is not advertised widely, but see Galileo forum post for details
- Head over to Wireless Linux site and download the Linux diver for the Intel Centrino Advanced-N 6235. The file name is iwlwifi-6000g2b-ucode-18.168.6.1.tgz
- Attach your Galileo to your network router with a standard Ethernet cable
- Download the sketch source code below. Modify the MAC address in the sketch to match you Galileo board’s MAC address printed on the label on the Ethernet plug.
#include SPI.h #include Ethernet.h // the media access control (ethernet hardware) address for the Galileo: byte mac[] = { 0x98, 0x4F, 0xEE, 0x00, 0x08, 0x2D}; //the IP address for the Galileo: byte ip[] = { 192, 168, 0, 2 }; void setup() { Serial.begin(9600); Serial.println("Attempting to start Ethernet"); if (Ethernet.begin(mac) == 0) { Serial.println("Failed to configure Ethernet using DHCP"); Serial.println("Attempting to configure Ethernet using Static IP"); Ethernet.begin(mac, ip); } Serial.print("Your IP address: "); Serial.println(Ethernet.localIP()); } void loop () {}
- Compile and upload the sketch.
- Open the Serial Console in the Arduino IDE. You should see a Message that reports the IP address assigned by your DHCP server “Attempting to start Ethernet” “Your IP address: 192.168. 1. 49”
- Do a full format of a microSD Card (no Quickformat)
- Copy all the files from Prepare the microSD Card
- Plug the micro SD card into the SD card slot on the Galileo Board
- Boot your Gallileo board by pushing the REBOOT switch and wait until you see the board dectected by your computers USB port.
- Use SSH (mindterm or scp) to copy the file iwlwifi-6000g2b-6.ucode WiFI firmware to the /lib/firmware/ folder of you Galileo
- Generate the WPA credentials:
%wpa_passphrase NETWORK_NAME << EOF > /etc/wpa_supplicant.conf > YOUR_PASSWORD > EOF
- Start the network with:
%/etc/init.d/networking restart
- Shut down the WiFi with:
%ifdown wlan0
- Start up the WiFi
%ifup wlan0
Using the IP address that the Galileo reported in the Serial Terminal you should be able to telnet into the board. This will give you a Galileo Linux terminal prompt.