arduino YÚN uses WI-FI + linux
image © arduino
YÚN is the first member of a new groundbreaking line of Wi-Fi products that combines the power linux with ease of use of arduino. the ‘YÚN is similar to the arduino ‘leonardo’ (based on the ATmega32u4 processor) with a wifi system-on-a-chip running linino (a MIPS GNU/linux based on OpenWRT). a linux machine is embedded directly onto the PCB of the leonardo, and connected together so arduino can easily run commands on the linux side and use it as an ethernet and wifi interface. historically, interfacing arduino with complex web services has been quite a challenge due to the limited memory available. web services tend to use verbose text based formats like XML that require quite a lot or ram to parse. on the arduino YÚN, a ‘bridge library’ delegates all network connections and processing of HTTP transactions to the linux machine.
designboom recently traveled to turin, italy, to see arduino’s first officina, before setting off north to visit the italian factories that continue to be the heart of arduino manufacturing for the entire world. to see the full coverage, see here.
the all new arduino ‘ YÚN’
image © designboom
the YÚN has two separate network interfaces, a 10/100 mbit/s fast ethernet port and a IEEE 802.11 b/g/n standard compliant 2.4ghz Wi-Fi interface, supporting WEP, WPA and WPA2 encryption. the Wi-Fi interface can also operate as an access point (AP). in AP mode any WIFI enabled device can connect directly to the network created on the YÚN. while a YÚN in this mode can’t connect to the internet, it could act as a hub for a group of Wi-Fi enabled sensors. historically, interfacing arduino with web services has been challenging due to memory restrictions. the YÚN’s linux environment simplifies the means to access internet services by using many if the same tools you would use on your computer. you can run several applications as complex as you need, without stressing the ATmega microcontroller. to help develop applications that can connect to popular web services, arduino has partnered with temboo, a service that simplifies accessing hundreds of the web’s most popular APis. a temboo library comes with the YÚN, making it easy to connect to a large variety of online tools.
testing out the arduino YÚN at the manufacturing plant in turin, italy
connection between the two processors:
the yún’s bridge library enables communication between the two processors, connecting the hardware serial port of the AR9331 to serial1 on the 32U4 (digital pins 0 & 1). another post will describe the library in greater depth. the serial port of the AR9331 exposes the linux console (aka, the command line interface, or CLI) for communication with the 32U4. the console is a means for the linux kernel and other processes to output messages to the user and receive input from the user. file and system management tools are installed by default. it’s also possible to install and run your own applications using bridge. the ATmega32U4 can be programmed from the AR9331 by uploading a sketch through the YÚN’s Wi-Fi interface. when connected to the same Wi-Fi network as your computer, the board will appear under the ‘port’ menu of the arduino IDE. the sketch will be transferred to the AR9331, and the linux distribution will program the ATmega32U4 through the SPI bus, emulating an AVR ISP programmer.
arduino YÚN intro
video courtesy arduino
the YÚN can be powered through the micro-usb connector, the vin pin, or the optional power over ethernet (POE) module. when powering the board though the vin pin, you must supply a regulated 5VDC. there is no on-board voltage regulator for higher voltages.
playing with the new arduino YÚN at the headquarters in turin, italy
video © designboom
linux OS specifications:
the YÚN runs a version of the OpenWRT linux distribution called ‘linino’. the on-board 16mb flash memory that contains the linux image has a full python installation and package manager you can use to install additional software. the AR9331 has 64 mb of DDR2 ram available, providing the resources to perform complex tasks like running a web server or streaming video from a webcam. you can expand the storage memory by adding a micro-SD card or a USB pen drive. by including a directory named ‘arduino’ at the root level of the storage device, it will be automatically recognized by the YÚN.
the arduino YÚN’s getting a final check before being shipped
the YÚN has a USB host port connected to the AR9331. you can connect USB peripherals like webcams, memory sticks, or joypads to this input. generally, linux has drivers included for the more common devices like mass storage or mice and keyboards. for more specific devices like webcams, you will need to refer to the device specifications to find the appropriate driver. as the USB port is connected to the linux processor, it’s not directly accessible from sketches on the 32U4.
the last step in the production process
operating voltage: 5v
input voltage: 5v via microUSB or PoE 802.3af
digital I/O pins: 14
PWM channels: 7
analog input channels: 6 (plus 6 multiplexed on 6 digital pins)
DC current per i/o pin: 40 mA
DC current for 3.3v pin: 50 mA
flash memory: 32 KB (ATmega32u4) of which 4 KB used by bootloader
SRAM: 2.5 KB (ATmega32u4)
EEPROM: 1 KB (ATmega32u4)
clock speed: 16 mhz
processor: MIPS 24k operating at up to 400 mhz
memory: DDR2 64mb ram and 16 mb spi flash
AP or router: complete IEEE 802.11bgn 1×1
host/device: USB 2.0
microSD: poe compatible 802.3af card support