Difference between revisions of "Iduino Yun Shield"
(→General setting) |
(→How to upload, download or edit the files in Iduino_Yun_Shield?) |
||
(21 intermediate revisions by the same user not shown) | |||
Line 18: | Line 18: | ||
==Overview and Hard ware Resources== | ==Overview and Hard ware Resources== | ||
− | + | ||
− | + | [[File:Front iamge.png|500px]] | |
− | + | [[File:Back image.png|500px]] | |
− | + | ||
#Processor: 400MHz, 24 MIPS | #Processor: 400MHz, 24 MIPS | ||
Line 33: | Line 33: | ||
#1×Reset button | #1×Reset button | ||
#Compatible with 3.3V or 5V I/O Arduino | #Compatible with 3.3V or 5V I/O Arduino | ||
− | + | #Size: 70mm * 53mm*24mm | |
− | + | #Weight: 33.2g | |
− | |||
− | |||
==Software Resource== | ==Software Resource== | ||
Line 56: | Line 54: | ||
=Interfaces= | =Interfaces= | ||
==Interface layout== | ==Interface layout== | ||
− | + | [[File:Interface layout.png]] | |
− | + | [[File:Wireframe.png|500px]] | |
− | |||
− | |||
− | |||
==Interface specifications== | ==Interface specifications== | ||
Line 97: | Line 92: | ||
Use browser (recommend Firefox or Chrome) to set Iduino_Yun_Shield, and you will see login page after entering 192.168.240.1. | Use browser (recommend Firefox or Chrome) to set Iduino_Yun_Shield, and you will see login page after entering 192.168.240.1. | ||
− | [[File:Webpage access.png| | + | [[File:Webpage access.png|500px|webpage access]] |
Default password for Iduino_Yun_Shield is ‘iduino’. | Default password for Iduino_Yun_Shield is ‘iduino’. | ||
Line 103: | Line 98: | ||
===SSH Access=== | ===SSH Access=== | ||
By SSH Access, users can enter Linux system directory and customize more functions as well as applications. | By SSH Access, users can enter Linux system directory and customize more functions as well as applications. | ||
+ | |||
[[File:SSH access.png|SSH access]] | [[File:SSH access.png|SSH access]] | ||
Line 115: | Line 111: | ||
===General setting=== | ===General setting=== | ||
After login, the GUI will show the WIFI/ETH status. | After login, the GUI will show the WIFI/ETH status. | ||
+ | |||
[[File:General setting1.png|400px|]] | [[File:General setting1.png|400px|]] | ||
Click the SYSTEM button, and you can set the device password and parameter. | Click the SYSTEM button, and you can set the device password and parameter. | ||
+ | |||
[[File:General setting2.png|400px|]] | [[File:General setting2.png|400px|]] | ||
===Settings of Iduino=== | ===Settings of Iduino=== | ||
Click SENSORS button and enter the settings relate to Iduino | Click SENSORS button and enter the settings relate to Iduino | ||
− | [[File:Settings of iduino.png| | + | |
+ | [[File:Settings of iduino.png|600px|]] | ||
Arduino board Type: Define the setting of bootloader/mcu type/fuse during Sketch uploading | Arduino board Type: Define the setting of bootloader/mcu type/fuse during Sketch uploading | ||
Line 130: | Line 129: | ||
===Upgrade=== | ===Upgrade=== | ||
You can repair bug, upgrade system, and add new function by upgrading Iduino_Yun_Shield firmware through GUI. Turn to page of GUI→Upgrade and choose correct firmware. The firmware used for webpage upgrade should be Sysupgrade Type, and you can decide to save setting or not after upgrade. | You can repair bug, upgrade system, and add new function by upgrading Iduino_Yun_Shield firmware through GUI. Turn to page of GUI→Upgrade and choose correct firmware. The firmware used for webpage upgrade should be Sysupgrade Type, and you can decide to save setting or not after upgrade. | ||
− | |||
− | [[File:Upgrade2.png| | + | [[File:Upgrade1.png|600px|upgrade]] |
+ | |||
+ | [[File:Upgrade2.png|600px|upgrade]] | ||
Usually, it takes 2 minutes to upgrade firmware. The Iduino_Yun_Shield will restart automatically and all the LEDs will blink together. | Usually, it takes 2 minutes to upgrade firmware. The Iduino_Yun_Shield will restart automatically and all the LEDs will blink together. | ||
Line 148: | Line 148: | ||
===Connect to Leonardo=== | ===Connect to Leonardo=== | ||
As is shown in the follow figure, simply plug the Iduino_Yun_Shield on the top of Leonardo, and power the Leonardo via DC jack | As is shown in the follow figure, simply plug the Iduino_Yun_Shield on the top of Leonardo, and power the Leonardo via DC jack | ||
− | [[File:Connect_to_leonardo.png]] | + | |
+ | [[File:Connect_to_leonardo.png|500px]] | ||
In Arduino IDE, the board type selected should be Arduino Yun. | In Arduino IDE, the board type selected should be Arduino Yun. | ||
Line 155: | Line 156: | ||
1) In Uno, the UART connection between mega328P and mega16u2 will influence the Bridge feature with Iduino_Yun_Shield. So we have to disconnect it by setting the mege16u2 into reset mode, as below: | 1) In Uno, the UART connection between mega328P and mega16u2 will influence the Bridge feature with Iduino_Yun_Shield. So we have to disconnect it by setting the mege16u2 into reset mode, as below: | ||
− | [[File:Connect to arduino uno.png| | + | [[File:Connect to arduino uno.png|500px|connect to arduino uno]] |
Note: USB upgrade/debug won’t work after this change. User must upgrade/debug via Arduino IDE via Wifi. | Note: USB upgrade/debug won’t work after this change. User must upgrade/debug via Arduino IDE via Wifi. | ||
Line 190: | Line 191: | ||
===Connect to Arduino Duemilanove/Diecimila=== | ===Connect to Arduino Duemilanove/Diecimila=== | ||
1) The mega avr interface on the Duemilanove/Diecimila is connected to the FTDI chip, and we must disconnect them as the below figure: | 1) The mega avr interface on the Duemilanove/Diecimila is connected to the FTDI chip, and we must disconnect them as the below figure: | ||
+ | |||
[[File:Connect to ADorD.png|400px|connect to Arduino Duemilanove/Diecimila]] | [[File:Connect to ADorD.png|400px|connect to Arduino Duemilanove/Diecimila]] | ||
Line 245: | Line 247: | ||
4) Compile and upload sketch to Arduino board. During uploading, the Iduino_Yun_Shield will ask you to input the password, which is “iduino” by default. | 4) Compile and upload sketch to Arduino board. During uploading, the Iduino_Yun_Shield will ask you to input the password, which is “iduino” by default. | ||
− | [[File: | + | [[File:Iduino Yun Shield-Update Sketch.png|500px|upload sketch]] |
=Example= | =Example= | ||
Line 283: | Line 285: | ||
'''Test Interface:''' | '''Test Interface:''' | ||
− | [[File:Test interface.jpg|test interface]] | + | [[File:Test interface.jpg|500px|test interface]] |
=FAQ= | =FAQ= | ||
Line 334: | Line 336: | ||
::Protocol: SCP | ::Protocol: SCP | ||
− | [[File:How6.6 1.jpg]] | + | [[File:How6.6 1.jpg|500px]] |
There will be 2 warnings during login and just ignore it. After login, a management panel will appear. | There will be 2 warnings during login and just ignore it. After login, a management panel will appear. | ||
Line 340: | Line 342: | ||
The left part of this panel is your PC’s directories and the right part is the directories of Iduino_Yun_Shield. You can upload/download files by dragging, or double click the file to edit its content. | The left part of this panel is your PC’s directories and the right part is the directories of Iduino_Yun_Shield. You can upload/download files by dragging, or double click the file to edit its content. | ||
− | [[File:How6.6 2.jpg]] | + | [[File:How6.6 2.jpg|500px]] |
==How to reset Iduino_Yun_Shield?== | ==How to reset Iduino_Yun_Shield?== | ||
Line 350: | Line 352: | ||
There are some cases that the Iduino_Yun_Shield fails to boot. For example, upgrade an improper firmware or lost power during upgrade. But you are still able to recover the Iduino_Yun_Shield by using the U-boot of Iduino_Yun_Shield. An instruction in Windows is shown as below: | There are some cases that the Iduino_Yun_Shield fails to boot. For example, upgrade an improper firmware or lost power during upgrade. But you are still able to recover the Iduino_Yun_Shield by using the U-boot of Iduino_Yun_Shield. An instruction in Windows is shown as below: | ||
− | '''Set | + | '''1.Turn of Windows firewall'''<br> |
+ | [[File:YUN图片1.png]] | ||
+ | |||
+ | '''2.Set IP address as "192.168.255.2", Subnet mask: 255.255.255.0'''<br> | ||
+ | [[File:YUN图片2.png]] | ||
+ | |||
+ | '''3. You need firmwares called "kernel" and "root-squash", put the firmwares and "tftpd32.exe" in same folder.'''<br> | ||
+ | [[File:YUN图片3.png]] | ||
+ | |||
+ | '''4.Connect Iduino Yun Shield to computer via cable. Power Iduino Yun Shield with 9V of DC.'''<br> | ||
+ | '''5.Set TPFP service:''' | ||
+ | :(1)Open "tftpd32.exe", Choose "192.168.255.2" in "Service interfaces".<br> | ||
+ | [[File:YUN图片4.png]] | ||
+ | |||
+ | :(2)Host: 192.168.255.2 | ||
+ | :: Port:6666<br> | ||
+ | [[File:YUN图片5.png]] | ||
+ | |||
+ | :(3)Choose file "kernel" in "Local File".<br> | ||
+ | [[File:YUN图片6.png]]<br> | ||
+ | [[File:YUN图片7.png]] | ||
− | + | '''6.Open "hercules_3-2-8.exe", set the following parameters in UDP board:'''<br> | |
+ | :Module IP: 192.168.255.1<br> | ||
+ | :Port: 6666<br> | ||
+ | :Local Port: 6666<br> | ||
+ | Click "Listen":<br> | ||
+ | [[File:YUN图片8.png]] | ||
− | ''' | + | '''7.Back to tftpd32, click "Put":'''<br> |
+ | [[File:YUN图片9.png]] | ||
− | + | '''8.After clicking "Put", you can see "kernel" displayed in "Received data" on Hercule.'''<br> | |
+ | [[File:YUN图片10.png]] | ||
− | + | '''9.Access "Failsafe" mode: Disconnect the power supply for Iduino Yun Shield, keep pressing button "Failsafe". Then power Iduino Yun Shield again, you will see the LEDs of LAN,WLAN and SYS blinking at the same time. When these LEDs stop blinking, release "Failsafe".''' | |
− | : | ||
− | |||
− | |||
− | |||
− | ''' | + | '''10.Send <font color="red">printenv<CR></font> command on Hercules. "Received data" will display some information from Iduino Yun Shield as follow, if not, re-send <font color="red">printenv<CR></font>'''<br> |
+ | [[File:YUN图片11.png]] | ||
− | + | '''11.Send the following commands in order, to upgrade kernel:''' | |
+ | tftpboot 0x81000000 dragino2-yun-geeetech-v2.0.2-kernel.bin<CR> | ||
+ | [[File:YUN图片12.png]] | ||
− | + | erase 0x9fea0000 +0x140000<CR> | |
+ | [[File:YUN图片13.png]] | ||
− | + | cp.b 0x81000000 0x9fea0000 $$filesize<CR> | |
+ | [[File:YUN图片14.png]] | ||
− | + | '''12.Disconnect the power supply for Iduino Yun Shield, and back to tftpd32, click "Break":'''<br> | |
+ | [[File:YUN图片15.png]] | ||
− | + | '''13.Change "Local File"'''<br> | |
+ | [[File:YUN图片16.png]] | ||
− | + | '''14.Choose <font color="blue">root-squashfs</font> file'''<br> | |
+ | [[File:YUN图片17.png]] | ||
− | ''' | + | '''15.Click "Put" to send file to Hercules.'''<br> |
+ | [[File:YUN图片18.png]]<br> | ||
+ | [[File:YUN图片19.png]] | ||
− | + | '''16. Keep pressing "Failsafe" button on Iduino Yun Shield, power Iduino Yun Shield again, you will see LEDs of LAN,WLAN and SYS blinking at the same time. When they stop blinking, release "Failsafe" button. Iduino Yun Shield is in Failsafe mode now. | |
+ | ''' | ||
− | + | '''17.Send <font color="red">printenv<CR></font> command on Hercules. "Received data" will display some information from Iduino Yun Shield as follow, if not, re-send <font color="red">printenv<CR></font>'''<br> | |
+ | [[File:YUN图片11.png]] | ||
− | + | '''18.Send the following commands to upgrade rootfs:'''<br> | |
+ | tftpboot 0x81000000 dragino2-yun-geeetech-v2.0.2-rootfs-squashfs.bin<CR> | ||
+ | [[File:YUN图片21.png]] | ||
− | + | erase 0x9f050000 +0xe50000<CR> | |
+ | [[File:YUN图片22.png]] | ||
− | + | cp.b 0x81000000 0x9f050000 $$filesize<CR> | |
+ | [[File:YUN图片23.png]] | ||
+ | |||
+ | 19.Send the following command to reset Iduino Yun Shield. | ||
+ | reset<CR> | ||
+ | [[File:YUN图片24.png]] | ||
+ | |||
+ | <font color="red">Relevant file:</font><br> | ||
+ | http://www.geeetech.com/wiki/images/4/41/How_to_recover_Iduino_Yun_Shield.rar | ||
− | |||
− | |||
− | |||
− | |||
:Warning: User should use correct address in the erase and cp.b. Wrong address may destroy the boot-loader of Iduino_Yun_Shield and the device won’t boot anymore, or destroy the radio data leading to a poor Wifi performance or incorrect MAC address. | :Warning: User should use correct address in the erase and cp.b. Wrong address may destroy the boot-loader of Iduino_Yun_Shield and the device won’t boot anymore, or destroy the radio data leading to a poor Wifi performance or incorrect MAC address. | ||
Recover in Linux is similar with Windows. The different is that the tool used in Linux is nc, namely nc-kul6666. The figure below shows that the Iduino_Yun_Shield has been in Failsafe mode and detected by nc. | Recover in Linux is similar with Windows. The different is that the tool used in Linux is nc, namely nc-kul6666. The figure below shows that the Iduino_Yun_Shield has been in Failsafe mode and detected by nc. | ||
− | [[File:Reset firmware.png|reset firmware] | + | [[File:Reset firmware.png|reset firmware] |
− | |||
− | |||
== How to get it == | == How to get it == | ||
Click here to buy: [http://www.geeetech.com/iduino-yun-shield-p-914.html iduino Yun Shield] | Click here to buy: [http://www.geeetech.com/iduino-yun-shield-p-914.html iduino Yun Shield] |
Latest revision as of 09:54, 8 July 2016
Contents
- 1 Introduction
- 2 Interfaces
- 3 How to set up Iduino_Yun_Shield
- 4 Use with Arduino Board
- 5 Example
- 6 FAQ
- 6.1 The advantages of Iduino_Yun_Shield compared to official Arduino Yun
- 6.2 Is Iduino_Yun_Shield compatible with different Arduino boards?
- 6.3 How to set up /www/sd and mnt/sd?
- 6.4 What if Arduino IDE doesn’t detect Iduino_Yun_Shield?
- 6.5 Where can you find the source code of the Iduino_Yun_Shield?
- 6.6 How to upload, download or edit the files in Iduino_Yun_Shield?
- 6.7 How to reset Iduino_Yun_Shield?
- 6.8 How to recover the Iduino_Yun_Shield in case firmware crash?
- 6.9 How to get it
Introduction
Iduino_Yun_Shield, an extremely powerful development for Arduino board, is designed to solve the problems of connection and storage which exist in the Arduino board. Iduino_Yun_Shield runs Open Source OpenWrt System (Same system as runs in Arduino Yun) and it is fully compatible with Arduino IDE V1.5.4 or later versions. Yun Shield is an ideal choice for Arduino Projects which require various internet connections and more storage.
Actually, Iduino_Yun_Shield is equal to the official Arduino Yun, but Iduino_Yun_Shield is more flexible because it can work with other Arduino board such as Uno, Duemilanove, and Mega etc. Iduino_Yun_Shield uses external antenna which provides stable connection under various environments.
The Iduino Yun is the core module of Iduino_Yun_Shield. And it requires 200mA current when in full load, so it is powered by the Arduino VIN pins to avoid overheated in the Arduino onboard 5V LD0.
Features
- Open source Linux system (OpenWrt) inside
- Low power consumption
- Compatible with Arduino IDE 1.5.4 or later versions. Users can program, debug or upload Sketch to Arduino board
- Managed by Web GUI, SSH via LAN or Wifi
- Software upgradable via network
- Support internet connection via LAN port, Wifi or 3G dongle
- Support USB flash to provide storage for Arduino projects
- Reliable design provides robust system
- Compatible with Arduino Leonardo, Uno, Duemilanove, Diecimila and Mega
Overview and Hard ware Resources
- Processor: 400MHz, 24 MIPS
- Flash: 16MB
- RAM: 64MB
- Power input: 4.75V~23V via Arduino Vin pin
- 1×10M/100M RJ45
- Connector 150M Wifi 802.11 b/g/n
- External antenna via I-Pex
- 1×USB port for USB storage or 3G connection
- 1×Reset button
- Compatible with 3.3V or 5V I/O Arduino
- Size: 70mm * 53mm*24mm
- Weight: 33.2g
Software Resource
Compiling environment: Arduino IDE 1.5.4 or later version
Source
The Open Source hardware of Iduino_Yun_Shield: https://github.com/dragino/modules/tree/master/hardware/YunShield
The Open Source code of Iduino_Yun_Shield: https://github.com/dragino/linino
The official webpage of Arduino Yun Bridge: http://arduino.cc/en/Reference/YunBridgeLibrary
The official forum of Arduino Yun http://forum.arduino.cc/index.php?board=93.0
Interfaces
Interface layout
Interface specifications
- RJ45, Wifi, USB port and Failsafe are connected to the Iduino Yun module directly, and the Iduino Yun module uses SPI and UART to communicate with Arduino board
- The SPI interface is used to upload the sketch coming from the Arduino IDE. SPI interface connects to Iduino Yun only in the upload time, so the Arduino SPI can still be used to connect to the other slave devices.
- The pins of two sides are respectively connected to the corresponding pins of Arduino
How to set up Iduino_Yun_Shield
Getting IP address
There is a Wifi interface a LAN port on the Iduino_Yun_Shield. And they both have an IP address for network connecting and device management.
Factory IP of Wifi port
At the first boot of Iduino_Yun_Shield, an unsecure Wifi network called Iduino-xxxxxx will automatically generate. Users can use their laptop to connect to this Wifi network and the laptop will get an IP 192.168.240.xxx. The default IP of Iduino_Yun_Shield is 192.168.240.1.
FallBack IP
The LAN port of Iduino_Yun_Shield distributes a Fall Back IP
- 172.31.255.254/255.255.255.252
If the user’s laptop IP is
- 172.31.255.253/255.255.255.252
Then you can access Yun Shield by Fall Back IP.
Detect IP from Arduino IDE
If the Ethernet port of Iduino_Yun_Shield is connected to Uplink Router or Wifi Router, the PC in the same network can use Arduino IDE to detect the IP of Iduino_Yun_Shield.
Allocation pattern
The Iduino_Yun_Shield runs Open Source Linux System. If you have a PC which is in the same network with Iduino_Yun_Shield, you can access its system by Web or Secure Shell (SSH).
Webpage access
Use browser (recommend Firefox or Chrome) to set Iduino_Yun_Shield, and you will see login page after entering 192.168.240.1.
Default password for Iduino_Yun_Shield is ‘iduino’.
SSH Access
By SSH Access, users can enter Linux system directory and customize more functions as well as applications.
SSH Access:
- IP address: IP address of Iduino_Yun_Shield
- Port: 22
- User Name: root
- Password: iduino (default)
Webpage Setting
General setting
After login, the GUI will show the WIFI/ETH status.
Click the SYSTEM button, and you can set the device password and parameter.
Settings of Iduino
Click SENSORS button and enter the settings relate to Iduino
Arduino board Type: Define the setting of bootloader/mcu type/fuse during Sketch uploading
Operation Mode: Make sure the mode is Arduino Bridge mode so that the Bridge class can work
Upgrade
You can repair bug, upgrade system, and add new function by upgrading Iduino_Yun_Shield firmware through GUI. Turn to page of GUI→Upgrade and choose correct firmware. The firmware used for webpage upgrade should be Sysupgrade Type, and you can decide to save setting or not after upgrade.
Usually, it takes 2 minutes to upgrade firmware. The Iduino_Yun_Shield will restart automatically and all the LEDs will blink together.
Use with Arduino Board
The Iduino_Yun_Shield uses SPI for uploading sketch and uses UART port for Bridge class to talk to the AVR. While connecting Iduino_Yun_Shield to Arduino board, below points should be checked:
- Whether the Arduino board is powered by DC jack;
- If the board type setting is correct in the Iduino_Yun_Shield;
- If the board type setting is correct in the Arduino IDE;
- Whether the Arduino SPI and UART is not influenced by other hardware
- Make sure the UART mode is in Arduino Bridge.
Connect to Arduino Board
Connect to Leonardo
As is shown in the follow figure, simply plug the Iduino_Yun_Shield on the top of Leonardo, and power the Leonardo via DC jack
In Arduino IDE, the board type selected should be Arduino Yun.
Connect to Arduino Uno
1) In Uno, the UART connection between mega328P and mega16u2 will influence the Bridge feature with Iduino_Yun_Shield. So we have to disconnect it by setting the mege16u2 into reset mode, as below:
Note: USB upgrade/debug won’t work after this change. User must upgrade/debug via Arduino IDE via Wifi.
2) Add board type in the file: Arduino\hardware\arduino\avr\board.txt, as below, and reopen the Arduino IDE:
unoyun.name=Arduino Uno --Iduino Yún unoyun.upload.via_ssh=true unoyun.vid.0=0x2341 unoyun.pid.0=0x0043 unoyun.vid.1=0x2341 unoyun.pid.1=0x0001 unoyun.upload.tool=avrdude unoyun.upload.protocol=arduino unoyun.upload.maximum_size=32256 unoyun.upload.maximum_data_size=2048 unoyun.upload.speed=57600 unoyun.upload.disable_flushing=true unoyun.upload.use_1200bps_touch=true unoyun.upload.wait_for_upload_port=true unoyun.bootloader.tool=avrdude unoyun.bootloader.low_fuses=0xff unoyun.bootloader.high_fuses=0xde unoyun.bootloader.extended_fuses=0x05 unoyun.bootloader.file=optiboot/optiboot_atmega328.hex unoyun.bootloader.unlock_bits=0x3F unoyun.bootloader.lock_bits=0x0F unoyun.build.mcu=atmega328p unoyun.build.f_cpu=16000000L unoyun.build.board=AVR_YUN unoyun.build.core=arduino unoyun.build.variant=standard
Connect to Arduino Duemilanove/Diecimila
1) The mega avr interface on the Duemilanove/Diecimila is connected to the FTDI chip, and we must disconnect them as the below figure:
2) Add a “Duemilanove” board type in the file: Arduino\hardware\arduino\avr\board.txt. User can use the Uno Yun board type if there is mega328P. For mega328/mega168/mega168P, they can modify the upload.maximum_data/upload.maximum_size and build.mcu accordingly.
3) Plug the Iduino_Yun_Shield on the Duemilanove and power it via DC jack.
Connect to Arduino Mega2560
1) In Mega2560, the UART between mega2560 and mega16u2 will influence the Bridge feature with Iduino_Yun_Shield. So we have to disconnect it by setting mega16u2 into reset mode, as below figure:
2) Add a “Mega2560 Yun” board type in the file: Arduino\hardware\arduino\avr\board.txt, as below, and reopen the Arduino IDE:
mega2560Yun.name=Arduino Mega 2560 -- Iduino Yún mega2560Yun.upload.via_ssh=true mega2560Yun.vid.0=0x2341 mega2560Yun.pid.0=0x0044 mega2560Yun.vid.1=0x2341 mega2560Yun.pid.1=0x003f mega2560Yun.upload.tool=avrdude mega2560Yun.upload.protocol=arduino mega2560Yun.upload.maximum_size=258048 mega2560Yun.upload.maximum_data_size=8192 mega2560Yun.upload.speed=57600 mega2560Yun.upload.disable_flushing=true mega2560Yun.upload.use_1200bps_touch=true mega2560Yun.upload.wait_for_upload_port=true mega2560Yun.bootloader.tool=avrdude mega2560Yun.bootloader.low_fuses=0xff mega2560Yun.bootloader.high_fuses=0xd8 mega2560Yun.bootloader.extended_fuses=0xfd mega2560Yun.bootloader.file=stk500v2/stk500boot_v2_mega2560.hex mega2560Yun.bootloader.unlock_bits=0x3F mega2560Yun.bootloader.lock_bits=0x0F mega2560Yun.build.mcu=atmega2560 mega2560Yun.build.f_cpu=16000000L mega2560Yun.build.board=AVR_MEGA2560 mega2560Yun.build.core=arduino mega2560Yun.build.variant=mega
3) Plug the Iduino_Yun_Shield on the Mega2560 and power it via DC jack.
Detect Iduino_Yun_Shield
Make sure your laptop and Iduino_Yun_Shield are in the same network. The Iduino_Yun_Shield will broadcast data in this network and Arduino IDE will show Iduino_Yun_Shield in Tools>Port after receiving this data.
Upload Sketch
1) In the Arduino IDE, choose correct board type for AVR module.
2) In the Arduino IDE, choose correct port (may be the address of Arduino Yun).
3) In the Iduino_Yun_Shield GUI>Sensor page, choose correct board type for uploading.
4) Compile and upload sketch to Arduino board. During uploading, the Iduino_Yun_Shield will ask you to input the password, which is “iduino” by default.
Example
Say hello to Linux
Introduction: This example is a Hello test between Arduino and Iduino_Yun_Shield, which can be found at Arduino IDE--> File --> Examples --> Bridge --> ConsoleRead. The course of this example can be checked at http://arduino.cc/en/Tutorial/ConsoleRead. The code and notes will be shown as below:
Code:
#include <Console.h>//use Console class for Arduino IDE debug over Wifi, similarto Serial class, String name; voidsetup() { // Initialize Console and wait for port to open: Bridge.begin(); Console.begin(); // Wait for Console port to connect while (!Console); Console.println("Hi, what's your name?");//Data flow: Arduino --> Yun Shield --> Arduino IDE } void loop() { if (Console.available() > 0) { char c = Console.read(); //read the next char received, data flow: IDE --> Yun Shield--> Arduino // look for the newline character, this is the last character in the string if (c == '\n') { //print text with the name received Console.print("Hi "); Console.print(name); Console.println("! Nice to meet you!"); Console.println(); // Ask again for name and clear the old name Console.println("Hi, what's your name?"); name = ""; // clear the name string } Else { // if the buffer is empty Cosole.read() returns -1 name += c; // append the read char from Console to the name string } } }
Test Interface:
FAQ
The advantages of Iduino_Yun_Shield compared to official Arduino Yun
In Hardware Aspect
Both Arduino Yun and Iduino_Yun_Shield have the same CPU, Memory size, and RAM size for the Linux system. The Arduino Yun is an integrated of Linux part and MCU part. Iduino_Yun_Shield is designed as a shield which can be used with existing Arduino boards.
Basically, Iduino_Yun_Shield + Arduino Leonardo equal to an Arduino Yun, but Iduino_Yun_Shield is more flexible because it can be used with other Arduino boards such as Arduino Uno, Duemilanove, and Diecimila etc.
Iduino_Yun_Shield is replicable and reproducible: The design of Iduino_Yun_Shield is open and the most complicated and difficult parts are in the Dragino HE module. User can purchase the Dragino HE module separately to customize their projects and release variant Yun Solution.
Stable and flexible Wifi performance: Arduino Yun uses chip-like antenna design. If there is a shield on the top of Arduino Yun, the Wifi will be greatly shielded and lead to a poor Wifi performance. Instead, Iduino_Yun_Shield uses external antenna design. User can connect different type of antennas to the I-pex connector of Iduino_Yun_Shield and that makes the installation more flexible and the signal can transferred several kilometers.
In Software Aspect
Iduino_Yun_Shield has repaired some bugs and adds more functions as well as supports more board types.
Is Iduino_Yun_Shield compatible with different Arduino boards?
If the Arduino board is different from the supported boards, you can check the following list to check the compatibility:
1.The voltage of Vin pin to power the Iduino_Yun_Shield is 7~15V;
2.The variant has same definition and position of SPI in the ICSP header as the official board;
3.The variant has same definition and position of D0 and D1 pins as the official board
4.Check whether there are ICs connected to the AVR and the UART of SPI, and evaluate if they will influence the communication between Yun Shield and AVR.
The system structure section of Iduino_Yun_Shield well explains the working principle of it. If you are still not sure if Iduino_Yun_Shield is compatible with their boards or having trouble in the compatibility, then you can send the board info to support@dragino.com, and our team will review and check it.
How to set up /www/sd and mnt/sd?
The way to use /www/sd and /mnt/sd is as the same as Arduino Yun. User can prepare a USB flash and create directory /arduino and /arduino/www at the root of USB flash. Then input the USB flash into the Iduino_Yun_Shield and it will automatically create directory /www/sd and /mnt/sd, which link to /arduino and /arduino/www.
What if Arduino IDE doesn’t detect Iduino_Yun_Shield?
You can check the below issues:
- Whether the Arduino version is 1.5.4 or later;
- Whether you PC is in the same network with the Iduino_Yun_Shield;
- If the Iduino_Yun_Shield boots in advance than Arduino IDE, this situation may happen. So try to reboot the Iduino_Yun_Shield and check again.
Where can you find the source code of the Iduino_Yun_Shield?
The source code can be found at https://github.com/dragino/linino
How to upload, download or edit the files in Iduino_Yun_Shield?
Iduino_Yun_Shield has a built-in Linux system and supports SCP protocol. You can download or edit the Linux files using SCP tools. In Windows OS, the SCP tool is winscp. Install it and log into SCP as below:
- Host name: The IP address of Iduino_Yun_Shield
- User name: root
- Password: iduino (default)
- Protocol: SCP
There will be 2 warnings during login and just ignore it. After login, a management panel will appear.
The left part of this panel is your PC’s directories and the right part is the directories of Iduino_Yun_Shield. You can upload/download files by dragging, or double click the file to edit its content.
How to reset Iduino_Yun_Shield?
Iduino_Yun_Shield has a toggle button which can be used for reset. You can press the toggle button to reset the running Iduino_Yun_Shield.
- If pressing the toggle button and release after 5 seconds, it will reset the Wifi setting and other settings will be kept.
- If pressing the toggle button and release after 30 seconds, it will reset all the settings to factory default.
How to recover the Iduino_Yun_Shield in case firmware crash?
There are some cases that the Iduino_Yun_Shield fails to boot. For example, upgrade an improper firmware or lost power during upgrade. But you are still able to recover the Iduino_Yun_Shield by using the U-boot of Iduino_Yun_Shield. An instruction in Windows is shown as below:
2.Set IP address as "192.168.255.2", Subnet mask: 255.255.255.0
3. You need firmwares called "kernel" and "root-squash", put the firmwares and "tftpd32.exe" in same folder.
4.Connect Iduino Yun Shield to computer via cable. Power Iduino Yun Shield with 9V of DC.
5.Set TPFP service:
- (1)Open "tftpd32.exe", Choose "192.168.255.2" in "Service interfaces".
- (2)Host: 192.168.255.2
- Port:6666
- Port:6666
- (3)Choose file "kernel" in "Local File".
6.Open "hercules_3-2-8.exe", set the following parameters in UDP board:
- Module IP: 192.168.255.1
- Port: 6666
- Local Port: 6666
7.Back to tftpd32, click "Put":
8.After clicking "Put", you can see "kernel" displayed in "Received data" on Hercule.
9.Access "Failsafe" mode: Disconnect the power supply for Iduino Yun Shield, keep pressing button "Failsafe". Then power Iduino Yun Shield again, you will see the LEDs of LAN,WLAN and SYS blinking at the same time. When these LEDs stop blinking, release "Failsafe".
10.Send printenv<CR> command on Hercules. "Received data" will display some information from Iduino Yun Shield as follow, if not, re-send printenv<CR>
11.Send the following commands in order, to upgrade kernel:
tftpboot 0x81000000 dragino2-yun-geeetech-v2.0.2-kernel.bin<CR>
erase 0x9fea0000 +0x140000<CR>
cp.b 0x81000000 0x9fea0000 $$filesize<CR>
12.Disconnect the power supply for Iduino Yun Shield, and back to tftpd32, click "Break":
15.Click "Put" to send file to Hercules.
16. Keep pressing "Failsafe" button on Iduino Yun Shield, power Iduino Yun Shield again, you will see LEDs of LAN,WLAN and SYS blinking at the same time. When they stop blinking, release "Failsafe" button. Iduino Yun Shield is in Failsafe mode now.
17.Send printenv<CR> command on Hercules. "Received data" will display some information from Iduino Yun Shield as follow, if not, re-send printenv<CR>
18.Send the following commands to upgrade rootfs:
tftpboot 0x81000000 dragino2-yun-geeetech-v2.0.2-rootfs-squashfs.bin<CR>
erase 0x9f050000 +0xe50000<CR>
cp.b 0x81000000 0x9f050000 $$filesize<CR>
19.Send the following command to reset Iduino Yun Shield.
reset<CR>
Relevant file:
http://www.geeetech.com/wiki/images/4/41/How_to_recover_Iduino_Yun_Shield.rar
- Warning: User should use correct address in the erase and cp.b. Wrong address may destroy the boot-loader of Iduino_Yun_Shield and the device won’t boot anymore, or destroy the radio data leading to a poor Wifi performance or incorrect MAC address.
Recover in Linux is similar with Windows. The different is that the tool used in Linux is nc, namely nc-kul6666. The figure below shows that the Iduino_Yun_Shield has been in Failsafe mode and detected by nc.
[[File:Reset firmware.png|reset firmware]
How to get it
Click here to buy: iduino Yun Shield